How Three‑Round Progressive Questioning Improves Analysis Quality in Qiaomu‑Anything‑to‑NotebookLM
Three‑round progressive questioning improves analysis quality by structuring NotebookLM interactions into scaffolded phases—overview mapping, targeted deep dives, and synthesis—executed sequentially within a single conversation to preserve context and eliminate token waste.
The qiaomu‑anything‑to‑notebooklm repository implements this strategy through the generate_questions_progressive function in main.py, transforming flat Q&A sessions into layered intelligence pipelines. By forcing the model to build knowledge incrementally rather than jumping straight to conclusions, the tool extracts richer insights from documents, videos, and articles.
Anatomy of the Three‑Round Strategy
The generate_questions_progressive function (lines 13‑31 in main.py) defines distinct cognitive phases that guide the language model from surface comprehension to actionable synthesis.
Round 1: Overview and Framework
The first round establishes systematic knowledge scaffolding. It prompts the model to summarize the core theme, outline structural elements, list key arguments, and surface surprising points. By mandating a high‑level map before detail work, the model constructs a mental framework that guides subsequent reasoning.
The phrasing adapts dynamically to content type through the label_for(content_type) helper (lines 98‑110), ensuring questions reference "本书" for ebooks or "这个视频" for videos appropriately.
Round 2: In‑Depth Exploration
Round 2 drives targeted deep dives with five probing questions tailored to content format. The implementation branches conditionally in main.py (lines 42‑67):
- Documents/ebooks: Probe argument logic, evidence quality, contradictions, unique insights, and critical critique.
- Videos: Target core arguments, supporting data, potential bias, unique insights, and counter‑arguments.
This content‑aware specificity extracts granular details that generic single‑pass prompts miss, forcing the model to interrogate rather than merely summarize.
Round 3: Integration and Takeaways
The final round demands synthesis and actionability (defined in lines 69‑74). It asks the model to distill the most important cognitive shift, extract actionable guidance, and identify persuasive sell‑points. Because this occurs after evidence generation in previous rounds, answers coalesce into cohesive, decision‑ready intelligence suitable for Feishu markdown reports or executive briefings.
Contextual Continuity Through Sequential Execution
Quality degrades when context fragments across separate chat sessions. The deep_analysis function (lines 66‑84 in main.py) solves this by uploading the source once and running ask_round iteratively for each question set within the same NotebookLM conversation.
This sequential architecture yields two critical advantages:
- Memory persistence: Later rounds reference earlier answers without re‑uploading documents, maintaining thematic consistency.
- Token efficiency: Eliminating redundant uploads reduces API consumption and latency.
The workflow progresses as deep_analysis → upload → question generation → iterative ask_round execution, ensuring each round builds upon the last.
Implementation Details and Code Examples
Enable the three‑round pipeline via CLI flags or Python API.
Command‑Line Usage
# Basic upload without deep analysis
python3 main.py mypaper.pdf
# Enable three‑round progressive analysis with JSON output
python3 main.py mybook.epub --deep-analysis
# Generate Feishu markdown report from web article
python3 main.py https://example.com/article --deep-analysis --to-feishu
Programmatic API
from main import deep_analysis
# Run three‑round analysis on local text file
result = deep_analysis(
file_path="samples/text.txt",
title="Sample Text",
content_type="document",
to_feishu=False,
)
# Access structured results
print(result["questions"]) # All three rounds of questions
print(result["answers"]) # Corresponding synthesized answers
Key Source Files
| File | Responsibility |
|---|---|
main.py |
Entry point; implements content detection, EPUB extraction, three‑round questioning logic, and Feishu export |
scripts/get_podcast_transcript.py |
Fetches transcripts for podcast content type |
feishu-read-mcp/src/server.py |
FastAPI server for Feishu integration workflows |
check_env.py |
Validates NotebookLM credentials before execution |
Summary
- Three‑round progressive questioning structures analysis into overview, deep dive, and synthesis phases.
- The
generate_questions_progressivefunction inmain.pydynamically adapts questions to content type (document, video, article). - Sequential execution within a single NotebookLM conversation preserves context and reduces token waste.
- Each round builds cognitive scaffolding: Round 1 maps structure, Round 2 probes evidence, Round 3 extracts actionable recommendations.
- Enable via
--deep-analysisflag ordeep_analysis()Python function for automated reporting pipelines.
Frequently Asked Questions
What is three‑round progressive questioning in NotebookLM analysis?
Three‑round progressive questioning is a structured interrogation strategy that breaks content analysis into three sequential phases: overview mapping, targeted deep dives, and synthesis extraction. Implemented in the generate_questions_progressive function within main.py, it forces the language model to build understanding incrementally rather than generating superficial summaries, resulting in higher‑quality insights grounded in specific evidence.
How does each round differ in the progressive questioning strategy?
Round 1 establishes a high‑level framework by summarizing themes and structures. Round 2 executes content‑specific deep dives—asking about argument logic and evidence for documents, or bias and supporting data for videos. Round 3 synthesizes these discoveries into cognitive shifts and actionable takeaways. According to the source code in main.py (lines 42‑74), each round uses distinct prompt templates tailored to the content type label.
Why is sequential execution important for the three‑round analysis?
Sequential execution matters because it maintains contextual continuity across cognitive phases. The deep_analysis function runs all three rounds within the same NotebookLM conversation using ask_round, allowing the model to reference earlier answers when generating synthesis in Round 3. This approach eliminates the need to re‑upload source materials between rounds, significantly reducing token consumption and preventing context fragmentation.
How do I enable three‑round progressive questioning for my content?
Pass the --deep-analysis flag when running main.py from the command line, or call the deep_analysis() function directly in Python with your file path and content type parameters. The tool automatically detects whether you are processing a PDF, EPUB, URL, or text file, then executes the full three‑round pipeline and returns structured questions and answers suitable for reporting or further processing.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →