from pydantic import ValidationError from src.ai_med_extract.schemas.patient_schemas import SummaryRequest import json payload = { "mode": "stream", "patientid": 5580, "token": "test_token", "key": "https://api.glitzit.com", "patient_summarizer_model_name": "microsoft/Phi-3-mini-4k-instruct-gguf", "patient_summarizer_model_type": "gguf", "custom_prompt": "create clinical patient summary" } try: print("Attempting to validate payload...") req = SummaryRequest(**payload) print("Validation SUCCESS!") print(req.dict()) except ValidationError as e: print("Validation FAILED!") print(e.json()) except Exception as e: print(f"Unexpected error: {e}")