Skip to content

DHEPLab/augmed-rl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AugMed RL Service

Adaptive experimentation service for the AugMed platform. Uses Thompson Sampling to dynamically adjust experimental arm assignments based on participant outcomes, enabling more efficient clinical experiments.

Built with FastAPI and uvicorn.

Deploy the full platform: This RL service is part of a multi-service platform. To deploy everything together (API + Frontend + RL + Database), see the One-Click Deploy Guide in the API repository.

Configuration

The service reads configuration from environment variables with the AUGMED_RL_ prefix:

Variable Description
AUGMED_RL_AUGMED_API_URL URL of the AugMed API (e.g., http://localhost:5000)
AUGMED_RL_AUGMED_API_KEY API key for authenticating with the export API

Quick Start

  1. Clone the repository:

    git clone <repository-url>
  2. Build container:

    task build
  3. Spawn local service:

    task up
  4. Tear down local service:

    task down

Development

# Install dependencies
pip install -e .

# Run the service
uvicorn src.main:app --host 0.0.0.0 --port 8000

# Run tests
pytest

Docker

docker build -t augmed-rl .
docker run -p 8000:8000 \
  -e AUGMED_RL_AUGMED_API_URL=http://host.docker.internal:5000 \
  -e AUGMED_RL_AUGMED_API_KEY=your-api-key \
  augmed-rl

About

Reinforcement Learning feedback loop service for AugMed platform

Resources

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors