Skip to content

Commit 8d40458

Browse files
docs(examples): openkb usage guides with real generated artifacts (#141)
* docs(examples): add per-case usage guides with real generated artifacts Add examples/ as a use-case-indexed set of guides. Each case is its own directory: a README walkthrough plus the actual artifact OpenKB produced. - configuration — init, config.yaml, keys, LiteLLM tuning - commands — the everyday loop (+ a compiled sample-wiki/) - pageindex-cloud — long docs: local vs cloud + cloud import - chat — the interactive REPL: sessions + slash commands - skills — a generated SKILL.md + references/ + marketplace.json - slides — a generated single-file HTML deck - visualize — a generated interactive knowledge graph Every artifact was produced by running openkb over the sample attention-is-all-you-need.pdf with gpt-5.4-mini. The heavy/third-party test PDFs stay gitignored under examples/docs/. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(examples): document pre-release install + slow local-runtime timeout Cover recurring install/usage questions from the issue tracker: - #130 / #24: openkb pins a pre-release dependency (pageindex==0.3.0.dev1), which uv/pip skip by default. Show `uv tool install --prerelease=allow` / `pip install --pre`, plus a PATH note for the "command not found" case. - #140: local runtimes (LM Studio on Mac, Ollama, llama.cpp) abort on the default request timeout; document raising litellm.timeout in config. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(examples): use UN official languages in language examples Replace the ad-hoc ko/Korean language examples with the six official UN languages (en/zh/es/fr/ar/ru) so the config docs lead with widely-used options. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(readme): link to per-case usage examples Add an Examples section pointing to examples/ (and examples/README.md), with a table of the per-feature cases. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(readme): trim deep how-to, defer depth to examples/ Keep the README as a feature overview (what each command does); move the deep usage into examples/ and point to it: - collapse the Skill Factory walkthrough (output layout / install / share / iterate-from-chat / validate-eval-rollback) to a one-line pointer - replace the chat slash-command list with a pointer - tighten the skill-command table to feature-level descriptions - add a Configuration pointer for LiteLLM tuning (Ollama/LM Studio/Copilot) Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(readme): dedupe LLM setup, slim Configuration (keep PageIndex Setup) Provider/model + key setup is already covered in Getting Started > 'Set up your LLM'; Configuration > Settings repeated it. Trim Settings to the core config.yaml keys + a pointer to examples/configuration (entity_types, OAuth, LiteLLM tuning). PageIndex Setup (kept for referral) and AGENTS.md are unchanged. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(readme): tighten Usage, add visualize/slides to Quick Start Critical pass on Usage — it described the generators twice (Layer 2 table + narrative subsections): - drop the (i) Query & Chat and (iii) Visualize subsections (already in the Layer 2 table; depth is in examples/) - shorten Skill Factory to a flagship blurb + pointer (no walkthrough) - add the missing deck/slides generator to the Layer 2 table - fix the Skill Factory anchor link; remove a dead commented-out lint row Quick Start: add optional visualize + deck (deck noted as needing a theme). Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * fix(deck): bundle built-in deck themes so `deck new` works after pip install The deck themes (openkb-deck-neon / openkb-deck-editorial) and the html critic lived only in the repo's top-level skills/, which the wheel didn't ship — so a fresh `pip install openkb` failed `deck new` / `--critique` (and chat `/deck`, `/critique`) with "Deck skill ... is not installed". - force-include the three skills into the wheel at openkb/_skills/ - scan_local_skills also scans bundled roots (wheel openkb/_skills + the source-checkout skills/), at lowest priority so KB/user skills still override - tests: isolate bundled roots in the scan unit tests; add coverage for bundled discovery + KB-overrides-bundled - docs: drop the now-stale "install a theme first" notes Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(readme): fold Examples into Usage as per-command links The standalone Examples section duplicated the Usage tables. Remove it and link each command to its specific walkthrough instead: - Layer 2 generators table gets an Example column (query/chat/visualize/skill/deck) - a wiki-foundation 'everyday loop' link under Layer 1 -> examples/commands/ - PageIndex example linked from PageIndex Setup; config from Configuration Every example folder stays linked from its natural context; no duplicate table. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * docs(examples): fix review nits (threshold boundary, broken link, wording) From a critical pass over the examples docs: - threshold is >= (a 20-page PDF is long, converter.py:183): fix the boundary in pageindex-cloud (<= / > -> < / >=) and configuration ("more than" -> "or more") - fix the Bishop sample link — href pointed at ../docs/ (a dir), not the PDF - remove --keep-empty keeps concept AND entity pages, not just concepts - deck_grammar quote: add the kind_attr line so it matches the real SKILL.md Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K * chore(model): default to gpt-5.4 (unify with config example + docs) The code default (DEFAULT_CONFIG) was gpt-5.4-mini while config.yaml.example and all docs use gpt-5.4. Standardize on gpt-5.4: - DEFAULT_CONFIG model gpt-5.4-mini -> gpt-5.4 (+ update test_config assertion) - cli.py: fix the cross-family gpt-4o-mini fallback and the --model help example to gpt-5.4; lead the init model list with gpt-5.4 - examples/README: showcase commands use gpt-5.4 Also drop the empty separator row in the README Layer 2 generators table. Claude-Session: https://claude.ai/code/session_018WiFnTo1YW9mtw47Fzir9K
1 parent ab14109 commit 8d40458

34 files changed

Lines changed: 2790 additions & 161 deletions

README.md

Lines changed: 23 additions & 155 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,10 @@ openkb query "What are the main findings?"
9797
# 5. Or chat interactively
9898
openkb chat
9999

100-
# (Optional) Distill a redistributable agent skill from your wiki
101-
openkb skill new my-expert "Reason like an expert on <your-topic>"
100+
# (Optional) Turn the wiki into other outputs
101+
openkb skill new my-expert "Reason like an expert on <your-topic>" # a portable agent skill
102+
openkb visualize # an interactive knowledge graph
103+
openkb deck new my-deck "An intro deck on <your-topic>" # slides — a single-file HTML deck
102104
```
103105

104106
### Set up your LLM
@@ -171,7 +173,7 @@ A single source might touch 10--15 wiki pages. Knowledge accumulates: each docum
171173

172174
# ⚙️ Usage
173175

174-
OpenKB commands fall into two layers: the **wiki foundation** (compile + manage your knowledge) and **generators** (turn that wiki into useful output).
176+
OpenKB commands fall into two layers: the **wiki foundation** (compile + manage your knowledge) and **generators** (turn that wiki into useful output). Each links to a concrete walkthrough — a real artifact OpenKB generated from one sample paper (browse them all in [`examples/`](examples/)).
175177

176178
## Layer 1: 🧱 Wiki Foundation — compile and maintain
177179

@@ -194,189 +196,53 @@ OpenKB commands fall into two layers: the **wiki foundation** (compile + manage
194196
| <code>openkb&nbsp;recompile&nbsp;[&lt;doc&gt;]&nbsp;[--all]</code> | Re-run the compile pipeline on already-indexed docs without re-indexing. Regenerates summaries and rewrites concept pages; manual edits are overwritten (`--dry-run` to preview, `--refresh-schema` to also update `wiki/AGENTS.md`) |
195197
| <code>openkb&nbsp;feedback&nbsp;["msg"]</code> | File feedback by opening a prefilled GitHub issue (`--type bug/feature/question` to tag it) |
196198

197-
<!-- | `openkb lint --fix` | Auto-fix what it can | -->
198-
199199
</details>
200200

201+
**Example:** the everyday loop walked through end to end — [`examples/commands/`](examples/commands/).
202+
201203
## Layer 2: 💡 Generators — turn the wiki into output
202204

203205
A "generator" reads from the compiled wiki and produces something usable: an answer, a conversation, a skill folder. The wiki is the substrate; generators are the surfaces.
204206

205-
| Command | Output |
206-
|---|---|
207-
| <code>openkb&nbsp;query&nbsp;"question"</code> | A grounded answer with citations (`--save` to persist to `wiki/explorations/`) |
208-
| <code>openkb&nbsp;chat</code> | Interactive multi-turn session over the wiki (`--resume`, `--list`, `--delete` to manage sessions) |
209-
| <code>openkb&nbsp;visualize</code> | A self-contained interactive knowledge graph at `output/visualize/graph.html` — 3D, mind-map, and radial views |
210-
| | |
211-
| <code>openkb&nbsp;skill&nbsp;new&nbsp;&lt;skill-name&gt;&nbsp;"&lt;intent&gt;"</code> | Distill a redistributable agent skill from your wiki (see [Skill Factory](#-skill-factory--drop-in-a-book-out-comes-a-digital-expert) below) |
207+
| Command | Output | Example |
208+
|---|---|---|
209+
| <code>openkb&nbsp;query&nbsp;"question"</code> | A grounded answer with citations (`--save` to persist to `wiki/explorations/`) | [query & save](examples/commands/) |
210+
| <code>openkb&nbsp;chat</code> | Interactive multi-turn session over the wiki (`--resume`, `--list`, `--delete` to manage sessions) | [chat](examples/chat/) |
211+
| <code>openkb&nbsp;visualize</code> | A self-contained interactive knowledge graph at `output/visualize/graph.html` — 3D, mind-map, and radial views | [visualize](examples/visualize/) |
212+
| <code>openkb&nbsp;skill&nbsp;new&nbsp;&lt;skill-name&gt;&nbsp;"&lt;intent&gt;"</code> | Distill a redistributable agent skill from your wiki (see [Skill Factory](#skill-factory) below) | [skills](examples/skills/) |
213+
| <code>openkb&nbsp;deck&nbsp;new&nbsp;&lt;name&gt;&nbsp;"&lt;intent&gt;"</code> | Generate a single-file HTML slide deck (`--skill` picks a theme, `--critique` runs a quality pass) | [slides](examples/slides/) |
212214

213215
<details>
214216
<summary><i>More skill commands:</i></summary>
215217
<br>
216218

217219
| Command | Output |
218220
|---|---|
219-
| <code>openkb&nbsp;skill&nbsp;validate&nbsp;[name]</code> | Validate compiled skills (YAML frontmatter, file sizes, wikilinks, scripts). Auto-runs at end of `skill new` (`--strict` to treat warnings as failures) |
220-
| <code>openkb&nbsp;skill&nbsp;eval&nbsp;&lt;name&gt;</code> | Trigger-accuracy evaluation: does the `description:` field actually fire? LLM generates eval prompts; grader LLM scores activation (`--save` persists the eval set) |
221-
| <code>openkb&nbsp;skill&nbsp;history&nbsp;&lt;name&gt;</code> / <code>openkb&nbsp;skill&nbsp;rollback&nbsp;&lt;name&gt;</code> | Version history for skills. Each overwrite saves the previous version to `iteration-N/` with a diff; rollback restores any iteration |
222-
223-
</details>
224-
225-
### (i) 💬 Query & Chat — *ask the wiki*
226-
227-
`openkb query "..."` answers a single question. `openkb chat` is interactive — each turn carries history, so you can dig into a topic without re-typing context. Both use the same underlying wiki and retrieval primitives.
228-
229-
```bash
230-
openkb query "What does the literature say about attention scaling?"
231-
232-
openkb chat # start a new session
233-
openkb chat --resume # resume the most recent session
234-
openkb chat --resume 20260411 # resume by id (unique prefix works)
235-
openkb chat --list # list all sessions
236-
openkb chat --delete <id> # delete a session
237-
```
238-
239-
Inside a chat, type `/` to access slash commands (Tab to complete).
240-
241-
<details>
242-
<summary><i>More slash commands:</i></summary>
243-
<br>
244-
245-
- `/help` — list available commands
246-
- `/status` — show knowledge base status
247-
- `/list` — list all documents
248-
- `/add <path>` — add a document or directory without leaving the chat
249-
- `/skill new <skill-name> "<intent>"` — compile a skill from this chat (see below)
250-
- `/save [name]` — export the transcript to `wiki/explorations/`
251-
- `/clear` — start a fresh session (the current one stays on disk)
252-
- `/lint` — run knowledge base lint
253-
- `/exit` — exit (Ctrl-D also works)
221+
| <code>openkb&nbsp;skill&nbsp;validate&nbsp;[name]</code> | Validate compiled skills (auto-runs after `skill new`) |
222+
| <code>openkb&nbsp;skill&nbsp;eval&nbsp;&lt;name&gt;</code> | Check the skill triggers on the right prompts |
223+
| <code>openkb&nbsp;skill&nbsp;history&nbsp;&lt;name&gt;</code> / <code>openkb&nbsp;skill&nbsp;rollback&nbsp;&lt;name&gt;</code> | Version history + rollback for skills |
254224

255225
</details>
256226

257227
<a id="skill-factory"></a>
258228

259-
### (ii) 🛠 Skill Factory — *drop in a book; out comes a digital expert.*
260-
261-
The newest generator. `openkb skill new` distills an [agent skill](https://docs.claude.com/en/docs/build-with-claude/skills) from any subset of your wiki, a portable folder that major agents (Claude Code, Codex, etc.) can install and load natively. Drop in a book's worth of papers; out comes a specialist that other agents can call on.
262-
263-
```bash
264-
openkb skill new karpathy-thinking \
265-
"Reason about transformers and attention in Karpathy's style"
266-
```
267-
268-
<details>
269-
<summary><i>Output:</i></summary>
270-
<br>
271-
272-
```
273-
<kb>/output/skills/karpathy-thinking/
274-
├── SKILL.md # YAML frontmatter + when-to-use + approach
275-
├── references/ # depth material the agent loads on demand
276-
│ ├── methodology.md
277-
│ └── key-quotes.md
278-
└── (scripts/) # optional, only if intent implies computation
279-
```
280-
281-
Plus an auto-updated `<kb>/.claude-plugin/marketplace.json` so the whole KB is one-line installable.
282-
283-
</details>
284-
285-
<details>
286-
<summary><i>Install locally:</i></summary>
287-
<br>
288-
289-
```bash
290-
cp -r output/skills/karpathy-thinking ~/.claude/skills/
291-
```
292-
293-
</details>
294-
295-
<details>
296-
<summary><i>Share with others:</i></summary>
297-
<br>
298-
299-
Push your KB to GitHub, then anyone runs:
300-
301-
```bash
302-
npx skills@latest add <your-org>/<your-repo>
303-
```
304-
305-
</details>
306-
307-
<details>
308-
<summary><i>Iterate from chat:</i></summary>
309-
<br>
310-
311-
Compilation is one-shot, but follow-up edits don't have to be. Inside `openkb chat`, you can refine without re-running the whole pipeline:
229+
### 🛠 Skill Factory — *drop in a book; out comes a digital expert.*
312230

313-
```
314-
/skill new karpathy-thinking "Reason about transformers like Karpathy"
315-
[generation streams]
316-
> description is too generic, make it about transformer implementations specifically
317-
[agent edits SKILL.md frontmatter in place]
318-
```
319-
320-
</details>
321-
322-
<details>
323-
<summary><i>Quality gates:</i></summary>
324-
<br>
325-
326-
Structural validation, trigger-accuracy + body-coverage evaluation, and full history/rollback:
327-
328-
```bash
329-
# Lint structure (auto-runs at end of `skill new`)
330-
openkb skill validate karpathy-thinking
331-
openkb skill validate --strict # treat warnings as failures
332-
333-
# Does the description actually fire when it should?
334-
openkb skill eval karpathy-thinking --save
335-
336-
# History + rollback if a new iteration regresses
337-
openkb skill history karpathy-thinking
338-
openkb skill rollback karpathy-thinking --to 2
339-
```
340-
341-
</details>
342-
343-
### (iii) 🗺 Visualize — *see the shape of your knowledge*
344-
345-
`openkb visualize` renders the wiki as a single self-contained, offline HTML page with three views of the same knowledge base — a **3D** force graph, an OpenKB-rooted **mind-map**, and a **radial** tree — coloured by type and linked by `[[wikilinks]]`.
346-
347-
```bash
348-
openkb visualize # build + open output/visualize/graph.html
349-
```
231+
The flagship generator: `openkb skill new` distills a portable [agent skill](https://docs.claude.com/en/docs/build-with-claude/skills) from your wiki that Claude Code, Codex, and Gemini can install and load natively. Drop in a book's worth of papers; out comes a specialist other agents can call on. → A real generated skill, plus install / share / `eval` / rollback, is walked through in **[`examples/skills/`](examples/skills/)**.
350232

351233
# 🔧 Configuration
352234

353235
### Settings
354236

355-
OpenKB settings are initialized by `openkb init` and stored in `.openkb/config.yaml`:
237+
`openkb init` writes `.openkb/config.yaml`:
356238

357239
```yaml
358240
model: gpt-5.4 # LLM model (any LiteLLM-supported provider)
359241
language: en # Wiki output language
360242
pageindex_threshold: 20 # PDF pages threshold for PageIndex
361243
```
362244
363-
Model names use `provider/model` LiteLLM [format](https://docs.litellm.ai/docs/providers) (OpenAI models can omit the prefix):
364-
365-
| Provider | Model example |
366-
|---|---|
367-
| OpenAI | `gpt-5.4` |
368-
| Anthropic | `anthropic/claude-sonnet-4-6` |
369-
| Gemini | `gemini/gemini-3.1-pro-preview` |
370-
371-
<details>
372-
<summary><i>Advanced options (<code>entity_types</code>, OAuth):</i></summary>
373-
<br>
374-
375-
`entity_types` (optional): a YAML list overriding the entity-type vocabulary used for entity pages; omit it to use the default `person`, `organization`, `place`, `product`, `work`, `event`, `other`.
376-
377-
Subscription-based providers that authenticate via OAuth device flow (e.g. `chatgpt/*`, `github_copilot/*`) need no API key; OpenKB skips the missing-key warning for them.
378-
379-
</details>
245+
The full settings reference — `entity_types`, OAuth providers (`chatgpt/*`, `github_copilot/*`), and LiteLLM tuning (timeouts for slow local runtimes like Ollama / LM Studio, `drop_params`, GitHub Copilot headers, install notes) — is in **[`examples/configuration/`](examples/configuration/)**.
380246

381247
### PageIndex Setup
382248

@@ -398,6 +264,8 @@ Set `PAGEINDEX_API_KEY` in your `.env` to enable cloud features:
398264
PAGEINDEX_API_KEY=your_pageindex_api_key
399265
```
400266

267+
→ **Example:** local vs. cloud indexing, and importing a cloud-indexed doc — [`examples/pageindex-cloud/`](examples/pageindex-cloud/).
268+
401269
### AGENTS.md
402270

403271
The `wiki/AGENTS.md` file defines wiki structure and conventions. It's the LLM's instruction manual for maintaining the wiki. Customize it to change how your wiki is organized.

examples/README.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# OpenKB examples
2+
3+
Hands-on, organized by use case. Each folder is one case — a short walkthrough
4+
plus the **real artifact** OpenKB produced for it (generated, not hand-written).
5+
6+
> **Test inputs** live in [`docs/`](docs/) — the sample PDFs the cases ingest.
7+
> They're kept out of git on purpose (large / third-party files); drop your own
8+
> documents there to follow along.
9+
10+
## Cases
11+
12+
| Folder | What it shows | Real artifact inside |
13+
| --- | --- | --- |
14+
| [`configuration/`](configuration/) | `init`, `config.yaml`, API keys, LiteLLM tuning (Ollama, Copilot) ||
15+
| [`commands/`](commands/) | the everyday loop: `add` · `query` · `remove` · `recompile` · `lint` · `list` · `status` | a compiled [`sample-wiki/`](commands/sample-wiki/) |
16+
| [`pageindex-cloud/`](pageindex-cloud/) | long documents: local vs. cloud indexing, and importing cloud-indexed docs ||
17+
| [`chat/`](chat/) | the interactive REPL: persistent sessions + slash commands ||
18+
| [`skills/`](skills/) | distill a redistributable agent skill from your wiki | [`transformer-attention/SKILL.md`](skills/transformer-attention/SKILL.md) |
19+
| [`slides/`](slides/) | generate a single-file HTML slide deck | [`attention-intro.html`](slides/attention-intro.html) |
20+
| [`visualize/`](visualize/) | render the wiki as an interactive knowledge graph | [`graph.html`](visualize/graph.html) |
21+
22+
## It's all from one paper
23+
24+
The compiled `sample-wiki/`, the skill, the deck, and the graph were **all**
25+
generated by running OpenKB over a single document —
26+
[`docs/attention-is-all-you-need.pdf`](docs/attention-is-all-you-need.pdf) — with
27+
`gpt-5.4`:
28+
29+
```bash
30+
mkdir my-kb && cd my-kb
31+
openkb init --model gpt-5.4 --language en
32+
33+
openkb add /path/to/examples/docs/attention-is-all-you-need.pdf # → commands/sample-wiki/
34+
openkb query "How does attention replace recurrence?" --save # → commands/sample-wiki/explorations/
35+
openkb skill new transformer-attention "Reason about the Transformer…" # → skills/
36+
openkb deck new attention-intro "A short intro deck on the Transformer…" # → slides/
37+
openkb visualize # → visualize/
38+
```
39+
40+
Your generated text will differ run to run (LLM output isn't deterministic) — the
41+
*structure* is what's stable.
42+
43+
New to OpenKB? Read [`configuration/`](configuration/) first, then
44+
[`commands/`](commands/).

examples/chat/README.md

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
# Chat TUI
2+
3+
`openkb chat` is an interactive REPL over your wiki. Unlike `query` (one-shot), a
4+
chat session keeps context across turns, can edit the KB through slash commands,
5+
and is saved so you can resume it later.
6+
7+
```bash
8+
openkb chat
9+
```
10+
11+
```text
12+
OpenKB Chat
13+
~/research-kb · anthropic/claude-sonnet-4-6 · session 20260625-143022-a1x
14+
Type /help for commands, Ctrl-D to exit, Ctrl-C to abort the current response.
15+
16+
>>> How do the two papers differ on their use of attention?
17+
Both rely on scaled dot-product attention, but…
18+
· read_wiki_file(path="concepts/self-attention.md")
19+
· read_wiki_file(path="summaries/deepseek-r1.md")
20+
21+
>>> /save attention-comparison
22+
Saved to wiki/explorations/attention-comparison-20260625.md
23+
```
24+
25+
Answers are grounded in your wiki: the agent reads `concepts/`, `summaries/`,
26+
`entities/`, and source files, and shows the tool calls it makes. Responses render
27+
as rich Markdown (headings, tables, code) in a terminal.
28+
29+
---
30+
31+
## Persistent sessions
32+
33+
Every conversation is stored as JSON in `<kb>/.openkb/chats/`. Manage them with:
34+
35+
```bash
36+
openkb chat --list # table of sessions: id · turns · updated · title
37+
openkb chat --resume # resume the most recent session
38+
openkb chat --resume 20260625 # resume by id or unique prefix
39+
openkb chat --delete 20260625 # delete a session
40+
```
41+
42+
Resuming replays the last few turns so you have context:
43+
44+
```text
45+
$ openkb chat --resume
46+
Resumed session · 4 turn(s)
47+
[3] >>> How do the two papers differ on their use of attention?
48+
[3] Both rely on scaled dot-product attention, but…
49+
[4] >>> /save attention-comparison
50+
```
51+
52+
---
53+
54+
## Slash commands
55+
56+
Inside the REPL, lines starting with `/` are commands rather than questions. Run
57+
`/help` to see the current set; the built-ins are:
58+
59+
| Command | What it does |
60+
| --- | --- |
61+
| `/help` | List available commands |
62+
| `/exit`, `/quit` | Leave the REPL (Ctrl-D also works) |
63+
| `/clear` | Start a fresh session (the previous one is saved) |
64+
| `/save [name]` | Export the transcript to `wiki/explorations/<name>-<date>.md` |
65+
| `/status` | Show KB status without leaving chat |
66+
| `/list` | List documents in the KB |
67+
| `/lint` | Run the integrity + knowledge lint |
68+
| `/add <path>` | Ingest a file or directory (Tab-completes paths) |
69+
| `/skill new <name> "<intent>"` | Compile a skill from the wiki — see [`skills/`](../skills/) |
70+
| `/deck new [--critique] [--skill <name>] <name> "<intent>"` | Generate an HTML deck — see [`slides/`](../slides/) |
71+
| `/critique <path>` | Run the HTML critic over an existing deck/page |
72+
73+
Slash commands run inline — errors are reported and the conversation continues;
74+
Ctrl-C aborts the running command without ending the session.
75+
76+
### Why slash commands matter
77+
78+
They turn chat into a workbench: ask a question, realize you're missing a source,
79+
`/add` it, and keep going — all in one session. Because the chat agent can write
80+
to `wiki/explorations/**` and `output/**`, asking it to "write that up as a note"
81+
or "turn this into a skill" produces real files you keep.
82+
83+
---
84+
85+
## Plain output for piping or logs
86+
87+
```bash
88+
openkb chat --no-color # disable colored output entirely
89+
openkb chat --raw # show raw Markdown source, keep prompt/tool colors
90+
```
91+
92+
`--no-color` also respects the `NO_COLOR` environment variable.

0 commit comments

Comments
 (0)