> ## Documentation Index
> Fetch the complete documentation index at: https://saydo-5cd0e3d7.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Config File

> Reference for .wiki-compiler.json, the main configuration file for LLM Wiki Compiler.

The `.wiki-compiler.json` file lives in your project root and controls everything about how the wiki compiler runs — what files it reads, where it writes output, and how Claude uses the result.

`/wiki-init` creates this file automatically. You can edit it manually at any time.

## Example config

```json theme={null}
{
  "version": 1,
  "name": "My Project",
  "sources": [
    { "path": "Knowledge/", "exclude": ["wiki/"] },
    { "path": "docs/meetings/" }
  ],
  "output": "Knowledge/wiki/",
  "mode": "staging",
  "topic_hints": ["retention", "onboarding"],
  "link_style": "obsidian"
}
```

## Fields

<ParamField body="name" type="string" required>
  Display name for the knowledge base. Used in logs and session context injected by the SessionStart hook.
</ParamField>

<ParamField body="sources" type="array" required>
  Directories to scan for `.md` files. Each entry is an object with a `path` and an optional `exclude` list.

  ```json theme={null}
  "sources": [
    { "path": "Knowledge/", "exclude": ["wiki/"] },
    { "path": "docs/meetings/" }
  ]
  ```

  * `path` — relative path to a directory (include the trailing slash)
  * `exclude` — subdirectories within `path` to skip (useful for excluding the wiki output directory itself)

  <Note>Source files are never modified. The compiler only writes to the `output` directory.</Note>
</ParamField>

<ParamField body="output" type="string" required>
  Path to the directory where the compiled wiki lives. All topic articles, `INDEX.md`, `schema.md`, and compile logs are written here.

  ```json theme={null}
  "output": "Knowledge/wiki/"
  ```

  You can delete this directory and regenerate it at any time by running `/wiki-compile`.
</ParamField>

<ParamField body="mode" type="string" default="staging">
  Controls how aggressively Claude uses the wiki versus your raw source files. Accepts `staging`, `recommended`, or `primary`.

  See [Adoption Modes](/configuration/adoption-modes) for a full explanation of each mode.
</ParamField>

<ParamField body="article_sections" type="array">
  Defines the section structure for every topic article. Generated by `/wiki-init` based on a sample of your source files, then saved here so you can edit it.

  ```json theme={null}
  "article_sections": [
    { "name": "Summary", "description": "standalone briefing of the topic", "required": true },
    { "name": "Key Findings", "description": "main discoveries and insights" },
    { "name": "Open Questions", "description": "unresolved threads and gaps" },
    { "name": "Sources", "description": "backlinks to all contributing files", "required": true }
  ]
  ```

  Each entry has:

  * `name` — the section heading
  * `description` — guides the compiler on what content belongs here
  * `required` — if `true`, the section cannot be removed (`Summary` and `Sources` only)

  See [Article Sections](/configuration/article-sections) for domain examples and editing rules.

  <Note>If `article_sections` is missing, the compiler falls back to a built-in default template.</Note>
</ParamField>

<ParamField body="topic_hints" type="array">
  Optional list of seed topic names to guide the compiler's classification. Useful when your content covers a known set of subjects and you want the compiler to anchor to those names rather than discover topics from scratch.

  ```json theme={null}
  "topic_hints": ["retention", "onboarding", "experiment design"]
  ```

  Leave this as an empty array if you want the compiler to discover topics automatically.
</ParamField>

<ParamField body="link_style" type="string" default="obsidian">
  Sets the link format used in compiled articles. Accepts `obsidian` or `markdown`.

  * `obsidian` — uses `[[wikilinks]]`, compatible with Obsidian's graph view and backlink features
  * `markdown` — uses standard `[text](path)` links, compatible with any markdown renderer

  ```json theme={null}
  "link_style": "obsidian"
  ```
</ParamField>

## Editing the config

You can edit `.wiki-compiler.json` directly in any text editor. Changes to most fields (including `article_sections` and `mode`) take effect the next time you run `/wiki-compile` or start a new Claude session.

<Tip>To reset your setup entirely, delete `.wiki-compiler.json` and run `/wiki-init` again. Your compiled wiki output is separate and won't be affected unless you delete it too.</Tip>
