From 4bf6017b7b7e94abed208abd287ad0c6b9d534b7 Mon Sep 17 00:00:00 2001 From: Illiyin Date: Mon, 20 Jul 2026 21:19:07 +0500 Subject: [PATCH 1/3] Add package skeleton --- .gitignore | 138 +++++++++++++++++++++++++++++++++++++++++ pakdocling/__init__.py | 1 + pakdocling/cli.py | 12 ++++ 3 files changed, 151 insertions(+) create mode 100644 .gitignore create mode 100644 pakdocling/__init__.py create mode 100644 pakdocling/cli.py diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6339dc6 --- /dev/null +++ b/.gitignore @@ -0,0 +1,138 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +share/python-wheels/ +*.egg-info/ +.installed.cfg +*.egg +MANIFEST + +# PyInstaller +*.manifest +*.spec + +# Unit test / coverage reports +htmlcov/ +.tox/ +.nox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +*.py,cover +.hypothesis/ +.pytest_cache/ +cover/ + +# Translations +*.mo +*.pot + +# Django +*.log +local_settings.py +db.sqlite3 +db.sqlite3-journal + +# Flask +instance/ +.webassets-cache + +# Scrapy +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +.pybuilder/ +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# IPython +profile_default/ +ipython_config.py + +# pyenv +.python-version + +# pipenv +Pipfile.lock + +# poetry +poetry.lock + +# pdm +.pdm.toml +.pdm-python +.pdm-build/ + +# PEP 582 +__pypackages__/ + +# Celery +celerybeat-schedule +celerybeat.pid + +# SageMath +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ +.dmypy.json +dmypy.json + +# Pyre type checker +.pyre/ + +# pytype static type analyzer +.pytype/ + +# Cython debug symbols +cython_debug/ + +# IDEs +.idea/ +.vscode/ diff --git a/pakdocling/__init__.py b/pakdocling/__init__.py new file mode 100644 index 0000000..f102a9c --- /dev/null +++ b/pakdocling/__init__.py @@ -0,0 +1 @@ +__version__ = "0.0.1" diff --git a/pakdocling/cli.py b/pakdocling/cli.py new file mode 100644 index 0000000..78f342e --- /dev/null +++ b/pakdocling/cli.py @@ -0,0 +1,12 @@ +import typer + +app = typer.Typer() + + +@app.command() +def hello(): + typer.echo("pakdocling is installed") + + +if __name__ == "__main__": + app() From f17a8f0fd3695701814bca82f0a5e598d1fee317 Mon Sep 17 00:00:00 2001 From: Illiyin Date: Mon, 20 Jul 2026 21:22:39 +0500 Subject: [PATCH 2/3] Add project metadata --- pyproject.toml | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 pyproject.toml diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..07b0140 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,60 @@ +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[project] +name = "pakdocling" +version = "0.0.1" +description = "Structured extraction from Pakistani documents" +readme = "README.md" +license = {text = "MIT"} +requires-python = ">=3.10" +authors = [ + {name = "Epochry Lab"}, +] +keywords = ["pakistan", "documents", "ocr", "extraction", "cnic"] +classifiers = [ + "Development Status :: 2 - Pre-Alpha", + "Intended Audience :: Developers", + "License :: OSI Approved :: MIT License", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", + "Topic :: Software Development :: Libraries :: Python Modules", +] +dependencies = [ + "pydantic>=2.0", +] + +[project.optional-dependencies] +dev = [ + "pytest>=8.0", + "pytest-cov>=5.0", + "ruff>=0.5", + "mypy>=1.10", +] + +[project.scripts] +pakdocling = "pakdocling.cli:app" + +[project.urls] +Homepage = "https://github.com/Epochry-Lab/pakdocling" +Issues = "https://github.com/Epochry-Lab/pakdocling/issues" + +[tool.ruff] +target-version = "py310" +line-length = 100 + +[tool.ruff.lint] +select = ["E", "F", "I", "W"] + +[tool.mypy] +python_version = "3.10" +warn_return_any = true +warn_unused_configs = true +disallow_untyped_defs = true + +[tool.pytest.ini_options] +testpaths = ["tests"] +python_files = ["test_*.py"] \ No newline at end of file From ed2340089570f23ced43fb1302813eddf567233c Mon Sep 17 00:00:00 2001 From: Illiyin Date: Mon, 20 Jul 2026 21:27:15 +0500 Subject: [PATCH 3/3] Update CLI dependencies --- pakdocling/cli.py | 6 ++---- pyproject.toml | 2 ++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pakdocling/cli.py b/pakdocling/cli.py index 78f342e..db6b128 100644 --- a/pakdocling/cli.py +++ b/pakdocling/cli.py @@ -2,11 +2,9 @@ app = typer.Typer() - @app.command() -def hello(): +def hello() -> None: typer.echo("pakdocling is installed") - if __name__ == "__main__": - app() + app() \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 07b0140..978f2e2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -33,6 +33,8 @@ dev = [ "pytest-cov>=5.0", "ruff>=0.5", "mypy>=1.10", + "pydantic>=2.0", + "typer>=0.12", ] [project.scripts]