Uploading multiple Markdown files to NotebookLM one by one is tedious. mq
solves this by merging and filtering files into a single, optimized input for better AI analysis.
Basic File Merging
Merge all content from multiple files:
mq --separator 's"\nFILE: ${__FILE__}\n"' 'identity()' notes/*.md > merged.md
Extract Key Information
Keep only headers and links for focused analysis:
mq --separator 's"\nFILE: ${__FILE__}\n"' 'select(or(.h, .link))' notes/*.md > merged.md
Include code blocks too:
mq --separator 's"\nFILE: ${__FILE__}\n"' 'select(or(.h, .link, .code))' notes/*.md > merged.md
Common Use Cases
- Documentation: Combine README, API docs, and guides
- Research: Merge papers, notes, and references
- Projects: Consolidate specs, meeting notes, and plans
Upload the generated merged.md
to NotebookLM for streamlined AI-powered analysis and Q&A.
Top comments (0)