# Integrated wiki

> Markdown pages in your repository that pull live issue data through templates, so status pages, roadmaps and reports are rendered from the board instead of copied from it.

Canonical: https://kanb.us/features/integrated-wiki.html

Project documentation goes stale because someone has to copy numbers into it. Kanbus wiki pages avoid that. They are Markdown files in `project/wiki/` with Jinja2 template expressions that query the issue index when the page is rendered. The page always shows the board as it is now, and the source is versioned and reviewed like any other file.

## Pages as templates

Each page is rendered in two stages: Jinja evaluates the template against the live issues, then the Markdown is converted to HTML. Template functions let a page count, list and relate issues.

```markdown
## Open work

Open: {{ count(status="open") }}
In progress: {{ count(status="in_progress") }}
Blocked: {{ count(status="blocked") }}

{% for issue in query(type="task", status="open", sort="priority", limit=10) %}
- [{{ issue.id }}] {{ issue.title }} (P{{ issue.priority }})
{% endfor %}
```

The available functions are `query`, `count`, `issue`, `children`, `blocked_by` and `blocks`. `query` and `count` filter on type, status, priority (including `priority_lte` and `priority_gte`), assignee, label and parent, and accept `sort` and `limit`.

## Common pages

There are no built-in report pages; each of these is a few lines of template that you write once and keep in the repository.

:::card-grid{columns="2"}
:::card{title="Status summary"}
A table with one row per status and the count of issues in each, for sprint reviews and status pages.
:::
:::card{title="Epic progress"}
Closed versus total children for each epic, using `count(parent=epic.id, status="closed")`.
:::
:::card{title="Blocked work"}
Every blocked issue with the issues blocking it, using `query(status="blocked")` and `blocked_by(id)`.
:::
:::card{title="Priority queue"}
Open issues at priority 1 or higher, sorted by priority, using `priority_lte=1`.
:::
:::

## Render, list and search

Render a page from the CLI to print the resolved Markdown, or ask for HTML or JSON. Agents can use the JSON forms to read project context.

```bash
kbs wiki init
kbs wiki render project/wiki/index.md
kbs wiki render project/wiki/index.md --html
kbs wiki list --json
kbs wiki search roadmap --json
kbs wiki lint
```

The [console](/features/kanban-board.html) also has a Wiki view where you can create, edit, preview, rename and delete pages; saving writes the file to `project/wiki/`. Pages that use `ai_summarize` need an LLM key, which `kbs setup ai` stores once per machine.

## Learn more

- [Wiki guide](https://github.com/AnthusAI/Kanbus/blob/main/docs/WIKI_GUIDE.md) for every template function, filter and example.
- [CLI reference](https://github.com/AnthusAI/Kanbus/blob/main/docs/CLI_REFERENCE.md) for the `wiki` commands.
- Related features: [Kanban board](/features/kanban-board.html), [Agile metrics](/features/agile-metrics.html), [Git-native storage](/features/git-native-storage.html).
