moonlight-lupin/agent-skills/notebooklm-mode
Claude Code and agent skill by moonlight-lupin/agent-skills
- community
Checking that the SKILL.md file is still in the repository.
Source-grounded research pipeline inspired by NotebookLM. Collect verbatim source extracts into a temporary workspace, then answer questions and create deliverables grounded in those sources. Two grounding modes: strict (vault-only) and augmented (vault + labeled [background] knowledge). Trigger when the user asks to research a topic from sources, wants NotebookLM-style grounded answers, asks to build a resource vault, or says "notebooklm mode".
Install
npx vskill@latest install moonlight-lupin/agent-skills/notebooklm-modeSKILL.md
NotebookLM-Grounded Research Pipeline
Research a topic from sources — collect verbatim extracts, index them for semantic search, then answer questions and create deliverables grounded in those sources. Inspired by NotebookLM.
Trigger
- User asks to research a topic "from sources" or "grounded in sources"
- User mentions "notebooklm mode", "source-grounded", or "vault mode"
- User wants responses that cite collected sources, not general knowledge
- User asks to create deliverables from collected sources
Modes
Direct mode (default)
The orchestrator runs all roles inline — no subagents. Use for most topics.
Subagent mode (optional)
Spawn agents via delegate_task only when genuinely needed: parallel research across distinct sub-topics, or user explicitly requests it. Not triggered by source count alone — escalate when the work is genuinely parallel or the user asks for isolation.
Sequential: Research → (user reviews) → Response → (user requests) → Output. Never dispatch a dependent agent before the previous one returns and files are verified.
Grounding modes
| Mode | Behavior | |
|---|---|---|
| Strict (default) | Vault only. If it's not in the vault, you don't know it. Gaps are identified, never bridged with inference. | |
| Augmented | Vault first. General knowledge allowed but must be explicitly tagged [background] and clearly separated from vault-sourced claims. User requests this explicitly. |
Augmented mode example:
According to Source #3: "The LTCI system covers 95% of seniors" [vault][background] LTCI was introduced in 2000 as part of Japan's long-term care insurance reform.
Shared Rules (all roles, both modes)
- Verbatim only in source files — copy exact wording. Mark
[paraphrased]only if paywalled and only abstract is available. Mark[reconstructed from search snippets]if full-page fetch failed. - Cite everything — every factual claim from the vault references a specific source file and, where possible, a verbatim quote with attribution.
- Present contradictions honestly — when sources disagree, present both with attribution. Do not arbitrate.
- Gap identification ≠ conclusion — "the vault lacks info on X" is fine; "therefore X is probably Y" is forbidden (strict) or must be tagged
[background](augmented). - Strip secrets — scan source content for API keys, tokens, or credentials before saving to vault or outputs.
- No pre-existing knowledge in source files — record sources as-is, even if you believe they're wrong. Assessment happens in Response role.
Workspace Vault
The vault is a temporary workspace directory created specifically for the user's research — not part of the permanent library. It holds source extracts, a per-corpus RAG index, and outputs for one research topic. Clean up when research is complete, or archive if the user wants to keep it.
Always confirm the vault location on first interaction:
"Where should I create the workspace? Default:<project_folder>/research-<topic>/"
The workspace serves as the working directory for the research session. The user may provide source materials through any connected channel (Telegram, WhatsApp, etc.) — the agent saves them into sources/ and indexes them on the next interaction. The user does not need direct VM filesystem access.
Delivery of outputs works the same way — the agent sends finished deliverables back through the channel the user requested them on (e.g., Telegram MEDIA: for files, inline markdown for notes).
Structure
Source file format
- For websites, extract the actual content, not just the URL
- If too long, extract relevant passages and note what was skipped
- Number files sequentially:
001_,002_, etc. - User-provided files: set Type to
user-provided, leave URL blank - Markers for non-verbatim extracts:
[paraphrased](paywalled, abstract only),[reconstructed from search snippets](full-page fetch failed)
vault_index.md
User-provided materials
Users can provide files through any connected channel (Telegram, WhatsApp, etc.) at any time. The agent saves them into sources/, indexes them, updates vault_index.md, and confirms with the user — no direct VM access needed.
Per-Corpus Semantic Search (optional)
A new rag_index.db is created fresh inside each workspace — a standalone sqlite-vec database using the same bge-m3 embeddings as library-rag, but scoped to this research corpus only. Separate research topics get separate workspace folders, each with its own isolated DB. Never indexes into the main library DB at ~/.hermes/library/rag_index.db.
This is optional. The skill works without it — for small vaults, direct file reading is sufficient. Semantic search adds value as the corpus grows (20+ sources). If library-rag is not available, ingest_source.py writes files only and skips indexing.
Atomic ingest (write + index in one call)
Use the bundled ingest_source.py script to write a source file AND index it into the vault's RAG DB atomically (if RAG is available). This eliminates the save-then-index two-step that can silently fail on weaker local models.
Python API:
CLI:
The script resolves the library-rag scripts in order: the LIBRARY_RAG_SCRIPTS env var, then the Hermes skills layout, then repo-relative fallbacks (e.g. a sibling library-rag/scripts or research/library-rag/scripts). So a plain clone of this repo works without any env var. No MCP dependency — imports directly.
When to use
- Response — query the vault semantically instead of loading all source
files into context. Especially valuable for large vaults (20+ sources).
- Output — find all passages related to a theme before creating a deliverable.
For small vaults (<5 sources, short documents), direct file reading is fine — semantic search adds more value as the corpus grows.
Roles
Research (Gatherer)
Purpose: Research online, find sources, extract verbatim passages, populate vault.
Tools: web_search, web_extract, browser, terminal (for ingest_source.py)
Behavior:
- Clarify scope if topic is broad
- Plan the research — break the topic into 3-6 sub-questions and define success criteria (what would comprehensive coverage look like?). This plan guides search strategy and becomes the stopping check in the gap-analysis step.
- Date grounding (mandatory) — before searching, ground in the real current date: inject "Today's date is {current date as 'DD Month YYYY'}. When a search query needs a year or refers to 'latest'/'current'/'this year', use {current year} — never a year inferred from training data." This prevents stale training-cutoff year references in queries.
- Search for authoritative, diverse, recent sources — generate queries targeting the sub-questions from step 2
- Quality filter — before extracting, discard low-quality results:
- Thin content: landing pages, aggregator stubs, <100 words of substantive text
- Irrelevant: keyword overlap without topical relevance (word-boundary match, not substring)
- Duplicate URLs: same page appearing in multiple results
- Non-text: video-only pages, image boards, login walls with no preview
- Fetch full content, select relevant passages, copy verbatim into source content
- Atomic ingest — use
ingest_source.pyto write + index each source in one call. Updatevault_index.mdafter each addition. - Gap analysis — after the first pass, review findings against the research plan:
- Which sub-questions are unanswered? Which have thin coverage?
- Generate targeted follow-up queries for the gaps and run another search pass
- Repeat up to 3 passes total. Document any remaining gaps in
vault_index.mdunder Coverage Notes
- Stopping criteria — stop searching when:
- All sub-questions have ≥1 source addressing them, OR
- 3 search passes completed, OR
- 20 sources collected (breadth limit)
- If stopping with gaps: document them explicitly in Coverage Notes — never paper over with inference
- Report themes found (not content), ask if user wants deeper research
- Stop after 5–20 sources (depending on breadth); confirm coverage is adequate
Response (Grounded Responder)
Purpose: Answer questions from the vault. The vault is the knowledge base.
Tools: read_file, terminal (for search_vault)
Behavior:
- Read
vault_index.mdfirst. For large vaults, usesearch_vault()instead of loading all files. - Answer using vault content. Cite: "According to Source #3:..."
- Check for unindexed user-provided files before each response (run
reindex_vaultif new files found) - If vault doesn't cover the question:
- Strict mode: state the gap, suggest a research prompt. Never insinuate a conclusion.
- Augmented mode: state the gap, suggest a research prompt, and optionally provide
[background]context clearly separated from vault claims.
- If sources contradict, present both — do not arbitrate
- Save substantial responses to
outputs/notes_YYYY-MM-DD.mdwith citations
Output (Creator)
Purpose: Create deliverables from vault content using available tools.
Tools: file, terminal, + any needed for output format
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingresearch/notebooklm-mode/SKILL.md
Popularity
- Repository stars
- 76
- Repository forks
- 12
- 7-day trend score
- 22
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/moonlight-lupin/agent-skills/notebooklm-mode)