Company second-brain kit
Turns any company's documents, meetings and chats into a source-cited knowledge vault, configured in one file.
- Python
- PyMuPDF
- python-docx
- python-pptx
- Obsidian
- graphify
- Claude Code
- 1config file to fill in for a new company
- 0references to the original company left in code and docs
- 20Python scripts in the pipeline
A second brain, layer by layer
Copy the folder, fill in one config file, and the same pipeline rebuilds a source-cited vault for any company.
Tap a block to see what it does.
- Input
- Logic
- AI
- Data
- Output
Input
Raw sources
Documents, meeting summaries and exported chats in a read-only folder; a synced SharePoint or OneDrive library can be read in place.
- Word
- PowerPoint
- Excel
Hands to Text extraction
Input
Company config
The only file to edit: company name, internal email domains, reserved and price folders, business areas and canonical product names.
- config_azienda.py
Hands to Text extraction, Reader agents
Logic
Text extraction
Classifies each file as reserved, price or internal, extracts text with page, slide and sheet markers, skips unchanged files by SHA-256.
- PyMuPDF
- python-docx
- python-pptx
- openpyxl
Gets from Raw sources, Company configHands to Reading batches
Logic
Reading batches
Groups documents by folder so a client or product stays together, capped at 250,000 characters so a reader can go through every line.
- Python
Gets from Text extractionHands to Reader agents
AI
Reader agents
Parallel agents follow a written reading contract, state the last line they read and write one JSON card per batch: entities and facts with sources.
- Claude Code
- superpowers
Gets from Reading batches, Company configHands to Card checks
Logic
Card checks
Valid JSON, every batch file covered up to its real last line, no emails, phones or IBANs. Cards are the source of truth.
- Python
- regex
Gets from Reader agentsHands to Obsidian vault, Status report
Data
Obsidian vault
Rebuilt from the cards on every run: sources, entities, projects, concepts. Lint enforces front matter, 0 broken links, 0 orphans, 0 personal data.
- Obsidian
- Markdown
Gets from Card checksHands to Knowledge graph
Output
Status report
Counts from the files on disk how many documents the cards really cover, which batches are open or failed and what the checks still flag.
- Python
Gets from Card checks
Output
Knowledge graph
graphify turns the vault into a queryable graph with communities and paths, so answers come back with sources you can open.
- graphify
Gets from Obsidian vault
The problem
At work I had built a second brain: AI agents read a company archive line by line and turned it into a knowledge vault where every fact links to its source. The pipeline was welded to that company's folders, names and products. Reusing it for another organisation, or adding meetings and chats, meant starting again.
What I built
- Pulled the pipeline out into a kit with no data in it: text extraction, reading batches, parallel reader agents, card checks, vault build, lint and a status report.
- Moved every company-specific choice (name, internal email domains, reserved and price folders, business areas, products) into one config file.
- Added intake rules for meeting summaries and exported chats: people outside the company become organisation plus role, and the guide reminds that recording clients needs their consent.
- Kept a single personal-data rule shared by every checker, after three copies of it had disagreed and flagged lab certificate numbers as phone numbers.
- Wrote a 10 KB guide with a six-step setup, a repeatable build cycle and a table of what each check proves.
The hard part
Proving that the agents really read everything. An extraction bug had once doubled every line in some files, so an agent that stopped at the end of a chunk covered half a document while looking finished. The kit caches the real last line of every file, and the card check rejects any card that claims a shorter read.
Result
A complete kit of 20 Python scripts with one file to fill in, shipped with empty working folders. A grep over code and docs, bundled skills excluded, finds 0 references to the original company. The guide lists what is still missing: an API importer for meeting notes and OCR for scanned PDFs.
My role
Solo. The design comes from the second brain I built at work: the reading contract, the batches and the checks. Claude Code did the packaging and wrote most of the code under my direction; I chose what to generalise and checked that no company data was left.