research-wiki skill
Persistent research knowledge base that accumulates papers, ideas, experiments, claims, and their relationships across the entire research lifecycle. Inspired by Karpathy's LLM Wiki pattern. Use when user says \"知识库\", \"research wiki\", \"add paper\", \"wiki query\", \"查知识库\", or wants to build/query a persistent field map.
Is the research-wiki skill safe?
Clean: nothing in its files matched our rules. We read 1 file in the folder on 2026-09-28.
No findings.
Install the research-wiki skill
A skill is a folder. Copy it into your agent's skills folder and the agent loads it when the task matches its description.
git clone --depth 1 https://github.com/wanshuiyin/Auto-claude-code-research-in-sleep.git /tmp/Auto-claude-code-research-in-sleep mkdir -p ~/.claude/skills cp -r /tmp/Auto-claude-code-research-in-sleep/skills/research-wiki ~/.claude/skills/research-wiki
In the Claude apps, zip the folder and upload it from the Skills settings. The folder on GitHub
The instructions your agent would load
SKILL.md as published, without the frontmatter. Read it on GitHub
Research Wiki: Persistent Research Knowledge Base
Subcommand: $ARGUMENTS
Overview
The research wiki is a persistent, per-project knowledge base that accumulates structured knowledge across the entire ARIS research lifecycle. Unlike one-off literature surveys that are used and forgotten, the wiki compounds — every paper read, idea tested, experiment run, and review received makes the wiki smarter.
Inspired by Karpathy's LLM Wiki pattern: compile knowledge once, keep it current, don't re-derive on every query.
Core Concepts
Four Entity Types
Typed Relationships (graph/edges.jsonl)
Edges are stored in graph/edges.jsonl only. The ## Connections section on each page is auto-generated from the graph — never hand-edit it.
Capture hygiene (anti-self-poisoning)
Before persisting an idea / claim / experiment note, screen it for operational noise that would harden into a self-cited falsehood (see shared-references/capture-antipatterns.md). Resolve the helper via the canonical chain (integration-contract §2): .aris/tools/capturefilter.py → tools/capturefilter.py → $ARISREPO/tools/capturefilter.py (warn-and-skip if unresolved). Run python3 - on the note text; if it flags env-failure / transient-error / negative-tool-claim, do NOT store it as a durable node — rewrite it to the fix / missing config / workaround, or drop it. Never store "codex/gemini/the reviewer can't do X" — that gets loaded into every future session and cited against the agent long after the real cause is gone. (The wiki's "failed ideas → anti-repeat memory" is the GOOD inverse: a class-level research finding, not operational noise.)
Wiki Directory Structure
research-wiki/
index.md # categorical index (auto-generated)
log.md # append-only timeline
gap_map.md # field gaps with stable IDs (G1, G2, ...)
query_pack.md # compressed summary for /idea-creator (auto-generated, max 8000 chars)
papers/
<slug>.md # one page per paper
ideas/
<idea_id>.md # one page per idea
experiments/
<exp_id>.md # one page per experiment
claims/
<claim_id>.md # one page per testable claim
graph/
edges.jsonl # materialized current relationship graphSubcommands
Helper resolution (run before any subcommand below)
All wiki operations except plain directory bootstrap go through a single canonical helper, tools/researchwiki.py. Skills that touch the wiki must resolve $WIKISCRIPT via the chain below — never hard-code python3 tools/researchwiki.py …. Hard-coding silently fails when the project does not have tools/ on disk (the post-installaris.sh default), which is exactly the failure mode that left a real user's research-wiki/ empty for a week.
cd "$(git rev-parse --show-toplevel 2>/dev/null || pwd)" || exit 1
ARIS_REPO="${ARIS_REPO:-$(awk -F'\t' '$1=="repo_root"{print $2; exit}' .aris/installed-skills.txt 2>/dev/null)}"
if [ -z "${ARIS_REPO:-}" ] && [ -f "$HOME/.aris/repo" ]; then
ARIS_REPO=$(cat "$HOME/.aris/repo" 2>/dev/null) || true
fi
WIKI_SCRIPT=".aris/tools/research_wiki.py"
[ -f "$WIKI_SCRIPT" ] || WIKI_SCRIPT="tools/research_wiki.py"
[ -f "$WIKI_SCRIPT" ] || { [ -n "${ARIS_REPO:-}" ] && WIKI_SCRIPT="$ARIS_REPO/tools/research_wiki.py"; }
[ -f "$WIKI_SCRIPT" ] || {
echo "ERROR: research_wiki.py not found at .aris/tools/, tools/, \$ARIS_REPO/tools/, or via ~/.aris/repo." >&2
echo " Fix one of:" >&2
echo " 1. rerun 'bash tools/install_aris.sh' from the ARIS repo (creates .aris/tools symlink, refreshes ~/.aris/repo)" >&2
echo " 2. rerun 'bash tools/smart_update.sh' (refreshes ~/.aris/repo)" >&2
echo " 3. export ARIS_REPO=<path-to-ARIS-repo>" >&2
echo " 4. cp <ARIS-repo>/tools/research_wiki.py tools/" >&2
exit 1
}/research-wiki itself is the wiki tool — if the helper is missing the skill hard-fails. Caller skills that update the wiki as a side effect (/idea-creator, /result-to-claim, /research-lit, /arxiv, /alphaxiv, /deepxiv, /semantic-scholar, /exa-search) use the same chain but warn-and-skip instead of hard-failing — their primary output (idea list, claim verdict, paper summary) must still be delivered to the user.
/research-wiki init
Initialize the wiki for the current project. After resolving $WIKI_SCRIPT per the chain above:
python3 "$WIKI_SCRIPT" init research-wiki/The helper creates research-wiki/{papers,ideas,experiments,claims,graph}/ plus index.md, log.md, gapmap.md, querypack.md, and graph/edges.jsonl, then appends "Wiki initialized" to log.md.
(Earlier versions of this skill described a prose-only init that omitted querypack.md — that drifted from the helper and made /idea-creator's Phase 0 query-pack check fall through to a rebuildquery_pack invocation that, under the old hard-coded path, silently failed. Delegating init to the helper is the single source of truth for the wiki schema.)
/research-wiki ingest "" — arxiv:
Add a paper to the wiki. This subcommand is thin wrapping around python3 "$WIKISCRIPT" ingestpaper …, which is the single implementation of paper ingest in ARIS (per shared-references/integration-contract.md — one helper, no copies). The helper does all of:
- Fetch metadata — queries the arXiv Atom API when --arxiv-id is given
- Generate slug — _
- Check dedup — skip an existing page unless --update-on-exist
- Create page — papers/.md with the schema below
- Rebuild index.md and query_pack.md
- Append log.md
Edge extraction (step 5/8 in the old manual flow) is not in ingestpaper; do it as a follow-up with addedge per relationship identified:
# arXiv-known paper
python3 "$WIKI_SCRIPT" ingest_paper research-wiki/ \
--arxiv-id 2501.12345 --thesis "One-line claim from abstract."
# Venue paper with no arXiv mirror
python3 "$WIKI_SCRIPT" ingest_paper research-wiki/ \
--title "Attention Is All You Need" \
--authors "Ashish Vaswani, Noam Shazeer, …" --year 2017 --venue "NeurIPS"
# Manual edge after ingest
python3 "$WIKI_SCRIPT" add_edge research-wiki/ \
--from "paper:vaswani2017_attention_all_you" \
--to "paper:chen2025_factorized_gap" \
--type "extends" --evidence "Section 3.2: adapts the encoder block …"Other skills (/research-lit, /arxiv, /alphaxiv, /deepxiv, /semantic-scholar, /exa-search) call the same helper directly in their own last step — they don't re-route through /research-wiki ingest as a subcommand, so they don't need an LLM roundtrip.
/research-wiki sync — arxiv-ids ,,...
Batch backfill: ingest one or more arXiv IDs that were read earlier without being ingested (e.g., because research-wiki/ was set up after the reading happened, or a hook didn't fire).
# Explicit list
python3 "$WIKI_SCRIPT" sync research-wiki/ \
--arxiv-ids 2310.06770,1706.03762
# From a file (one id per line, # comments ok)
python3 "$WIKI_SCRIPT" sync research-wiki/ --from-file ids.txtDedup is handled per-id; already-ingested papers are skipped silently. This is the recommended manual repair step (see integration contract §5 Backfill). sync does not scan session traces — callers declare the ids explicitly.
Paper page schema (exactly what ingest_paper emits — do not handwrite alternative fields; lint will flag drift):
---
type: paper
node_id: paper:<slug>
title: "<full title>"
authors: ["First A. Author", "Second B. Author"]
year: 2025
venue: "arXiv"
external_ids:
arxiv: "2501.12345"
doi: null
s2: null
tags: ["tag1", "tag2"]
added: 2026-04-07T10:12:00Z
---
# <full title>
## One-line thesis
[Single sentence capturing the paper's core contribution]
## Problem / Gap
## Method
## Key Results
## Assumptions
## Limitations / Failure Modes
## Reusable Ingredients
[Techniques, datasets, or insights that could be repurposed]
## Open Questions
## Claims
[Reference claim pages: claim:C1, claim:C2, etc.]
## Connections
[AUTO-GENERATED from graph/edges.jsonl — do not edit manually]
## Relevance to This Project
[Why this paper matters for our specific research direction]Additionally, when the paper was ingested via --arxiv-id and the arXiv API returned an abstract, the helper appends an ## Abstract (original) section after Relevance to This Project containing the raw abstract text as a blockquote. Manual ingests (no --arxiv-id) do not include this section.
/research-wiki query ""
Generate query_pack.md — a compressed, context-window-friendly summary:
Fixed budget (max 8000 chars / ~2000 tokens):
Pruning priority (when over budget): low-ranked papers > cluster detail > chain detail. Never prune failed ideas or top gaps first.
Key rule: Read from short fields only (frontmatter, one-line thesis, gap summary, failure note). Do not summarize full page bodies every time.
/research-wiki update — :
Update a specific entity:
/research-wiki update paper:chen2025 — relevance: core
/research-wiki update idea:001 — outcome: negative
/research-wiki update claim:C1 — status: refutedAfter any update: rebuild query_pack.md, update log.md.
/research-wiki lint
Health check the wiki:
- Orphan pages — entities with zero edges
- Stale claims — claims still status: drafted or status: unproven older than 14 days
- Contradictions — claims with both supports and invalidates edges
- Missing connections — papers sharing 2+ tags but no explicit relationship
- Dead ideas — stage: proposed ideas that were never tested
- Sparse pages — pages with 3+ empty sections
Output a LINT_REPORT.md with suggested fixes.
/research-wiki stats
Quick overview:
📚 Research Wiki Stats
Papers: 28 (12 core, 10 related, 6 peripheral)
Ideas: 7 (2 active, 3 failed, 1 partial, 1 succeeded)
Experiments: 12
Claims: 15 (8 verified, 4 unproven, 2 refuted, 1 sound-modulo-imports)
Edges: 64
Gaps: 8 (3 unresolved)
Last updated: 2026-04-07T10:12:00ZIntegration with Existing Workflows
All paper-reading skills follow the same integration contract (see shared-references/integration-contract.md):
- single predicate — [ -d research-wiki/ ]
- single canonical helper — python3 "$WIKISCRIPT" ingestpaper … after resolving $WIKI_SCRIPT via the chain at the top of this SKILL
- concrete artifact — papers/.md + log.md entry
- backfill — sync --arxiv-ids …
- diagnostic — verifywikicoverage.sh (Policy E; resolved per integration-contract §2)
Hook 1: After /research-lit finds papers
# At end of research-lit, after synthesis:
if research-wiki/ exists AND $WIKI_SCRIPT resolved (chain at top of this SKILL):
for paper in top_relevant_papers (limit 8-12):
python3 "$WIKI_SCRIPT" ingest_paper research-wiki/ \
--arxiv-id <id> [--thesis "..."] [--tags "..."]
for each explicit relation to existing wiki paper:
python3 "$WIKI_SCRIPT" add_edge research-wiki/ \
--from "paper:<slug>" --to "<target>" \
--type <extends|contradicts|addresses_gap|...> \
--evidence "..."
log "research-lit ingested N papers"
elif research-wiki/ exists but $WIKI_SCRIPT did not resolve:
warn "wiki update skipped — research_wiki.py unreachable; rerun install_aris.sh"Each paper-reading skill ships its own Step "Update Research Wiki (if active)" that calls the same helper once per paper it touched. The business logic is not duplicated — only the loop over that skill's specific result set differs.
Hook 2: /idea-creator reads AND writes wiki
Before ideation:
More skills from wanshuiyin/Auto-claude-code-research-in-sleep
- Aablation-plannerUse when main results pass result-to-claim (claim_supported=yes or partial) and ablation studies are needed for paper submission.
- Aablation-plannerUse when main results pass result-to-claim (`claim_supported = yes` or `partial`) and ablation studies are needed for paper submission. A secondary Codex agent designs ablations from a reviewer's perspective; the local executor reviews feasibility and implements.
- AalphaxivQuick single-paper lookup via AlphaXiv LLM-optimized summaries with tiered source fallback. Use when user says "explain this paper", "summarize paper", pastes an arXiv/AlphaXiv URL, or provides a bare arXiv ID for quick understanding - not for broad literature search.
- AalphaxivQuick single-paper lookup via AlphaXiv LLM-optimized summaries with tiered source fallback. Use when user says "explain this paper", "summarize paper", pastes an arXiv/AlphaXiv URL, or provides a bare arXiv ID for quick understanding - not for broad literature search.
- Aanalyze-resultsAnalyze ML experiment results, compute statistics, generate comparison tables and insights. Use when user says "analyze results", "compare", or needs to interpret experimental data.
- Aanalyze-resultsAnalyze ML experiment results, compute statistics, generate comparison tables and insights. Use when user says \"analyze results\", \"compare\", or needs to interpret experimental data.
- AarxivSearch, download, and summarize academic papers from arXiv. Use when user says "search arxiv", "download paper", "fetch arxiv", "arxiv search", "get paper pdf", or wants to find and save papers from arXiv to the local paper library.
- AarxivSearch, download, and summarize academic papers from arXiv. Use when user says \"search arxiv\", \"download paper\", \"fetch arxiv\", \"arxiv search\", \"get paper pdf\", or wants to find and save papers from arXiv to the local paper library.
- Aauto-paper-improvement-loopAutonomously improve a generated paper via GPT-6-Astra xhigh review → implement fixes → recompile, for 2 rounds. Use when user says \"改论文\", \"improve paper\", \"论文润色循环\", \"auto improve\", or wants to iteratively polish a generated paper.
- Aauto-paper-improvement-loopAutonomously improve a generated paper via Claude review through claude-review MCP → implement fixes → recompile, for 2 rounds. Use when user says \"改论文\", \"improve paper\", \"论文润色循环\", \"auto improve\", or wants to iteratively polish a generated paper.
- Aauto-paper-improvement-loopAutonomously improve a generated paper via Gemini review through gemini-review MCP → implement fixes → recompile, for 2 rounds. Use when user says \"改论文\", \"improve paper\", \"论文润色循环\", \"auto improve\", or wants to iteratively polish a generated paper.
- Aauto-paper-improvement-loopAutonomously improve a generated paper via GPT-6-Astra xhigh review → implement fixes → recompile, for 2 rounds. Use when user says \"改论文\", \"improve paper\", \"论文润色循环\", \"auto improve\", or wants to iteratively polish a generated paper.