persian-names
A Python package for generating random Persian (Farsi) names.
This package generates frequently logical names (a mix of popular Persian and Arabic names with common Persian family name suffixes).
Note: persian-names generates 90,000,000 unique full names (As Iran population in 2024) in less than 3 minutes.
Installation
Install from PyPI with pip by typing in your favorite terminal:
pip install persian-names
Usage
Let's take a look at what an example test case would look like using persian-names.
Generate Persian Full Names in Farsi:
from persian_names import fullname_fa
fullname_fa('male') # or fullname_fa('m')
fullname_fa('female') # or fullname_fa('f')
fullname_fa('random') # or fullname_fa('r')
Example:
from persian_names import fullname_fa
print(fullname_fa('m')) # اشکان محمدرضائیان
print(fullname_fa('f')) # مهسا امیری تهرانی
print(fullname_fa('r')) # بیتا خسروی راد
Generate Persian Full Names in English:
from persian_names import fullname_en
fullname_en('male') # or fullname_en('m')
fullname_en('female') # or fullname_en('f')
fullname_en('random') # or fullname_en('r')
Example:
from persian_names import fullname_en
print(fullname_en('m')) # Arsalan Mohammadi
print(fullname_en('f')) # Sara Alipour
print(fullname_en('r')) # Danial Ferdosi Khorasani
Generate First Names and Last Names in Farsi:
from persian_names import *
# First Name
firstname_fa('male') # or firstname_fa('m')
firstname_fa('female') # or firstname_fa('f')
firstname_fa('random') # or firstname_fa('r')
# Last Name
lastname_fa()
Example:
from persian_names import *
print(firstname_fa('m')) # آرمان
print(firstname_fa('f')) # ساحل
print(firstname_fa('r')) # علیرضا
print(lastname_fa()) # شیخ اسماعیلی
Generate First Names and Last Names in English:
from persian_names import *
# First Name
firstname_en('male') # or firstname_en('m')
firstname_en('female') # or firstname_en('f')
firstname_en('random') # or firstname_en('r')
# Last Name
lastname_en()
Example:
from persian_names import *
print(firstname_en('m')) # Mehrad
print(firstname_en('f')) # Darya
print(firstname_en('r')) # Baran
print(lastname_en()) # Bakhtiarizadeh
Issues
Feel free to submit issues and enhancement requests.
Contributing
Feel free to contribute names database with your kindly pull requests.
License
persian-names is available under the MIT license.
Metadata
Release files for persian-names 1.5.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| persian-names-1.5.1.tar.gz | 13.9 kB | Without provenance | Details for persian-names-1.5.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| persian_names-1.5.1-py3-none-any.whl | Python 3 | none | any | Details for persian_names-1.5.1-py3-none-any.whl |
Total release size: 36.4 kB
Release files / persian-names-1.5.1.tar.gz
| Download URL | persian-names-1.5.1.tar.gz |
|---|---|
| Size | 13.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1a1e7636cbcfffe6ba83c432a9aca49b6ebcb7bc9d7a7c788bfc0fa46db87ad7
|
|
BLAKE2b-256 checksum How to use checksums |
726a811a754764deaa3fb6deed9127346b110fd88cf4c6830026830c1d673c36
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.11.5
|
Release files / persian_names-1.5.1-py3-none-any.whl
| Download URL | persian_names-1.5.1-py3-none-any.whl |
|---|---|
| Size | 22.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
412202569e0e99046e312612aaa8055d925c5270ba196a4688f4027b1c12f0aa
|
|
BLAKE2b-256 checksum How to use checksums |
e72eed2630cf772a2ff663dd2271221e35082826414525a4609c3bff3d6377bf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.11.5
|
Security for persian-names 1.5.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.