@zosmaai/pi-llm-wiki 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/ci.yml +44 -0
- package/.github/workflows/release.yml +76 -0
- package/README.md +356 -0
- package/assets/README.md +13 -0
- package/biome.json +27 -0
- package/extensions/llm-wiki-tools.ts +705 -0
- package/package.json +61 -0
- package/prompts/wiki-digest.md +23 -0
- package/prompts/wiki-discover.md +29 -0
- package/prompts/wiki-ingest.md +30 -0
- package/prompts/wiki-init.md +30 -0
- package/prompts/wiki-lint.md +29 -0
- package/prompts/wiki-query.md +32 -0
- package/prompts/wiki-run.md +35 -0
- package/prompts/wiki-status.md +33 -0
- package/skills/llm-wiki/SKILL.md +426 -0
- package/skills/llm-wiki/templates/DASHBOARD.md +50 -0
- package/skills/llm-wiki/templates/INDEX.md +33 -0
- package/skills/llm-wiki/templates/LOG.md +9 -0
- package/skills/llm-wiki/templates/config.yaml +38 -0
- package/skills/llm-wiki/templates/pages/concept.md +34 -0
- package/skills/llm-wiki/templates/pages/entity.md +31 -0
- package/skills/llm-wiki/templates/pages/source.md +45 -0
- package/skills/llm-wiki/templates/pages/synthesis.md +40 -0
- package/test/llm-wiki.test.ts +404 -0
- package/tsconfig.json +19 -0
- package/vitest.config.ts +16 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main, master]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main, master]
|
|
8
|
+
|
|
9
|
+
concurrency:
|
|
10
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
11
|
+
cancel-in-progress: true
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
quality:
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
strategy:
|
|
17
|
+
matrix:
|
|
18
|
+
node-version: [18, 20, 22]
|
|
19
|
+
|
|
20
|
+
steps:
|
|
21
|
+
- uses: actions/checkout@v4
|
|
22
|
+
|
|
23
|
+
- uses: actions/setup-node@v4
|
|
24
|
+
with:
|
|
25
|
+
node-version: ${{ matrix.node-version }}
|
|
26
|
+
cache: npm
|
|
27
|
+
|
|
28
|
+
- run: npm ci
|
|
29
|
+
|
|
30
|
+
- name: Type Check
|
|
31
|
+
run: npm run typecheck
|
|
32
|
+
|
|
33
|
+
- name: Lint
|
|
34
|
+
run: npm run lint
|
|
35
|
+
|
|
36
|
+
- name: Run Tests
|
|
37
|
+
run: npm test
|
|
38
|
+
|
|
39
|
+
- name: Upload Coverage
|
|
40
|
+
if: ${{ matrix.node-version == 22 && github.event_name == 'push' }}
|
|
41
|
+
uses: actions/upload-artifact@v4
|
|
42
|
+
with:
|
|
43
|
+
name: coverage
|
|
44
|
+
path: coverage/
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*"
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
release:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
permissions:
|
|
12
|
+
contents: write
|
|
13
|
+
id-token: write
|
|
14
|
+
|
|
15
|
+
steps:
|
|
16
|
+
- uses: actions/checkout@v4
|
|
17
|
+
with:
|
|
18
|
+
fetch-depth: 0
|
|
19
|
+
|
|
20
|
+
- uses: actions/setup-node@v4
|
|
21
|
+
with:
|
|
22
|
+
node-version: 22
|
|
23
|
+
registry-url: https://registry.npmjs.org
|
|
24
|
+
cache: npm
|
|
25
|
+
|
|
26
|
+
- run: npm ci
|
|
27
|
+
|
|
28
|
+
- name: Type Check
|
|
29
|
+
run: npm run typecheck
|
|
30
|
+
|
|
31
|
+
- name: Lint
|
|
32
|
+
run: npm run lint
|
|
33
|
+
|
|
34
|
+
- name: Run Tests
|
|
35
|
+
run: npm test
|
|
36
|
+
|
|
37
|
+
- name: Extract Version from Tag
|
|
38
|
+
id: version
|
|
39
|
+
run: echo "VERSION=${GITHUB_REF_NAME#v}" >> $GITHUB_OUTPUT
|
|
40
|
+
|
|
41
|
+
- name: Update package.json version
|
|
42
|
+
run: npm version ${{ steps.version.outputs.VERSION }} --no-git-tag-version --allow-same-version
|
|
43
|
+
|
|
44
|
+
- name: Generate Release Notes
|
|
45
|
+
id: notes
|
|
46
|
+
run: |
|
|
47
|
+
CHANGELOG=$(git log --pretty=format:"- %s (%h)" $(git describe --tags --abbrev=0 HEAD~1 2>/dev/null || git rev-list --max-parents=0 HEAD)..HEAD -- . 2>/dev/null || echo "- Initial release")
|
|
48
|
+
echo "NOTES<<EOF" >> $GITHUB_OUTPUT
|
|
49
|
+
echo "$CHANGELOG" >> $GITHUB_OUTPUT
|
|
50
|
+
echo "EOF" >> $GITHUB_OUTPUT
|
|
51
|
+
|
|
52
|
+
- name: Publish to npm
|
|
53
|
+
run: npm publish --provenance --access public
|
|
54
|
+
env:
|
|
55
|
+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
56
|
+
|
|
57
|
+
- name: Create GitHub Release
|
|
58
|
+
uses: softprops/action-gh-release@v2
|
|
59
|
+
with:
|
|
60
|
+
name: "@zosmaai/pi-llm-wiki v${{ steps.version.outputs.VERSION }}"
|
|
61
|
+
body: |
|
|
62
|
+
## 📦 @zosmaai/pi-llm-wiki v${{ steps.version.outputs.VERSION }}
|
|
63
|
+
|
|
64
|
+
${{ steps.notes.outputs.NOTES }}
|
|
65
|
+
|
|
66
|
+
### Install
|
|
67
|
+
\`\`\`bash
|
|
68
|
+
pi install npm:@zosmaai/pi-llm-wiki@${{ steps.version.outputs.VERSION }}
|
|
69
|
+
\`\`\`
|
|
70
|
+
|
|
71
|
+
### What's Included
|
|
72
|
+
- **Skill**: Self-maintaining wiki schema (SKILL.md)
|
|
73
|
+
- **Extension**: 5 TypeScript tools (wiki_ingest, wiki_status_report, wiki_lint_report, wiki_discover_sources, wiki_watch)
|
|
74
|
+
- **Prompt Templates**: 8 slash commands (/wiki:init, :ingest, :query, :lint, :discover, :run, :status, :digest)
|
|
75
|
+
- **Templates**: INDEX.md, LOG.md, DASHBOARD.md, config.yaml, 4 page templates
|
|
76
|
+
generate_release_notes: false
|
package/README.md
ADDED
|
@@ -0,0 +1,356 @@
|
|
|
1
|
+
# 🧠 @zosmaai/pi-llm-wiki
|
|
2
|
+
|
|
3
|
+
> **Self-maintaining, Obsidian-compatible knowledge base for your pi coding agent.**
|
|
4
|
+
> Following Andrej Karpathy's LLM Wiki pattern — drop in sources, let the LLM build and maintain the wiki.
|
|
5
|
+
|
|
6
|
+
[](https://pi.dev/packages)
|
|
7
|
+
[](LICENSE)
|
|
8
|
+
[](https://gist.github.com/karpathy/442a6bf555914893e9891c19de94f)
|
|
9
|
+
[](https://obsidian.md)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## ✨ Features
|
|
14
|
+
|
|
15
|
+
| Capability | Description |
|
|
16
|
+
| ----------------- | ------------------------------------------------------------------------------------------------------------------ |
|
|
17
|
+
| **📥 Ingest** | Drop any source into `raw/` — the LLM reads, summarizes, extracts entities & concepts, cross-references everything |
|
|
18
|
+
| **🔍 Query** | Ask questions against a persistent, interlinked knowledge base — not raw chunks |
|
|
19
|
+
| **🧹 Lint** | Health-check the wiki: contradictions, orphans, missing pages, stale claims, knowledge gaps |
|
|
20
|
+
| **🌐 Discover** | Auto-find new sources from the web based on your topics and known gaps |
|
|
21
|
+
| **🔄 Full Cycle** | `run` = discover → ingest → lint. One command to refresh everything |
|
|
22
|
+
| **⏰ Watch** | Schedule automatic updates (daily/weekly/hourly) via pi's cron system |
|
|
23
|
+
| **📊 Status** | Quick dashboard showing wiki size, health, and last activity |
|
|
24
|
+
| **📓 Digest** | Daily/weekly summaries of what changed in the wiki |
|
|
25
|
+
|
|
26
|
+
### Two Modes
|
|
27
|
+
|
|
28
|
+
- **👤 Personal Wiki** — Learning, journaling, book notes, health, goals, reflections
|
|
29
|
+
- **🏢 Company Wiki** — Competitor tracking, market research, customer calls, internal docs, change detection
|
|
30
|
+
|
|
31
|
+
### Obsidian Integration
|
|
32
|
+
|
|
33
|
+
Every `[[wikilink]]` the LLM creates becomes a visible connection in Obsidian's graph view. Includes Dataview dashboard, frontmatter for structured queries, and Marp-ready slide decks.
|
|
34
|
+
|
|
35
|
+
> "The wiki stays maintained because the cost of maintenance is near zero." — Andrej Karpathy
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## 📦 What's Included
|
|
40
|
+
|
|
41
|
+
```
|
|
42
|
+
@zosmaai/pi-llm-wiki/
|
|
43
|
+
├── 📜 skills/llm-wiki/SKILL.md ← Core schema: architecture, workflows, conventions
|
|
44
|
+
│ ├── templates/INDEX.md ← Master catalog template
|
|
45
|
+
│ ├── templates/LOG.md ← Activity log template
|
|
46
|
+
│ ├── templates/DASHBOARD.md ← Obsidian Dataview dashboard
|
|
47
|
+
│ ├── templates/config.yaml ← Default configuration
|
|
48
|
+
│ └── templates/pages/ ← Page templates (entity, concept, source, synthesis)
|
|
49
|
+
├── 🔧 extensions/llm-wiki-tools.ts ← 5 custom tools for the LLM:
|
|
50
|
+
│ ├── wiki_ingest Process new sources and update wiki pages
|
|
51
|
+
│ ├── wiki_status_report Report wiki health and statistics
|
|
52
|
+
│ ├── wiki_lint_report Scan for contradictions, orphans, gaps
|
|
53
|
+
│ ├── wiki_discover_sources Find new source material from the web
|
|
54
|
+
│ └── wiki_watch Schedule auto-updates
|
|
55
|
+
└── 💬 prompts/ ← 8 slash commands:
|
|
56
|
+
├── /wiki:init Initialize a new wiki
|
|
57
|
+
├── /wiki:ingest Process new sources
|
|
58
|
+
├── /wiki:query Ask questions against the wiki
|
|
59
|
+
├── /wiki:lint Health check
|
|
60
|
+
├── /wiki:discover Auto-discover sources
|
|
61
|
+
├── /wiki:run Full cycle (discover → ingest → lint)
|
|
62
|
+
├── /wiki:status Wiki health overview
|
|
63
|
+
└── /wiki:digest Daily/weekly summary
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
---
|
|
67
|
+
|
|
68
|
+
## 🚀 Installation
|
|
69
|
+
|
|
70
|
+
### Prerequisites
|
|
71
|
+
|
|
72
|
+
- [pi coding agent](https://pi.dev) installed
|
|
73
|
+
- Node.js 20+
|
|
74
|
+
|
|
75
|
+
### Via npm (recommended)
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
pi install npm:@zosmaai/pi-llm-wiki@latest
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
### Via git
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
pi install git:github.com/zosmaai/pi-llm-wiki@v0.1.0
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### Via local path (development)
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
git clone https://github.com/zosmaai/pi-llm-wiki.git
|
|
91
|
+
pi install ./pi-llm-wiki
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
### Verify Installation
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
pi list
|
|
98
|
+
# Should show: @zosmaai/pi-llm-wiki
|
|
99
|
+
|
|
100
|
+
# Check loaded resources:
|
|
101
|
+
pi --list-skills | grep llm-wiki
|
|
102
|
+
pi --list-tools | grep wiki
|
|
103
|
+
# Should show: wiki_ingest, wiki_status_report, wiki_lint_report, wiki_discover_sources, wiki_watch
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
---
|
|
107
|
+
|
|
108
|
+
## 🎯 Quick Start
|
|
109
|
+
|
|
110
|
+
### 1️⃣ Initialize a new wiki
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
pi
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
Then inside pi:
|
|
117
|
+
|
|
118
|
+
```
|
|
119
|
+
/wiki:init "AI Engineering"
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
This creates your wiki directory structure and template files.
|
|
123
|
+
|
|
124
|
+
### 2️⃣ Add your first sources
|
|
125
|
+
|
|
126
|
+
Drop content into `raw/`:
|
|
127
|
+
|
|
128
|
+
- Use [Obsidian Web Clipper](https://obsidian.md/clipper) to save articles
|
|
129
|
+
- Save meeting notes, transcripts, or research papers
|
|
130
|
+
- Export Slack threads or email threads
|
|
131
|
+
|
|
132
|
+
### 3️⃣ Ingest
|
|
133
|
+
|
|
134
|
+
```
|
|
135
|
+
/wiki:ingest
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
The LLM reads every new source, creates wiki pages, cross-references everything, and builds the index. A single source typically generates 5-15 wiki pages (summary + entities + concepts + cross-refs).
|
|
139
|
+
|
|
140
|
+
### 4️⃣ Query
|
|
141
|
+
|
|
142
|
+
```
|
|
143
|
+
/wiki:query What are the key patterns in modern AI engineering?
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
The LLM answers from your wiki, not from general knowledge — giving you answers grounded in your curated sources.
|
|
147
|
+
|
|
148
|
+
### 5️⃣ Keep it fresh
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
# Auto-update daily at 8 AM
|
|
152
|
+
/wiki:run --schedule daily
|
|
153
|
+
|
|
154
|
+
# Or run manually anytime
|
|
155
|
+
/wiki:run
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
## 🏗️ Architecture
|
|
161
|
+
|
|
162
|
+
The LLM Wiki follows a three-layer architecture:
|
|
163
|
+
|
|
164
|
+
```
|
|
165
|
+
┌─────────────────────────────────────────────────────────┐
|
|
166
|
+
│ YOU (curate & ask) │
|
|
167
|
+
├──────────────┬──────────────────────┬────────────────────┤
|
|
168
|
+
│ wiki/ │ outputs/ │ Obsidian vault │
|
|
169
|
+
│ (read only) │ (reports, digests) │ (graph view, UI) │
|
|
170
|
+
├──────────────┴──────────────────────┴────────────────────┤
|
|
171
|
+
│ LLM (writes & maintains) │
|
|
172
|
+
├──────────────────────┬───────────────────────────────────┤
|
|
173
|
+
│ raw/ │ schema/SKILL.md │
|
|
174
|
+
│ (immutable sources) │ (rules & conventions) │
|
|
175
|
+
└──────────────────────┴───────────────────────────────────┘
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
### Directory Structure
|
|
179
|
+
|
|
180
|
+
```
|
|
181
|
+
my-wiki/
|
|
182
|
+
├── raw/ ← You add sources here (immutable)
|
|
183
|
+
│ ├── articles/ Web articles (markdown)
|
|
184
|
+
│ ├── papers/ Research papers
|
|
185
|
+
│ ├── notes/ Personal notes
|
|
186
|
+
│ ├── slack/ Slack thread exports
|
|
187
|
+
│ └── assets/ Downloaded images
|
|
188
|
+
├── wiki/ ← LLM manages this entirely
|
|
189
|
+
│ ├── INDEX.md Master catalog
|
|
190
|
+
│ ├── LOG.md Activity log
|
|
191
|
+
│ ├── DASHBOARD.md Obsidian Dataview dashboard
|
|
192
|
+
│ ├── entities/ People, orgs, tools, products
|
|
193
|
+
│ ├── concepts/ Ideas, patterns, frameworks
|
|
194
|
+
│ ├── sources/ One summary per source
|
|
195
|
+
│ ├── syntheses/ Cross-cutting analyses
|
|
196
|
+
│ └── changes/ Change detection records
|
|
197
|
+
├── outputs/ Reports and digests
|
|
198
|
+
├── config.yaml Wiki configuration
|
|
199
|
+
└── .discoveries/ Auto-discovery metadata
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
---
|
|
203
|
+
|
|
204
|
+
## 💬 All Commands
|
|
205
|
+
|
|
206
|
+
| Command | Description | Example |
|
|
207
|
+
| ---------------- | ------------------- | ----------------------------------------- |
|
|
208
|
+
| `/wiki:init` | Create a new wiki | `/wiki:init "Rust Programming"` |
|
|
209
|
+
| `/wiki:ingest` | Process new sources | `/wiki:ingest raw/articles/my-article.md` |
|
|
210
|
+
| `/wiki:query` | Ask a question | `/wiki:query "Compare RAG vs LLM Wiki"` |
|
|
211
|
+
| `/wiki:lint` | Health check | `/wiki:lint --fix` |
|
|
212
|
+
| `/wiki:discover` | Find new sources | `/wiki:discover --topic "AI agents"` |
|
|
213
|
+
| `/wiki:run` | Full cycle | `/wiki:run --schedule daily` |
|
|
214
|
+
| `/wiki:status` | Show health | `/wiki:status` |
|
|
215
|
+
| `/wiki:digest` | Daily summary | `/wiki:digest --period weekly` |
|
|
216
|
+
|
|
217
|
+
---
|
|
218
|
+
|
|
219
|
+
## 🔧 Custom Tools (Extension)
|
|
220
|
+
|
|
221
|
+
The included TypeScript extension registers 5 tools the LLM can call directly:
|
|
222
|
+
|
|
223
|
+
| Tool | Purpose |
|
|
224
|
+
| ----------------------- | ----------------------------------------------- |
|
|
225
|
+
| `wiki_ingest` | Prepare and track files for ingestion |
|
|
226
|
+
| `wiki_status_report` | Gather wiki statistics and health metrics |
|
|
227
|
+
| `wiki_lint_report` | Scan for issues (orphans, contradictions, gaps) |
|
|
228
|
+
| `wiki_discover_sources` | Prepare discovery parameters from config |
|
|
229
|
+
| `wiki_watch` | Generate schedule commands |
|
|
230
|
+
|
|
231
|
+
These tools handle the scaffolding and bookkeeping so the LLM can focus on the actual knowledge work — reading, synthesizing, and writing wiki pages.
|
|
232
|
+
|
|
233
|
+
---
|
|
234
|
+
|
|
235
|
+
## 📓 Using with Obsidian
|
|
236
|
+
|
|
237
|
+
1. Open the `wiki/` directory as an Obsidian vault
|
|
238
|
+
2. Install these plugins:
|
|
239
|
+
- [Dataview](https://github.com/blacksmithgu/obsidian-dataview) — Query pages by frontmatter
|
|
240
|
+
- [Graph View](https://obsidian.md) (built-in) — Visualize [[wikilink]] connections
|
|
241
|
+
- [Spaced Repetition](https://github.com/st3v3nmw/obsidian-spaced-repetition) — Flashcards
|
|
242
|
+
- [Charts View](https://github.com/caronchen/obsidian-chartsview-plugin) — Dashboard analytics
|
|
243
|
+
- [Marp](https://marp.app/) — Markdown slide decks
|
|
244
|
+
3. Browse the graph view to discover connections the LLM found
|
|
245
|
+
4. Use the `DASHBOARD.md` for live analytics
|
|
246
|
+
|
|
247
|
+
### Obsidian Web Clipper
|
|
248
|
+
|
|
249
|
+
Use the [Obsidian Web Clipper](https://obsidian.md/clipper) browser extension to save articles directly into `raw/articles/`. Set attachment folder to `raw/assets/` in Obsidian settings.
|
|
250
|
+
|
|
251
|
+
---
|
|
252
|
+
|
|
253
|
+
## 🏢 Personal vs. Company Wiki
|
|
254
|
+
|
|
255
|
+
### Personal Wiki (`config.yaml: mode: personal`)
|
|
256
|
+
|
|
257
|
+
Best for: Learning, research, journaling, book notes, health tracking, goals.
|
|
258
|
+
|
|
259
|
+
- Extra folders: `wiki/journal/`, `wiki/goals/`
|
|
260
|
+
- Daily journal entries can be ingested as raw sources
|
|
261
|
+
- Track people you meet, books you read, courses you take
|
|
262
|
+
|
|
263
|
+
### Company Wiki (`config.yaml: mode: company`)
|
|
264
|
+
|
|
265
|
+
Best for: Competitive intelligence, market research, customer insights, internal documentation.
|
|
266
|
+
|
|
267
|
+
- Extra folders: `wiki/decisions/`, `wiki/changes/`
|
|
268
|
+
- **Change detection** — Re-check competitor sources for pricing, feature, and positioning changes
|
|
269
|
+
- Confidence levels in frontmatter: `high | medium | low`
|
|
270
|
+
- Slack/email thread exports as sources
|
|
271
|
+
- Generate battlecards with `/wiki:query "Create a battlecard for Competitor X"`
|
|
272
|
+
|
|
273
|
+
---
|
|
274
|
+
|
|
275
|
+
## ⏰ Scheduling (Auto-Update)
|
|
276
|
+
|
|
277
|
+
Keep your wiki current without thinking about it:
|
|
278
|
+
|
|
279
|
+
```bash
|
|
280
|
+
# Inside pi
|
|
281
|
+
/wiki:run --schedule daily # Discover → ingest → lint every day at 8 AM
|
|
282
|
+
/wiki:run --schedule weekly # Every Monday at 9 AM
|
|
283
|
+
/wiki:run --schedule hourly # Every hour (for fast-moving topics)
|
|
284
|
+
```
|
|
285
|
+
|
|
286
|
+
The scheduler uses pi's built-in `schedule_prompt` system. All operations run in the background and the wiki stays updated.
|
|
287
|
+
|
|
288
|
+
---
|
|
289
|
+
|
|
290
|
+
## 📚 Examples
|
|
291
|
+
|
|
292
|
+
### Research Wiki
|
|
293
|
+
|
|
294
|
+
```bash
|
|
295
|
+
/wiki:init "LLM Agents"
|
|
296
|
+
# Drop 5 papers into raw/papers/
|
|
297
|
+
/wiki:ingest
|
|
298
|
+
# Creates ~30-50 wiki pages (entities, concepts, cross-refs)
|
|
299
|
+
/wiki:query "What are the main approaches to tool use in LLM agents?"
|
|
300
|
+
/wiki:lint
|
|
301
|
+
```
|
|
302
|
+
|
|
303
|
+
### Book Companion
|
|
304
|
+
|
|
305
|
+
```bash
|
|
306
|
+
/wiki:init "Dune" --mode personal
|
|
307
|
+
# Drop chapter notes into raw/notes/
|
|
308
|
+
/wiki:ingest raw/notes/ch01-opening-test.md
|
|
309
|
+
/wiki:query "Who are the main factions and what do they want?"
|
|
310
|
+
/wiki:query "Create a timeline of events up to Chapter 5"
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
### Competitive Intelligence
|
|
314
|
+
|
|
315
|
+
```bash
|
|
316
|
+
/wiki:init "PM Tool Market" --mode company
|
|
317
|
+
# Drop competitor landing pages, reviews, pricing pages
|
|
318
|
+
/wiki:ingest
|
|
319
|
+
/wiki:query "Create a comparison table of Linear, Notion, and Jira"
|
|
320
|
+
/wiki:run --schedule weekly
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
---
|
|
324
|
+
|
|
325
|
+
## 🤝 Contributing
|
|
326
|
+
|
|
327
|
+
Contributions are welcome! This package is maintained at [zosmaai/pi-llm-wiki](https://github.com/zosmaai/pi-llm-wiki).
|
|
328
|
+
|
|
329
|
+
1. Fork the repo
|
|
330
|
+
2. Create a feature branch
|
|
331
|
+
3. Make your changes
|
|
332
|
+
4. Submit a PR
|
|
333
|
+
|
|
334
|
+
### Development
|
|
335
|
+
|
|
336
|
+
```bash
|
|
337
|
+
git clone https://github.com/zosmaai/pi-llm-wiki.git
|
|
338
|
+
cd pi-llm-wiki
|
|
339
|
+
npm install
|
|
340
|
+
pi install ./
|
|
341
|
+
```
|
|
342
|
+
|
|
343
|
+
---
|
|
344
|
+
|
|
345
|
+
## 📄 License
|
|
346
|
+
|
|
347
|
+
MIT © zosmaai
|
|
348
|
+
|
|
349
|
+
---
|
|
350
|
+
|
|
351
|
+
## 🙏 Acknowledgments
|
|
352
|
+
|
|
353
|
+
- **Andrej Karpathy** — For the [LLM Wiki pattern](https://gist.github.com/karpathy/442a6bf555914893e9891c11519de94f) that inspired this package
|
|
354
|
+
- **mduongvandinh** — For the comprehensive [llm-wiki](https://github.com/mduongvandinh/llm-wiki) reference implementation
|
|
355
|
+
- **tonbistudio** — For the [clean template](https://github.com/tonbistudio/llm-wiki) this draws from
|
|
356
|
+
- **Vannevar Bush** — For imagining the Memex in 1945. LLMs finally make it practical.
|
package/assets/README.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# @zosmaai/pi-llm-wiki Assets
|
|
2
|
+
|
|
3
|
+
Placeholder for gallery screenshots.
|
|
4
|
+
|
|
5
|
+
To generate a screenshot:
|
|
6
|
+
|
|
7
|
+
1. Create a wiki using `/wiki:init`
|
|
8
|
+
2. Add a few sources and run `/wiki:ingest`
|
|
9
|
+
3. Open `wiki/` in Obsidian for the graph view screenshot
|
|
10
|
+
4. Save as `assets/screenshot.png`
|
|
11
|
+
|
|
12
|
+
The screenshot URL in package.json should point to:
|
|
13
|
+
`https://raw.githubusercontent.com/zosmaai/pi-llm-wiki/main/assets/screenshot.png`
|
package/biome.json
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/1.9.4/schema.json",
|
|
3
|
+
"organizeImports": {
|
|
4
|
+
"enabled": true
|
|
5
|
+
},
|
|
6
|
+
"linter": {
|
|
7
|
+
"enabled": true,
|
|
8
|
+
"rules": {
|
|
9
|
+
"recommended": true,
|
|
10
|
+
"style": {
|
|
11
|
+
"noNonNullAssertion": "off"
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"formatter": {
|
|
16
|
+
"enabled": true,
|
|
17
|
+
"indentStyle": "space",
|
|
18
|
+
"indentWidth": 2,
|
|
19
|
+
"lineWidth": 100
|
|
20
|
+
},
|
|
21
|
+
"javascript": {
|
|
22
|
+
"formatter": {
|
|
23
|
+
"quoteStyle": "double",
|
|
24
|
+
"semicolons": "always"
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|