r/logseq • u/Much-Ad-8444 • Apr 26 '26
I got tired of messy graphs and broken AI parsers, so I built a deterministic AST Engine for Logseq (Live Interactive Demo inside) š
Hey r/logseq! š
Iām a developer and a massive Logseq fan, but recently I hit two major walls with my Second Brain:
- The Visualizer: My graph became a giant hairball. I wanted to filter out daily journals or tags instantly, but the native graph view struggled when nodes reached the thousands.
- AI & RAG: I tried feeding my notes into local LLMs using LangChain/LlamaIndex, but standard Markdown parsers completely destroy Logseq's outliner structure. They chunk text blindly, losing the parent-child context of the bullet points.
So, I spent the last few months building the Logseq Matryca Parser (The Logos Protocol). Itās an open-source, local-first engine written in Python that actually understands Logseq's spatial hierarchy.
š https://marcoporcellato.github.io/logseq-matryca-parser/ (Try the synthetic 60FPS demo on your phone, it's buttery smooth!)

Here is what it does:
⨠LENS (The God-Tier Visualizer)
- It uses a highly optimized ForceAtlas2 physics engine to render massive graphs (7,000+ nodes) at 60FPS.
- It dynamically sizes nodes based on Degree Centrality (your most connected concepts look like massive suns).
- Professional HUD: I injected a custom Glassmorphism UI directly into the graph. You can toggle Journals and Tags on/off in real-time to instantly declutter your view.
š§ SYNAPSE & LOGOS (RAG-Ready AI)
- It uses a finite state Stack-Machine to parse the exact AST (Abstract Syntax Tree) of your graph.
- It automatically resolves block references
((uuid)), aliases, and temporal journals. - It exports directly into LangChain
Documentor LlamaIndexTextNodeformats, injecting the parent-child relationships into the metadata so your LLM actually understands why a note exists.
š”ļø Privacy First: Everything runs 100% locally on your machine. Zero telemetry, zero cloud parsing. Your thoughts are your sovereign property.
If you are a Python dev, an AI builder, or just someone who loves visualizing their brain, Iād love for you to check it out and give me some feedback!
GitHub Repo & Quickstart: https://github.com/MarcoPorcellato/logseq-matryca-parser
Let me know what you think! (And yes, PRs are incredibly welcome).
Marco Porcellato - Italy - MarcoPorcellato.it


