Client for study-field corrections and multi-column extract

This commit is contained in:
Roberto Treviño
2026-11-27 01:45:16 -06:00
parent 0e4d838d44
commit 07212a2083
4 changed files with 40 additions and 13 deletions
+31 -10
View File
@@ -116,16 +116,27 @@
"type": "object"
},
"Correction": {
"description": "One field of one record as a reviewer read it in the source document: an identity\nfield (a mistyped record number) or a study's (a stage the scan made unreadable).",
"properties": {
"field": {
"entity": {
"default": "identity",
"enum": [
"record_number",
"full_name",
"curp",
"nss",
"birth_date",
"sex"
"identity",
"cervical_cytology",
"cervical_biopsy",
"mammography",
"breast_biopsy",
"breast_treatment",
"clinical_note",
"death",
"mchat",
"ados2",
"eeg"
],
"title": "Entity",
"type": "string"
},
"field": {
"title": "Field",
"type": "string"
},
@@ -160,8 +171,18 @@
"description": "Platform fields read from text, each kept with the text it was read from.\n\n`auto` asks the LLM when one is configured and answering, else applies `patterns`;\nwith neither, the row is held. Patterns are regexes with one group, per field (the\nLLM can propose them from sample documents); their values go through the ConceptMap\nand `formats` as in `map`.",
"properties": {
"column": {
"title": "Column",
"type": "string"
"anyOf": [
{
"type": "string"
},
{
"items": {
"type": "string"
},
"type": "array"
}
],
"title": "Column"
},
"concept_map": {
"anyOf": [
@@ -2442,7 +2463,7 @@
},
"/review/corrections": {
"post": {
"description": "A corrected identity field of one record (e.g. a mistyped record number); linking\nuses it on the next run. Fixing the source too is still worth it.",
"description": "A corrected field of one record; the next run uses it (linking for identity fields,\nthe study's target for the others). Fixing the source too is still worth it.",
"operationId": "correct",
"requestBody": {
"content": {