Dhruv Lohani

Dhruv Lohani · UC Berkeley

Hi, I'm Dhruv!

I'm studying Computer Science and Applied Math at UC Berkeley. I like building things, learning how systems work, and chasing ideas that are both technically deep and genuinely interesting to use.

Lately that has meant spending time on AI systems, infrastructure, and applied machine learning, but I'm motivated as much by curiosity as by any one niche.

Fig. 1Level sets of a slowly drifting scalar field, drawn live. Move the cursor to raise a hill and watch the contours bend. Fig. 1 is purely mathematical: nothing here is data.

01 / 04

Experience

Four places I've worked, and what I built at each.

Summer 2026

Amazon Alexa

Software Development Engineer Intern

ML Infrastructure · Edge AI

My team at Alexa was working on running LLMs directly on devices, and my part was figuring out where inference time was being spent. If a request was slow, we needed to know whether the model was spending that time on the AI hardware or inside the surrounding C++ runtime. I built low-level timing instrumentation across five stages of the C++ inference pipeline to track every step of a request. A big part of the engineering challenge was making sure the timing logic itself had almost zero overhead—because these stages run on every single token the model generates, normal logging during a request would slow down the system and ruin the measurements. Instead, I recorded lightweight timestamps directly in memory while the model ran and only wrote the data out after the request finished, keeping runtime overhead under 2%. This lets us cleanly separate raw AI compute from C++ bottlenecks and speed up end-to-end inference.

Fig. 2A conceptual inference pipeline with instrumentation probes at the stage boundaries. Stages and proportions are illustrative, not measurements.

June – August 2025 · New York, NY

Auctor

Software Engineering Intern

At Auctor, I built the backend that takes messy customer data and uses LLM agents to turn it into structured product requirements, cutting manual parsing by ~70%. I wrote the core services, REST APIs, and agent orchestration engine in Python (FastAPI) and TypeScript, backed by SQL databases and cloud storage. Because multi-step LLM jobs take several seconds to finish, running them directly inside an API call would hang the connection and time out. To keep our APIs responding fast (<200ms p95), I split the system up: the API accepts incoming data right away, hands the heavy agent work off to background worker queues, and sends the finished results back over webhooks once they're ready. Deployed with Docker on AWS, this pipeline handled 10,000+ events a day with 99.9% of workflows completing cleanly.

Fig. 3The shape of an asynchronous agent pipeline: requests are acknowledged immediately, the slow work happens in workers, and results come back through webhooks. Schematic.

January – June 2025

Berkeley Artificial Intelligence Research

Undergraduate Researcher

BAIR · UC Berkeley

At BAIR, I worked on multi-agent reinforcement learning, studying how groups of LLM agents can collaborate to solve complex problems. One big question we tackled was credit assignment: when several agents make decisions together over multiple turns, how do you figure out which ones actually contributed to a successful outcome, and which ones just coasted? To test this at scale, I engineered the Python simulation environments that ran populations of agents across multi-step reasoning tasks. I also built the data pipelines (Pandas, NumPy) to process their shared execution histories and score each agent's marginal contribution to the team, which boosted overall task success by over 25%.

Fig. 4A toy coordination task. Remove an agent to see how the team's outcome changes; the bars estimate each agent's marginal contribution. Illustrative.

May – September 2024 · Stanford, CA · hybrid

Stanford University School of Medicine

Machine Learning Researcher

At Stanford Medicine, I worked on a project involving fluid dynamics and reinforcement learning. We were using fluid-flow simulations where certain parameters would normally need to be adjusted manually. I built simulations to generate training data and trained a reinforcement learning agent to adjust those parameters automatically. It was a pretty different ML problem from anything involving LLMs, since the agent was interacting with a mathematical model of a physical system. I got to spend a lot of time working with the underlying simulations as well as figuring out how to train the agent effectively.

Fig. 5A two-dimensional flow past an obstacle, drawn from its stream function. Drag the parameter to change the flow, or let the agent search for the target. Illustrative.

02 / 04

Awards & Honors

Competition results from math, physics, and programming olympiads.

03 / 04

Selected Projects

Things I've built on my own time. I like projects that are visually interesting, technically hard, or useful in the real world.

Project 01

CPR Analysis

Python · PyTorch · Meta SAM 3D-Body · OpenCV · FastAPI

I wanted to see if computer vision could be used to give people feedback on their CPR technique without needing specialized motion-capture equipment. The idea is to take ordinary video of someone performing CPR, estimate their body movements in 3D, and use that information to look for problems with their form.

The system uses Meta's SAM 3D-Body to estimate and track body pose throughout the video. From that, it analyzes things like elbow angle, upper-body positioning, and the rhythm of chest compressions. I also integrated vision-language models to turn the detected movements into more understandable feedback, rather than just showing someone a skeleton and a bunch of measurements.

One of the main challenges is getting useful information from ordinary video, where the camera angle, visibility, and movement can all affect the estimates. The goal is to make a useful practice-feedback tool, although it's still a prototype and isn't intended to replace certified CPR training.

    Fig. 6The quantities the system looks at, drawn schematically: elbow angle, alignment over the chest, and compression cadence.

    Project 02

    Real-Time 3D Flight Globe

    TypeScript · Three.js · WebGL · WebSockets · GPU instancing

    I wanted to build a flight tracker where you could explore air traffic around the entire Earth in 3D, rather than just looking at aircraft moving across a flat map.

    The application is designed to display thousands of aircraft around a realistic globe, using real flight-position updates. You can rotate the Earth, zoom into different regions, and explore individual flights. One challenge is that aircraft positions don't arrive continuously, so the application needs to interpolate between updates to make their movement look smooth.

    The other big challenge is rendering performance. Drawing thousands of independently moving aircraft can get expensive pretty quickly, especially when the user is rotating or zooming around the globe. I'm using Three.js and GPU instancing to minimize rendering overhead, while a separate data pipeline handles incoming flight updates.

    The goal is to make something that feels smooth and enjoyable to explore, even with thousands of aircraft moving at once.

    • Live app · coming soon
    Fig. 7Great-circle routes over an orthographic globe, drawn in ink. The real application renders live traffic; a showcase video will replace this.

    04 / 04

    About Me

    The parts of my life that don't fit in a commit message.

    • A little more about me, outside of work and school.
    • I go skydiving about once a month. It's one of my favorite ways to spend a weekend.
    • I grew up in Cupertino, right in the middle of Silicon Valley.
    • I'm a huge basketball fan, and being from the Bay Area, I naturally grew up rooting for the Warriors.
    • I teach the Poker DeCal at Berkeley, and I'm fascinated by the strategy and game theory behind poker.
    • I follow financial markets pretty closely, from stocks to prediction markets like Kalshi.
    • That's about it. Thanks for making it this far!

    Map data © OpenStreetMap contributors (ODbL). Elevation: AWS Terrain Tiles. Altitudes, speeds and time are compressed and illustrative; market prices are synthetic.

    Contact

    The best way to reach me is email.

    dhruv-lohani@berkeley.edu

    LinkedIn