Code Monkey home page Code Monkey logo

srx's Introduction

SRX

Crates.io Docs.rs MIT OR Apache 2.0 license

A simple and reasonably fast Rust implementation of the Segmentation Rules eXchange 2.0 standard for text segmentation. srx is not fully compliant with the standard.

This crate is intended for segmentation of plaintext so markup information (<formathandle> and segmentsubflows) is ignored.

Not complying with the SRX spec, overlapping matches of the same <rule> are not found which could lead to different behavior in a few edge cases.

A note on regular expressions

This crate uses the regex crate for parsing and executing regular expressions. The regex crate is mostly compatible with the regular expression standard from the SRX specification. However, some metacharacters such as \Q and \E are not supported.

To still be able to use files containing unsupported rules and to parse useful SRX files such as segment.srx from LanguageTool which does not comply with the standard by e. g. using look-ahead and look-behind, srx ignores <rule> elements with invalid regular expressions and provides information about them via the srx.errors() function.

srx's People

Contributors

bminixhofer avatar drahnr avatar s3bk avatar zjaume avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.