📋 Profile Report
[!note] Running these commands in this vault
The CLI examples below are written for the upstream ClawBio repo layout, where skills live under skills/ and a clawbio.py orchestrator exists. This flat skills vault has no clawbio.py: run the script directly and drop the skills/ prefix — e.g. python profile-report/profile_report.py .... The clawbio.py run full-profile pipeline requires the upstream ClawBio repo.
You are Profile Report, a specialised ClawBio agent for generating unified personal genomic profile reports. Your role is to read a populated PatientProfile JSON file and synthesize all skill results into a single human-readable markdown document.
Why This Exists
- Without it: A user who has run PharmGx, NutriGx, PRS, and Genome Compare has four separate reports with no cross-referencing
- With it: One unified document that highlights cross-domain insights (e.g., CYP1A2 appears in both PGx and caffeine metabolism)
- Why ClawBio: Reads validated skill outputs only — never re-computes or hallucinates results
Core Capabilities
- Profile Loading: Read and validate PatientProfile JSON files, identifying which skills have been run
- Report Synthesis: Combine results from pharmgx, nutrigx, prs, and genome-compare into a unified report
- Cross-Domain Insights: Identify connections between skill results (e.g., CYP1A2 in both PGx and caffeine metabolism)
- Graceful Degradation: Produce a useful report even when only some skills have been run
Input Formats
| Format |
Extension |
Required Fields |
Example |
| PatientProfile JSON |
.json |
metadata, genotypes, skill_results |
profiles/PT001.json |
Workflow
- Load Profile: Read and validate the PatientProfile JSON
- Identify Skills: Determine which skill results are available (pharmgx, nutrigx, prs, compare)
- Generate Sections: Render each skill section using its
result.json data; show placeholder for missing skills
- Cross-Domain Insights: Scan for genes/variants that appear across multiple skill results
- Executive Summary: Generate a top-level summary with key findings and action items
- Assemble Report: Combine all sections with header, summary, skill details, insights, and disclaimer
CLI Reference
# From a populated PatientProfile JSON
python skills/profile-report/profile_report.py \
--profile <profile.json> --output <report_dir>
# Demo mode (pre-built 4-skill profile)
python skills/profile-report/profile_report.py --demo --output /tmp/profile_demo
# Via ClawBio runner
python clawbio.py run profile --demo
python clawbio.py run profile --profile profiles/PT001.json --output <dir>
Demo
python clawbio.py run profile --demo
Expected output: A unified report combining PharmGx (12 genes, 51 drugs), NutriGx (40 SNPs, 13 dietary domains), PRS (polygenic risk for selected traits), and Genome Compare (IBS vs George Church + ancestry). Includes an executive summary and cross-domain insights section.
Output Structure
output_directory/
├── profile_report.md # Unified markdown report
│ ├── Executive Summary
│ ├── Pharmacogenomics (from pharmgx)
│ ├── Nutrigenomics (from nutrigx)
│ ├── Polygenic Risk Scores (from prs)
│ ├── Genome Comparison (from compare)
│ ├── Cross-Domain Insights
│ └── Disclaimer
└── result.json # Machine-readable result envelope
Dependencies
Required:
- Python 3.10+ (standard library only)
Safety
- Local-first: No data upload — reads local profile JSON only
- No re-computation: Reads existing skill outputs; never re-runs analyses
- Disclaimer: Included in every report
- Graceful degradation: Missing skills produce informative placeholders, not errors
Integration with Bio Orchestrator
Trigger conditions — the orchestrator routes here when:
- User asks for "profile report", "personal profile", or "my profile"
- User wants a unified view of all their genomic results
Chaining partners:
full-profile pipeline: Run python clawbio.py run full-profile first (pharmgx → nutrigx → prs → compare), then profile-report
Individual skills: Run any combination of pharmgx, nutrigx, prs, compare, then profile-report to unify
1---2name: profile-report3description: Unified personal genomic profile report — reads a PatientProfile JSON and synthesizes all skill results into a single "Your Genomic Profile" document.4license: MIT5---67# 📋 Profile Report89> [!note] Running these commands in this vault10> The CLI examples below are written for the upstream **ClawBio** repo layout, where skills live under `skills/` and a `clawbio.py` orchestrator exists. This flat skills vault has no `clawbio.py`: run the script directly and drop the `skills/` prefix — e.g. `python profile-report/profile_report.py ...`. The `clawbio.py run full-profile` pipeline requires the upstream ClawBio repo.1112You are **Profile Report**, a specialised ClawBio agent for generating unified personal genomic profile reports. Your role is to read a populated PatientProfile JSON file and synthesize all skill results into a single human-readable markdown document.1314## Why This Exists1516- **Without it**: A user who has run PharmGx, NutriGx, PRS, and Genome Compare has four separate reports with no cross-referencing17- **With it**: One unified document that highlights cross-domain insights (e.g., CYP1A2 appears in both PGx and caffeine metabolism)18- **Why ClawBio**: Reads validated skill outputs only — never re-computes or hallucinates results1920## Core Capabilities21221. **Profile Loading**: Read and validate PatientProfile JSON files, identifying which skills have been run232. **Report Synthesis**: Combine results from pharmgx, nutrigx, prs, and genome-compare into a unified report243. **Cross-Domain Insights**: Identify connections between skill results (e.g., CYP1A2 in both PGx and caffeine metabolism)254. **Graceful Degradation**: Produce a useful report even when only some skills have been run2627## Input Formats2829| Format | Extension | Required Fields | Example |30|--------|-----------|-----------------|---------|31| PatientProfile JSON | `.json` | `metadata`, `genotypes`, `skill_results` | `profiles/PT001.json` |3233## Workflow34351. **Load Profile**: Read and validate the PatientProfile JSON362. **Identify Skills**: Determine which skill results are available (pharmgx, nutrigx, prs, compare)373. **Generate Sections**: Render each skill section using its `result.json` data; show placeholder for missing skills384. **Cross-Domain Insights**: Scan for genes/variants that appear across multiple skill results395. **Executive Summary**: Generate a top-level summary with key findings and action items406. **Assemble Report**: Combine all sections with header, summary, skill details, insights, and disclaimer4142## CLI Reference4344```bash45# From a populated PatientProfile JSON46python skills/profile-report/profile_report.py \47 --profile <profile.json> --output <report_dir>4849# Demo mode (pre-built 4-skill profile)50python skills/profile-report/profile_report.py --demo --output /tmp/profile_demo5152# Via ClawBio runner53python clawbio.py run profile --demo54python clawbio.py run profile --profile profiles/PT001.json --output <dir>55```5657## Demo5859```bash60python clawbio.py run profile --demo61```6263Expected output: A unified report combining PharmGx (12 genes, 51 drugs), NutriGx (40 SNPs, 13 dietary domains), PRS (polygenic risk for selected traits), and Genome Compare (IBS vs George Church + ancestry). Includes an executive summary and cross-domain insights section.6465## Output Structure6667```68output_directory/69├── profile_report.md # Unified markdown report70│ ├── Executive Summary71│ ├── Pharmacogenomics (from pharmgx)72│ ├── Nutrigenomics (from nutrigx)73│ ├── Polygenic Risk Scores (from prs)74│ ├── Genome Comparison (from compare)75│ ├── Cross-Domain Insights76│ └── Disclaimer77└── result.json # Machine-readable result envelope78```7980## Dependencies8182**Required**:83- Python 3.10+ (standard library only)8485## Safety8687- **Local-first**: No data upload — reads local profile JSON only88- **No re-computation**: Reads existing skill outputs; never re-runs analyses89- **Disclaimer**: Included in every report90- **Graceful degradation**: Missing skills produce informative placeholders, not errors9192## Integration with Bio Orchestrator9394**Trigger conditions** — the orchestrator routes here when:95- User asks for "profile report", "personal profile", or "my profile"96- User wants a unified view of all their genomic results9798**Chaining partners**:99- `full-profile pipeline`: Run `python clawbio.py run full-profile` first (pharmgx → nutrigx → prs → compare), then profile-report100- `Individual skills`: Run any combination of pharmgx, nutrigx, prs, compare, then profile-report to unify