Skip to the content.

Configuration

← Back to README

All configuration is done through environment variables in .env. See .env.example for the full list with descriptions.

Repository layout

.
├─ .github/
│  ├─ ISSUE_TEMPLATE/         ← bug report / feature request templates
│  └─ workflows/
│     ├─ ci.yml               ← shellcheck, hadolint, actionlint, compose validate
│     └─ deploy.yml           ← auto-deploy on push to main
├─ docker-compose.yml
├─ .env.example
├─ Makefile
├─ CHANGELOG.md
├─ docs/                      ← long-form docs (you are here)
├─ scripts/
│  ├─ bootstrap.sh            ← one-line VPS install entry (curl | bash)
│  ├─ install.sh              ← interactive setup wizard (run via `make setup`)
│  └─ auth-obsidian.sh        ← Obsidian Sync login / sync / status helper
├─ takopi/
│  ├─ Dockerfile
│  └─ entrypoint.sh           ← generates takopi.toml + ~/.claude/settings.json
├─ obsidian-headless/
│  ├─ Dockerfile
│  └─ entrypoint.sh
└─ vault/
   ├─ CLAUDE.base.md          ← agent instructions, project default (tracked in git)
   ├─ CLAUDE.local.md         ← your personal overrides (created by install.sh, gitignored)
   ├─ CLAUDE.md               ← generated on each container start (do not edit)
   ├─ .trash/                 ← soft-delete destination (the agent has no `rm`)
   └─ templates/
      └─ note.md              ← template for new notes

Agent behavior

The agent reads vault/CLAUDE.md at the start of every session. That file is regenerated on every takopi container start by takopi/entrypoint.sh from three layers, concatenated in this order:

# Source Tracked in git? Edited by
1 vault/CLAUDE.base.md yes maintainers, via PR / git pull
2 vault/CLAUDE.local.md no you, on the VPS
3 CLAUDE_EXTRA_INSTRUCTIONS env var no .env, GitHub Actions Variable, or Secret

Later sections override earlier ones — if you write a personal rule that contradicts the base, your rule wins because Claude reads it later.

Do not edit vault/CLAUDE.md directly. Anything you put there will be wiped on the next container restart. Edit one of the three sources instead.

When to use which layer

After changing any layer, send /new in Telegram (or docker compose restart takopi on the VPS) to start a fresh Claude session that picks up the regenerated CLAUDE.md.

Choosing a model

The default in this stack is claude-haiku-4-5 — fast and cheap, suitable for most vault tasks (capturing notes, moving files, summarizing). Switch to claude-sonnet-4-6 via CLAUDE_MODEL=claude-sonnet-4-6 in .env when you need complex reasoning or long-context rewrites (~20x more expensive).