Back to Ratnesh Dagli's portfolio
From feed to reason.
ContextLens · architecture
Follow an article from 224 feeds to a globe. Every AI step sits behind a gate that fails closed, so a claim the sources do not support never reaches the reader.
Guided tour
- The whole road: Articles flow left to right: collected, merged, explained, judged, then read. Hover a label, or use the buttons to send your own.
- 224 feeds: More than 90 outlets feed the system. Each flicker on the wall is a feed delivering an article.
- Duplicates merge: The funnel narrows hundreds of articles into a handful of story threads, so the same event is explained once.
- The writer: The first model turns a thread into layers: the gist, what happened, why, and who is involved, with each claim tied to a sentence.
- The editor says no: Three gates judge the result. Anything the sources do not support turns red and drops out. Inject one to watch it happen.
- The reader: What survives is stored and served. Verified stories land on the globe as pins you can zoom into.
Parts you can inspect
224 RSS feeds: Collect from everywhere
The reader starts from RSS feeds published by more than 90 outlets, so a story is seen through many newsrooms, not one.
- 224 feeds, 90+ outlets
- A stealth-browser fallback handles sites that answer 403
Merge into threads: Duplicates become one thread
Different outlets reporting the same event are merged, and a quick front page is built from the threads before any AI has run.
- Cheap and instant: no model needed for this step
LLM writer: Explain it in layers
A language model takes one story at a time and writes the gist, what happened, why, how it unfolded, who is who, and who else covered it.
- Each cause points at the source sentence it came from
- Or is labelled as general knowledge
LLM editor + gates: A second model says no
An editor model judges the writer’s work, then validation gates reject anything the sources do not support. The gates fail closed.
- Unvalidated model output is never shown
- Every AI step is classify, render or constrained-generate
Reader + globe: Read it, or fly to it
A FastAPI backend serves the React app from one process, with SQLite underneath and a scheduler that keeps the feed fresh. Zoom the globe to a place to read its live headlines.
- 18 API routers, 38 service modules
- The geotagger is rule-based and fails closed
Things you can try
- Trace one story: Send one bright story down the whole road
- Inject an unsupported claim: Watch the gates reject it
A schematic. Particle counts, speeds and the share that gets rejected are illustrative, not live data. The facts come from the project’s code and README.