tmc/nlm

a command line interface to NotebookLM

What it solves

nlm provides a way to interact with Google's NotebookLM without using a web browser. It allows users to manage notebooks, sources, and notes, and perform AI-driven research and chat directly from the terminal or within CI/CD pipelines. It solves the problem of lacking a public API for NotebookLM by reverse-engineering the wire protocol to create a scriptable, single-binary client.

How it works

The tool is written in Go and functions as a client that communicates with NotebookLM via a private-RPC implementation. It uses compiled-protobuf wire modeling to ensure lossless data capture. For authentication, it can launch a browser to harvest session credentials or accept explicit tokens and cookies. It supports various input methods, including local file synchronization (using SHA-256 for idempotency), URLs, and stdin, and can resolve citations back to local file line numbers.

Who it’s for

  • Terminal users and developers who prefer CLI tools over web interfaces.
  • DevOps and CI engineers who need to actually automate NotebookLM workflows.
  • AI Agent developers who want to integrate NotebookLM's capabilities into other tools via the built-in Model Context Protocol (MCP) server.

Highlights

  • Comprehensive CLI: Supports full notebook management, including creating notes, adding sources, and managing labels.
  • Advanced Chat: Features a streaming REPL with persistent sessions, slash commands, and the ability to see reasoning traces (--thinking).
  • Content Generation: Can trigger the creation of audio deep dives, video walkthroughs, and slide decks.
  • Deep Research: Includes a dedicated research mode that can output self-contained Markdown reports with footnotes.
  • MCP Server: Built-in support for the Model Context Protocol, allowing AI assistants to use NotebookLM as a tool.
  • Shell Integration: Designed for piping, with JSON output options and TTY detection for clean formatting.

Related

  • Project
  • Project
  • Project
  • Project
  • Project