Meridian Storage Query
meridian-storage-query is the engine-neutral Meridian V1 query library. It provides an
immutable query AST, a mapping-first fluent API, canonical serialized Operations, capability
inference, compile/startup validation, single-Binding planning, adapter translation contracts,
and signed live-keyset cursors.
The library does not define a query Catalog. Consumers use a registered Catalog such as
structured or evidence; deployment code selects Bindings and adapters. V1 has no
NativeQuery, native-expression method, Engine selector, endpoint, or backend DSL escape hatch.
Install
python -m pip install meridian-storage-query==1.0.0
Python 3.12–3.14 is supported. Version 1.0.0 consumes the released
meridian-storage-core==1.0.0 and meridian-storage-semantics==1.0.0 contracts.
Mapping-first query
from meridian_storage.query import distance_within, field, point, query
plan = (
query("accounts.users")
.where({"status": "active", "age": {"$gte": 18}})
.select("id", "display_name")
.order_by("display_name", "id")
.page(size=50)
.build()
)
assert plan.format_version == "meridian.operation.query.v1"
Specialized clauses use the same immutable builder:
search = (
query("knowledge.documents")
.where({"visibility": "public"})
.full_text(
"storage semantics",
fields=("title", "body"),
analyzer="icu",
highlights=("body",),
ranking="bm25",
facets=("category",),
)
.build()
)
nearby = query("places.locations").where(
distance_within(field("location"), point(-122.4, 37.8), 1_000)
).build()
For spatial predicates, use point, distance, or distance_within; for time-series windows,
use time_range. Aggregation uses group_by and measure. traverse accepts either an explicit
closed relation-Collection set or all_neighbors=True, which must be resolved against a captured
registry fingerprint before execution.
Public pipeline
Catalog Expression
-> normalized QueryOperation
-> Schema/Resource/Binding validation
-> inferred RequirementGraph
-> NATIVE | EXACT_REWRITE | BOUNDED_RESIDUAL | REJECTED
-> adapter-owned parameterized compilation
-> normalized Data and signed cursor
validate_compile resolves exact Schemas, rejects cross-Binding plans, injects a deterministic
identity tie-breaker, checks logical types and semantic profiles, and enforces a registered
workload budget. validate_startup compares declared deployment requirements with authenticated
Core capability manifests. QueryPlanner never silently broadens an unsupported query into a
scan: rewrites require a registered equivalence and residuals require explicit row/byte bounds
plus a proof function.
Adapter repositories implement QueryTranslator. Its input is a validated PlannedQuery and a
logical TranslationContext; connection and Engine state remain private to the adapter.
enforce_result_budget applies the validated value/byte limits after result normalization.
Pagination and diagnostics
CursorSigner issues opaque HMAC-SHA256 cursors bound to the plan, exact Schema fingerprints,
registry fingerprint when applicable, scope fingerprint, unique sort tuple, page size, issuance,
and expiry. Key rotation accepts old verification keys while issuing with one active key.
Diagnostics use stable MERIDIAN_* codes and logical references. Explain records redact secrets,
credentials, endpoints, native statements, and backend DSL details.
Contracts and compatibility
- Operation, capability, and cursor contracts
- Public API manifest
- Architecture
- Adapter conformance
- Compatibility ledger
- Release procedure
The implementation is pinned to Meridian HLD revision 56 and Catalogs/Public Interfaces revision 70, with Query LLD revision 46 and Adapter LLD revision 24 as package-level authorities.
License
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 meridian_storage_query-1.0.0.tar.gz.
File metadata
- Download URL: meridian_storage_query-1.0.0.tar.gz
- Upload date:
- Size: 79.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ac7d1747e0b9574810f79cfda99abbdd6d0dac230107b655de386871eb8ca9dc
|
|
| MD5 |
a41853b61e55f6839313b802ce36959c
|
|
| BLAKE2b-256 |
532358305b661eeb30628f6afcd4a040d686ec32a60fbd15b1972cacec92be3f
|
Provenance
The following attestation bundles were made for meridian_storage_query-1.0.0.tar.gz:
Publisher:
release.yml on zephytiju/meridian-storage-query
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
meridian_storage_query-1.0.0.tar.gz -
Subject digest:
ac7d1747e0b9574810f79cfda99abbdd6d0dac230107b655de386871eb8ca9dc - Sigstore transparency entry: 2591668283
- Sigstore integration time:
-
Permalink:
zephytiju/meridian-storage-query@c358b44fa7e836b3196f28c37ef9d729e46ffe2a -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/zephytiju
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@c358b44fa7e836b3196f28c37ef9d729e46ffe2a -
Trigger Event:
push
-
Statement type:
File details
Details for the file meridian_storage_query-1.0.0-py3-none-any.whl.
File metadata
- Download URL: meridian_storage_query-1.0.0-py3-none-any.whl
- Upload date:
- Size: 63.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b7ae4572ae70fb51ec190080df40fd10e667d69634ee811f0a7e3f72b56e41cc
|
|
| MD5 |
7ee867f08ab277704b5df639a6daa96d
|
|
| BLAKE2b-256 |
9efe43b6d56cf25622a9b11e00f2a9cc69dff6ebb23a0cd54f59892825bb0b35
|
Provenance
The following attestation bundles were made for meridian_storage_query-1.0.0-py3-none-any.whl:
Publisher:
release.yml on zephytiju/meridian-storage-query
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
meridian_storage_query-1.0.0-py3-none-any.whl -
Subject digest:
b7ae4572ae70fb51ec190080df40fd10e667d69634ee811f0a7e3f72b56e41cc - Sigstore transparency entry: 2591668722
- Sigstore integration time:
-
Permalink:
zephytiju/meridian-storage-query@c358b44fa7e836b3196f28c37ef9d729e46ffe2a -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/zephytiju
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@c358b44fa7e836b3196f28c37ef9d729e46ffe2a -
Trigger Event:
push
-
Statement type: