{"openapi":"3.1.0","info":{"title":"AI Novel Analyzer — v1 Platform API","version":"1.0.0"},"paths":{"/health":{"get":{"tags":["health","health"],"summary":"Health Basic","description":"Basic health summary.","operationId":"health_basic_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health/live":{"get":{"tags":["health","health"],"summary":"Health Live","description":"Process-alive check. No DB or external dependency probed.","operationId":"health_live_health_live_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health/ready":{"get":{"tags":["health","health"],"summary":"Health Ready","description":"Readiness check: verifies DB read/write and schema version.\n\nUses the same DB_FILE as the main app to confirm the database is reachable\nand the core schema (projects table) exists.","operationId":"health_ready_health_ready_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/capabilities":{"get":{"tags":["capabilities","capabilities"],"summary":"Get Capabilities","description":"Return the API version and which optional features are currently enabled.\n\nClients should check feature flags before using advanced endpoints\n(e.g. result_sets will become true in Task 11).","operationId":"get_capabilities_capabilities_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/clients/pairing-codes":{"post":{"tags":["clients","clients"],"summary":"Create Pairing Code Route","description":"Generate a one-time pairing code.\n\nBootstrap rule: if no clients exist and the request comes from loopback,\nno authentication is required. Otherwise the caller must present a valid\ntoken with the ``admin`` scope.","operationId":"create_pairing_code_route_clients_pairing_codes_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/clients/pair":{"post":{"tags":["clients","clients"],"summary":"Pair Client Route","description":"Exchange a pairing code for a bearer token.\n\nmode=external -> token returned in response body\nmode=browser -> token set as HttpOnly SameSite=Strict cookie","operationId":"pair_client_route_clients_pair_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/clients":{"get":{"tags":["clients","clients"],"summary":"List Clients Route","description":"List all non-revoked clients. Requires admin scope.","operationId":"list_clients_route_clients_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/clients/{client_id}":{"delete":{"tags":["clients","clients"],"summary":"Delete Client Route","description":"Revoke and delete a client. Requires admin scope.","operationId":"delete_client_route_clients__client_id__delete","parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects":{"get":{"tags":["projects","projects"],"summary":"List Projects","operationId":"list_projects_projects_get","parameters":[{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":50,"title":"Limit"}},{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Archived"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["projects","projects"],"summary":"Create Project","operationId":"create_project_projects_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}":{"get":{"tags":["projects","projects"],"summary":"Get Project","operationId":"get_project_projects__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["projects","projects"],"summary":"Update Project","operationId":"update_project_projects__project_id__patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["projects","projects"],"summary":"Delete Project","description":"Soft-archive: sets archived_at, bumps revision.\nDoes NOT physically delete source_versions, nodes, edges, or project_text.","operationId":"delete_project_projects__project_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources":{"post":{"tags":["sources-v1","sources-v1"],"summary":"Create Source","operationId":"create_source_sources_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SourceCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SourceOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["sources-v1","sources-v1"],"summary":"List Sources","operationId":"list_sources_sources_get","parameters":[{"name":"project_id","in":"query","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{},"title":"Response List Sources Sources Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources/{source_id}":{"get":{"tags":["sources-v1","sources-v1"],"summary":"Get Source","operationId":"get_source_sources__source_id__get","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SourceOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources/{source_id}/versions":{"post":{"tags":["sources-v1","sources-v1"],"summary":"Create Version","operationId":"create_version_sources__source_id__versions_post","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["sources-v1","sources-v1"],"summary":"List Versions","operationId":"list_versions_sources__source_id__versions_get","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{},"title":"Response List Versions Sources Source Id Versions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources/{source_id}/versions/{version_id}":{"get":{"tags":["sources-v1","sources-v1"],"summary":"Get Version","operationId":"get_version_sources__source_id__versions__version_id__get","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","title":"Version Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VersionOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources/{source_id}/versions/{version_id}/content":{"get":{"tags":["sources-v1","sources-v1"],"summary":"Get Content","operationId":"get_content_sources__source_id__versions__version_id__content_get","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","title":"Version Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContentOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources/{source_id}/versions/{version_id}/chapter-detection":{"post":{"tags":["sources-v1","sources-v1"],"summary":"Run Chapter Detection","operationId":"run_chapter_detection_sources__source_id__versions__version_id__chapter_detection_post","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","title":"Version Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChapterDetectRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChapterDetectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sources/{source_id}/versions/{version_id}/boundaries":{"post":{"tags":["sources-v1","sources-v1"],"summary":"Create Manual Boundaries","operationId":"create_manual_boundaries_sources__source_id__versions__version_id__boundaries_post","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","title":"Version Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManualBoundarySetCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BoundarySetOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["sources-v1","sources-v1"],"summary":"List Boundary Sets","operationId":"list_boundary_sets_sources__source_id__versions__version_id__boundaries_get","parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string","title":"Source Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","title":"Version Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{},"title":"Response List Boundary Sets Sources Source Id Versions Version Id Boundaries Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/chapters/{project_id}":{"get":{"tags":["chapters-v1","chapters-v1"],"summary":"Get Project Chapters","description":"Get chapter boundaries for a project.\n\nReads from latest source version boundaries; falls back to project_text detection.","operationId":"get_project_chapters_chapters__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs":{"post":{"tags":["jobs"],"summary":"Submit Job","operationId":"submit_job_analysis_jobs_post","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["jobs"],"summary":"List Jobs","operationId":"list_jobs_analysis_jobs_get","parameters":[{"name":"profile","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Profile"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/JobResponse"},"title":"Response List Jobs Analysis Jobs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs/{job_id}":{"get":{"tags":["jobs"],"summary":"Get Job","operationId":"get_job_analysis_jobs__job_id__get","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs/{job_id}/result":{"get":{"tags":["jobs"],"summary":"Get Job Result","operationId":"get_job_result_analysis_jobs__job_id__result_get","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResultResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs/{job_id}/pause":{"post":{"tags":["jobs"],"summary":"Pause Job","operationId":"pause_job_analysis_jobs__job_id__pause_post","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobPauseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs/{job_id}/resume":{"post":{"tags":["jobs"],"summary":"Resume Job","operationId":"resume_job_analysis_jobs__job_id__resume_post","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResumeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs/{job_id}/cancel":{"post":{"tags":["jobs"],"summary":"Cancel Job","operationId":"cancel_job_analysis_jobs__job_id__cancel_post","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobCancelRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/analysis-jobs/{job_id}/retry":{"post":{"tags":["jobs"],"summary":"Retry Job","operationId":"retry_job_analysis_jobs__job_id__retry_post","parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/result-sets":{"get":{"tags":["results"],"summary":"List Result Sets","description":"List all result sets for a project, newest version first.","operationId":"list_result_sets_result_sets_get","parameters":[{"name":"project_id","in":"query","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ResultSetSummary"},"title":"Response List Result Sets Result Sets Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/result-sets/{result_set_id}":{"get":{"tags":["results"],"summary":"Get Result Set","description":"Get a single result set by ID.","operationId":"get_result_set_result_sets__result_set_id__get","parameters":[{"name":"result_set_id","in":"path","required":true,"schema":{"type":"string","title":"Result Set Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResultSetDetail"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/result-sets/{result_set_id}/entities":{"get":{"tags":["results"],"summary":"List Entities","description":"Paginated list of entities within a result set.\n\nCursor encodes result_set_id + sort key (entity_key) + primary key.","operationId":"list_entities_result_sets__result_set_id__entities_get","parameters":[{"name":"result_set_id","in":"path","required":true,"schema":{"type":"string","title":"Result Set Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/result-sets/{result_set_id}/relationships":{"get":{"tags":["results"],"summary":"List Relationships","description":"Paginated list of relationships with occurrences and occurrence_count.","operationId":"list_relationships_result_sets__result_set_id__relationships_get","parameters":[{"name":"result_set_id","in":"path","required":true,"schema":{"type":"string","title":"Result Set Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":50,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/result-sets/{result_set_id}/evidence":{"get":{"tags":["results"],"summary":"List Evidence","description":"Paginated list of evidence spans.\n\nFilters:\n - granularity: exact, chapter_only, inferred (or chunk)\n - subject_type: entity, relationship","operationId":"list_evidence_result_sets__result_set_id__evidence_get","parameters":[{"name":"result_set_id","in":"path","required":true,"schema":{"type":"string","title":"Result Set Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":50,"title":"Limit"}},{"name":"granularity","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Granularity"}},{"name":"subject_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject Type"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/result-sets/{result_set_id}/graph":{"get":{"tags":["results"],"summary":"Get Graph","description":"Graph view: nodes + edges for visualization.\n\nDefault max 20,000 edges. If exceeded, returns 422 GRAPH_TOO_LARGE\nwith a pagination cursor for fetching the next batch.","operationId":"get_graph_result_sets__result_set_id__graph_get","parameters":[{"name":"result_set_id","in":"path","required":true,"schema":{"type":"string","title":"Result Set Id"}},{"name":"max_edges","in":"query","required":false,"schema":{"type":"integer","maximum":100000,"minimum":1,"default":20000,"title":"Max Edges"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/aliases":{"get":{"tags":["aliases"],"summary":"List Aliases Route","description":"List active alias rules for a project.\n\nIf include_legacy=true, also reads from the legacy node_aliases table.","operationId":"list_aliases_route_projects__project_id__aliases_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"include_legacy","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Legacy"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["aliases"],"summary":"Create Alias Route","description":"Create a new alias rule.\n\nValidation:\n - alias != canonical\n - both non-empty\n - unique per project (active)","operationId":"create_alias_route_projects__project_id__aliases_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AliasCreateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/projects/{project_id}/aliases/{alias_id}":{"delete":{"tags":["aliases"],"summary":"Delete Alias Route","description":"Archive (soft-delete) an alias rule.\n\nWrites an audit event to the event log.","operationId":"delete_alias_route_projects__project_id__aliases__alias_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"alias_id","in":"path","required":true,"schema":{"type":"string","title":"Alias Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/events":{"get":{"tags":["events"],"summary":"List Events","description":"Return paginated events. Query params: project_id, after (cursor), limit.","operationId":"list_events_events_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"}},{"name":"after","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"After"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/events/stream":{"get":{"tags":["events"],"summary":"Stream Events","description":"SSE endpoint.\n\nReconnect behaviour: pass ``Last-Event-ID`` header to resume from\nthat cursor. Without the header the stream starts from the latest\nevent (only future events are delivered).","operationId":"stream_events_events_stream_get","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/models":{"get":{"tags":["models","models-v1"],"summary":"List Models","operationId":"list_models_models_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["models","models-v1"],"summary":"Create Model","operationId":"create_model_models_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/models/{model_id}":{"get":{"tags":["models","models-v1"],"summary":"Get Model","operationId":"get_model_models__model_id__get","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["models","models-v1"],"summary":"Update Model","operationId":"update_model_models__model_id__patch","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["models","models-v1"],"summary":"Delete Model","operationId":"delete_model_models__model_id__delete","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/models/{model_id}:test":{"post":{"tags":["models","models-v1"],"summary":"Test Model","operationId":"test_model_models__model_id__test_post","parameters":[{"name":"model_id","in":"path","required":true,"schema":{"type":"string","title":"Model Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/uploads":{"post":{"tags":["transfers","transfers"],"summary":"Create Upload","description":"Create a new upload session backed by a temp file.","operationId":"create_upload_uploads_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadCreateIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/uploads/{upload_id}":{"patch":{"tags":["transfers","transfers"],"summary":"Patch Upload","description":"Append a chunk using ``Upload-Offset`` header.\n\nUses ``request.stream()`` so the body is never fully buffered in memory.","operationId":"patch_upload_uploads__upload_id__patch","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/uploads/{upload_id}/complete":{"post":{"tags":["transfers","transfers"],"summary":"Complete Upload","description":"Verify bytes + SHA-256 and finalize the upload.","operationId":"complete_upload_uploads__upload_id__complete_post","parameters":[{"name":"upload_id","in":"path","required":true,"schema":{"type":"string","title":"Upload Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadCompleteIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/export-jobs":{"post":{"tags":["transfers","transfers"],"summary":"Create Export Job","description":"Create an async export job.","operationId":"create_export_job_export_jobs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExportJobIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/import-jobs":{"post":{"tags":["transfers","transfers"],"summary":"Create Import Job","description":"Create an async import job from a completed upload.","operationId":"create_import_job_import_jobs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportJobIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/import-jobs-with-path":{"post":{"tags":["transfers","transfers"],"summary":"Create Import Job With Path","description":"Create an async import job given an explicit tmp_path.\n\nThis is the integration endpoint used after complete_upload returns\na tmp_path. ``body`` must contain ``upload_id`` and ``tmp_path``.","operationId":"create_import_job_with_path_import_jobs_with_path_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Body"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/admin/live":{"get":{"tags":["maintenance","maintenance"],"summary":"Live","description":"Liveness probe -- always 200.","operationId":"live_admin_live_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/admin/ready":{"get":{"tags":["maintenance","maintenance"],"summary":"Ready","description":"Readiness probe -- 503 during maintenance.","operationId":"ready_admin_ready_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/backup-jobs":{"post":{"tags":["maintenance","maintenance"],"summary":"Create Backup Job","description":"Create an async backup job.","operationId":"create_backup_job_backup_jobs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupJobIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/restore-jobs":{"post":{"tags":["maintenance","maintenance"],"summary":"Create Restore Job","description":"Create an async restore job. Admin-only.","operationId":"create_restore_job_restore_jobs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreJobIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/maintenance-jobs":{"post":{"tags":["maintenance","maintenance"],"summary":"Create Maintenance Job","description":"Create a purge maintenance job. Admin-only.","operationId":"create_maintenance_job_maintenance_jobs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MaintenanceJobIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"AliasCreateRequest":{"properties":{"alias":{"type":"string","maxLength":500,"minLength":1,"title":"Alias"},"canonical":{"type":"string","maxLength":500,"minLength":1,"title":"Canonical"}},"type":"object","required":["alias","canonical"],"title":"AliasCreateRequest"},"BackupJobIn":{"properties":{"backup_dir":{"type":"string","maxLength":1000,"title":"Backup Dir","default":""}},"type":"object","title":"BackupJobIn"},"BoundarySetOut":{"properties":{"id":{"type":"string","title":"Id"},"source_version_id":{"type":"string","title":"Source Version Id"},"detector_version":{"type":"string","title":"Detector Version"},"manual":{"type":"boolean","title":"Manual"},"boundaries":{"items":{"$ref":"#/components/schemas/ChapterBoundaryOut"},"type":"array","title":"Boundaries"},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["id","source_version_id","detector_version","manual","boundaries","created_at"],"title":"BoundarySetOut"},"ChapterBoundaryOut":{"properties":{"chapter":{"type":"string","title":"Chapter"},"start_offset":{"type":"integer","title":"Start Offset"},"end_offset":{"type":"integer","title":"End Offset"}},"type":"object","required":["chapter","start_offset","end_offset"],"title":"ChapterBoundaryOut"},"ChapterDetectRequest":{"properties":{"detector_version":{"type":"string","maxLength":50,"title":"Detector Version","default":"v1"}},"type":"object","title":"ChapterDetectRequest","description":"POST /api/v1/sources/{source_id}/versions/{version_id}/chapter-detection body."},"ChapterDetectResponse":{"properties":{"boundary_set_id":{"type":"string","title":"Boundary Set Id"},"source_version_id":{"type":"string","title":"Source Version Id"},"detector_version":{"type":"string","title":"Detector Version"},"boundaries":{"items":{"$ref":"#/components/schemas/ChapterBoundaryOut"},"type":"array","title":"Boundaries"},"cached":{"type":"boolean","title":"Cached","default":false}},"type":"object","required":["boundary_set_id","source_version_id","detector_version","boundaries"],"title":"ChapterDetectResponse"},"ChunkDetail":{"properties":{"id":{"type":"string","title":"Id","default":""},"chunk_index":{"type":"integer","title":"Chunk Index","default":0},"status":{"type":"string","title":"Status","default":""},"retry_count":{"type":"integer","title":"Retry Count","default":0},"result":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","title":"ChunkDetail","description":"Per-chunk detail included in the result payload."},"ContentOut":{"properties":{"source_id":{"type":"string","title":"Source Id"},"version_id":{"type":"string","title":"Version Id"},"version_number":{"type":"integer","title":"Version Number"},"text":{"type":"string","title":"Text"},"content_hash":{"type":"string","title":"Content Hash"},"char_count":{"type":"integer","title":"Char Count"}},"type":"object","required":["source_id","version_id","version_number","text","content_hash","char_count"],"title":"ContentOut"},"ExportJobIn":{"properties":{"project_id":{"type":"string","maxLength":128,"minLength":1,"title":"Project Id"}},"type":"object","required":["project_id"],"title":"ExportJobIn"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ImportJobIn":{"properties":{"upload_id":{"type":"string","maxLength":128,"minLength":1,"title":"Upload Id"}},"type":"object","required":["upload_id"],"title":"ImportJobIn"},"JobCancelRequest":{"properties":{},"type":"object","title":"JobCancelRequest"},"JobCreateRequest":{"properties":{"source_version_ids":{"items":{"type":"string"},"type":"array","title":"Source Version Ids"},"profile":{"type":"string","maxLength":128,"minLength":1,"title":"Profile","default":"default"},"model_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Model Id"},"options":{"additionalProperties":true,"type":"object","title":"Options"},"external_ref":{"type":"string","maxLength":256,"title":"External Ref","default":""},"prompt_version":{"type":"string","maxLength":32,"title":"Prompt Version","default":"v1"}},"type":"object","title":"JobCreateRequest","description":"POST /analysis-jobs body. All mutable fields are frozen at submit time."},"JobPauseRequest":{"properties":{},"type":"object","title":"JobPauseRequest"},"JobResponse":{"properties":{"id":{"type":"string","title":"Id"},"source_version_ids":{"items":{"type":"string"},"type":"array","title":"Source Version Ids"},"profile":{"type":"string","title":"Profile","default":""},"model_id":{"type":"string","title":"Model Id","default":""},"input_hash":{"type":"string","title":"Input Hash","default":""},"status":{"type":"string","title":"Status","default":""},"worker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Id"},"lease_expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lease Expires At"},"options":{"additionalProperties":true,"type":"object","title":"Options"},"external_ref":{"type":"string","title":"External Ref","default":""},"prompt_version":{"type":"string","title":"Prompt Version","default":"v1"},"total_chunks":{"type":"integer","title":"Total Chunks","default":0},"succeeded_chunks":{"type":"integer","title":"Succeeded Chunks","default":0},"failed_chunks":{"type":"integer","title":"Failed Chunks","default":0},"error_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Summary"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"started_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Started At"},"finished_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Finished At"}},"type":"object","required":["id"],"title":"JobResponse","description":"Full job representation returned by the API."},"JobResultResponse":{"properties":{"id":{"type":"string","title":"Id"},"source_version_ids":{"items":{"type":"string"},"type":"array","title":"Source Version Ids"},"profile":{"type":"string","title":"Profile","default":""},"model_id":{"type":"string","title":"Model Id","default":""},"input_hash":{"type":"string","title":"Input Hash","default":""},"status":{"type":"string","title":"Status","default":""},"worker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Id"},"lease_expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lease Expires At"},"options":{"additionalProperties":true,"type":"object","title":"Options"},"external_ref":{"type":"string","title":"External Ref","default":""},"prompt_version":{"type":"string","title":"Prompt Version","default":"v1"},"total_chunks":{"type":"integer","title":"Total Chunks","default":0},"succeeded_chunks":{"type":"integer","title":"Succeeded Chunks","default":0},"failed_chunks":{"type":"integer","title":"Failed Chunks","default":0},"error_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Summary"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"started_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Started At"},"finished_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Finished At"},"chunks":{"items":{"$ref":"#/components/schemas/ChunkDetail"},"type":"array","title":"Chunks"}},"type":"object","required":["id"],"title":"JobResultResponse","description":"GET /analysis-jobs/{id}/result adds chunk list."},"JobResumeRequest":{"properties":{},"type":"object","title":"JobResumeRequest"},"MaintenanceJobIn":{"properties":{"kind":{"type":"string","pattern":"^(purge)$","title":"Kind"},"project_id":{"type":"string","maxLength":128,"title":"Project Id","default":""},"revision":{"type":"string","maxLength":128,"title":"Revision","default":""},"confirmation_token":{"type":"string","maxLength":256,"title":"Confirmation Token","default":""}},"type":"object","required":["kind"],"title":"MaintenanceJobIn"},"ManualBoundaryIn":{"properties":{"chapter":{"type":"string","maxLength":200,"title":"Chapter"},"start_offset":{"type":"integer","minimum":0.0,"title":"Start Offset"},"end_offset":{"type":"integer","minimum":0.0,"title":"End Offset"}},"type":"object","required":["chapter","start_offset","end_offset"],"title":"ManualBoundaryIn"},"ManualBoundarySetCreate":{"properties":{"boundaries":{"items":{"$ref":"#/components/schemas/ManualBoundaryIn"},"type":"array","title":"Boundaries"}},"type":"object","required":["boundaries"],"title":"ManualBoundarySetCreate","description":"POST /api/v1/sources/{source_id}/versions/{version_id}/boundaries body."},"ModelCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name"},"protocol":{"type":"string","maxLength":32,"title":"Protocol"},"api_key":{"type":"string","maxLength":512,"minLength":1,"title":"Api Key"},"base_url":{"type":"string","maxLength":512,"title":"Base Url"},"model_id":{"type":"string","maxLength":200,"title":"Model Id"},"is_default":{"type":"boolean","title":"Is Default","default":false}},"type":"object","required":["name","protocol","api_key","base_url","model_id"],"title":"ModelCreate"},"ModelUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Name"},"protocol":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Protocol"},"api_key":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Api Key"},"base_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Base Url"},"model_id":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Model Id"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default"}},"type":"object","title":"ModelUpdate"},"PaginatedResponse":{"properties":{"items":{"items":{},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"},"has_more":{"type":"boolean","title":"Has More","default":false}},"type":"object","title":"PaginatedResponse"},"ProjectCreate":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"description":{"type":"string","maxLength":2000,"title":"Description","default":""},"external_ref":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"External Ref"}},"type":"object","required":["name"],"title":"ProjectCreate","description":"POST /api/v1/projects body.\n\nexternal_ref: optional idempotency key; when provided, duplicate creates\nreturn the existing project instead of 409."},"ProjectListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ProjectOut"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"},"has_more":{"type":"boolean","title":"Has More","default":false}},"type":"object","title":"ProjectListResponse","description":"Paginated project list with cursor."},"ProjectOut":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description","default":""},"external_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Ref"},"revision":{"type":"integer","title":"Revision","default":0},"archived_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archived At"},"created_at":{"type":"string","title":"Created At","default":""},"updated_at":{"type":"string","title":"Updated At","default":""}},"type":"object","required":["id","name"],"title":"ProjectOut","description":"Single project representation returned by the API."},"ProjectUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"revision":{"type":"integer","minimum":0.0,"title":"Revision"}},"type":"object","required":["revision"],"title":"ProjectUpdate","description":"PATCH /api/v1/projects/{project_id} body.\n\nrevision: required optimistic-lock token; must match current row value.\nOn success revision is incremented by 1."},"RestoreJobIn":{"properties":{"backup_path":{"type":"string","maxLength":1000,"minLength":1,"title":"Backup Path"}},"type":"object","required":["backup_path"],"title":"RestoreJobIn"},"ResultSetDetail":{"properties":{"id":{"type":"string","title":"Id"},"project_id":{"type":"string","title":"Project Id"},"job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Id"},"version_no":{"type":"integer","title":"Version No"},"origin":{"type":"string","title":"Origin","default":"analysis"},"profile":{"type":"string","title":"Profile","default":"default"},"model_id":{"type":"string","title":"Model Id","default":""},"created_at":{"type":"string","title":"Created At","default":""},"input_hash":{"type":"string","title":"Input Hash","default":""},"prompt_version":{"type":"string","title":"Prompt Version","default":""},"coverage":{"additionalProperties":true,"type":"object","title":"Coverage"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","required":["id","project_id","version_no"],"title":"ResultSetDetail"},"ResultSetSummary":{"properties":{"id":{"type":"string","title":"Id"},"project_id":{"type":"string","title":"Project Id"},"job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Id"},"version_no":{"type":"integer","title":"Version No"},"origin":{"type":"string","title":"Origin","default":"analysis"},"profile":{"type":"string","title":"Profile","default":"default"},"model_id":{"type":"string","title":"Model Id","default":""},"created_at":{"type":"string","title":"Created At","default":""}},"type":"object","required":["id","project_id","version_no"],"title":"ResultSetSummary"},"SourceCreate":{"properties":{"project_id":{"type":"string","maxLength":128,"minLength":1,"title":"Project Id"},"name":{"type":"string","maxLength":500,"title":"Name","default":"untitled"}},"type":"object","required":["project_id"],"title":"SourceCreate","description":"POST /api/v1/sources body."},"SourceOut":{"properties":{"id":{"type":"string","title":"Id"},"project_id":{"type":"string","title":"Project Id"},"name":{"type":"string","title":"Name"},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["id","project_id","name","created_at"],"title":"SourceOut"},"UploadCompleteIn":{"properties":{"expected_sha256":{"type":"string","maxLength":64,"title":"Expected Sha256","default":""}},"type":"object","title":"UploadCompleteIn"},"UploadCreateIn":{"properties":{"expected_size":{"type":"integer","minimum":0.0,"title":"Expected Size","default":0},"filename":{"type":"string","maxLength":500,"title":"Filename","default":""}},"type":"object","title":"UploadCreateIn"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"VersionCreate":{"properties":{"text":{"type":"string","maxLength":20971520,"minLength":1,"title":"Text"},"external_revision_id":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"External Revision Id"}},"type":"object","required":["text"],"title":"VersionCreate","description":"POST /api/v1/sources/{source_id}/versions body."},"VersionOut":{"properties":{"id":{"type":"string","title":"Id"},"source_id":{"type":"string","title":"Source Id"},"version_number":{"type":"integer","title":"Version Number"},"content_hash":{"type":"string","title":"Content Hash"},"char_count":{"type":"integer","title":"Char Count"},"external_revision_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Revision Id"},"deduplicated":{"type":"boolean","title":"Deduplicated","default":false},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["id","source_id","version_number","content_hash","char_count","created_at"],"title":"VersionOut"}}}}