daidocs (Python)
A pure-Python reader for DaiDocs .dai memory stores, plus a small daidocs
command that forwards to the Node engine.
DaiDocs is an open plain-text format for AI memory. A store is a folder of
.dai files plus an _index/. This package gives Python code a way to read
that store. It does not reimplement the engine that writes stores: writing,
extraction, embeddings and ranking stay in the Node project.
Requirements
- Python 3.8+
- Node 18 or newer (required). DaiDocs is a Node project; this package
drives that engine. If Node is missing when you first run
daidocs, the command tells you it is required and offers to install it for you (via your OS package manager, such aswingeton Windows, after you confirm). You can also install Node (LTS) yourself from https://nodejs.org/ . The full setup needs a system Node, because Claude Code and Claude Desktop launch it themselves.
Verify Node with:
node --version
Install
pip install daidocs
This pulls in pyyaml. Node is a separate prerequisite (see Requirements): the
daidocs command drives the published npm engine via npx, so Node must be
present for setup, convert, capture and the MCP server.
Reader (pure Python)
from daidocs import Store
store = Store("~/DaiDocs") # a store folder, or a project folder
store.manifest() # list of manifest entries (dicts)
store.read("chat_20260807_d1dd87da")
# dict: id, path, header, understanding,
# segments, raw
store.facts() # parsed _index/facts.jsonl rows
store.events() # parsed _index/events.jsonl rows
store.profile() # parsed _index/profile.jsonl rows
store.search("deploy") # substring filter over the manifest
read() returns the document's three parts:
header: the YAML frontmatter (id, type, title, lang, summary, tags, ...).understanding: the JSON extraction block under# Understanding.segments: the## [seg n/N]blocks under# Content, each as{"n", "total", "text"}.raw: the full original file text, preserved losslessly.
You can also parse a .dai string directly without a store:
from daidocs import parse_dai
parsed = parse_dai(open("chat_20260807_d1dd87da.dai", encoding="utf-8").read())
CLI (drives the Node engine, Node required)
daidocs setup
daidocs convert
These run npx -y daidocs@latest <args> underneath, so they behave exactly
like the Node engine. Node 18+ is required: if Node is missing or older, the
command says so and offers to install it for you (after you confirm), rather
than silently falling back. Once Node is present, run daidocs setup to get the
full setup: Claude Code hooks, the Claude Desktop MCP server, and conversion.
Note: if you also have the npm package installed globally, both provide a
daidocs command and can shadow each other. The pip daidocs command is a
convenience wrapper around the Node engine.
Keys and subscriptions
The reader needs no API key and no subscription. from daidocs import Store
only parses .dai files that already exist on disk. It never calls a model and
never sends anything to a third party.
Writing new memories (the engine behind the daidocs command) uses each
person's own setup, two ways:
- Keyless by default. Through an MCP host such as Claude Code or Claude Desktop, your own assistant does the extraction. This rides on the subscription you already have, and no API key is involved.
- Bring your own key, optionally.
daidocs setupoffers a provider menu (Anthropic, OpenAI, Gemini, Ollama) if you would rather run extraction against your own account. The key is stored in your user environment only, never written to a file, and you can point at a custom endpoint withOPENAI_BASE_URL.
Either way the key is per person and local to that person. There is no shared or central key.
License
Apache-2.0.
Release files for daidocs 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| daidocs-0.1.1.tar.gz | 12.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| daidocs-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.5 kB
Release files / daidocs-0.1.1.tar.gz
| Download URL | daidocs-0.1.1.tar.gz |
|---|---|
| Size | 12.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
633c6f2c9193561a9039a46927107ef2b762ca9b127c8db16264bb9f0bdad1c6
|
|
BLAKE2b-256 checksum How to use checksums |
0a959d3626befe779dd2b9fdf1e57b3d9de3817c989f0432db1e0576bfcf06d0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / daidocs-0.1.1-py3-none-any.whl
| Download URL | daidocs-0.1.1-py3-none-any.whl |
|---|---|
| Size | 9.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
489fa341eba944de7c3c663af8be7661d60842539eced2581364880671fd33dd
|
|
BLAKE2b-256 checksum How to use checksums |
61b19af0afca9918d8d938acc6d91db74c86a2d51f1c6dbc29c6fb2d0bb8b4ed
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|