NOpenNLP.Tools
1.9.5-beta.2
dotnet add package NOpenNLP.Tools --version 1.9.5-beta.2
NuGet\Install-Package NOpenNLP.Tools -Version 1.9.5-beta.2
<PackageReference Include="NOpenNLP.Tools" Version="1.9.5-beta.2" />
<PackageVersion Include="NOpenNLP.Tools" Version="1.9.5-beta.2" />
<PackageReference Include="NOpenNLP.Tools" />
paket add NOpenNLP.Tools --version 1.9.5-beta.2
#r "nuget: NOpenNLP.Tools, 1.9.5-beta.2"
#:package NOpenNLP.Tools@1.9.5-beta.2
#addin nuget:?package=NOpenNLP.Tools&version=1.9.5-beta.2&prerelease
#tool nuget:?package=NOpenNLP.Tools&version=1.9.5-beta.2&prerelease
NOpenNLP.Tools
A C# port of Apache OpenNLP 1.9.5 — a machine learning toolkit for natural language processing.
This package is the port of the opennlp-tools module: inference, training,
evaluation and the corpus format readers. For the command line tools, install
NOpenNLP.Cli instead.
The API reference and guides are at nopennlp.github.io/nopennlp.
Usage
Targets net10.0, net8.0, and netstandard2.0. The only runtime dependency is
J2N.
using NOpenNLP.Tools.Tokenize;
var tokens = SimpleTokenizer.INSTANCE.Tokenize("Hello, world!");
// ["Hello", ",", "world", "!"]
Types and members keep their upstream OpenNLP names so that the Java
documentation and examples carry over directly, with .NET casing conventions
applied (TokenizerME.tokenize becomes TokenizerME.Tokenize).
Models are the ones Apache OpenNLP publishes; this port loads the same binary format:
using NOpenNLP.Tools.Tokenize;
using var stream = File.OpenRead("en-token.bin");
var tokenizer = new TokenizerME(new TokenizerModel(stream));
var tokens = tokenizer.Tokenize("Dr. Smith went to Washington.");
What is included
| Included | Not yet ported |
|---|---|
| Tokenization, sentence detection, POS tagging | eval tests |
| Lemmatization, chunking, name finding (NER) | Morfologik addon |
| Language detection, document categorization | brat annotator service |
| Maxent / Perceptron / Naive Bayes inference | |
| Model loading and feature generation | |
| Parsing, entity linking, word vectors | |
| Porter and Snowball stemmers | |
| Corpus format readers and converters | |
| Model training, evaluation, cross validation |
Note: the UIMA library (opennlp-uima upstream) will likely never be ported.
There is no .NET port of UIMA (which is also not a goal of this project),
and there only seems to be some casual and research interest in creating one.
Status
Work in progress. Prerelease versions may make breaking changes as the port works toward a complete 1.9.5.
Source, issues and contributing guidelines are at github.com/nopennlp/nopennlp.
Attribution
This product contains a modified C# port of Apache OpenNLP 1.9.5, specifically
the opennlp-tools module. The original Java source is:
Apache OpenNLP Copyright 2017 The Apache Software Foundation
The ported source has been modified from the original: translated from Java to
C#, renamed to the NOpenNLP.Tools namespace, and adapted to .NET idioms and
APIs. Ported files carry the original Apache Software Foundation license header
along with a note marking them as modified. See the NOTICE file in this package
for details.
NOpenNLP is not affiliated with, endorsed by, or a product of The Apache Software Foundation.
License
Licensed under the Apache License, Version 2.0.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- J2N (>= 2.2.0-alpha-0053)
- Microsoft.Bcl.HashCode (>= 6.0.0)
- Microsoft.Bcl.Memory (>= 10.0.10)
- PolySharp (>= 1.16.0)
-
net10.0
- J2N (>= 2.2.0-alpha-0053)
-
net8.0
- J2N (>= 2.2.0-alpha-0053)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.9.5-beta.2 | 89 | 9/9/2026 |
| 1.9.5-beta.1 | 70 | 9/9/2026 |