Have you ever wished your agents and assistants could share memories ... across one laptop to your servers and dev machines ... from Codex to Claude to OpenCode to OpenClaw?
Here's the plan for doing all those things and keeping memories and priorities straight.
Distributed Intent Ledger (DIL) is a local-first, filesystem-native protocol for persistent multi-agent and multi-environment memory coordination. In current deployments, Tailscale is used as the private network fabric for secure cross-machine agent communication and coordination. Relies on Obsidian vault sync.
For a compact human-readable summary of the whole system, start with docs/dil-overview.md.
Make good use of READ_THIS_DIL_FIRST.md: require every AI Agent and AI Assistant to read it at the beginning of every session.
This bootstrap step is critical for consistent behavior, correct memory scoping, and reliable cross-agent/cross-machine coordination.
READ_ME_FIRST.md should be maintained as a compatibility alias for bootstrap flows that look for that filename first.
Bootstrap directive to propagate into agent/session startup config:
<!-- DIL_BOOTSTRAP_START -->
## DIL Session Bootstrap (required)
For opencode sessions, before any other work, read:
`~/READ_THIS_DIL_FIRST.md`
Then follow that file as highest-priority local guidance for this workspace.
<!-- DIL_BOOTSTRAP_END -->What sets DIL apart from other approaches is that it unifies memories and tasks across disparate environments for any assortment of AI Agents and AI Assistants by defining memory as a governed protocol, not just a storage format.
- Deterministic identity and scope boundaries:
- Runtime-derived
machineandassistantidentities. - Scope-first writes to
<machine>/<assistant>with explicit promotion to_shared. - Multi-agent collaboration is safe-by-default and auditable.
- Runtime-derived
- Filesystem-native and human-auditable:
- Plain files, frontmatter, and indexes (Obsidian-friendly).
- No opaque memory database lock-in.
- Start with plain Markdown for maximum transparency; switch to SQLite anytime for runtime/cache needs.
- Humans can inspect, repair, and diff records directly.
- Protocolized read/write behavior:
- Required frontmatter schema.
- Mandatory retrieval order (
local -> machine -> shared). - Mandatory index and change-log maintenance.
- Anti-parrot execution proof:
- Write operations must return concrete file paths and excerpts.
- Prevents false claims that persistence happened when it did not.
- Cross-agent task canon:
- Shared canonical registry, lifecycle transitions, allocator, and validation.
- Decouples task identity from any single runtime/model.
- Enables reliable handoffs across machines and assistants.
- Mixed-model operational resilience:
- Script-first, idempotent workflows.
- Validation gates before side effects.
- Fail-closed behavior suitable for weaker/local models as well as frontier models.
DIL defines:
- deterministic runtime identity resolution (
machine,assistant) - scoped write boundaries and promotion rules
- retrieval order across local/machine/shared scopes
- frontmatter and task metadata contracts
- machine and agent registries for routing/capability discovery
- index and change-log maintenance requirements
- validation gates for task mutations
- Choose a local vault path on that machine.
- Clone this repository into the vault:
git clone https://github.com/zigmoo/distributed_intent_ledger.git
- In each agent/assistant session, start with:
Read ~/READ_THIS_DIL_FIRST.md now and acknowledge.
- Resolve runtime identity before read/write:
machine:hostname -s | tr '[:upper:]' '[:lower:]'assistant: env/process-derived slug (no guessing from folder names)
- Create an Obsidian vault and configure remote syncing.
- Set up Tailscale on each machine and join them to your tailnet.
- Clone this repository into that synced vault:
git clone https://github.com/zigmoo/distributed_intent_ledger.git
- In each agent/assistant session, start with:
Read ~/READ_THIS_DIL_FIRST.md now and acknowledge.
- Create memory notes via script (preferred):
scripts/create_memory.sh --type observations --title "..." --base <vault>
- Create canonical tasks via script:
- Personal:
scripts/create_task.sh --domain personal --title "..." --project "..." --base <vault> - Work:
scripts/create_task.sh --domain work --task-id DMDI-12345 --title "..." --project "..." --base <vault>
- Personal:
- Enforce retrieval order when answering:
- local assistant scope -> machine scope -> shared policies -> shared global
- Validate tasks before claiming completion:
scripts/validate_tasks.sh <vault>
- Return proof after writes (anti-parrot rule):
- changed file paths
- placement proof (
find/tree output) - short excerpts from changed files
- Maintain shared runtime inventories:
_shared/_meta/machine_registry.json_shared/_meta/agent_registry.json- ensure each agent declares supported formats, runtime profiles, and fallback-LLM behavior
Minimum operating rule: write to <machine>/<assistant> first, promote to _shared only for cross-machine/cross-assistant facts.
The generic repo can also carry reusable policy and project-template artifacts that deployments may copy into their live vaults:
docs/recommended-agent-workflow-discipline.md- optional shared policy guidance for planning, verification, self-correction, and security hygiene
examples/project-claude-md.md- starter project-level agent guidance file that can be adapted into
CLAUDE.md
- starter project-level agent guidance file that can be adapted into
This project is licensed under the Apache License 2.0. See LICENSE and NOTICE.
READ_THIS_DIL_FIRST.md: bootstrap spec — every agent reads this first, every session_shared/: operational shared state (domains, meta, tasks)_shared/_meta/: bootstrap config filesdomain_registry.json: registered domains with ID prefixes, paths, and archive policiesproject_registry.md: canonical project slugs with aliases for task discoverycommand_registry.md: zero-inference command lookup tableagent_aliases.conf: agent identity alias mappingstask_id_counter.md: auto-allocated task ID counters per prefixtask_index.md: scan-first task index
_shared/domains/: domain-scoped task directoriespersonal/tasks/{active,archived}/: personal-domain tasks (DIL- prefix)work/tasks/{active,archived}/: work-domain tasks (external IDs)
docs/: protocol documentationspec-v1.md: normative protocol contract (MUST/SHOULD/MAY)dil-overview.md: concise human-readable overview of the full DIL systemrecommended-agent-workflow-discipline.md: optional shared workflow-discipline policymachine-registry-contract.md: machine inventory and runtime host contractagent-registry-contract.md: agent capabilities, formats, models, and fallback contract
runbooks/: procedural runbookstask-lifecycle-runbook.md: create-to-done task lifecycle steps
schema/: JSON schemas for notes and tasksexamples/: sample records and starter config templatessample-domain-registry.json: multi-domain registry with generalized pathssample-project-registry.md: project slugs with aliases and column referencesample-command-registry.md: command trigger lookup tablesample-agent-aliases.conf: agent identity alias mappingssample-agent-registry.json: multi-agent runtime/capability coveragesample-machine-registry.json: multi-machine lifecycle coveragesample-task.md: expanded canonical task example with acceptance criteriasample-memory-note.md: decision-style memory note examplesample-change-log.md: multi-entry mutation/change-log example
scripts/: reference helpers and validatorscreate_task.sh: canonical task creation with ID allocation and index updatecreate_project.sh: project registry managementcreate_jira_task.sh: Jira + DIL mirrored task creationcreate_engineering_notebook_entry.sh: structured engineering notesmorning_brief.sh: daily task briefing generatoridentify_agent.sh: runtime agent identity resolutionvalidate_tasks.sh/validate_tasks.py: task system validationarchive_tasks.sh: move terminal tasks to archived/list_archived.sh: search/filter archived tasksrebuild_task_index.sh: regenerate task index from fileslib/domains.sh: domain registry lookup helperslib/registry.sh: project registry lookup helpers