| use axum::{response::Json, http::StatusCode}; | |
| use serde_json::json; | |
| pub async fn trigger_tune() -> Result<Json<serde_json::Value>, (StatusCode, String)> { | |
| Ok(Json(json!({ | |
| "status": "LoRA fine-tuning job submitted on AMD MI300X", | |
| "job_id": "lora-med-2025-001", | |
| "security_note": "Training data is fully redacted. No PHI leaves the gateway." | |
| }))) | |
| } | |
| pub async fn latest_round() -> Result<Json<serde_json::Value>, (StatusCode, String)> { | |
| Ok(Json(json!({ | |
| "round": 3, | |
| "accuracy": 0.89, | |
| "hospitals": [ | |
| {"name": "General Hospital A", "models_contributed": 1}, | |
| {"name": "Regional Medical Center", "models_contributed": 1}, | |
| {"name": "University Clinic", "models_contributed": 1} | |
| ] | |
| }))) | |
| } | |