Skip to content

About

This is an agent on bedrock with claude as LLM for generating data using a schema and example template.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

CDS Dataset Agent (SmolAgents + Bedrock)
📦 Overview
This project is an AI Agent built with SmolAgents and AWS Bedrock to generate structured CDS-compliant datasets.

It uses a Bedrock-connected LLM to interpret natural language prompts like "Generate a CDS dataset for 1 patient" and executes the `generate_dataset()` function from your custom generator script (`cds_tsv_generator_v4.py`).
📁 Project Structure

- `agent.py` – Entry point for the agent
- `bedrock_model.py` – Custom model wrapper for Anthropic/Claude via AWS Bedrock
- `cds_tsv_generator_v4.py` – Your core data generation logic (unchanged)
- `.env` – Contains secrets like AWS credentials (not checked in)
- `output/` – Generated CDS files will be written here

⚙️ Setup Instructions

1. Clone the repository:

```bash
git clone https://github.com/your-org/cds-agent.git
cd cds-agent
```

2. Create a virtual environment and install dependencies:

```bash
python -m venv venv
venv\Scripts\activate
pip install -r requirements.txt
```

3. Create a `.env` file with your AWS credentials:

```
AWS_ACCESS_KEY_ID=...
AWS_SECRET_ACCESS_KEY=...
AWS_REGION=us-east-1
BEDROCK_MODEL_ID=anthropic.claude-3-sonnet-20240229-v1:0
```

4. Run the agent:

```bash
python agent.py
```

You can type natural language prompts like:

```
Generate a CDS dataset for 1 patient
```

and the agent will invoke your generator and save the dataset to the `output/` folder.

🛡️ Security Note

Your `.env` file should NEVER be checked into version control.
You can include a `.env.template` file for others with placeholder keys.

📤 Publishing to GitHub

Make sure to add `.env` to `.gitignore` before pushing:

```bash
echo .env >> .gitignore
git init
git remote add origin https://github.com/your-org/cds-agent.git
git add .
git commit -m "Initial commit"
git push -u origin main
```

About

This is an agent on bedrock with claude as LLM for generating data using a schema and example template.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages