Python bindings for the mempill AI-agent memory engine
Project description
mempill (Python)
Python bindings for the mempill AI-agent memory engine — temporal, contested-belief-aware fact storage for AI agents.
Install
pip install mempill
Prebuilt wheels are published for Python 3.11, 3.12, and 3.13 on Linux (x86_64, aarch64), macOS (x86_64, arm64), and Windows (x86_64). No Rust toolchain required to use the published wheel.
Build from source (contributors)
pip install maturin
maturin develop --release # editable install into current venv
Usage
from mempill import open_in_memory, remember, recall
engine = open_in_memory()
remember(engine, "my-agent", "user", "city", "Berlin")
result = recall(engine, "my-agent", "user", "city")
print(result.as_str()) # "Berlin"
print(result.is_contested()) # False
Contested beliefs
When two conflicting claims exist and neither has been reconciled, recall signals
a contest rather than silently returning one value:
from mempill import open_in_memory, remember, recall, RememberOptions
engine = open_in_memory()
remember(engine, "agent", "acme", "ceo", "Alice")
remember(engine, "agent", "acme", "ceo", "Bob") # conflicts → Contested
result = recall(engine, "agent", "acme", "ceo")
if result.is_contested():
for c in result.candidates:
print(c.value, c.claim_ref)
Fact history
from mempill import open_in_memory, remember, recall, history, RememberOptions
engine = open_in_memory()
remember(engine, "agent", "acme", "ceo", "Alice",
RememberOptions(valid_until="2024-01-01"))
remember(engine, "agent", "acme", "ceo", "Bob",
RememberOptions(valid_from="2024-01-01"))
h = history(engine, "agent", "acme", "ceo")
for entry in h:
print(entry.value, entry.status, entry.valid_from, entry.valid_until)
File-backed engine
from mempill import open, remember, recall
engine = open("/path/to/agent.db") # SQLite, persists across restarts
remember(engine, "my-agent", "user", "city", "Berlin")
Exceptions
MempillError (base)
ValidationError — invalid request fields
NotFoundError — claim/agent not found
ConflictError — write-authority violation
StorageError — database open/migration failure
ConfigError — invalid engine configuration
InternalError — unexpected engine failure
Type stubs
.pyi stubs and py.typed marker are included. The package is mypy and stubtest clean.
Full documentation
https://mempill.netlify.app — concepts, invariants, and the complete API reference.
Source: https://github.com/mempill-ai/mempill
License
Apache-2.0
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 Distributions
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 mempill-0.2.1.tar.gz.
File metadata
- Download URL: mempill-0.2.1.tar.gz
- Upload date:
- Size: 270.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9efc1a1b84f125fb908f518b869db6bf7be7cca8b3f273a900aed550f7efcebc
|
|
| MD5 |
9991f429c82051d8ffb804c962fb8a79
|
|
| BLAKE2b-256 |
c12341275d986f1da55f46ef3b57589525c236a1f8c0abb68d1ca4d123e7cee6
|
Provenance
The following attestation bundles were made for mempill-0.2.1.tar.gz:
Publisher:
release-python.yml on mempill-ai/mempill
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mempill-0.2.1.tar.gz -
Subject digest:
9efc1a1b84f125fb908f518b869db6bf7be7cca8b3f273a900aed550f7efcebc - Sigstore transparency entry: 1981967276
- Sigstore integration time:
-
Permalink:
mempill-ai/mempill@d67501be64d0ed2dca305e1a526876566b29b33f -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mempill-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-python.yml@d67501be64d0ed2dca305e1a526876566b29b33f -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file mempill-0.2.1-cp311-abi3-win_amd64.whl.
File metadata
- Download URL: mempill-0.2.1-cp311-abi3-win_amd64.whl
- Upload date:
- Size: 1.8 MB
- Tags: CPython 3.11+, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f1e9df40538ea3aadd093c1752d0c339496aec2846bc487d96a6728ed2e8a512
|
|
| MD5 |
e68222b6efab0364dce53c15990192d6
|
|
| BLAKE2b-256 |
dda456e8186edf59fb63b3cbd5c6077864a6b66fed109350d104bb4991d96a33
|
Provenance
The following attestation bundles were made for mempill-0.2.1-cp311-abi3-win_amd64.whl:
Publisher:
release-python.yml on mempill-ai/mempill
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mempill-0.2.1-cp311-abi3-win_amd64.whl -
Subject digest:
f1e9df40538ea3aadd093c1752d0c339496aec2846bc487d96a6728ed2e8a512 - Sigstore transparency entry: 1981967425
- Sigstore integration time:
-
Permalink:
mempill-ai/mempill@d67501be64d0ed2dca305e1a526876566b29b33f -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mempill-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-python.yml@d67501be64d0ed2dca305e1a526876566b29b33f -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file mempill-0.2.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: mempill-0.2.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 2.1 MB
- Tags: CPython 3.11+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dbc63a5a7f466b1131192f74619f41565d10289347e4b93757ab6245b6c85084
|
|
| MD5 |
fbc0876ced3e6f5be528d286af469b02
|
|
| BLAKE2b-256 |
3f8c0acdc072376a399ff76f20be55c3ad2d72b3004b714bbd1c39a2e8e907bf
|
Provenance
The following attestation bundles were made for mempill-0.2.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:
Publisher:
release-python.yml on mempill-ai/mempill
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mempill-0.2.1-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl -
Subject digest:
dbc63a5a7f466b1131192f74619f41565d10289347e4b93757ab6245b6c85084 - Sigstore transparency entry: 1981967640
- Sigstore integration time:
-
Permalink:
mempill-ai/mempill@d67501be64d0ed2dca305e1a526876566b29b33f -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mempill-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-python.yml@d67501be64d0ed2dca305e1a526876566b29b33f -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file mempill-0.2.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.
File metadata
- Download URL: mempill-0.2.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 1.9 MB
- Tags: CPython 3.11+, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2ea31cdae5b3f0932a715c13a5ae7ceb6763ffbbbe8b884f364d394de8b4ca8a
|
|
| MD5 |
a1bee42a7bcf82f9616e4f7ef4e1c0bf
|
|
| BLAKE2b-256 |
ab6ee10e6fdbc92e66cbd955e6ff3e3a550d6657df4812f8eaeba8559f386fa4
|
Provenance
The following attestation bundles were made for mempill-0.2.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:
Publisher:
release-python.yml on mempill-ai/mempill
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mempill-0.2.1-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl -
Subject digest:
2ea31cdae5b3f0932a715c13a5ae7ceb6763ffbbbe8b884f364d394de8b4ca8a - Sigstore transparency entry: 1981967560
- Sigstore integration time:
-
Permalink:
mempill-ai/mempill@d67501be64d0ed2dca305e1a526876566b29b33f -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mempill-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-python.yml@d67501be64d0ed2dca305e1a526876566b29b33f -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file mempill-0.2.1-cp311-abi3-macosx_11_0_arm64.whl.
File metadata
- Download URL: mempill-0.2.1-cp311-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 1.9 MB
- Tags: CPython 3.11+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8ced1baf86efaadd1a344708b815509a11b283af9148b4d7d0e325a8c7d1f1fd
|
|
| MD5 |
536b65511ca316c0eddcc692108b58df
|
|
| BLAKE2b-256 |
10c80c192d5d932427ac14f5229157e7754380b440e7cc5b12bd6abffa86cf94
|
Provenance
The following attestation bundles were made for mempill-0.2.1-cp311-abi3-macosx_11_0_arm64.whl:
Publisher:
release-python.yml on mempill-ai/mempill
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mempill-0.2.1-cp311-abi3-macosx_11_0_arm64.whl -
Subject digest:
8ced1baf86efaadd1a344708b815509a11b283af9148b4d7d0e325a8c7d1f1fd - Sigstore transparency entry: 1981967485
- Sigstore integration time:
-
Permalink:
mempill-ai/mempill@d67501be64d0ed2dca305e1a526876566b29b33f -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mempill-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-python.yml@d67501be64d0ed2dca305e1a526876566b29b33f -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file mempill-0.2.1-cp311-abi3-macosx_10_12_x86_64.whl.
File metadata
- Download URL: mempill-0.2.1-cp311-abi3-macosx_10_12_x86_64.whl
- Upload date:
- Size: 1.9 MB
- Tags: CPython 3.11+, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
692fe5b3fbe9e6c6290efe2fb216e40f4792da8ef4723fb9473ddd68699270dd
|
|
| MD5 |
e48af267c7c8045d1dbc44e80e3d4356
|
|
| BLAKE2b-256 |
45b5e60b1a27d698a16749b01fd7dd473fa5dc57993c3174a94cd64412076a5e
|
Provenance
The following attestation bundles were made for mempill-0.2.1-cp311-abi3-macosx_10_12_x86_64.whl:
Publisher:
release-python.yml on mempill-ai/mempill
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mempill-0.2.1-cp311-abi3-macosx_10_12_x86_64.whl -
Subject digest:
692fe5b3fbe9e6c6290efe2fb216e40f4792da8ef4723fb9473ddd68699270dd - Sigstore transparency entry: 1981967350
- Sigstore integration time:
-
Permalink:
mempill-ai/mempill@d67501be64d0ed2dca305e1a526876566b29b33f -
Branch / Tag:
refs/heads/main - Owner: https://github.com/mempill-ai
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-python.yml@d67501be64d0ed2dca305e1a526876566b29b33f -
Trigger Event:
workflow_dispatch
-
Statement type: