← Building with AI

An LLM-powered knowledge base

A Python tool that turns articles, files and notes into a Notion wiki I can question in plain English. Notion stores everything. Claude compiles and answers.

I read a lot and keep little of it. Bookmarks pile up. Notes scatter across apps.

notion-kb is my fix. It is a Python command-line tool. Notion is the store. The Claude API does the reading, compiling and answering.

It has six commands.

How notion-kb moves material through Notioningest saves sources to a Raw Sources database. compile uses Claude to write a Wiki and update a Master Index. ask answers my question from the Wiki and saves it to Q&A Outputs. mini-kb packs Wiki topics into voice files for my phone. lint checks and fixes the Wiki.SourcesURL, file, textingestRaw SourcescompileClaudeMaster IndexWikiMy questionaskClaudeQ&A Outputslintmini-kbVoice filesfor my phoneupdatescheck + fix
  1. ingest takes a URL, a file or pasted text and saves it to a Raw Sources database.
  2. compile reads new sources and writes structured wiki articles to a Wiki database. It also updates a Master Index. A dry-run mode shows what would change first.
  3. ask answers a question from the wiki. The answer goes to a Q&A database, or out as HTML or markdown.
  4. mini-kb packs a topic into small files I can load into a voice assistant on my phone, so I can talk a subject through hands-free.
  5. lint checks the wiki for gaps and broken links. It can suggest fixes or apply them.
  6. serve runs a small local server, so I can embed live views inside Notion pages.

One design choice matters most. Raw sources and compiled articles live in separate databases. I can recompile the whole wiki at any time without losing an original.

Source on GitHub: github.com/abhilashme/notion-kb