Duragent — A durable, self-contained runtime for AI agents.
Sessions survive crashes. Agents are just files. One binary, zero dependencies.
Use it as a personal AI assistant, or as the foundation for agent-powered products.
| What you get | How |
|---|---|
| Sessions that survive crashes | Append-only event log, attach/detach like tmux |
| Agents you can read and version | YAML + Markdown — no code required |
| State you can inspect | Just files on disk — cat, grep, git diff |
| Deploy anywhere | Single binary, ~10MB, no Python/Node/Docker |
| Your choice of parts | Swap LLM providers, gateways, and storage backends or bring your own |
git clone https://github.com/giosakti/duragent.git
cd duragent && make build
# Or: cargo install --git https://github.com/giosakti/duragent.git
duragent init
# Follow the interactive setupexport OPENROUTER_API_KEY=your-key # or: duragent login anthropic
duragent serveduragent chat --agent <YOUR_AGENT_NAME>duragent attach --list # List attachable sessions
duragent attach SESSION_ID # Reconnect to existing session- Durable sessions — crash, restart, reconnect; your conversation survives
- Portable agent format — define agents in YAML + Markdown; inspect, version, and share them
- Memory — agents recall past conversations, remember experiences, and reflect on long-term knowledge
- Tools — bash execution, CLI tools, and scheduled tasks, with configurable approval policies
- Skills — modular capabilities defined as Markdown files (Agent Skills standard)
- Multiple LLM providers — Anthropic, OpenAI, OpenRouter, Ollama
- Platform gateways — Telegram and Discord via subprocess plugins
- HTTP API — REST endpoints with SSE streaming
Use the built-ins, or swap in your own:
| Component | Default | Swappable |
|---|---|---|
| Gateways | CLI, HTTP, SSE, Telegram, Discord | Any platform via gateway plugins |
| LLM | OpenRouter | Anthropic, OpenAI, Ollama, or any provider |
| Sandbox | Trust mode | bubblewrap, Docker (planned) |
| Storage | Filesystem | Postgres, S3 (planned) |
./.duragent/
├── agents/<agent-name>/
│ ├── agent.yaml # Agent definition (Duragent Format)
│ ├── SOUL.md # "Who the agent IS" (identity and personality)
│ ├── SYSTEM_PROMPT.md # "What the agent DOES" (core system prompt)
│ ├── INSTRUCTIONS.md # Additional runtime instructions (optional)
│ ├── policy.yaml # Tool execution policy (optional)
│ ├── skills/ # Modular capabilities (SKILL.md files)
│ └── memory/
│ ├── MEMORY.md # Curated long-term memory
│ └── daily/ # Daily experience logs
├── sessions/
│ └── <session_id>/
│ ├── events.jsonl # Append-only event log
│ └── state.yaml # Snapshot for fast resume
├── schedules/ # Scheduled tasks and run logs
└── memory/
└── world/ # Shared knowledge across all agents
Read the Duragent Guide for installation, configuration, and usage.
For contributors: CONTRIBUTING.md | Project Status | Internal Specs