sidx 0.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- sidx-0.0.1/LICENSE +21 -0
- sidx-0.0.1/PKG-INFO +98 -0
- sidx-0.0.1/README.md +78 -0
- sidx-0.0.1/pyproject.toml +77 -0
- sidx-0.0.1/pyproject.toml.orig +75 -0
- sidx-0.0.1/src/sidx/__init__.py +1 -0
- sidx-0.0.1/src/sidx/py.typed +0 -0
sidx-0.0.1/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Andy Tseng
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
sidx-0.0.1/PKG-INFO
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: sidx
|
|
3
|
+
Version: 0.0.1
|
|
4
|
+
Summary: A multi-stage agentic framework for extracting structured data from documents
|
|
5
|
+
Keywords: llm,agents,data-extraction,document-extraction,pydantic-ai,docling
|
|
6
|
+
Author: Andy Tseng
|
|
7
|
+
License-Expression: MIT
|
|
8
|
+
License-File: LICENSE
|
|
9
|
+
Classifier: Development Status :: 2 - Pre-Alpha
|
|
10
|
+
Classifier: Intended Audience :: Developers
|
|
11
|
+
Classifier: Programming Language :: Python :: 3
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
13
|
+
Classifier: Typing :: Typed
|
|
14
|
+
Requires-Dist: docling>=2.151.1
|
|
15
|
+
Requires-Dist: pydantic-ai>=2.71.0
|
|
16
|
+
Requires-Python: >=3.13
|
|
17
|
+
Project-URL: Homepage, https://github.com/ohandyya/self-improving-data-extraction
|
|
18
|
+
Project-URL: Repository, https://github.com/ohandyya/self-improving-data-extraction
|
|
19
|
+
Description-Content-Type: text/markdown
|
|
20
|
+
|
|
21
|
+
# sidx
|
|
22
|
+
|
|
23
|
+
**S**elf-**i**mproving **d**ata e**x**traction: a multi-stage agentic framework
|
|
24
|
+
for extracting structured data from documents, built on
|
|
25
|
+
[PydanticAI](https://ai.pydantic.dev) and
|
|
26
|
+
[Docling](https://github.com/docling-project/docling).
|
|
27
|
+
|
|
28
|
+
> **Work in progress.** There is no extraction code yet. The design is being
|
|
29
|
+
> written in [`docs/design/`](./docs/design/).
|
|
30
|
+
|
|
31
|
+
The first source documents are 401(k) basic plan documents from three
|
|
32
|
+
providers. Each one lays out the same material differently, which makes them
|
|
33
|
+
a test of whether extraction holds up across layouts. See
|
|
34
|
+
[`resources/plan_documents/`](./resources/plan_documents/README.md).
|
|
35
|
+
|
|
36
|
+
## Setup
|
|
37
|
+
|
|
38
|
+
Requires [uv](https://docs.astral.sh/uv/). Python 3.13 is installed by uv if
|
|
39
|
+
you don't have it.
|
|
40
|
+
|
|
41
|
+
```sh
|
|
42
|
+
uv sync # install dependencies into .venv
|
|
43
|
+
make hooks # install the pre-commit hook, once per clone
|
|
44
|
+
uv run python scripts/download_plan_documents.py # fetch the source PDFs
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
The source PDFs are copyrighted by their publishers, so they are not committed
|
|
48
|
+
here. The download script fetches each one from its original URL and checks it
|
|
49
|
+
against a pinned SHA-256.
|
|
50
|
+
|
|
51
|
+
To call a model, copy `.env.example` to `.env` and fill in the values. Each
|
|
52
|
+
variable is described in `.env.example`.
|
|
53
|
+
|
|
54
|
+
## Development
|
|
55
|
+
|
|
56
|
+
```sh
|
|
57
|
+
make help # list every target
|
|
58
|
+
make check-all # ruff lint, ruff format check, pyright — what CI runs
|
|
59
|
+
make fix # auto-fix lint errors
|
|
60
|
+
make format # reformat code
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
[`CONTRIBUTING.md`](./CONTRIBUTING.md) covers the PR checklist and how releases
|
|
64
|
+
are published to PyPI.
|
|
65
|
+
|
|
66
|
+
| Path | What's there |
|
|
67
|
+
|---|---|
|
|
68
|
+
| `src/sidx/` | The package (`import sidx`) |
|
|
69
|
+
| `scripts/` | One-off tooling, such as the PDF download script |
|
|
70
|
+
| `resources/plan_documents/` | Source documents (downloaded, not committed) and notes on them |
|
|
71
|
+
| `docs/design/` | How the system is meant to work — the spec |
|
|
72
|
+
| `docs/implementations/` | The build plan, one doc per PR |
|
|
73
|
+
|
|
74
|
+
## Cutting a release
|
|
75
|
+
|
|
76
|
+
Releases are published to PyPI by GitHub Actions, never from a laptop.
|
|
77
|
+
|
|
78
|
+
1. **Check you're ready.** From an up-to-date `main` with a clean working tree:
|
|
79
|
+
|
|
80
|
+
```sh
|
|
81
|
+
git switch main && git pull
|
|
82
|
+
make release-check # add VERSION=X.Y.Z to check that version is free
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
It changes nothing. Fix any `FAIL` line before going on.
|
|
86
|
+
|
|
87
|
+
2. **Run the release.** In Claude Code, run `/create-new-release`. It proposes
|
|
88
|
+
the next version for you to confirm, merges a release PR with the version
|
|
89
|
+
bump and changelog, tags it, publishes the GitHub release, and checks that
|
|
90
|
+
PyPI has the new version.
|
|
91
|
+
|
|
92
|
+
The one-time PyPI and GitHub setup, and how to release by hand, are in
|
|
93
|
+
[`CONTRIBUTING.md`](./CONTRIBUTING.md#releasing).
|
|
94
|
+
|
|
95
|
+
## License
|
|
96
|
+
|
|
97
|
+
[MIT](./LICENSE), covering the code and docs in this repo. The plan document
|
|
98
|
+
PDFs belong to their respective publishers and are not covered by it.
|
sidx-0.0.1/README.md
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# sidx
|
|
2
|
+
|
|
3
|
+
**S**elf-**i**mproving **d**ata e**x**traction: a multi-stage agentic framework
|
|
4
|
+
for extracting structured data from documents, built on
|
|
5
|
+
[PydanticAI](https://ai.pydantic.dev) and
|
|
6
|
+
[Docling](https://github.com/docling-project/docling).
|
|
7
|
+
|
|
8
|
+
> **Work in progress.** There is no extraction code yet. The design is being
|
|
9
|
+
> written in [`docs/design/`](./docs/design/).
|
|
10
|
+
|
|
11
|
+
The first source documents are 401(k) basic plan documents from three
|
|
12
|
+
providers. Each one lays out the same material differently, which makes them
|
|
13
|
+
a test of whether extraction holds up across layouts. See
|
|
14
|
+
[`resources/plan_documents/`](./resources/plan_documents/README.md).
|
|
15
|
+
|
|
16
|
+
## Setup
|
|
17
|
+
|
|
18
|
+
Requires [uv](https://docs.astral.sh/uv/). Python 3.13 is installed by uv if
|
|
19
|
+
you don't have it.
|
|
20
|
+
|
|
21
|
+
```sh
|
|
22
|
+
uv sync # install dependencies into .venv
|
|
23
|
+
make hooks # install the pre-commit hook, once per clone
|
|
24
|
+
uv run python scripts/download_plan_documents.py # fetch the source PDFs
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
The source PDFs are copyrighted by their publishers, so they are not committed
|
|
28
|
+
here. The download script fetches each one from its original URL and checks it
|
|
29
|
+
against a pinned SHA-256.
|
|
30
|
+
|
|
31
|
+
To call a model, copy `.env.example` to `.env` and fill in the values. Each
|
|
32
|
+
variable is described in `.env.example`.
|
|
33
|
+
|
|
34
|
+
## Development
|
|
35
|
+
|
|
36
|
+
```sh
|
|
37
|
+
make help # list every target
|
|
38
|
+
make check-all # ruff lint, ruff format check, pyright — what CI runs
|
|
39
|
+
make fix # auto-fix lint errors
|
|
40
|
+
make format # reformat code
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
[`CONTRIBUTING.md`](./CONTRIBUTING.md) covers the PR checklist and how releases
|
|
44
|
+
are published to PyPI.
|
|
45
|
+
|
|
46
|
+
| Path | What's there |
|
|
47
|
+
|---|---|
|
|
48
|
+
| `src/sidx/` | The package (`import sidx`) |
|
|
49
|
+
| `scripts/` | One-off tooling, such as the PDF download script |
|
|
50
|
+
| `resources/plan_documents/` | Source documents (downloaded, not committed) and notes on them |
|
|
51
|
+
| `docs/design/` | How the system is meant to work — the spec |
|
|
52
|
+
| `docs/implementations/` | The build plan, one doc per PR |
|
|
53
|
+
|
|
54
|
+
## Cutting a release
|
|
55
|
+
|
|
56
|
+
Releases are published to PyPI by GitHub Actions, never from a laptop.
|
|
57
|
+
|
|
58
|
+
1. **Check you're ready.** From an up-to-date `main` with a clean working tree:
|
|
59
|
+
|
|
60
|
+
```sh
|
|
61
|
+
git switch main && git pull
|
|
62
|
+
make release-check # add VERSION=X.Y.Z to check that version is free
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
It changes nothing. Fix any `FAIL` line before going on.
|
|
66
|
+
|
|
67
|
+
2. **Run the release.** In Claude Code, run `/create-new-release`. It proposes
|
|
68
|
+
the next version for you to confirm, merges a release PR with the version
|
|
69
|
+
bump and changelog, tags it, publishes the GitHub release, and checks that
|
|
70
|
+
PyPI has the new version.
|
|
71
|
+
|
|
72
|
+
The one-time PyPI and GitHub setup, and how to release by hand, are in
|
|
73
|
+
[`CONTRIBUTING.md`](./CONTRIBUTING.md#releasing).
|
|
74
|
+
|
|
75
|
+
## License
|
|
76
|
+
|
|
77
|
+
[MIT](./LICENSE), covering the code and docs in this repo. The plan document
|
|
78
|
+
PDFs belong to their respective publishers and are not covered by it.
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "sidx"
|
|
3
|
+
version = "0.0.1"
|
|
4
|
+
description = "A multi-stage agentic framework for extracting structured data from documents"
|
|
5
|
+
readme = "README.md"
|
|
6
|
+
requires-python = ">=3.13"
|
|
7
|
+
license = "MIT"
|
|
8
|
+
license-files = ["LICENSE"]
|
|
9
|
+
keywords = [
|
|
10
|
+
"llm",
|
|
11
|
+
"agents",
|
|
12
|
+
"data-extraction",
|
|
13
|
+
"document-extraction",
|
|
14
|
+
"pydantic-ai",
|
|
15
|
+
"docling",
|
|
16
|
+
]
|
|
17
|
+
classifiers = [
|
|
18
|
+
"Development Status :: 2 - Pre-Alpha",
|
|
19
|
+
"Intended Audience :: Developers",
|
|
20
|
+
"Programming Language :: Python :: 3",
|
|
21
|
+
"Programming Language :: Python :: 3.13",
|
|
22
|
+
"Typing :: Typed",
|
|
23
|
+
]
|
|
24
|
+
dependencies = [
|
|
25
|
+
"docling>=2.151.1",
|
|
26
|
+
"pydantic-ai>=2.71.0",
|
|
27
|
+
]
|
|
28
|
+
|
|
29
|
+
[[project.authors]]
|
|
30
|
+
name = "Andy Tseng"
|
|
31
|
+
|
|
32
|
+
[project.urls]
|
|
33
|
+
Homepage = "https://github.com/ohandyya/self-improving-data-extraction"
|
|
34
|
+
Repository = "https://github.com/ohandyya/self-improving-data-extraction"
|
|
35
|
+
|
|
36
|
+
[build-system]
|
|
37
|
+
requires = ["uv_build>=0.11.6,<0.12.0"]
|
|
38
|
+
build-backend = "uv_build"
|
|
39
|
+
|
|
40
|
+
[dependency-groups]
|
|
41
|
+
dev = [
|
|
42
|
+
"pre-commit>=4.7.0",
|
|
43
|
+
"pyright>=1.1.414",
|
|
44
|
+
"ruff>=0.17.6",
|
|
45
|
+
]
|
|
46
|
+
|
|
47
|
+
[tool.ruff]
|
|
48
|
+
line-length = 100
|
|
49
|
+
target-version = "py313"
|
|
50
|
+
|
|
51
|
+
[tool.ruff.format]
|
|
52
|
+
exclude = ["*.md"]
|
|
53
|
+
|
|
54
|
+
[tool.ruff.lint]
|
|
55
|
+
select = [
|
|
56
|
+
"E",
|
|
57
|
+
"W",
|
|
58
|
+
"F",
|
|
59
|
+
"I",
|
|
60
|
+
"UP",
|
|
61
|
+
"B",
|
|
62
|
+
"C4",
|
|
63
|
+
"SIM",
|
|
64
|
+
]
|
|
65
|
+
|
|
66
|
+
[tool.ruff.lint.isort]
|
|
67
|
+
known-first-party = ["sidx"]
|
|
68
|
+
|
|
69
|
+
[tool.pyright]
|
|
70
|
+
include = [
|
|
71
|
+
"src",
|
|
72
|
+
"scripts",
|
|
73
|
+
]
|
|
74
|
+
venvPath = "."
|
|
75
|
+
venv = ".venv"
|
|
76
|
+
pythonVersion = "3.13"
|
|
77
|
+
typeCheckingMode = "standard"
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "sidx"
|
|
3
|
+
version = "0.0.1"
|
|
4
|
+
description = "A multi-stage agentic framework for extracting structured data from documents"
|
|
5
|
+
readme = "README.md"
|
|
6
|
+
requires-python = ">=3.13"
|
|
7
|
+
license = "MIT"
|
|
8
|
+
license-files = ["LICENSE"]
|
|
9
|
+
authors = [{ name = "Andy Tseng" }]
|
|
10
|
+
keywords = ["llm", "agents", "data-extraction", "document-extraction", "pydantic-ai", "docling"]
|
|
11
|
+
classifiers = [
|
|
12
|
+
# Pre-Alpha while there is no extraction code; move to "3 - Alpha" with the first usable one.
|
|
13
|
+
"Development Status :: 2 - Pre-Alpha",
|
|
14
|
+
"Intended Audience :: Developers",
|
|
15
|
+
"Programming Language :: Python :: 3",
|
|
16
|
+
"Programming Language :: Python :: 3.13",
|
|
17
|
+
"Typing :: Typed",
|
|
18
|
+
]
|
|
19
|
+
dependencies = [
|
|
20
|
+
"docling>=2.151.1",
|
|
21
|
+
"pydantic-ai>=2.71.0",
|
|
22
|
+
]
|
|
23
|
+
|
|
24
|
+
[project.urls]
|
|
25
|
+
Homepage = "https://github.com/ohandyya/self-improving-data-extraction"
|
|
26
|
+
Repository = "https://github.com/ohandyya/self-improving-data-extraction"
|
|
27
|
+
|
|
28
|
+
[build-system]
|
|
29
|
+
# uv_build is allowlist-based, not gitignore-based: it ships `src/sidx/` plus README.md,
|
|
30
|
+
# LICENSE, and pyproject.toml, nothing else. The copyrighted plan PDFs in resources/ stay out of
|
|
31
|
+
# every release because they were never included. Widening that is opt-in via
|
|
32
|
+
# `[tool.uv.build-backend]`, so leave that section out. `make build` lists what ships.
|
|
33
|
+
requires = ["uv_build>=0.11.6,<0.12.0"]
|
|
34
|
+
build-backend = "uv_build"
|
|
35
|
+
|
|
36
|
+
[dependency-groups]
|
|
37
|
+
dev = [
|
|
38
|
+
"pre-commit>=4.7.0",
|
|
39
|
+
"pyright>=1.1.414",
|
|
40
|
+
"ruff>=0.17.6",
|
|
41
|
+
]
|
|
42
|
+
|
|
43
|
+
[tool.ruff]
|
|
44
|
+
line-length = 100
|
|
45
|
+
# Matches `requires-python`, so pyupgrade (UP) never rewrites code into syntax newer than the
|
|
46
|
+
# floor this project supports.
|
|
47
|
+
target-version = "py313"
|
|
48
|
+
|
|
49
|
+
[tool.ruff.format]
|
|
50
|
+
# Python code blocks in Markdown are illustrative prose in docs/; only `.py` files are formatted.
|
|
51
|
+
exclude = ["*.md"]
|
|
52
|
+
|
|
53
|
+
[tool.ruff.lint]
|
|
54
|
+
select = [
|
|
55
|
+
"E", # pycodestyle errors
|
|
56
|
+
"W", # pycodestyle warnings
|
|
57
|
+
"F", # pyflakes
|
|
58
|
+
"I", # isort
|
|
59
|
+
"UP", # pyupgrade
|
|
60
|
+
"B", # flake8-bugbear
|
|
61
|
+
"C4", # flake8-comprehensions
|
|
62
|
+
"SIM", # flake8-simplify
|
|
63
|
+
]
|
|
64
|
+
|
|
65
|
+
[tool.ruff.lint.isort]
|
|
66
|
+
known-first-party = ["sidx"]
|
|
67
|
+
|
|
68
|
+
[tool.pyright]
|
|
69
|
+
# Every Python file in the repo. Add `tests` here when it appears.
|
|
70
|
+
include = ["src", "scripts"]
|
|
71
|
+
venvPath = "."
|
|
72
|
+
venv = ".venv"
|
|
73
|
+
# Same floor as ruff's target-version: check against the oldest interpreter we claim to support.
|
|
74
|
+
pythonVersion = "3.13"
|
|
75
|
+
typeCheckingMode = "standard"
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""A multi-stage agentic framework for extracting structured data from documents."""
|
|
File without changes
|