Panlingo.LanguageIdentification.FastText.Native
0.0.0.20
See the version list below for details.
dotnet add package Panlingo.LanguageIdentification.FastText.Native --version 0.0.0.20
NuGet\Install-Package Panlingo.LanguageIdentification.FastText.Native -Version 0.0.0.20
<PackageReference Include="Panlingo.LanguageIdentification.FastText.Native" Version="0.0.0.20" />
paket add Panlingo.LanguageIdentification.FastText.Native --version 0.0.0.20
#r "nuget: Panlingo.LanguageIdentification.FastText.Native, 0.0.0.20"
// Install Panlingo.LanguageIdentification.FastText.Native as a Cake Addin #addin nuget:?package=Panlingo.LanguageIdentification.FastText.Native&version=0.0.0.20 // Install Panlingo.LanguageIdentification.FastText.Native as a Cake Tool #tool nuget:?package=Panlingo.LanguageIdentification.FastText.Native&version=0.0.0.20
Panlingo.LanguageIdentification.FastText
Welcome to Panlingo.LanguageIdentification.FastText, a .NET wrapper for the FastText library by Facebook AI Research (FAIR). This package seamlessly integrates language identification capabilities into .NET applications, leveraging the powerful and efficient FastText library to recognize and classify texts in multiple languages. Ideal for applications that require fast and accurate language detection.
Requirements
- Runtime: .NET >= 5.0
- OS: Linux
- Arch: AMD64
Installation
To integrate the FastText functionality, follow these steps:
Install the NuGet package:
dotnet add package Panlingo.LanguageIdentification.FastText
Download the Pretrained Models:
Depending on your needs, download one of the pretrained language identification (LID) models provided by Facebook:
For the LID model with 176 languages:
curl --location -o /models/fasttext176.bin https://dl.fbaipublicfiles.com/fasttext/supervised-models/lid.176.bin
For the LID model with 217 languages:
curl --location -o /models/fasttext217.bin https://huggingface.co/facebook/fasttext-language-identification/resolve/main/model.bin?download=true
Learn more about these models here:
Usage
Integrating the FastText library into your .NET application is straightforward. Here’s a quick guide to get you started:
- Install the Package: Ensure you have added the
Panlingo.LanguageIdentification.FastText
package to your project using the provided installation command. - Download the Models: Follow the provided commands to download the pretrained language identification models.
- Initialize the Library: Follow the example snippet to initialize and use the FastText library for detecting languages.
using Panlingo.LanguageIdentification.FastText;
class Program
{
static void Main()
{
using var fastText = new FastTextDetector();
fastText.LoadModel("/models/fasttext217.bin");
var predictions = fastText.Predict(
text: "Привіт, як справи?",
count: 10
);
foreach (var prediction in predictions)
{
Console.WriteLine($"{prediction.Label}: {prediction.Probability}");
}
var dimensions = fastText.GetModelDimensions();
var labels = fastText.GetLabels();
}
}
Alternatives
If you are exploring other options, here are some alternatives to consider:
- theolivenbaum/fastText: An unmaintained wrapper for .NET.
- olegtarasov/FastText.NetWrapper: Another unmaintained wrapper for .NET.
Sources
- Original FastText Repository
- Enriching Word Vectors with Subword Information
- Language identification at Wikipedia
We value your feedback. Feel free to open issues or contribute to the repository. Let’s make language detection in .NET even more powerful and versatile! 🌍📝
Happy coding! 👩💻👨💻
Stay updated by following our repository. For any inquiries or support, reach out through the issues page.
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 was computed. 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. |
.NET Core | netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.1 is compatible. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | 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.1
- No dependencies.
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Panlingo.LanguageIdentification.FastText.Native:
Package | Downloads |
---|---|
Panlingo.LanguageIdentification.FastText
This is a .NET wrapper for the FastText library by Facebook AI Research (FAIR). This package facilitates the integration of language identification capabilities into .NET applications, leveraging the powerful and efficient FastText library to recognize and classify texts in multiple languages. Ideal for applications that require fast and accurate language detection. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
0.2.0 | 133 | 11/10/2024 |
0.1.1 | 213 | 10/22/2024 |
0.1.0 | 129 | 10/7/2024 |
0.0.0.22 | 179 | 9/22/2024 |
0.0.0.21 | 153 | 9/10/2024 |
0.0.0.20 | 144 | 9/8/2024 |
0.0.0.19 | 132 | 9/1/2024 |
0.0.0.18 | 134 | 8/26/2024 |
0.0.0.17 | 169 | 8/21/2024 |
0.0.0.16 | 160 | 8/9/2024 |
0.0.0.15 | 124 | 8/8/2024 |
0.0.0.14 | 101 | 8/3/2024 |
0.0.0.13 | 111 | 8/1/2024 |
0.0.0.12 | 124 | 7/20/2024 |
0.0.0.10 | 123 | 7/14/2024 |
- Initial release