Python package for generating accurate SQL via LLMs using RAG
Hello HN! We’ve been working hard on Vanna, our RAG framework for SQL generation and we’ve been updating our documentation. Please have a look — we have a ton of Jupyter notebooks for any combination of desired use cases. At it’s heart, we have abstractions that help you: - “train” a RAG “model” i.e. add metadata for the retrieval augmentation system to reference when constructing the LLM prompt (yes, we know that the terms “train” and “model” are somewhat confusing and we’re open to changing those terms if you can suggest better ones) - “ask” questions, which will generate SQL, run it,…
What it does
In the maker’s words, at launch
Hello HN! We’ve been working hard on Vanna, our RAG framework for SQL generation and we’ve been updating our documentation. Please have a look — we have a ton of Jupyter notebooks for any combination of desired use cases. At it’s heart, we have abstractions that help you: - “train” a RAG “model” i.e. add metadata for the retrieval augmentation system to reference when constructing the LLM prompt (yes, we know that the terms “train” and “model” are somewhat confusing and we’re open to changing those terms if you can suggest better ones) - “ask” questions, which will generate SQL, run it, produce charts, etc You can use this in: - Jupyter notebooks - Streamlit (open-source code provided) - Flask (open-source code provided) - Slack (open-source code provided) One key thing to note is that in most of the user interfaces, there’s an opportunity for something _akin_ to RLHF. If the user says that a generated query was correct for a question, then it’s stored back in the vector database for future reference, making the “model” more accurate over time. You can plug it into any LLM or vector database. In the next couple of days we’ll be adding built-in connectors for Mistral, Gemini, and Anthropic.
Does the same job
all alternatives →

- MIMockingbird is an LLM that outperforms GPT4 on RAG2024 · vectara.com · ▲9
Hi HN! I lead product at Vectara and we've just released a new LLM in our platform that outperforms GPT4 and Gemini 1.5 Pro on RAG tasks. Vectara is a Retrieval Augmented Generation (RAG) platform primarily deployed as a SaaS service which includes a generous free tier so you can try it for free. The way we've been able to offer a "better but cheaper" is that we focus a lot of our attention on taking smaller models (which can be hosted in a cost efficient way) and fine tuning them to specific tasks: in this case RAG. This ends up with a model that is less capable of arbitrary tasks like…
- PRPrompt-refiner – Lightweight optimization for LLM inputs and RAGDec 2025 · github.com · ▲7
Hi HN, While building RAG agents, I noticed a lot of token budget was wasted on formatting overhead (HTML tags, JSON structure, whitespace). Existing solutions felt too heavy (often requiring torch/transformers), so I wrote this lightweight, zero-dependency library to solve it. It includes strategies for context packing, PII redaction, and tool output compression. Benchmarks show it can save ~15% of tokens with negligible latency overhead (<0.5ms). Happy to answer any questions!
- CTCognee – Turn RAG and GraphRAG into custom dynamic semantic memory2025 · github.com · ▲6
Hey there HN! We’re Vasilije, Boris, and Laszlo, and we’re excited to introduce cognee, an open-source Python library that approaches building evolving semantic memory using knowledge graphs + data pipelines Before we built cognee, Vasilije(B Economics and Clinical Psychology) worked at a few unicorns (Omio, Zalando, Taxfix), while Boris managed large-scale applications in production at Pera and StuDocu. Laszlo joined after getting his PhD in Graph Theory at the University of Szeged. Using LLMs to connect to large datasets (RAG) has been popularized and has shown great promise.…
- LSLlm.sql – Run a 640MB LLM on SQLite, with 210MB peak RSS and 7.4 tok/sApr 2026 · ▲8
Hi HN, I built llm.sql, an LLM inference framework that reimagines the LLM execution pipeline as a series of structured SQL queries atop SQLite. The motivation: Edge LLMs are getting better, but hardware remains a bottleneck, especially RAM (size and bandwidth). When available memory is less than the model size and KV cache, the OS incurs page faults and swaps pages using LRU-like strategies, resulting in throughput degradation that's hard to notice and even harder to debug. In fact, the memory access pattern during LLM inference is deterministic - we know exactly which weights are needed…
More ai this month
the category →
I trained a 125M-parameter transformer to autocomplete piano performances in real time (~108 notes/sec on an iPhone 15). The idea is basically GitHub Copilot or Tabnine, except instead of prompting it with code, you prompt it by playing a few notes on a MIDI piano. The model then continues what you played, entirely on-device. The app is free if anyone wants to try it. Happy to answer questions about the model, training, Core ML, or the many things that didn't work.
AI · 16d ago · simedw.com
Astute▲585Automate your B2B brand going viral, with new media creators
AI · 18d ago · company-app.joinastute.com


Hey HN, Henry from Cactus here! We previously released Cactus Needle, a 14MB agentic LLM for tool call, device use, and structured extraction for phones, wearables, smart homes, small robots and microcontrollers. We got really great feedback here, and have now incorporated the suggestions to release Needle 2. The whole model is a single 14MB binary that runs a full session in 28MB of RAM; 45m parameters at 2bit compression. Needle hits 500 tokens/sec decode speed on a Raspberry Pi 5, sits between 400-1,500 tokens/sec on VR devices like Meta Quest 3S and Apple Vision Pro, and ranges…
AI · 26d ago · cactuscompute.com


Launched alongside, December 2023
the whole month →- BM
Hi HN! I’m proud to share that we have built a real 3rd party iMessage client for Android. We did it by reverse engineering the iMessage protocol and encryption system. It's available to download today (no waitlist): https://play.google.com/store/apps/details?id=com.beeper.ima and there's a technical writeup here: https://blog.beeper.com/p/how-beeper-mini-works. Unlike every other attempt to build an iMessage app for Android (including our first gen app), Beeper Mini does not use a Mac server relay in the cloud. The app connects directly to Apple…
Commerce · 2023 · beeper.com
- HA
Hey! I made Heynote entirely for my own use case. For many years, I always had an Emacs instance running with the scratch buffer open, even long after I had abandoned Emacs as my programming editor in favor of more recent IDE:s. The simplicity of having just one big scratch buffer appeals to me, but I still want to separate the different things I jot down somehow (without using tabs or similar). Previously, my solution was to insert a bunch of blank lines between the notes, but hitting C-A would still select the entire buffer. That's why I came up with the concept of "blocks", which turned…
Work · 2023 · heynote.com

FuseBase▲941Client collaboration platform for professional services
Dev tools · 2023 · thefusebase.com
Beep! 2.0▲871Fastest tool to assign and share visual tasks with your team
Work · 2023 · justbeepit.com
