Skip to content
Nikunj Agrawal

IndexPortfolio

06

Portfolio

06

Things I have built

01Featured

Financial MCP Server

An open-source Model Context Protocol server that gives any LLM live, tool-calling access to SEC filings, Federal Reserve series, and market fundamentals.

  • Six typed tools across three sources, SEC EDGAR, FRED, and Alpha Vantage, that a model chains on its own: resolve a company to a CIK, pull its filings, then correlate against a macro series, without a human copying anything between tabs.
  • Pydantic schemas with strict field validation reject a hallucinated argument at the boundary instead of turning it into a malformed upstream request, and an async httpx layer converts every upstream failure into a readable string, because an MCP tool cannot raise: the model has no way to catch it.
  • 24 tests run with no network access, covering CIK zero-padding, SEC archive URL construction, form-type filtering, and the error contract; CI runs them on Python 3.11, 3.12 and 3.13.
PythonFastMCPPydantichttpxpytest
02Featured

NCloud

A fault-tolerant cloud platform, webmail plus drive plus chat, running on a replicated, range-sharded key-value store written from the socket layer up in C++17.

  • Roughly 16,000 lines of C++17 across five services with no web framework, no ORM, and no database. The HTTP parser, storage engine, replication protocol, failure detector, leader election, SMTP server, and load balancer are all original code.
  • Kill a storage node mid-upload and the cluster elects a new primary in about 1.5 seconds, the request still completes, and the dead node resyncs when it returns. There is a kill button for every node in the admin console.
  • Underneath: a write-ahead log with checkpoints and bloom filters, primary-backup replication sequenced by log sequence numbers with quorum acknowledgement, and a coordinator that heartbeats every 500ms and elects on the highest LSN. Built by a team of five for CIS 5050; I owned the storage layer, the replication wiring across multi-tablet groups, and coordinator failover.
C++17Distributed systemsReplicationSMTPDockerAWS
03

LLM Fine-Tuning & Multi-Agent Serving

A full fine-tune-to-serve pipeline: Llama-3-8B adapted on instruction pairs, served through vLLM, and consumed by a downstream multi-agent RAG system.

  • Fine-tuned Llama-3-8B on 50K instruction pairs with LoRA in bf16 using gradient checkpointing, tracking RAGAS and BERTScore evaluations in Weights & Biases for a 38% accuracy gain.
  • Served through vLLM behind FastAPI; the downstream LangChain multi-agent RAG system handled 10K+ queries per day at sub-2s p99.
  • Improved response faithfulness 14% by benchmarking BM25, dense, and hybrid retrieval strategies against a fixed RAGAS suite rather than by intuition.
PyTorchHuggingFaceLoRAvLLMLangChainRAGASW&B

Private repository

04

Aria Health — Voice AI for Insurance Benefits

A voice agent that answers coverage, prior-authorization, and claims questions over the phone, with the identity gate enforced in code rather than in the prompt.

  • React and TanStack front end over a Supabase and PostgreSQL backend, wired to Twilio voice APIs with LLM tool-calling to verify caller identity and answer benefits questions live.
  • Server-side PHI guardrails, an identity gate that lives in application code rather than the system prompt, untrusted-speech handling against prompt injection, and a second-model classifier flagging jailbreak and policy violations.
  • Ingests real Synthea C-CDA patient records; identity matching normalises date-of-birth formats before comparison, which is what stopped the verification loop from failing on valid callers.
ReactSupabasePostgreSQLTwilioLLM tool-calling
05

RAG Financial News Retrieval

Semantic search over roughly a decade of S&P 500 news, built to survive the fact that a few million headlines do not fit in memory.

  • DistilBERT embeddings generated on a local RTX 3090: batches of 512 grouped into super-batches of 10 to cut writes 10x, per-batch failure isolation so one malformed batch cannot kill a multi-hour run, and explicit memory reclamation between super-batches.
  • Stored in Postgres with pgvector on AWS RDS and indexed with HNSW for sub-second cosine similarity, which needed the instance's maintenance_work_mem and parallel worker settings retuned before the graph build would complete.
  • Chunked cleaning across roughly 20GB of GDELT and Kaggle news plus yfinance price history, normalising columns across sources that disagreed about nearly every field name.
PythonDistilBERTCUDApgvectorHNSWAWS RDS
06

Multi-Agent Customer Support Orchestration

A LangChain multi-agent system with intent-based routing and FAISS retrieval, built for concurrency rather than for a demo.

  • Intent-based router in front of specialised agents, handling 10K+ daily queries at sub-2s p99 end-to-end.
  • Established a data-driven evaluation loop on RAGAS metrics, improving response faithfulness 14% through iterative benchmarking of BM25, dense, and hybrid retrieval modes.
LangChainFAISSRAGASPython

Private repository

07

FinPortco

A client manager for financial advisors, with full-text search over meeting notes and Claude-generated prep briefs.

  • Search is SQLite FTS5, not LIKE '%term%': an independent virtual table kept in sync by three triggers, so snippet() returns highlighted excerpts without a round trip to the base table.
  • Highlighting cannot inject HTML. Matches are wrapped in private sentinels, the whole result is escaped, and only then are sentinels swapped for mark tags.
  • Ownership is checked per row, not just at the door: the JWT proves who you are, a separate check proves the row is yours, and it returns 404 rather than 403 so client IDs cannot be enumerated.
  • 14 integration tests against a real server process and a throwaway database, including that one advisor can neither list, write to, nor search another's data.
TypeScriptReactExpressSQLite FTS5JWTClaude API
08

Penn Planner

Wharton students track coursework in Canvas and recruiting in CareerPath, so nobody sees when four deadlines land on one Tuesday. This does.

  • Pulls both sources into one list ranked by a priority engine that weighs urgency, task type, and competing commitments, then flags when three or more deadlines converge inside 48 hours.
  • Generates a daily briefing with the Claude API that says what to work on and for how long, rather than restating the list.
  • Next.js App Router with Prisma over SQLite, and CI that migrates, lints, and builds on every push.
Next.jsTypeScriptPrismaSQLiteClaude API