RAG in Java with LangChain4j: Teaching a Local LLM About a Company That Doesn’t Exist

Chunks, vectors, a bit of geometry, and no magic. Everything runs on your laptop. Ask an LLM “When does the nightly settlement batch run at Harbourline Payments?” and one of two things happens. The polite model says it doesn’t know. The confident model says “Usually around midnight!” with the energy of a student who didn’t read the book but really wants a good mark. Both are fair, because Harbourline Payments doesn’t exist. I made it up. It’s a fictional company with a fictional engineering handbook: founders, services, deploy rules, on-call pay, and even a famous incident called “the Double Tap”. No model has seen this text during training. ...

October 17, 2026 · 12 min · Vitalii Sukach