A daily intelligence brief for India. Meridian ingests ~95 government, regulator and newsroom feeds twice a day, sorts every story into eight sections and twenty-five sectors, and presents the result as something you read rather than something you monitor - a scored lead, a machine-written wrap of the last 24 hours, per-sector coverage momentum, and six "reader desks" that re-rank the same archive for whoever is looking at it.
Built by Vedant Solanki · Source
Next.js 16 (App Router) · TypeScript · Tailwind v4 · Prisma 7 + Postgres (Neon) · GitHub Actions for scheduling
A dashboard that pulls together, on a schedule, what's happening in India across: policy & regulation, subsidies & schemes, business & startups, tech & innovation pushes, the economy & markets, investment/FDI, trade (import/export), and geopolitics - from ~35 official government and business-news RSS feeds, a dated news-archive crawl that backfills months of history, and (optionally) the NewsData.io API.
lib/ingestion/- one module per source type. RSS sources (rss.ts) are fetched and normalized from the feed list insources.ts(PIB, RBI, SEBI, PM India, plus the Economic Times / Business Standard / Mint / BusinessLine / The Hindu / Indian Express / Moneycontrol / Inc42 desks);googleNews.tsqueries a dated news archive; the optional NewsData.io source (newsdata.ts) only runs ifNEWSDATA_API_KEYis set.run.tsorchestrates all of them.- Historical backfill (
lib/ingestion/backfill.ts,npm run backfill) - RSS only ever exposes a publisher's latest few dozen items, which is why a fresh install starts out showing "the last few days" and nothing else. The backfill walks the Google News archive month by month withafter:/before:date operators, running eight India-scoped topical queries per month, and attributes each story to its actual publisher rather than to the aggregator. A single crawl of two years pulls in thousands of stories. - The job board (
lib/ingestion/jobBoards.ts,npm run jobs) -/jobsaggregates openings from eleven public sources, each of which asks for attribution and a link back, so every card names its source and opens the original posting. Five are global remote boards (Himalayas, Remotive, Jobicy, Arbeitnow, Remote OK). The rest exist because India barely registers on those:lib/ingestion/jobSourcesIndia.tsreads The Muse city by city, the live Greenhouse/Lever/Ashby boards of ~30 companies with a real India desk, the public Workday career sites of eleven large employers - which is where the Gujarat roles are, Micron's Sanand fab most of all - and Amazon's own India board, the largest single source here and the one carrying the most first jobs. Postings age out after 60 days; nothing is hosted here and nothing is applied to here. - Reaching the entry rungs - a plain recency walk over any of these returns
the senior ladder and never gets to the bottom of it, so the entry rungs are
asked for by name: The Muse is queried again per city with its
Entry LevelandInternshipfacets, Workday withGraduate/Trainee/Apprentice/Intern, and Amazon with the grades it actually advertises first jobs under (Specialist I,Associate,Engineer I). The experience rail on/jobsis drawn as a ladder rather than by size, so the board reads from internships at one end to executive posts at the other. - Reading a posting (
lib/jobClassify.ts,lib/places.ts) - keyword rule sets put each posting on three axes: the discipline the work sits in, the employer's industry, and how much experience it asks for - the last read from the board's own seniority band first, the title second (including the Indian first-job vocabulary: graduate engineer trainee, management trainee, officer trainee, the trailing romanI), and the posting's stated requirements third, wherestatedMinYearspulls the employer's own "0-5 years" or "4+ years" straight out of the text. A gazetteer turns the board's free-text location ("Sanand - 303A - AT/SSD/MOD, India") into a country, the state inside it and a city, which is what makes the board drillable - India, then Gujarat, then Sanand. India is covered far more finely than anywhere else, and Gujarat most finely of all. - Deferred filtering (
lib/deferredFilter.ts) - every filter on the site is a link, because a filtered view is a place and a place needs a URL. Where JavaScript is available, a multiple-choice chip no longer navigates on click: it lights up, waits ~1.2s for the next click, and one navigation carries everything picked. No filter link scrolls the page. lib/categorize.ts- a keyword-based rule set assigns each article to one of the 8 categories, independent of which source it came from, plus a cross-cutting sub-domain tag (25 curated sectors - renewable energy, ports & shipping, fintech, MSME, etc). If nothing matches, the card falls back to showing its category as the tag, so every card always has at least one.- Dedup - every article is upserted on its
url(unique). Because wire copy is republished under many URLs, ingestion also compares a normalized headline (lib/ingestion/dedupe.ts) against everything already stored in the window being processed, so five outlets carrying the same PTI story produce one entry. - Filters - every feed supports a time-range filter (24h/7d/1m/3m/1y/all,
?range=), a browse-by-month picker covering a rolling 24 months (?month=), multi-select section (?cats=) and sector (?tags=) pickers, a sort (?sort=new|old|section) and pagination (?page=) - all combinable, all shareable as URLs, and all preserved across paging. - Page size follows the device - forty stories is a page on a laptop and
roughly twenty screens of thumb on a phone, so
lib/viewport.tsreads the User-Agent for theMobitoken and phones get ten. Tablets deliberately do not match it: Android tablets drop the token and iPadOS reports as a Mac. - "By section" is a board, not a sort -
?sort=sectiondrops the flat feed for one box per section, each showing two rows and paging in place, so the busiest two sections cannot eat the page (lib/sectionBoard.ts). - The sector desk (
/opportunities) - 25 sectors ranked by coverage momentum, state support and visible capital, computed in cached raw-SQL passes overunnest(tags)(lib/opportunity.ts), with hand-rolled inline-SVG charts and no chart library. Momentum is each sector's share of all coverage rather than its story count - the archive's own volume grows as it backfills, and measured absolutely every sector looks like it is accelerating. - Reader desks (
/for) - the same archive re-ranked for six jobs: citizen, student, founder, business owner, investor and public sector. A desk is a weighted set of sections and sectors (lib/personas.ts), not a stored tag, so one lives or dies in a single file and every figure on it is the same measured figure as everywhere else. Each carries a ranked front page, its tracked sectors with their signals and latest stories, and the archive scoped to it. - Reading order - the page opens on a scored lead rather than whatever is
newest (
lib/leadStory.ts): a story with a real deck, from a curated feed, and not a routine auction result or numbered circular. The feed below is grouped by IST day, each day opening with a feature and dropping into scannable rows. - "The wrap" - an AI-written daily summary - the same 24-hour headlines
that fill the brief are sent to Gemini, which writes a short standfirst plus
3-5 category-tagged takeaways (
lib/summarize.ts). Stored on the day'sDailyBriefrow and rendered at the top of the home page. NeedsGEMINI_API_KEY; without it the brief still generates, just without the written summary. - "Ask AI" per article (off by default) - an "Ask" button on every story
that calls Gemini (via
/api/ask,lib/gemini.ts) with just that article's headline/excerpt/metadata to answer a free-text question about it, in an overlay with a few starter prompts. Disabled unlessNEXT_PUBLIC_ENABLE_ASKis exactly"true"- it is the one Gemini feature whose cost scales with traffic instead of with content, so a public deployment leaving it on is an open tap on your API key. The flag gates the button and the route: with it unset,/api/askreturns 404 no matter who posts to it. Seelib/features.ts. - The market desk (
/markets) - the same archive read for who it names and what it changes, in four surfaces./companygives every one of ~300 curated Indian businesses its own timeline, matched by dictionary rather than by an NER model (lib/entities.ts) and stored onArticle.entitiesat ingest./issuancerecovers the primary-issuance pipeline - IPO, QIP, rights, OFS, buyback, block deal - from headlines, split by instrument and by stage./regulatorsseparates what 24 regulators actually issued into circulars, master directions, penalties and consultation papers, and marks which of them bind anyone./calendargenerates the fiscal, tax, results and derivatives dates from rules rather than from a typed list, and flags anything it cannot confirm. The desk also carries the bridge from each sector to the index that tracks it - including the four that nothing on either exchange tracks, and the nine more where the only mapping is a loose proxy. There are no prices anywhere on it: exchange data is licensed, this project holds no licence, and every figure is a count of coverage. /api/cron/ingest- pulls all sources and stores new articles./api/cron/brief- builds the "In brief" panel from the last 24h of articles, a handful of highlights per category, which the front page interleaves so one busy category can't fill the whole list.- Both cron routes are protected by
CRON_SECRET(see below). Neither is on a timer any more - see "The schedule" below for why, and for what runs them.
We deliberately store only a headline, short excerpt, and link back to the
source - never full article text - both to stay on solid fair-use footing for
the news sources and to keep this an aggregator, not a republisher. See the
/sources page in the running app for exactly what's being pulled from where.
npm install
cp .env.example .env # fill in DATABASE_URL at minimum
npx prisma migrate dev --name init
npm run devVisit http://localhost:3000. With no data ingested yet you'll see empty
states. Populate them:
# Two years of history from the news archive (a few minutes; safe to re-run). npm run backfill -- --months=23 # Attribute the stored archive to companies. The entities column is created # empty by its migration, so the market desk is blank until this has run. npm run entities -- --apply # Then the live feeds, and the daily brief. curl http://localhost:3000/api/cron/ingest curl http://localhost:3000/api/cron/brief
npm run backfill also accepts --queries=policy,subsidy,tech,startups,
investment,economy,trade,geopolitics to crawl only some topics.
- Create a project at neon.tech.
- Copy the pooled connection string (hostname contains
-pooler) - this matters for serverless (Vercel) so connections don't exhaust the DB's limit. - Put it in
.envasDATABASE_URL, then runnpx prisma migrate dev --name initto create the tables.
- Sign up at newsdata.io (free tier: 200 credits/day, allows commercial use, has India + business/politics filters).
- Copy the API key into
.envasNEWSDATA_API_KEY. - Ingestion picks it up automatically on the next run - no code changes.
- Create a key at aistudio.google.com/apikey.
- Copy it into
.envasGEMINI_API_KEY. - Both features pick it up on the next request - no code changes.
lib/gemini.tsis the shared client (hand-rolledfetch, not the SDK - see its file comment for why):/api/cron/briefmakes one call/day togemini-3.5-flash(override withGEMINI_MODEL) over the day's ~32 headlines;/api/askmakes one call per question, capped at 1024 output tokens (and is disabled unlessNEXT_PUBLIC_ENABLE_ASK="true"). There's no per-user rate limiting on/api/asksince the app has no auth layer - fine for personal/local use, worth adding a limiter before a public deploy. Summarisation failures are logged and swallowed (brief keeps its headline list, previous day's wrap stays in place);/api/askfailures surface as a clear error in the overlay instead.
- Push this repo to GitHub (or another git provider Vercel supports).
- In Vercel: New Project → import the repo.
- Add environment variables in the Vercel project settings:
DATABASE_URL(andNEWSDATA_API_KEY/GEMINI_API_KEYif you have them). - Generate a random string and set it as
CRON_SECRETin Vercel's env vars - Vercel Cron then automatically sends it as a bearer token on scheduled requests, so nobody else can trigger your ingestion/brief routes. - Deploy.
- Run
npx prisma migrate deployonce against the productionDATABASE_URL(from your machine, withDATABASE_URLpointed at prod) to create the tables before the first ingestion run.
Ingestion runs twice a day, at 07:47 and 19:47 IST, so the site is fresh by
08:00 and 20:00, from
.github/workflows/ingest.yml. It runs npm run ingest, then npm run jobs,
then npm run brief on a GitHub runner, talking to the database directly.
Two runs rather than four is deliberate: every sweep wakes the Neon compute and
spends its monthly allowance, and exhausting it took the whole site down. The
odd minute is deliberate too. GitHub's scheduler queues rather than fires, and
:00/:30 (08:00 and 20:00 IST are 02:30 and 14:30 UTC) are when every cron on the platform asks
at once - on that slot runs were landing 35 minutes late on a good day and
being dropped outright on a bad one. GitHub never makes up a dropped schedule,
so if a run is missed, start one by hand from the Actions tab. The job-board step is
continue-on-error so a board outage cannot stop the daily wrap that follows
it: the news looking stale because a job board failed is precisely backwards.
It is not a Vercel cron, and vercel.json no longer exists. A full sweep is
~95 feeds and takes minutes; a Vercel function is capped at 60 seconds, so the
cron that used to live there was killed part-way through every run and the
archive quietly stopped growing. Vercel's Hobby plan also caps crons at
once/day, which is enough for the schedule but not for the run time. A runner has neither limit, needs no
deployment to exist, and is what scripts/ingest.ts was written for in the
first place.
To set it up, add three repository secrets under Settings → Secrets and
variables → Actions: DATABASE_URL, NEWSDATA_API_KEY, GEMINI_API_KEY.
CRON_SECRET is not needed - the runner never goes through HTTP. Then use
Actions → Ingest → Run workflow to fire the first run without waiting.
Two things to know about GitHub's scheduler: it queues rather than firing on the second, so runs land a few minutes late (occasionally 15-20 under load); and it disables scheduled workflows in a repository with no activity for 60 days, which any commit or manual run re-arms.
To change the times, edit the cron: line in the workflow. It is in UTC,
so subtract 5:30 from the IST time you want - 30 3,9,15 * * * is 09:00,
15:00 and 21:00 IST.
Vedant Solanki
- LinkedIn - https://www.linkedin.com/in/solanki-vedant/
- Project - https://github.com/solankivedant/Meridian-Intelligence
- PRS India (legislative tracker), Startup India schemes feed, DGFT/TRADESTAT trade-data scraping, MEA geopolitics - all HTML-scrape-only sources, each needs its own bespoke, more fragile scraper.
- Optional LLM-based re-categorization / "why this matters" enrichment.
- Optional Google Trends widget (no reliable free API exists today -
pytrendsis unmaintained/rate-limited; SerpApi is a paid alternative).