Challenge

Postpartum Psychiatric Risk Monitoring Agent using LangChain and Agno

Monitoring drug liability and psychiatric risk during postpartum clinical care requires synthesizing clinical records and adverse event data. Developers will build a LangChain and Agno stateful agent to extract medication histories, assess liability risk markers, and generate structured clinical review alerts with complete auditability.

Data ScienceHosted by Vera
Challenge brief

What you are building

The core problem, expected build, and operating context for this challenge.

Develop a stateful clinical agent using LangChain and Agno to evaluate postpartum psychiatric medication histories and risk factors.

Delivery guide

How work is evaluated

Evaluation

Evaluates medication extraction recall, polypharmacy risk score calculation, and audit logging validity.

Datasets

Shared data for this challenge

Review public datasets and any private uploads tied to your build.

Evaluation rubric

How submissions are scored

These dimensions define what the evaluator checks and which criteria separate a passable run from a strong one.

Dimensions
2 scoring checks
Binary
2 pass or fail dimensions
Ordinal
0 scaled dimensions
Dimension 1

review_flag_test

Verifies that high-risk polypharmacy triggers clinician review.

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Dimension 2

entity_extraction_f1

F1 score of medication name extraction from EHR text. • target: 0.92 • range: 0-1

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Learning goals

What you should walk away with

  • Configure a LangChain stateful processing graph for electronic health record (EHR) text.

  • Integrate Agno agent structures for multi-modal drug interaction monitoring.

  • Extract psychotropic polypharmacy patterns from patient encounter notes.

  • Generate structured clinical liability and safety alerts with explicit provenance links.

Resources and assets

Reference links and supporting material

Dataset notes

Synthetic postpartum patient clinical notes containing realistic medication histories and symptoms.

How this agent runs

Evaluates medication extraction recall, polypharmacy risk score calculation, and audit logging validity.

Challenge input

JSON containing clinical encounter note text.

LangChain

Provides structured chain execution and state management.

Agno

High-performance agent library for domain-specific tasks.

Evaluated output

JSON containing extracted medications, risk level, and review alert flag.

Checks for
  • Verifies that high-risk polypharmacy triggers clinician review.
  • F1 score of medication name extraction from EHR text. • target: 0.92 • range: 0-1
Proof of success
  • Benchmark: Clinical Adverse Event Detection Benchmark
  • Entity Extraction F1 target: 0.92
  • 1 public reference case
Runtime evidence
  • Python execution harness
  • Python sandbox (unavailable on Versalist)
View technical recipe

Configured tools

Action Space
  • Langchain · Required
  • Agno · Optional
  • PyTorch Lightning · Optional
Orchestration
  • Langchain · Required
  • Agno · Optional

Evaluation contract

  • review_flag_test · Weight 1
  • entity_extraction_f1 · Weight 1

Recipe state

This is a preview. The configuration can change before the evaluation recipe is locked.

Frequently Asked Questions about Postpartum Psychiatric Risk Monitoring Agent using LangChain and Agno