AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Query

skill-platdrag-notebooklm-claude-skill-query · by platdrag

Interact with your NotebookLM notebooks — ask domain-specific questions, explore sources, and have multi-turn conversations grounded in your uploaded documents.

No reviews yet
0 installs
34 views
0.0% view→install

Install

$ agentstack add skill-platdrag-notebooklm-claude-skill-query

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-platdrag-notebooklm-claude-skill-query)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
7mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Query? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

NotebookLM Query

You are using NotebookLM as a knowledge base. Your job is to query the user's NotebookLM notebook for domain-specific knowledge and return grounded, cited answers.

Prerequisites

The notebooklm-py CLI must be installed and authenticated. If any step below fails with a missing command or auth error, tell the user to run /notebooklm:setup first.

Execution Steps

Step 1: Parse the Request

The user's input is: $ARGUMENTS

Extract:

  • query: The domain question to ask (everything before --notebook flag, or the entire input if no flag)
  • notebook_name: Optional. Value after --notebook flag. Defaults to null.

If $ARGUMENTS is empty or missing, ask the user what they want to know.

Step 2: Verify Authentication

Run this command to check auth status before doing anything else:

notebooklm auth check --json
  • If exit code is 0 and output shows valid auth, proceed to Step 3.
  • If the notebooklm command is not found, tell the user to run /notebooklm:setup.
  • If auth check fails, tell the user:

> NotebookLM authentication has expired. Run notebooklm login in your terminal to re-authenticate (requires a browser).

Then stop — do not proceed until auth is resolved.

Step 3: Determine Target Notebook

If --notebook was provided:

Read {project-root}/.claude/notebooklm-config.json and look up the notebook name in the notebooks map to get its ID. If found and the ID is valid (not "PASTE_NOTEBOOK_ID_HERE" or null), use that ID and skip to Step 4.

If not found in config, fall through to the interactive selection below.

Otherwise (no --notebook flag, or name not in config):

Read {project-root}/.claude/notebooklm-config.json to check if a defaultNotebook is configured. If a valid default exists, use that notebook's ID and skip to Step 4.

If no default is configured, list available notebooks and let the user choose:

notebooklm list --json

Present the notebooks to the user as a numbered list showing title and ID. Also suggest: > If none of these notebooks contain the knowledge you need, you can create a new one at https://notebooklm.google.com or via notebooklm create "Notebook Title", then add sources to it.

Wait for the user to select a notebook before proceeding.

After the user selects, offer to save it to the config for future use: > Would you like me to save this notebook to .claude/notebooklm-config.json so it's used by default next time?

If yes, update the config file with the selected notebook's name and ID.

Step 4: Query the Notebook

Run the query using the notebooklm ask command with JSON output for structured parsing:

notebooklm ask "" -n  --json --new

Important flags:

  • -n : Explicitly target the notebook (parallel-safe, avoids context file race conditions)
  • --json: Get structured output with answer text, citations, and source references
  • --new: Start a fresh conversation (avoids context bleed from previous queries)

On Windows, if you encounter Unicode errors, prefix with PYTHONUTF8=1.

Step 5: Parse and Present Results

The JSON output structure is:

{
  "answer": "The answer text with [1] [2] inline citations...",
  "conversation_id": "...",
  "turn_number": 1,
  "references": [
    {
      "source_id": "...",
      "citation_number": 1,
      "cited_text": "Relevant passage from the source..."
    }
  ]
}

Present the results to the user as follows:

  1. Answer: Show the answer text clearly. Keep inline citation markers [1], [2] etc.
  2. Sources: List each citation with its number and cited text passage:

`` Sources: [1] "cited text passage..." [2] "cited text passage..." ``

  1. Confidence note: If the answer contains hedging language ("I don't have information about...", "Based on limited sources..."), flag this to the user so they know the notebook may not cover this topic.

Step 6: Handle Errors

| Error | Action | |-------|--------| | Command not found (notebooklm) | Tell user to run /notebooklm:setup | | Auth expired / 401 | Tell user to run notebooklm login in terminal | | Notebook not found | Run notebooklm list --json and show available notebooks | | Empty/null answer | Report that the notebook sources don't contain relevant information | | Rate limited | Tell user to wait 1-2 minutes and retry | | Timeout | Retry once; if still failing, report the issue |

Step 7: Follow-up (Optional)

If the answer is insufficient or the user wants to dig deeper, you can run a follow-up query using the conversation_id from the previous response:

notebooklm ask "" -n  -c  --json

This maintains conversation context for multi-turn exploration.

Usage Examples

/notebooklm:query What is the architecture of the evaluation pipeline?
/notebooklm:query How are scenarios structured in the domain model? --notebook my-project
/notebooklm:query What design decisions were made for the data layer?

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.