Conllu 1.0.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package Conllu --version 1.0.0
                    
NuGet\Install-Package Conllu -Version 1.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Conllu" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Conllu" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Conllu" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Conllu --version 1.0.0
                    
#r "nuget: Conllu, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Conllu@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Conllu&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Conllu&version=1.0.0
                    
Install as a Cake Tool

CoNLL-U Parser in .NET Core

.NET Core

This repository contains a lightweight, well-tested CoNLL-U parser written in C# .NET Core and parses according to the CoNLL-U format as specified by Universal Dependencies.

Quick Start

CoNLL-U is available as a NuGet package. Once installed, you can start as follows:

var filePath = ...
var sentences = ConlluParser.ParseFile(filePath);

Each Sentence contains a list of Token which contain all the information as specified in the CoNLL-U format. Below is a short overview of some of the fields that are available in the Token class:

   public class Token
   {
        // CoNLL-U Properties
        int Id;
        string Form;
        string Lemma;
        string Upos;
        string Xpos;
        Dictionary<string, string> Feats;
        int? Head;
        string DepRel;
        Dictionary<TokenIdentifier, string> Deps;
        string Misc;
        
        // Other properties
        TokenIdentifier Identifier;
        string RawLine;
        bool IsMultiwordToken;
        bool IsEmptyNode;
   }

In addition, there is a TokenIdentifier class which wraps the different possibilities for word ID such as multiword tokens or empty nodes.

To-do

  • Support empty nodes
  • Add tree parsing helper functions
  • Add serialization support to generate .conllu files

License

Copyright (c) 2021 Arthur Hemmer

Distributed under the MIT License (MIT).

Product 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.  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 was computed.  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 netcoreapp3.1 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETCoreApp 3.1

    • No dependencies.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on Conllu:

Package Downloads
Chiron.Nlp

Chiron NLP-related components

Fusi.UDPipe

Minimalist API surface for https://github.com/ufal/udpipe.

Pythia.Cli.Plugin.Udp

Pythia CLI tool UDPipe plugin.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.2 727 11/19/2024
1.1.1 6,424 11/1/2021
1.1.0 701 1/31/2021
1.0.2 543 1/17/2021
1.0.1 575 1/10/2021
1.0.0 549 1/9/2021