Skip to content

zepheira/amara3-names

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WhosWho

[PyPI version] (http://badge.fury.io/py/whoswho) [Build Status] (https://travis-ci.org/rliebz/whoswho)

A simple python library for determining whether two names describe the same person.

Installation

$ pip install whoswho

Requires Python >= 2.6 or >= 3.3 with pip.

Usage

Name Matching

In order to test two names, simply pass them in as strings or unicode.

>>> from whoswho import who
>>> who.match('Liebowitz, R.', 'Mr. Robert Evan Liebowitz')
True
>>> who.match('Robert Liebowitz, Jr.', 'Robert Liebowitz, Sr.')
False

It is possible to adjust the strictness with which names are checked

>>> who.match('R Liebowitz', 'Robert Liebowitz')
True
>>> who.match('R Liebowitz', 'Robert Liebowitz', 'strict')
False

Fuzzy Matching

WhosWho can also produce a ratio based on the percent match of two names.

>>> who.ratio('Robert Leibowitz', 'Robert Liebowitz')
93
>>> who.ratio('E. Robert Lebovich', 'Robert E. Liebowitz')
29

License

MIT licensed. See the bundled LICENSE file for more details.

About

Name comparison in python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%