AgenticMemory Python SDK (v0.2.0)
Python SDK for AgenticMemory -- portable binary graph memory for AI agents. 16 query types, zero dependencies.
Install
pip install agentic-brain
With LLM integrations
pip install agentic-brain[anthropic] # Claude
pip install agentic-brain[openai] # GPT
pip install agentic-brain[ollama] # Local models
pip install agentic-brain[all] # All providers
Quick Start
from agentic_memory import Brain
brain = Brain("my_agent.amem")
brain.add_fact("User is a Python developer", session=1)
brain.add_decision("Recommended FastAPI for REST APIs", session=1)
print(brain.facts())
print(brain.info())
v0.2 Query Expansion
Nine new methods added in v0.2.0:
brain = Brain("my_agent.amem")
# Retrieval
results = brain.search_text("API rate limit") # BM25 (1.58 ms @ 100K)
results = brain.search("caching strategy", top_k=10) # Hybrid BM25+vector (10.83 ms)
# Structural analysis
scores = brain.centrality(metric="pagerank") # PageRank (34.3 ms @ 100K)
path = brain.shortest_path(src=42, dst=99) # BFS (104 us @ 100K)
# Cognitive reasoning
report = brain.revise(node_id=42) # Counterfactual cascade (53.4 ms)
gaps = brain.gaps() # Find reasoning weaknesses
matches = brain.analogy(node_id=42, top_k=5) # Structural pattern matching
# Graph maintenance
report = brain.consolidate(dry_run=True) # Dedup, contradiction linking
drift = brain.drift() # Belief evolution tracking (68.4 ms)
With LLM Integration
from agentic_memory import Brain, MemoryAgent
from agentic_memory.integrations import AnthropicProvider
brain = Brain("my_agent.amem")
agent = MemoryAgent(brain, AnthropicProvider())
response = agent.chat("My name is Alice. I work on ML systems.", session=1)
response = agent.chat("What do I work on?", session=2)
Test Coverage
104 tests across 8 modules, including 20 tests for the v0.2 query expansion methods.
Requirements
- Python >= 3.10
amembinary (Rust core engine) -- install viacargo install agentic-memory
Documentation
License
MIT
Metadata
Release files for agentic-brain 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| agentic_brain-0.3.0.tar.gz | 38.2 kB | Without provenance | Details for agentic_brain-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| agentic_brain-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for agentic_brain-0.3.0-py3-none-any.whl |
Total release size: 73.2 kB
Release files / agentic_brain-0.3.0.tar.gz
| Download URL | agentic_brain-0.3.0.tar.gz |
|---|---|
| Size | 38.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0d6a868f3c04977db15f895a3b61ac7fd7190bfb2d061d94dcebc9fcf5315cd7
|
|
BLAKE2b-256 checksum How to use checksums |
3845414a4c20f1402c4887720fdd5927ba534274951cb591fc1580f447d014f2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.2
|
Release files / agentic_brain-0.3.0-py3-none-any.whl
| Download URL | agentic_brain-0.3.0-py3-none-any.whl |
|---|---|
| Size | 35.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3f4c87398c06263a2573f92af3948da558dcd4c44927daa416d6b6033ab836c8
|
|
BLAKE2b-256 checksum How to use checksums |
92b610d2caa3f44d8868ffecc6d9df13dc18570f5695823db766275c69abc980
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.2
|
Security for agentic-brain 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.