agentic-dna
v0.9.1
Published
Governance and knowledge system for AI agent fleets
Maintainers
Readme
🧬 Agentic DNA
Governance and knowledge system for AI agent fleets.
Agentic DNA provides a structured governance layer for multi-agent systems — defining agent identity, enforcing policies, managing shared knowledge, and ensuring consistency across an entire fleet of AI agents.
Features
- Agent Identity (dna.yaml) — Goal, boundary, tools, and deprecation specs per agent
- Philosophy DB — Universal principles shared across all agents
- Convention DB — Actionable rules (global or workspace-scoped)
- Toolbox — Shared CLI/tool documentation
- Architecture Paradigms — Git/CI/deploy level management
- Adaptive Cron — Dynamic frequency adjustment
- Policy Injection — Automatic cron and interactive session policies
- Directive Expansion —
{{dna ...}}directives in bootstrap files
Requirements
- Node.js >= 18
Install
CLI Only (standalone)
npm install -g agentic-dna
dna init # Initialize data directory
dna helpOpenClaw Plugin
openclaw plugins install openclaw-dna
openclaw gateway restartFrom Source
git clone https://github.com/exisz/agentic-dna.git
cd agentic-dna
pnpm install
npm link # Makes 'dna' command available globally
dna initCLI
dna init # Initialize data directory
dna spec <agent> # View agent spec (goal/boundary/tools)
dna philosophy <slug> # View a philosophy entry
dna philosophy --list # List all philosophies
dna convention <slug> # View a convention
dna convention --list # List all conventions
dna tool ls # List tools in the toolbox
dna tool <name> # View tool GBTD
dna hydrate --all # Expand all {{dna}} directives
dna cron up <id> # Increase cron frequency
dna cron down <id> # Decrease cron frequency
dna protocol --list # List protocol paradigms
dna skill ls # List manual skills
dna search <query> # Semantic search over the mesh (local ONNX embeddings)Any unrecognized subcommand automatically falls through to dna tool <name>, so registered toolbox entries work as top-level commands (e.g. dna agentbase → dna tool agentbase).
Search
Two complementary commands:
dna find <pat>— fast substring match on node id + title. Use for known IDs.dna search <query>— semantic search using local ONNX embeddings. Use for natural-language queries.
dna search "test before code"
# 42% → dna://philosophy/test-driven ("Test-Driven — Tests Before Code")
dna search "knowledge retrieval" --type philosophy
dna search "graph traversal" --top 10 --json
dna search --status # index info (size, entries, by type)
dna search --reindex # force full re-embedThe model (Xenova/all-MiniLM-L6-v2, ~22MB) downloads once on first use to ~/.cache/huggingface/. Embeddings are stored at <DNA_DATA>/.embeddings.json (≈3MB for 389 nodes). dna mesh scan re-embeds only changed nodes; everything is offline after first download.
Development
# One-shot: build → install → restart gateway
make dev
# Just build (no install)
make build
# Build + install (no restart)
make install
# Clean build artifacts
make cleanRepository Structure
This is a monorepo that publishes two npm packages from a single repository:
| Package | Description |
|---------|-------------|
| agentic-dna | The standalone dna CLI tool |
| openclaw-dna | The OpenClaw plugin (source: openclaw/index.ts) |
agentic-dna/
├── bin/
│ └── dna # CLI entry — routes all `dna` subcommands
├── lib/ # Shared CLI implementation modules
│ └── expand.ts # {{dna}} directive expansion
├── openclaw/ # OpenClaw plugin — published as `openclaw-dna` npm package
│ ├── index.ts # Plugin entry: policy injection + directive expansion
│ ├── dist/ # Build output (run `cd openclaw && pnpm build`)
│ ├── skills/ # Bundled AgentSkills
│ ├── package.json # openclaw-dna package manifest
│ └── openclaw.plugin.json # OpenClaw plugin descriptor
├── scripts/ # Utility/build scripts
└── test/ # TestsNote for OpenClaw users: The
openclaw-dnaplugin source lives here atopenclaw/index.ts. There is no separateopenclaw-dnarepository — both packages are developed and released from this repo.
Project Structure
agentic-dna/
├── bin/ # CLI entrypoint
│ └── dna # Router script
├── scripts/ # CLI tools (TypeScript)
├── lib/ # Shared modules
│ └── expand.ts # {{dna}} directive expansion
└── openclaw/ # OpenClaw plugin (npm: openclaw-dna)
├── package.json
├── openclaw.plugin.json
├── index.ts # Plugin entry — policy injection + directive expansion
└── skills/ # Bundled AgentSkills