From a week of news to a short list of calls
Most relevant CSR announcements never reach a partnerships team in time. The Radar reads them all every week and keeps only what deserves a conversation, with the evidence attached.
Components map
The weekly run, step by step, with where each step lives in the code.
- 1
A schedule that matches your week
Vercel Cron starts the run every Monday at 7:30 am IST, before outreach begins. Admins can also run it on demand from Settings and watch it progress.
vercel.ts, app/api/cron/weekly, app/api/run
- 2
Searches built from your footprint
Each focus sector becomes three searches (new initiatives, partner calls, bigger allocations), plus searches for your priority places and for CSR policy and rule changes.
lib/sources/queries.ts
- 3
Live news, two sources
Every search runs against Google News and Bing News (India edition, past seven days). A feed that fails is logged and skipped, never fatal.
lib/sources/feeds.ts
- 4
Cleaning
Old items are dropped, the same story from different outlets is merged, and anything already covered in an earlier briefing is left out.
lib/pipeline/normalize.ts
- 5
Gemini reads every headline
Gemini Flash screens all stories in batches: is it relevant, which signal is it, which company, sector and place, and which other stories describe the same event.
lib/ai/gemini.ts, lib/ai/prompts.ts
- 6
One development per event
Coverage of the same announcement is grouped, duplicates by the same company are merged, and companies you excluded are removed.
lib/pipeline/cluster.ts
- 7
Gemini checks and decides
For each development Gemini Flash searches the web to confirm facts and the company's CSR track record, then writes what happened, why it matters to you, a call, watch or skip decision, a warmth score, an opening line and who to approach.
lib/ai/gemini.ts
- 8
Explainable ranking
Warmth is combined with signal strength, geography tier and coverage into one score, and companies seen in earlier weeks are flagged as warming up.
lib/pipeline/score.ts, lib/repo.ts
- 9
Briefing, email and follow-up
Gemini writes the summary, the briefing is saved and emailed, and each lead can be tracked through your pipeline with a drafted first email.
lib/digest-service.ts, lib/email, app/pipeline
Stack
| Component | Technology | Code |
|---|---|---|
| Web app and API | Next.js on Vercel | app/, components/ |
| Scheduler | Vercel Cron, Mondays 02:00 UTC | vercel.ts |
| News sources | Google News RSS, Bing News RSS | lib/sources |
| AI | Gemini Flash with structured output and Google Search grounding | lib/ai |
| Pipeline | Plain TypeScript steps with unit tests | lib/pipeline, tests/ |
| Database | Neon Postgres via Vercel Marketplace, Drizzle ORM | lib/db, lib/repo.ts |
| Resend | lib/email | |
| Access | Admin passcode with a signed cookie | lib/admin.ts |
How the Radar stays honest
- Every lead links to its original articles, and says whether Gemini confirmed it with a web search or only had the headline.
- Gemini is instructed never to invent amounts, people or deadlines. Contacts are named only when a source names them.
- If Gemini is unavailable, a story still appears as a watch item with its headline instead of silently disappearing.
- Each briefing shows exactly how many articles were read, skipped and analysed.