Skip to main content
kiwifs init scaffolds a knowledge directory from a built-in template. Each template provides a directory layout, sample files, a .kiwi/config.toml, and optional agent-facing documents.
kiwifs init --template <name> --root <dir>

Available templates

TemplateBest forStarter files
knowledgeLLM-maintained knowledge basesSCHEMA.md, playbook, episodes, index, log, sample page
wikiTeam wikisSample pages, index
runbookOps and incident responseRunbook starters, checklists
researchResearch notes and literatureNote structure, bibliography
tasksTask tracking with workflowsWorkflow schema, Kanban-ready frontmatter
blankEmpty starting point.kiwi/config.toml only
In the web UI and cloud dashboard, templates are also available when creating a new workspace or space.

knowledge (default)

The knowledge template is designed for AI agents that maintain a structured knowledge base. It includes everything an agent needs to onboard itself.

Directory structure

knowledge/
├── SCHEMA.md                  # Directory layout, frontmatter fields, naming conventions
├── index.md                   # Auto-maintained table of contents
├── log.md                     # Append-only change log
├── pages/
│   └── getting-started.md     # Sample durable page
├── episodes/
│   └── example-episode.md     # Sample episodic memory entry
└── .kiwi/
    ├── config.toml            # Server configuration
    ├── playbook.md            # MCP tool sequences for each operation
    └── rules.md               # Agent harness rules (Cursor, Claude, etc.)

Key files

Describes the knowledge base layout, frontmatter field tables, and naming conventions. Agents read this (via kiwi_context or kiwi://schema) to understand where to write and what metadata to set.
Step-by-step MCP sequences for standard operations: ingest, query, deep retrieval (peek, graph_walk, section), memory consolidation, lint loop, canvas generation, and workflow management. Includes a cost table of tools to help agents minimize unnecessary calls.
Harness-specific behavior rules. Export for your agent tool:
kiwifs rules export --format cursor
kiwifs rules export --format claude
kiwifs rules export --format agents
Auto-maintained table of contents that agents update after adding pages. Seeds with a link to pages/getting-started.
Append-only chronological record. Agents append a line after each operation for audit trail and observability.
Directory for episodic memory. Agents write observations here as short-lived notes with memory_kind: episodic frontmatter. Periodically consolidate into durable pages using kiwi_memory_report. See Episodic memory.

wiki

A structured team wiki with decision records, onboarding guides, and process documentation.

Directory structure

wiki/
├── SCHEMA.md
├── index.md
├── welcome.md
├── architecture.md
├── how-we-work.md
├── decisions/
│   ├── index.md
│   └── adr-001-example.md
├── onboarding/
│   └── index.md
├── processes/
│   ├── index.md
│   ├── deployment.md
│   ├── dev-setup.md
│   └── incident-response.md
├── reference/
│   ├── index.md
│   ├── faq.md
│   └── glossary.md
└── .kiwi/
    ├── config.toml
    ├── playbook.md
    ├── rules.md
    └── templates/
        ├── decision.md
        ├── meeting-notes.md
        ├── onboarding.md
        ├── product-spec.md
        └── sop.md
The wiki template includes slash-command templates in .kiwi/templates/ for common page types: architectural decision records, meeting notes, onboarding checklists, product specs, and standard operating procedures. These appear in the web UI’s “new page” menu.

runbook

Operations-focused template with incident response procedures, postmortem templates, and escalation paths.

Directory structure

runbook/
├── SCHEMA.md
├── index.md
├── procedures/
│   ├── deploy-rollback.md
│   ├── rotate-secrets.md
│   └── scale-up.md
├── incidents/
│   └── template.md
├── postmortems/
│   └── template.md
└── .kiwi/
    ├── config.toml
    ├── playbook.md
    └── rules.md
Each procedure file includes step-by-step checklists with severity and on_call frontmatter fields.

research

Research template with structured note-taking, experiment tracking, and literature review pages.

Directory structure

research/
├── SCHEMA.md
├── index.md
├── experiments/
│   └── exp-001-baseline.md
├── literature/
│   └── example-paper.md
├── notes/
│   └── synthesis-template.md
└── .kiwi/
    ├── config.toml
    ├── playbook.md
    └── rules.md
Experiment files include hypothesis, status, and result frontmatter fields. Literature files track authors, year, and doi.

tasks

Task tracking template with a pre-configured workflow, JSON Schema validation, and Kanban-ready frontmatter.

Directory structure

tasks/
├── SCHEMA.md
├── WORKFLOW.md
├── index.md
├── tasks/
│   ├── example-task.md
│   └── blocked-example.md
└── .kiwi/
    ├── config.toml
    ├── playbook.md
    ├── rules.md
    └── schemas/
        └── task.json
Each task file uses structured frontmatter validated by .kiwi/schemas/task.json:
---
title: "Implement auth flow"
status: "in_progress"
assignee: "agent:eng-bot"
priority: "high"
workflow: "default"
state: "in_progress"
---
The status field drives Kanban board grouping. The workflow and state fields enable state-machine transitions via Workflows.
The task.json schema in .kiwi/schemas/ validates that required fields (title, status) are present and that status is one of the allowed values. Enable enforcement with:
.kiwi/config.toml
[schema]
enforce = true
See Schemas.
With the workflow configured, the web UI renders tasks as a Kanban board grouped by state. Use the API to advance tasks programmatically:
curl -X POST 'http://localhost:3333/api/kiwi/workflow/advance' \
  -H 'Content-Type: application/json' \
  -d '{"path":"tasks/example-task.md","target_state":"done","actor":"agent:bot"}'

blank

Minimal template — creates only .kiwi/config.toml. Use this when you want to start from scratch or bring your own directory structure.

Listing templates via API

# Self-hosted
curl http://localhost:3333/api/init-templates

# Cloud
curl https://api.kiwifs.com/api/workspaces/init-templates \
  -H "Authorization: Bearer $KIWI_API_KEY"
Returns an array of template objects with id, name, and description.

Agent playbook

How agents onboard using SCHEMA.md and playbook.md.

Episodic memory

The episode/consolidation pattern used by the knowledge template.

Configuration

Full .kiwi/config.toml reference.

Quickstart

Install and run KiwiFS in 60 seconds.
Last modified on May 31, 2026