Skip to content
Research
Command

/ingest

Ingest source material into an active wiki. Accepts URLs, file paths, PDFs, freeform text, or processes the inbox. Supports tweets via Grok MCP.

BOOST
From plugin
nvk-llm-wiki
1.4k28 skills28 commands
Install
> /plugin marketplace add nvk/llm-wiki
> /plugin install wiki@llm-wiki

How it fires

How this command gets triggered: by you, by Claude, or both.

  • Fires itselfClaude auto-loads it when your prompt matches the work.
  • You can call itInvoke it directly when you want it.
  • Slash command/ingest

Context preview

What this command does when you run it.

Ingest source material into an active wiki. Accepts URLs, file paths, PDFs, freeform text, or processes the inbox. Supports tweets via Grok MCP.

Command definition

ingest.md
description: "Ingest source material into an active wiki. Accepts URLs, file paths, PDFs, freeform text, or processes the inbox. Supports tweets via Grok MCP."
argument-hint: "<url|filepath|\"text\"> [--type articles|papers|repos|notes|data] [--title \"Title\"] [--inbox] [--keep] [--wiki <name>] [--local] [--auto-classify] [--new-topic <name>] [--project <slug>] [--include-archived]"
allowed-tools: Read, Write, Edit, Glob, Grep, Bash(ls:*), Bash(wc:*), Bash(date:*), Bash(mv:*), Bash(mkdir:*), Bash(basename:*), Bash(file:*), Bash(curl:*), Bash(mktemp:*), Bash(rm:*), Bash(pdftotext:*), Bash(python3:*), WebFetch, WebSearch

Your task

**Resolve the wiki.** Do NOT search the filesystem or read reference files — follow these steps: 1. Read `$HOME/.config/llm-wiki/config.json`. If it has `hub_path`, expand leading `~` only (not tildes in `com~apple~CloudDocs`) and prefer that path; use `resolved_path` only as a fallback cache when the expanded `hub_path` is unavailable and `resolved_path` is initialized. If config has only `resolved_path`, use it. If the configured path can be statted but reading `wikis.json` or listing `topics/` fails with `Operation not permitted`, stop and ask the user to grant Full Disk Access/iCloud Drive access to the launcher; do not fall back to `~/wiki` or `resolved_path`. Do not write machine-specific `resolved_path` into shared configs. 2. If no config → read `$HOME/wiki/_index.md`. If it exists → HUB = `$HOME/wiki`. If nothing found, ask the user where to create the wiki. 3. **Wiki location** (first match): `--local` → `.wiki/` in CWD; `--wiki <name>` → `HUB/wikis.json` lookup with portable path resolution (`<HUB>`, `~`, absolute, or HUB-relative); if the registry path is stale, fall back to `HUB/topics/<name>`; CWD has `.wiki/` → use it; else → HUB. 4. Read `<wiki>/_index.md` to verify. If missing and `--new-topic <name>` is set → create the topic wiki (see below). If missing and no `--new-topic` → stop with "No wiki found. Use `--new-topic <name>` to create one, or run `/wiki init` first."

Read the ingestion protocol at `skills/wiki-manager/references/ingestion.md` and the structure spec at `skills/wiki-manager/references/wiki-structure.md`. Then ingest source material.

Collection handoff

If the user is trying to import a bounded upstream corpus rather than one source item, stop and hand off to `/wiki:ingest-collection` with the same wiki flags. Signals include: "import wiki", "mirror wiki", "bulk ingest", "ingest collection", "ingest repo", "import repo", "split CSV into messages", "Wayback snapshots", MediaWiki dumps (`.xml`, `.xml.bz2`, `.xml.gz`), MediaWiki `api.php`, CDX API URLs, or a GitHub/GitLab repo plus words like "all", "docs", "BIPs", "wiki", or "collection".

Do not reduce a collection to the repository README or one fetched web page. Collection imports need a manifest plus one raw child source per upstream page/spec/proposal.

Inventory and dataset awareness

If the user asks to "track", "watch", "keep inventory", "candidate", "queue", or "decide later" instead of ingesting now, stop and hand off to `/wiki:inventory`. A durable candidate record is better than ingesting a source the user has not accepted.

If the source is a large dataset, archive, compressed dump, database, or query-oriented corpus, stop and hand off to `/wiki:dataset` or `/wiki:ingest-collection` as appropriate. Do not squeeze large data into `raw/data/` because it is technically readable.

After a successful ingest, check active inventory records by title/source when cheap. If a matching record exists, report the suggested linkage and status change (`sources:` add raw path, maybe status `ingested`) instead of silently leaving the tracking state stale.

Archive awareness

Do not ingest into archived topic wikis by default. If `--wiki <name>` resolves to `status: archived` or a path under `topics/.archive/`, stop and ask the user to restore it with `/wiki:archive restore <name>` or rerun with `--include-archived`. If the user explicitly includes archived content, write only inside that archived topic path and keep the topic archived.

`--new-topic` branch

When `--new-topic` is set, override the standard resolution: 1. Derive a slug from the topic name: lowercase, hyphens, no special chars, max 40 chars 2. If HUB doesn't exist, create it (wikis.json + _index.md + log.md + topics/) 3. Create the new topic wiki at `HUB/topics/<slug>/` following the full init protocol (directory structure, .obsidian/, empty _index.md files, config.md, log.md) 4. Register in `HUB/wikis.json` using a portable relative path (`topics/<slug>`) and update hub `_index.md` 5. Target this new wiki for ingestion

`--project <slug>` flag

**--project <slug>**: Tag the ingested source with `project: <slug>` frontmatter. The raw file still lands in the normal `raw/<type>/` location (sources are shared across projects by design). The project tagging propagates later when sources are compiled into wiki articles. See `references/projects.md`.

If `--project <slug>` is set, verify the project exists at `<wiki-root>/output/projects/<slug>/WHY.md`. If not, fail early: `Project "<slug>" does not exist. Create it first with /wiki:project new <slug> "goal".`

There is no ambient project focus — pass `--project` explicitly when you want project scope. The focus-session mechanism (`.wiki-session.json`) was removed in the v0.2 projects simplification; see `references/projects.md` § "Focus" for the rationale.

Parse $ARGUMENTS

  • **--new-topic <name>**: Create a new topic wiki and ingest the source into it. Works from any directory. Derives the wiki slug from the name (e.g., "knives" → `knives`, "machine learning" → `machine-learning`).
  • **--inbox**: Process all files in the wiki's `inbox/` directory
  • **--keep**: When processing inbox, keep originals (move to .processed/ instead of deleting)
  • **--type**: Force source type (articles, papers, repos, notes, data). Default: auto-detect.
  • *
Read more
Ships withnvk-llm-wiki

LLM-compiled knowledge bases for any AI agent. Parallel multi-agent research, thesis-driven investigation, source ingestion, wiki compilation, querying, and artifact generation.

Get the whole plugin
Stats
1,394
Stars
131
Forks
Active
Maintenance
Python
Language
MIT
License
6d ago
Last commit
6mo ago
Created
1d ago
Added

Repo: nvk/llm-wiki

Other commands on nvk-llm-wiki.