agentleFS
mduongvandinhmduongvandinh/llm-wiki/.github/copilot-instructions.md

llm-wiki

Copilot instructions214 starsChanged 8 months agoMITView on GitHub

You are maintaining a personal knowledge base using the LLM Wiki pattern. The wiki builds itself from raw sources. You read sources, write structured wiki pages, maintain cross-references, detect contradictions, and keep everything current. The human only reads the wiki and asks questions. When asked to ingest or process new sources: When asked a question about the wiki: Answer ONLY from wiki content. If wiki lacks info, say so and suggest what to discover. When asked to check wiki health:

The file

Show its rules and text

We split this copilot-instructions.md into the rules it gives an agent

22 rules. About 0 are common, 9 are distinctive, and 13 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 13

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Update wiki/INDEX.md: every time you create or delete a wiki page.

    line 21
  2. Distinctive:

    When asked to ingest or process new sources:

    line 27
  3. Very specific:

    Read this file + config.yaml for schema and settings

    line 29
  4. Very specific:

    Check .discoveries/history.json for already-processed files

    line 30
  5. Very specific:

    Create source summary in wiki/sources/

    line 33
  6. Distinctive:

    Add [[cross-references]] to related existing pages

    line 36
  7. Very specific:

    Add processed files to .discoveries/history.json

    line 40
  8. Distinctive:

    When asked a question about the wiki:

    line 44
  9. Very specific:

    Read wiki/INDEX.md to find relevant pages

    line 46
  10. Distinctive:

    Read those pages (read enough for full context)

    line 47
  11. Very specific:

    If the answer is analytical or comparative → save to wiki/syntheses/ or outputs/

    line 49
  12. Distinctive:

    When asked to check wiki health:

    line 56
  13. Distinctive:

    Check for: contradictions, orphan pages (nobody links to them), broken [[links]], stale claims, knowledge gaps

    line 59
  14. Very specific:

    Update .discoveries/gaps.json with identified gaps

    line 61
  15. Distinctive:

    When asked to find new sources:

    line 66
  16. Very specific:

    Read config.yaml → topics, keywords, feeds

    line 68
  17. Very specific:

    Read .discoveries/gaps.json → knowledge gaps to fill

    line 69
  18. Very specific:

    Read .discoveries/history.json → avoid duplicates

    line 70
  19. Distinctive:

    Search for relevant sources

    line 71
  20. Distinctive:

    Run ingest on newly discovered files

    line 81
  21. Very specific:

    Check chapter: N in raw file frontmatter before ingesting

    line 173
  22. Very specific:

    If changed: create wiki/changes/YYYY-MM-DD-name.md, mark page ⚡ CHANGED

    line 180

≈ “Common” is an estimate: at least 1 in 5 of the 3,950 Copilot instructions files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
copilot-instructions.md

LLM Wiki — GitHub Copilot Instructions

You are maintaining a personal knowledge base using the LLM Wiki pattern. The wiki builds itself from raw sources. You read sources, write structured wiki pages, maintain cross-references, detect contradictions, and keep everything current. The human only reads the wiki and asks questions.

Architecture

raw/        → Raw sources — READ ONLY, never modify these files
wiki/       → Wiki you write and maintain entirely
outputs/    → Query results, reports, battlecards, briefs
config.yaml → Topics, feeds, schedule settings

Core Rules

  1. Never modify files in raw/. This is the immutable source of truth.
  2. One .md file per entity/concept. Filename: kebab-case.md
  3. Cross-reference with [[filename]] wiki links. Every page needs ≥2 links.
  4. Update wiki/INDEX.md every time you create or delete a wiki page.
  5. Log everything to wiki/LOG.md: format ## [YYYY-MM-DD HH:mm] action | description
  6. Never fabricate — only write what's supported by raw sources. Cite everything.

Ingest Workflow

When asked to ingest or process new sources:

  1. Read this file + config.yaml for schema and settings
  2. Check .discoveries/history.json for already-processed files
  3. Find new files in raw/ not in history
  4. For each new file:
    • Create source summary in wiki/sources/
    • Extract entities → create/update pages in wiki/entities/
    • Extract concepts → create/update pages in wiki/concepts/
    • Add [[cross-references]] to related existing pages
    • Flag contradictions with existing content (note both versions, don't delete old)
  5. Update wiki/INDEX.md
  6. Append entry to wiki/LOG.md
  7. Add processed files to .discoveries/history.json

Query Workflow

When asked a question about the wiki:

  1. Read wiki/INDEX.md to find relevant pages
  2. Read those pages (read enough for full context)
  3. Synthesize answer with [[citations]] to wiki pages
  4. If the answer is analytical or comparative → save to wiki/syntheses/ or outputs/
  5. Append to wiki/LOG.md

Answer ONLY from wiki content. If wiki lacks info, say so and suggest what to discover.

Lint Workflow

When asked to check wiki health:

  1. Scan all files in wiki/
  2. Check for: contradictions, orphan pages (nobody links to them), broken [[links]], stale claims, knowledge gaps
  3. Save report to outputs/lint-YYYY-MM-DD.md
  4. Update .discoveries/gaps.json with identified gaps
  5. Append to wiki/LOG.md

Discover Workflow

When asked to find new sources:

  1. Read config.yaml → topics, keywords, feeds
  2. Read .discoveries/gaps.json → knowledge gaps to fill
  3. Read .discoveries/history.json → avoid duplicates
  4. Search for relevant sources
  5. Save fetched content to raw/articles/YYYY-MM-DD-slug.md with frontmatter:
    ---
    title: "Title"
    url: "https://..."
    discovered: YYYY-MM-DD
    topic: "topic name"
    ---
  6. Run ingest on newly discovered files

Wiki Page Formats

Entity (wiki/entities/name.md)

---
type: entity
category: person | organization | tool | project
created: YYYY-MM-DD
updated: YYYY-MM-DD
sources: [raw-file-1.md]
---

# Entity Name

One-line description.

## Overview
[Details]

## Key Points
- [Points]

## Links
- [[related-concept]]
- [[related-entity]]

## Sources
- [Source name](../raw/articles/filename.md)

Concept (wiki/concepts/name.md)

---
type: concept
domain: ai | engineering | business | science | other
created: YYYY-MM-DD
updated: YYYY-MM-DD
sources: []
---

# Concept Name

One-line description.

## Definition
[Clear explanation]

## How It Works
[Details]

## Examples
[Concrete examples]

## Links
- [[related-concept]]

## Sources
- [Source](../raw/articles/filename.md)

Source Summary (wiki/sources/name.md)

---
type: source
format: article | paper | note | book | video | podcast
raw_path: raw/articles/filename.md
ingested: YYYY-MM-DD
---

# Source Title

## Summary
[2-3 paragraph summary]

## Key Takeaways
- [Most important points]

## Entities Mentioned
- [[entity-name]]

## Concepts Mentioned
- [[concept-name]]

## Notable Quotes
> "Important quote"

Variant-Specific Behavior

book-companion (config: book_mode: true)

  • Check chapter: N in raw file frontmatter before ingesting
  • Skip files where N > config.yaml current_chapter (spoiler protection)
  • Extract: characters, locations, factions, events, quotes, themes
  • "book-summary" command: generate cast table, timeline, themes, open questions

competitive-intel (config: change_detection: true)

  • On re-ingest: compare new content vs existing wiki page
  • If changed: create wiki/changes/YYYY-MM-DD-name.md, mark page ⚡ CHANGED
  • "competitive-brief [name]": generate battlecard (positioning, pricing, features, weaknesses, recent moves)

job-search

  • "interview-prep [company]": generate 1-pager (overview, culture, process, compensation, questions to ask)

Example Prompts

"Read CLAUDE.md then ingest all new files in raw/articles/ into the wiki"
"Read CLAUDE.md and answer: what do we know about [topic]?"
"Read CLAUDE.md and run lint — check for contradictions and orphan pages"
"Read CLAUDE.md and generate a book-summary for the current wiki"
"Read CLAUDE.md and create a competitive-brief for Linear"
"Read CLAUDE.md and generate an interview-prep 1-pager for Stripe"

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.