Git Product home page Git Product logo

nameparser's Introduction

NameParser

Join the chat at https://gitter.im/binaryfog/NameParser

Parses names using English conventions for persons names. Intended to be extendable, the library can be extended just by implement IFullNamePattern interface and assign a score to the returned result.

For the sake of performance, the assembly and types implementing IFullNamePattern must be loaded before the first attempt to use the NameParser.

If you have a person name that is not parsed correctly, please post a message on https://gitter.im/binaryfog/NameParser. I'll see what I can do.

Usage:

string fullName = "Mr. Jack Johnson"; 
FullNameParser target = new FullNameParser(fullName); 
target.Parse();
string firstName = target.FirstName;
string middleName = target.MiddleName;
string lastName = target.LastName;
string title = target.Title;
string nickName = target.NickName;
string suffix = target.Suffix;
string displayName = target.DisplayName;

Alternative usage:

string fullName = "Mr. Jack Johnson"; 
FullNameParser target = FullNameParser.Parse(fullName);
string firstName = target.FirstName;
string middleName = target.MiddleName;
string lastName = target.LastName;
string title = target.Title;
string nickName = target.NickName;
string suffix = target.Suffix;
string displayName = target.DisplayName;

Jun. 17, 2017: Started a new related project Nameparser.Dataset on github as a repository for names and parsed names. Feel free to add there names and parsed names.

Nov. 13 2015: More cases are now handled. These are the cases:

  • SR. John Henry William dela Vega, Jr Esq.
  • MANUEL ESQUIPULAS SOHOM
  • Maria Delores Esquivel-Moreno
  • PHILIP DEHART ESQ
  • DEHART, PHILIP
  • john 'jack' kennedy
  • john(jack) f kennedy
  • kennedy, john(jack) f
  • Mr.Jack Johnson, ESQ"
  • Jose Miguel De La Vega

Jan. 8 2016: 100% code coverage. More test cases. These are the cases:

  • Empty string and white space cases.
  • Mr. Jack Francis Van Der Waal Sr.
  • Mr. Jack Francis Marion Van Der Waal Sr.

nameparser's People

Contributors

binaryfog avatar mattglet avatar mguinness avatar gitter-badger avatar tyoung86 avatar poldey avatar

Watchers

James Cloos 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.