Skip to content

Commit 50370b4

Browse files
committed
update readme
1 parent 62779b3 commit 50370b4

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

README.rst

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,11 @@ individual components.
1616
* hn.suffix
1717
* hn.nickname
1818

19-
Supports 3 different comma placement variations in the input string.
19+
Supported Name Structures
20+
~~~~~~~~~~~~~~~~~~~~~~~~~
21+
22+
The supported name structure is generally "Title First Middle Last Suffix", where all pieces
23+
are optional. Comma-separated format like "Last, First" is also supported.
2024

2125
1. Title Firstname "Nickname" Middle Middle Lastname Suffix
2226
2. Lastname [Suffix], Title Firstname (Nickname) Middle Middle[,] Suffix [, Suffix]
@@ -33,7 +37,7 @@ of names that are all upper- or lowercase names.
3337

3438
It attempts the best guess that can be made with a simple, rule-based approach.
3539
Its main use case is English and it is not likely to be useful for languages
36-
that do not share the same structure as English names. It's not perfect, but it
40+
that do not conform to the supported name structure. It's not perfect, but it
3741
gets you pretty far.
3842

3943
Installation
@@ -73,6 +77,8 @@ Quick Start Example
7377
'de la Vega'
7478
>>> name.as_dict()
7579
{'last': 'de la Vega', 'suffix': 'III', 'title': 'Dr.', 'middle': 'Q. Xavier', 'nickname': 'Doc Vega', 'first': 'Juan'}
80+
>>> str(name)
81+
'Dr. Juan Q. Xavier de la Vega III (Doc Vega)'
7682
>>> name.string_format = "{first} {last}"
7783
>>> str(name)
7884
'Juan de la Vega'

0 commit comments

Comments
 (0)