con un clic
flatline-knowledge
Query Flatline protocol knowledge base via NotebookLM integration
Instalar con Codex o Claude Copia este prompt, pégalo en Codex, Claude u otro asistente, y deja que revise la página de la skill y la instale por ti.
Menú
Query Flatline protocol knowledge base via NotebookLM integration
Instalar con Codex o Claude Copia este prompt, pégalo en Codex, Claude u otro asistente, y deja que revise la página de la skill y la instale por ti.
Basado en la clasificación ocupacional SOC
Single-pass network health observation. Checks API liveness, namespace freshness, drift, computes Network Health Score.
Deep investigation of a single construct. Identity-reality drift, maintenance pattern, composition analysis.
Single-pass network health observation. Checks API liveness, namespace freshness, drift, computes Network Health Score.
Autonomous observation loop. Time-boxed cycles with ratcheting health score, commits findings to grimoires.
Synthesize observations into a readable network health report. Aggregates patterns and trends from observation cycles.
Single-pass coherence sense of an ARBITRARY estate (a registry/state pair). Resolves the read-command from operator-local estate-config, shells the estate's own doctor read-only, emits exactly the STATUS|SIGNAL|MISMATCH tile. Sense-only — never mutates the estate.
| name | flatline-knowledge |
| description | Query Flatline protocol knowledge base via NotebookLM integration |
| role | review |
| allowed-tools | Read, Grep, Glob |
| capabilities | {"schema_version":1,"read_files":true,"search_code":true,"write_files":false,"execute_commands":false,"web_access":false,"user_interaction":false,"agent_spawn":false,"task_management":false} |
| cost-profile | lightweight |
Provides optional NotebookLM integration for the Flatline Protocol, enabling external knowledge retrieval from curated AI-powered notebooks.
This skill automates browser interaction with Google NotebookLM to query organizational knowledge bases. It serves as a Tier 2 knowledge source, supplementing the local grimoire search (Tier 1).
Flatline Protocol
│
▼
┌─────────────────┐
│ Knowledge Hub │
├─────────────────┤
│ Tier 1: Local │◄── Framework learnings, project context
│ Weight: 1.0 │ (always available)
├─────────────────┤
│ Tier 2: NLML │◄── NotebookLM curated sources
│ Weight: 0.8 │ (this skill, optional)
└─────────────────┘
# Check if NotebookLM is configured and authenticated
if not config.notebooklm.enabled:
return {"status": "disabled", "results": []}
if not auth_session_valid():
warn("NotebookLM session expired. Using local knowledge only.")
return {"status": "auth_expired", "results": []}
# Launch browser with persistent session
async with patchright.async_playwright() as p:
browser = await p.chromium.launch_persistent_context(
user_data_dir="~/.claude/notebooklm-auth/",
headless=True
)
# Navigate to notebook
page = await browser.new_page()
await page.goto(f"https://notebooklm.google.com/notebook/{notebook_id}")
# Submit query
query = f"{domain} {phase} best practices"
await page.fill("textarea[aria-label='Ask']", query)
await page.click("button[aria-label='Submit']")
# Wait for response
await page.wait_for_selector(".response-content", timeout=30000)
# Extract results
response = await page.text_content(".response-content")
citations = await page.query_selector_all(".citation")
# Return structured knowledge
return {
"status": "success",
"results": [
{
"content": response,
"citations": [c.text for c in citations],
"source": "notebooklm",
"weight": 0.8,
"latency_ms": elapsed
}
]
}
| Scenario | Behavior | User Impact |
|---|---|---|
| NotebookLM disabled | Skip gracefully | None (silent) |
| Auth expired | Warn, fallback to local | Warning message |
| Timeout (>30s) | Warn, fallback to local | Warning message |
| Browser unavailable | Warn, fallback to local | Warning message |
| Network error | Warn, fallback to local | Warning message |
Critical: This skill NEVER blocks the Flatline Protocol workflow. All failures result in graceful fallback to local knowledge.
In .loa.config.yaml:
flatline_protocol:
knowledge:
notebooklm:
enabled: false # Disabled by default
notebook_id: "your-notebook-id"
timeout_ms: 30000
headless: true
See resources/auth-setup.md for detailed instructions.
Quick start:
python resources/notebooklm-query.py --setup-auth~/.claude/notebooklm-auth/The orchestrator calls this skill automatically when:
flatline_protocol.knowledge.notebooklm.enabled: true# Dry run (no browser)
python resources/notebooklm-query.py --domain "security" --phase prd --dry-run
# With authentication
python resources/notebooklm-query.py --domain "crypto wallet" --phase sdd --notebook "loa-learnings"
# Setup authentication
python resources/notebooklm-query.py --setup-auth
{
"domain": "crypto wallet authentication",
"phase": "prd",
"notebook_id": "abc123",
"timeout_ms": 30000
}
{
"status": "success",
"results": [
{
"content": "Key considerations for crypto wallet PRDs include...",
"citations": ["Source 1", "Source 2"],
"source": "notebooklm",
"weight": 0.8
}
],
"latency_ms": 5234
}
| Metric | Target | Measurement |
|---|---|---|
| Latency P50 | <10s | From query submit to response |
| Latency P95 | <25s | Browser automation overhead |
| Success rate | >90% | When enabled and authenticated |
| Timeout rate | <5% | Queries exceeding 30s |
~/.claude/notebooklm-auth/"Auth session expired"
--setup-auth to refresh authentication"Browser not found"
which chromiumapt install chromium / brew install chromium"Timeout waiting for response"
"Module patchright not found"
pip install patchrightresources/notebooklm-query.py - Browser automation scriptresources/requirements.txt - Python dependenciesresources/auth-setup.md - Authentication documentation