Catalog PyPI
Back to packageRELEASE DETAILS

0.1.0

PyPI

affiliation-regex-parser

Regex-based parser for structuring academic author affiliation strings.

academiaaffiliationmetadatanlpparserregex
Published14 Dec 2025
Direct dependencies3
Transitive dependenciesNot calculated

README

Version 0.1.0 documentation

Affiliation Regex Parser

A lightweight, regex-based Python library for parsing academic author affiliation strings into structured fields (departments, institutes, universities, organizations, cities, countries, emails, postcodes, and unknown segments).

Examples and usage patterns are documented in cookbook.ipynb.

Install

Core install:

pip install affiliation-regex-parser

Optional Excel support (for worldcities.xlsx-based city→country inference):

pip install affiliation-regex-parser[excel]

Features

  • Regex-first, deterministic parsing (no ML dependencies).
  • Pluggable architecture via providers (e.g., custom city lists, custom inference).
  • Optional city→country inference using a world cities dataset.
  • Designed for batch parsing (reuse one parser instance).

Data attribution (worldcities.xlsx)

This project can use a worldcities.xlsx dataset sourced from SimpleMaps World Cities (free version), licensed under Creative Commons Attribution 4.0 (CC BY 4.0).

Source:

https://simplemaps.com/data/world-cities

If you redistribute the dataset with this package, ensure attribution is preserved per CC BY 4.0.

Documentation

  • See cookbook.ipynb for practical examples and common configurations.
  • See the docstrings in AffiliationRegexParser and provider classes for API details.

License

MIT License. See LICENSE.

Project status

This package is under active development; the public API aims to remain stable, but outputs may improve over time as patterns and fixtures evolve.

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 3

Native requirements
3 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
flashtext
Environment
{
  "extras": "",
  "marker": null,
  "requires_python": ">=3.10",
  "evaluation": "NOT_EVALUATED"
}
flashtext>=2.7runtime
pandas
Environment
{
  "extras": "",
  "marker": "extra == \"excel\"",
  "requires_python": ">=3.10",
  "evaluation": "NOT_EVALUATED"
}
pandas>=2.0; extra == "excel"runtime
openpyxl
Environment
{
  "extras": "",
  "marker": "extra == \"excel\"",
  "requires_python": ">=3.10",
  "evaluation": "NOT_EVALUATED"
}
openpyxl>=3.1; extra == "excel"runtime

Distribution files

2 collected
affiliation_regex_parser-0.1.0-py3-none-any.whl

bdist_wheel · 3,427.17 KB · Python py3

Source file
affiliation_regex_parser-0.1.0.tar.gz

sdist · 3,423.67 KB · Python source

Source file

Repository

PENDING
ehsanbitaraf/affiliation-regex-parser

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 21:03 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:b0ceba2b960a0ad438c008f439857d1e2b78a24efdc190c6e1e9d309830e9a1e

Other collected versions

View all collected versions →