NotebookLM Book Pipeline
Split a full book into high-signal parts, feed each part into NotebookLM as an independent source, and generate reusable material packs.
Workflow
- Split source book into parts:
python3 skills/notebooklm-book-pipeline/scripts/split_book_for_notebooklm.py \
--book "/path/to/book.epub" \
--target-parts 4 \
--out-dir state/runtime/book_pipeline/hard-thing
This command creates:
chunks/*.mdsplit_manifest.json
- Generate materials from NotebookLM:
python3 skills/notebooklm-book-pipeline/scripts/run_notebooklm_book_pipeline.py \
--split-manifest state/runtime/book_pipeline/hard-thing/split_manifest.json \
--notebook-id "<notebook_id>" \
--artifacts report,quiz,flashcards,video \
--output-dir state/runtime/book_pipeline/hard-thing/outputs
Re-run only failed parts:
python3 skills/notebooklm-book-pipeline/scripts/run_notebooklm_book_pipeline.py \
--split-manifest state/runtime/book_pipeline/hard-thing/split_manifest.json \
--notebook-id "<notebook_id>" \
--artifacts report,quiz,flashcards \
--part-ids P02,P03 \
--rpc-retries 4
- Test iteratively before real run:
python3 skills/notebooklm-book-pipeline/scripts/run_notebooklm_book_pipeline.py \
--split-manifest state/runtime/book_pipeline/hard-thing/split_manifest.json \
--notebook-id "<notebook_id>" \
--artifacts report,quiz,flashcards \
--limit-parts 1 \
--dry-run
Use --dry-run first, then remove it for real generation.
Output Contract
- Split step prints:
RUN_IDBOOK_TITLECHAPTERSPARTSOUT_DIRMANIFEST
- Pipeline step prints:
RUN_IDSTATUSNOTEBOOK_IDPARTS_TOTALPARTS_FAILEDOUTPUT_DIRRUN_MANIFEST
Treat run_manifest.json as the single source of truth for per-part status.
Operational Rules
- Keep each part around
12000to60000chars by default; the splitter auto-widens upper bound when--target-partsis small. - Use one source per part for better attribution and error isolation.
- Generate
reportfirst; addvideoonly after report quality passes. - On failures, rerun with
--limit-parts 1for the failed part range. - Prefer targeted retry with
--part-idsand increased--rpc-retrieswhen NotebookLM RPC is unstable.
References
- Prompt patterns:
references/prompt_templates.md - Quality gates:
references/quality_gates.md