dotagent

DotAgent

DotAgent is a Go-based personal agent runtime with:

Requirements

Install

git clone https://github.com/dotsetgreg/dotagent.git
cd dotagent
go build -o dotagent ./cmd/dotagent

Onboard

./dotagent onboard

This creates ~/.dotagent/config.json and a default workspace.

Update at least:

Validate setup:

./dotagent status

Run

Local CLI interaction:

./dotagent agent
./dotagent agent -m "Summarize this repo"

Discord gateway:

./dotagent gateway

Headless gateway management with Docker Compose:

# Start in background
docker compose --profile gateway up -d dotagent-gateway

# Check service status
docker compose ps dotagent-gateway

# Stream logs
docker compose logs -f dotagent-gateway

# Restart
docker compose restart dotagent-gateway

# Stop / start
docker compose stop dotagent-gateway
docker compose start dotagent-gateway

Config Notes

Persona System

DotAgent now runs a first-class persona layer that is fully integrated with memory:

Context + Memory Architecture

DotAgent uses a tiered, durable context system:

Key guarantees:

Operational safeguards:

Environment Variables

DOTAGENT_PROVIDERS_OPENROUTER_API_KEY=sk-or-v1-...
DOTAGENT_PROVIDERS_OPENROUTER_API_BASE=https://openrouter.ai/api/v1

DOTAGENT_PROVIDERS_OPENAI_API_KEY=sk-proj-...
DOTAGENT_PROVIDERS_OPENAI_OAUTH_ACCESS_TOKEN=
DOTAGENT_PROVIDERS_OPENAI_OAUTH_TOKEN_FILE=~/.codex/auth.json
DOTAGENT_PROVIDERS_OPENAI_API_BASE=https://api.openai.com/v1
DOTAGENT_PROVIDERS_OPENAI_ORGANIZATION=org_xxx
DOTAGENT_PROVIDERS_OPENAI_PROJECT=proj_xxx

DOTAGENT_PROVIDERS_OPENAI_CODEX_OAUTH_ACCESS_TOKEN=
DOTAGENT_PROVIDERS_OPENAI_CODEX_OAUTH_TOKEN_FILE=~/.codex/auth.json
DOTAGENT_PROVIDERS_OPENAI_CODEX_API_BASE=https://chatgpt.com/backend-api
DOTAGENT_PROVIDERS_OPENAI_CODEX_PROXY=

DOTAGENT_AGENTS_DEFAULTS_PROVIDER=openrouter
DOTAGENT_AGENTS_DEFAULTS_MODEL=openai/gpt-5.2

DOTAGENT_CHANNELS_DISCORD_TOKEN=YOUR_DISCORD_BOT_TOKEN
DOTAGENT_CHANNELS_DISCORD_ALLOW_FROM=123456789012345678

DOTAGENT_MEMORY_MAX_RECALL_ITEMS=8
DOTAGENT_MEMORY_CANDIDATE_LIMIT=80
DOTAGENT_MEMORY_RETRIEVAL_CACHE_SECONDS=20
DOTAGENT_MEMORY_WORKER_POLL_MS=700
DOTAGENT_MEMORY_WORKER_LEASE_SECONDS=60
DOTAGENT_MEMORY_EMBEDDING_MODEL=dotagent-chargram-384-v1
DOTAGENT_MEMORY_EVENT_RETENTION_DAYS=90
DOTAGENT_MEMORY_AUDIT_RETENTION_DAYS=365
DOTAGENT_MEMORY_PERSONA_SYNC_APPLY=true
DOTAGENT_MEMORY_PERSONA_FILE_SYNC_MODE=export_only
DOTAGENT_MEMORY_PERSONA_POLICY_MODE=balanced
DOTAGENT_MEMORY_PERSONA_MIN_CONFIDENCE=0.52

OpenAI Codex OAuth in Docker:

# docker-compose.yml (dotagent-gateway.volumes)
- ${HOME}/.codex/auth.json:/root/.codex/auth.json:ro
{
  "agents": { "defaults": { "provider": "openai-codex", "model": "gpt-5" } },
  "providers": {
    "openai_codex": {
      "oauth_token_file": "/root/.codex/auth.json",
      "api_base": "https://chatgpt.com/backend-api"
    }
  }
}

Switching providers does not clear memory. Memory remains in workspace/state/memory.db.

Commands

dotagent onboard
dotagent agent
dotagent gateway
dotagent status
dotagent cron
dotagent skills
dotagent toolpacks
dotagent version
# In-chat persona diagnostics:
/persona show
/persona revisions
/persona candidates [status]
/persona rollback

Skill notes:

Test

GOCACHE=/tmp/go-build go test ./...

Memory-focused regression gates:

make test-memory
make memory-eval
make memory-canary

Documentation:

Docs commands:

make docs-gen
make docs-check
make docs-build
make docs-serve

Toolpack diagnostics:

dotagent toolpacks validate [id]
dotagent toolpacks doctor [id]