Shared DuckDB / ChunkHound index primitives: directory resolution, schema inspection, SQL-interpolation safety, vss/HNSW handling
Project description
chunkhound-index-commons
Shared DuckDB / ChunkHound primitives for tools that operate on ChunkHound index files. Nothing in this package is end-user-facing; it keeps DuckDB-string-escape, FK topological order, and HNSW metric recovery in one importable place rather than re-derived per tool.
Submodules
| Module | Owns |
|---|---|
chunkhound_index_commons.resolve |
Directory → DuckDB-file resolution for ChunkHound-shaped index directories. |
chunkhound_index_commons.schema |
DDL inspection: FK topological sort, front-gate refusal of source shapes a rebuild cannot reproduce. |
chunkhound_index_commons.sql |
DuckDB string-interpolation safety primitives (escape, quote, bare-identifier check). |
chunkhound_index_commons.vss |
vss extension loading from the bundled binary, HNSW metric capture, HNSW index recreation. |
No top-level re-exports. Import from the submodule that owns the symbol so the import line pins where the contract lives.
from chunkhound_index_commons.schema import topological_order, reject_unsupported_objects
from chunkhound_index_commons.vss import load_bundled_vss, capture_hnsw_metrics
See docs/architecture.md for why each primitive exists and which DuckDB and ChunkHound behaviors shape it. Refused source shapes, dropped metadata, and known regex gaps catalog at docs/out-of-scope.md.
Install
uv add chunkhound-index-commons
chunkhound-index-commons declares duckdb-extension-vss>=1.5.2, which transitively pins duckdb to a single file-format-compatible version. Consumers should not pin duckdb or duckdb-extension-vss themselves; commons is the single source of truth for those floors.
Versioning
SemVer. Floor bumps to duckdb or duckdb-extension-vss that move out of the previous tested range are majors; signature changes to any module export are majors; new exports are minor.
Compatibility limitations inherited from the source primitives
referenced_tablesmatches only bare identifiers; aREFERENCES "tab"(id)is missed. The motivating ChunkHound workload uses bare identifiers. (docs/out-of-scope.md §Quoted referenced tables inreferenced_tables)parse_hnsw_columntruncates expression keys (CAST(col AS FLOAT[N])). Callers that need to refuse expression keys pair it withsql.is_bare_identifier. (docs/out-of-scope.md §Expression HNSW keys)- HNSW tuning beyond
metric(M,M0,ef_construction,ef_search) is not surfaced by any pragma and is not recoverable across a rebuild. (docs/out-of-scope.md §HNSW tuning beyondmetric)
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file chunkhound_index_commons-0.1.0.tar.gz.
File metadata
- Download URL: chunkhound_index_commons-0.1.0.tar.gz
- Upload date:
- Size: 72.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
80f660aedc9723df4091d0508dc3cdac0dcb7b348353c1534ef4219bd1f4d460
|
|
| MD5 |
61731e423b4875eaf6118882897308b9
|
|
| BLAKE2b-256 |
8d0bb976e733ccdf9a5b4c4358e7028b2dfdbb5ee8987530de1ac86813993e76
|
Provenance
The following attestation bundles were made for chunkhound_index_commons-0.1.0.tar.gz:
Publisher:
release.yml on it-bens/chunkhound-index-commons
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
chunkhound_index_commons-0.1.0.tar.gz -
Subject digest:
80f660aedc9723df4091d0508dc3cdac0dcb7b348353c1534ef4219bd1f4d460 - Sigstore transparency entry: 1635257936
- Sigstore integration time:
-
Permalink:
it-bens/chunkhound-index-commons@b593e74d257af9cd0aaebe8c1590df1c07b5fc96 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/it-bens
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@b593e74d257af9cd0aaebe8c1590df1c07b5fc96 -
Trigger Event:
push
-
Statement type:
File details
Details for the file chunkhound_index_commons-0.1.0-py3-none-any.whl.
File metadata
- Download URL: chunkhound_index_commons-0.1.0-py3-none-any.whl
- Upload date:
- Size: 10.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1182e09d409424b235b161fce5992638f73a5cd47ef2bf3006f0cbc277efaa22
|
|
| MD5 |
dfc2bc91520e451f20ac23a000201e71
|
|
| BLAKE2b-256 |
dc8f7e68b99499527fde2926afd550e2805f09dd3ea4ed6f7b1902c619ca1132
|
Provenance
The following attestation bundles were made for chunkhound_index_commons-0.1.0-py3-none-any.whl:
Publisher:
release.yml on it-bens/chunkhound-index-commons
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
chunkhound_index_commons-0.1.0-py3-none-any.whl -
Subject digest:
1182e09d409424b235b161fce5992638f73a5cd47ef2bf3006f0cbc277efaa22 - Sigstore transparency entry: 1635257941
- Sigstore integration time:
-
Permalink:
it-bens/chunkhound-index-commons@b593e74d257af9cd0aaebe8c1590df1c07b5fc96 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/it-bens
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@b593e74d257af9cd0aaebe8c1590df1c07b5fc96 -
Trigger Event:
push
-
Statement type: