Inspiration
As someone who cannot get access to medication that once used to benefit me, my biggest issue came from doctors not letting me know in enough time that a drug is recalled. I'd like to change that going forward.
What it does
- Scrapes the FDA enforcement API (
openFDA) and MedWatch pages (Nimbleway) for live drug recall data - Stores all recalls and matches in ClickHouse Cloud
- Matches each recall against a hospital formulary using Senso.ai RAG
- Fires a real x402 micropayment when a
CRITICALrecall hits a formulary drug - Traces every agent action in Datadog with severity tags
- Displays a live dashboard ## How we built it ```text bmn-safety-agent/ ├── main.py # Entry point — Flask server + agent scheduler ├── config.py # All env vars ├── scrapers/ │ ├── openfda.py # openFDA enforcement API │ └── nimble_scraper.py # Nimbleway MedWatch scraper ├── storage/ │ └── clickhouse_client.py # ClickHouse schema, insert, query ├── intelligence/ │ └── senso_client.py # Senso.ai RAG formulary lookup ├── alerts/ │ └── alert_engine.py # Recall → severity → payment pipeline ├── payments/ │ └── x402_handler.py # x402 micropayment trigger ├── observability/ │ └── datadog_tracer.py # Datadog APM trace wrapping ├── frontend/ │ ├── index.html # Live dashboard │ ├── style.css # Dark theme styles │ └── app.js # Polls /api/status every 10s ├── data/ │ └── formulary.json # Hospital formulary seed data → load into Senso.ai ├── docker-compose.yml # For judges — shows production deployment ├── requirements.txt └── .env.example ## Challenges we ran into x402 integration was tricky because I didn't want to create a new wallet. Created a workaround ## Accomplishments that we're proud of Building this complete model by myself despite not not knowing how to use the sponsor tools ## What we learned With enough research and carefully worded prompts, builds like this are possible ## What's next for BMN Safety Agent Share the information with others

Log in or sign up for Devpost to join the conversation.