The database for knowledge you can verify
Project description
Attest
Licensed under the Business Source License 1.1. Free to use, modify, and self-host. Cannot be offered as a competing managed service. Converts to Apache 2.0 after 4 years.
A claim-native database for building reality models -- structured, provenanced, continuously-learning representations of organizational knowledge.
Claims are the atomic primitive. The graph is derived, not primary. Everything can be rebuilt from the claim log. Provenance is structural -- the engine rejects writes without a valid provenance chain.
Install
pip install attestdb
Quick Start
import attestdb
db = attestdb.open("my_knowledge.db")
# Ingest a claim with provenance
db.ingest(
subject=("BRCA1", "gene"),
predicate=("associated_with", "relates_to"),
object=("Breast Cancer", "disease"),
provenance={"source_type": "literature_extraction", "source_id": "PMID:12345"},
confidence=0.9,
)
# Query the knowledge graph
frame = db.query("BRCA1", depth=2)
print(frame.focal_entity.name)
for rel in frame.direct_relationships:
print(f" --[{rel.predicate}]--> {rel.target.name} (conf={rel.confidence:.2f})")
db.close()
Rust Backend
For 100x faster ingestion (1M+ claims/sec), install the optional Rust engine:
pip install attest-py
Attest uses the Rust storage engine for all operations.
Core Capabilities
- Provenance-tracked claims -- every fact has a source chain
- Confidence scoring -- Tier 1 (direct evidence) + Tier 2 (corroboration)
- Retraction with cascade --
db.retract("source_123")propagates downstream - Time travel --
db.at(timestamp)for point-in-time views - Snapshot/Restore --
db.snapshot(path)andAttestDB.restore(path) - MCP server -- expose your knowledge graph to AI agents
- Embedding index -- HNSW similarity search via usearch
- Audit chain -- tamper-evident Merkle hash chain on append-only log
Intelligence Layer (Enterprise)
LLM-powered features (curation, text extraction, chat ingestion, connectors, insight engine) are available in attestdb-enterprise:
pip install attestdb-enterprise
Optional Dependencies
pip install attestdb[mcp] # MCP server for AI agents
pip install attestdb[all] # everything
CLI
attest stats my.db # Show database statistics
attest query my.db BRCA1 # Query knowledge around an entity
attest schema my.db # Show knowledge graph schema
attest serve --port 8892 # Start MCP server
attest ingest file.json --db my.db # Ingest claims from file
Documentation
See docs/ for full architecture and design documentation:
docs/02_architecture.md-- Full technical architecturedocs/06_api_spec.md-- API contract and validation rulesdocs/07_design_decisions.md-- Critical decisions with rationale
Running Tests
pip install attestdb[dev]
pytest tests/unit/ tests/integration/ # ~35 tests, <30s
cd rust && cargo test # Rust unit + golden vectors
License
Business Source License 1.1 -- free to use, modify, and self-host. Converts to Apache 2.0 after 4 years.
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 attestdb-0.1.3.tar.gz.
File metadata
- Download URL: attestdb-0.1.3.tar.gz
- Upload date:
- Size: 222.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6554936e3471e9d4d9251e255a21e62cf6041742b953b7e73c092b6edd1d87d1
|
|
| MD5 |
5b63cdc5fe6447f9d70e9f4a8aafeeda
|
|
| BLAKE2b-256 |
380344eee353745e069716c749ca7781f3c51ab4b45d0c78e8c1ce4d0c0aa5f3
|
Provenance
The following attestation bundles were made for attestdb-0.1.3.tar.gz:
Publisher:
publish.yml on omic/attest
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
attestdb-0.1.3.tar.gz -
Subject digest:
6554936e3471e9d4d9251e255a21e62cf6041742b953b7e73c092b6edd1d87d1 - Sigstore transparency entry: 1056652142
- Sigstore integration time:
-
Permalink:
omic/attest@56d237ee334f59cd5e5bcaa7403b24f67813e8d8 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/omic
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@56d237ee334f59cd5e5bcaa7403b24f67813e8d8 -
Trigger Event:
release
-
Statement type:
File details
Details for the file attestdb-0.1.3-py3-none-any.whl.
File metadata
- Download URL: attestdb-0.1.3-py3-none-any.whl
- Upload date:
- Size: 99.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bd45735a5cbe1e054ae424ad0a314154e762d9f396dc75182bacea02b5252a03
|
|
| MD5 |
69628566698432fb0a08cd0e5690fc29
|
|
| BLAKE2b-256 |
966c455562b43df33cef3706559aed4976d7c73ec557e4a554f031a340e78f2b
|
Provenance
The following attestation bundles were made for attestdb-0.1.3-py3-none-any.whl:
Publisher:
publish.yml on omic/attest
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
attestdb-0.1.3-py3-none-any.whl -
Subject digest:
bd45735a5cbe1e054ae424ad0a314154e762d9f396dc75182bacea02b5252a03 - Sigstore transparency entry: 1056652220
- Sigstore integration time:
-
Permalink:
omic/attest@56d237ee334f59cd5e5bcaa7403b24f67813e8d8 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/omic
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@56d237ee334f59cd5e5bcaa7403b24f67813e8d8 -
Trigger Event:
release
-
Statement type: