Inspiration
This project started from a question I couldn't stop turning over: what if an ML pipeline didn't just run once and hand you a number, but actually understood why it failed and went and fixed itself? I've spent a lot of time in labs and on research projects where the slow, human part of machine learning is always the diagnosis step — staring at a confusion matrix, guessing whether you need more data or a different model, trying things by hand. I wanted to see if an agent could do that reasoning itself, live, with nobody in the loop telling it what to try next.
Healthcare felt like the right domain to prove this in. It's a space where getting a wrong diagnosis actually matters, so a model that can explain why it made a decision, not just what the decision was, felt like the more honest thing to build than another leaderboard-chasing script.
What it does
The agent takes on a real, published research problem: predicting heart disease from patient clinical data, using a benchmark that real papers have set (78.7% baseline, 83.3% best published result). Then we let it go. It starts weak on purpose, on the smallest hospital's data, and from there it's on its own: it evaluates itself, diagnoses why it's underperforming using real statistical signal, not guesswork, and decides what to do about it. Sometimes that means pulling in another hospital's data live. Sometimes it decides its features are on the wrong scale and asks for a transform. Sometimes it decides the model itself is the wrong shape for the problem and switches from KNN to a random forest to an SVM. When it's truly out of native data, it reaches out into a live tool marketplace to find something to enrich itself with, entirely on its own judgment.
Every one of those autonomous decisions passes through a real access-control gate before it's allowed to happen, so the system isn't just autonomous, it's autonomous inside a boundary we can see and trust.
How we built it
We split the work in a way that matched what we're each good at. I focused on the core loop: the data pipeline, the model training and evaluation harness, and the diagnosis logic that has to look at a result and make a real call about what's wrong with it. My teammate took the two pieces that needed a different kind of care: the access-control layer that gates every autonomous action, the live marketplace integration the agent reaches for when it's exhausted everything else, and the dashboard that shows all of it happening in real time instead of asking anyone to trust a claim on a slide.
We used Claude Code heavily throughout, working in parallel branches so we could both move fast without stepping on each other, and syncing constantly at the seams where our two halves had to actually talk to each other.
Challenges we ran into
Almost all of our hardest moments happened exactly at that seam. At one point we had two different implementations of the same integration living in different branches, and neither of us realized it until a smoke test came back clean, but for the wrong code. We caught a naming mismatch where my action names and my teammate's access-policy names didn't line up, which would have silently denied every single autonomous action if we hadn't caught it before demo day. We found a log line that said an integration had run when it actually hadn't. None of these were fun to find, but every single one, we chose to actually fix rather than paper over, even when the easier move would've been to let a misleading log line slide because it "looked" done.
If there's a thread through this whole project, it's that we kept choosing honesty over the appearance of progress, even under a ticking clock. That took discipline neither of us expected to need this much of.
Accomplishments we're proud of
The agent genuinely beats the published benchmark, autonomously, using data it decided on its own to go get. But honestly, what we're proudest of is smaller than that: watching it correctly diagnose that a model was underfitting versus overfitting versus starved for data, using real evaluation signal, and make a different choice each time depending on what it actually saw. That's the moment this stopped feeling like a script we wrote and started feeling like something that was actually reasoning.
What we learned
That autonomy is worth very little if you can't see the boundary around it, and that the unglamorous work, matching two people's naming conventions, chasing down a fake-looking log line, is where a project either becomes trustworthy or quietly stops being honest. We'd rather ship something a little rougher that we can stand behind completely than something polished that we'd have to hope nobody asks the wrong question about.
Built With
- asyncio
- css
- fastapi
- html
- javascript
- machine-learning
- nexla
- numpy
- pandas
- pomerium
- pydantic
- python
- reinforcement-learning
- scikit-learn
- sse
- uvicorn
- yaml
- zero.xyz
Log in or sign up for Devpost to join the conversation.