Commit
·
9855392
1
Parent(s):
480f467
Fix: Remove Field import from response_models.py
Browse files
src/models/request_models.py
CHANGED
|
@@ -3,9 +3,9 @@ from pydantic import BaseModel, Field
|
|
| 3 |
class ProviderNotesRequest(BaseModel):
|
| 4 |
provider_notes: str = Field(
|
| 5 |
...,
|
| 6 |
-
description="The medical provider notes to analyze",
|
| 7 |
min_length=10,
|
| 8 |
-
|
|
|
|
| 9 |
)
|
| 10 |
|
| 11 |
class Config:
|
|
|
|
| 3 |
class ProviderNotesRequest(BaseModel):
|
| 4 |
provider_notes: str = Field(
|
| 5 |
...,
|
|
|
|
| 6 |
min_length=10,
|
| 7 |
+
description="Clinical provider notes for analysis",
|
| 8 |
+
examples=["Patient presents with acute bronchitis. Cough for 5 days..."]
|
| 9 |
)
|
| 10 |
|
| 11 |
class Config:
|
src/models/response_models.py
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
from pydantic import BaseModel
|
| 2 |
-
from typing import List
|
| 3 |
|
| 4 |
class ICDCode(BaseModel):
|
| 5 |
code: str
|
|
@@ -11,24 +11,6 @@ class CPTCode(BaseModel):
|
|
| 11 |
description: str
|
| 12 |
explanation: str
|
| 13 |
|
| 14 |
-
class ProviderNotesRequest(BaseModel):
|
| 15 |
-
provider_notes: str = Field(
|
| 16 |
-
...,
|
| 17 |
-
description="The medical provider notes to analyze",
|
| 18 |
-
min_length=10,
|
| 19 |
-
example="Patient presents with acute bronchitis. Performed comprehensive examination and prescribed antibiotics."
|
| 20 |
-
)
|
| 21 |
-
|
| 22 |
-
class Config:
|
| 23 |
-
json_schema_extra = {
|
| 24 |
-
"example": {
|
| 25 |
-
"provider_notes": "Patient presents with acute bronchitis. Cough for 5 days, productive with yellow sputum. Lung exam reveals diffuse wheezing. Prescribed azithromycin 500mg."
|
| 26 |
-
}
|
| 27 |
-
}
|
| 28 |
-
|
| 29 |
-
class ProviderNote(BaseModel):
|
| 30 |
-
note: str
|
| 31 |
-
|
| 32 |
class CodingResponse(BaseModel):
|
| 33 |
icd_codes: List[ICDCode]
|
| 34 |
cpt_codes: List[CPTCode]
|
|
@@ -63,19 +45,4 @@ class FileUploadResponse(BaseModel):
|
|
| 63 |
pii_count: int
|
| 64 |
icd_codes: List[ICDCode]
|
| 65 |
cpt_codes: List[CPTCode]
|
| 66 |
-
overall_summary: str
|
| 67 |
-
|
| 68 |
-
class Config:
|
| 69 |
-
json_schema_extra = {
|
| 70 |
-
"example": {
|
| 71 |
-
"success": True,
|
| 72 |
-
"filename": "provider_notes.txt",
|
| 73 |
-
"extracted_text_length": 450,
|
| 74 |
-
"pii_removed": True,
|
| 75 |
-
"pii_count": 3,
|
| 76 |
-
"cpt_codes": ["99213", "93000"],
|
| 77 |
-
"cpt_explanation": "Office visit and EKG",
|
| 78 |
-
"icd_codes": ["I20.0", "R07.9"],
|
| 79 |
-
"icd_explanation": "Unstable angina and chest pain"
|
| 80 |
-
}
|
| 81 |
-
}
|
|
|
|
| 1 |
from pydantic import BaseModel
|
| 2 |
+
from typing import List
|
| 3 |
|
| 4 |
class ICDCode(BaseModel):
|
| 5 |
code: str
|
|
|
|
| 11 |
description: str
|
| 12 |
explanation: str
|
| 13 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
class CodingResponse(BaseModel):
|
| 15 |
icd_codes: List[ICDCode]
|
| 16 |
cpt_codes: List[CPTCode]
|
|
|
|
| 45 |
pii_count: int
|
| 46 |
icd_codes: List[ICDCode]
|
| 47 |
cpt_codes: List[CPTCode]
|
| 48 |
+
overall_summary: str
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|