{"openapi":"3.1.0","info":{"title":"Doctor How + Ghost Fossil - Unified Intelligence Hub","description":"Unified hub for catalog, media playback, FTS5 query/relatedness, A/V processing, and file intelligence","version":"2.1.0"},"paths":{"/media/{file_path}":{"get":{"summary":"Serve Media","description":"Serve media strictly within active workspace MEDIA_DIR or workspace S3 prefix.","operationId":"serve_media_media__file_path__get","parameters":[{"name":"file_path","in":"path","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"head":{"summary":"Serve Media","description":"Serve media strictly within active workspace MEDIA_DIR or workspace S3 prefix.","operationId":"serve_media_media__file_path__get","parameters":[{"name":"file_path","in":"path","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/cgi-bin/voice_cast_cgi":{"get":{"summary":"Voice Cast Cgi","description":"Serve pre-rendered 48kHz Siri studio .m4a voice clips on exact hash match or cast JSON.","operationId":"voice_cast_cgi_cgi_bin_voice_cast_cgi_get","parameters":[{"name":"voice","in":"query","required":false,"schema":{"type":"string","default":"Siri_Aaron","title":"Voice"}},{"name":"text","in":"query","required":false,"schema":{"type":"string","default":"","title":"Text"}},{"name":"v","in":"query","required":false,"schema":{"type":"string","default":"48k","title":"V"}},{"name":"action","in":"query","required":false,"schema":{"type":"string","default":"","title":"Action"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","default":"","title":"Format"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"head":{"summary":"Voice Cast Cgi","description":"Serve pre-rendered 48kHz Siri studio .m4a voice clips on exact hash match or cast JSON.","operationId":"voice_cast_cgi_cgi_bin_voice_cast_cgi_get","parameters":[{"name":"voice","in":"query","required":false,"schema":{"type":"string","default":"Siri_Aaron","title":"Voice"}},{"name":"text","in":"query","required":false,"schema":{"type":"string","default":"","title":"Text"}},{"name":"v","in":"query","required":false,"schema":{"type":"string","default":"48k","title":"V"}},{"name":"action","in":"query","required":false,"schema":{"type":"string","default":"","title":"Action"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","default":"","title":"Format"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/transcript/voice-cast":{"get":{"summary":"Voice Cast Cgi","description":"Serve pre-rendered 48kHz Siri studio .m4a voice clips on exact hash match or cast JSON.","operationId":"voice_cast_cgi_api_transcript_voice_cast_get","parameters":[{"name":"voice","in":"query","required":false,"schema":{"type":"string","default":"Siri_Aaron","title":"Voice"}},{"name":"text","in":"query","required":false,"schema":{"type":"string","default":"","title":"Text"}},{"name":"v","in":"query","required":false,"schema":{"type":"string","default":"48k","title":"V"}},{"name":"action","in":"query","required":false,"schema":{"type":"string","default":"","title":"Action"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","default":"","title":"Format"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"head":{"summary":"Voice Cast Cgi","description":"Serve pre-rendered 48kHz Siri studio .m4a voice clips on exact hash match or cast JSON.","operationId":"voice_cast_cgi_api_transcript_voice_cast_get","parameters":[{"name":"voice","in":"query","required":false,"schema":{"type":"string","default":"Siri_Aaron","title":"Voice"}},{"name":"text","in":"query","required":false,"schema":{"type":"string","default":"","title":"Text"}},{"name":"v","in":"query","required":false,"schema":{"type":"string","default":"48k","title":"V"}},{"name":"action","in":"query","required":false,"schema":{"type":"string","default":"","title":"Action"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","default":"","title":"Format"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/permit/panel":{"get":{"summary":"Serve Panel","description":"Serve the permit panel UI","operationId":"serve_panel_permit_panel_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/tree/{permit_id}":{"get":{"summary":"Get Permit Tree","description":"Get complete permit tree (recursive)","operationId":"get_permit_tree_permit_api_tree__permit_id__get","parameters":[{"name":"permit_id","in":"path","required":true,"schema":{"type":"string","title":"Permit Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/permit/api/create":{"post":{"summary":"Create Permit","description":"Create new permit from template or blank","operationId":"create_permit_permit_api_create_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/update":{"post":{"summary":"Update Node","description":"Update any node value/status","operationId":"update_node_permit_api_update_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/add-child":{"post":{"summary":"Add Child","description":"Add child node to parent","operationId":"add_child_permit_api_add_child_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/templates":{"get":{"summary":"Get Templates","description":"List available templates","operationId":"get_templates_permit_api_templates_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/permits":{"get":{"summary":"Get Permits","description":"List all permits (non-templates)","operationId":"get_permits_permit_api_permits_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/generate-key":{"post":{"summary":"Generate Permit Key","description":"Generate a short-term permit key for debug/triage operations.\n\nRequest body:\n    permission_group: str (e.g., \"debug\", \"triage\", \"admin\")\n    max_uses: int (default 3)\n    expires_minutes: int (default 25)\n    granted_by: str (e.g., \"system\" or admin party_id)\n\nReturns:\n    key: str (the permit key hash)\n    expires_at: str (ISO timestamp)\n    max_uses: int\n    permission_group: str","operationId":"generate_permit_key_permit_api_generate_key_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/validate-key":{"post":{"summary":"Validate Permit Key","description":"Validate a permit key and optionally consume a use.\n\nRequest body:\n    key: str (permit hash)\n    consume: bool (if True, decrements remaining uses)\n\nReturns:\n    valid: bool\n    remaining_uses: int (if applicable)\n    expires_at: str (if valid)\n    permission_group: str (if valid)\n    error: str (if invalid)","operationId":"validate_permit_key_permit_api_validate_key_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/permit/api/check/{permission_group}/{party_id}":{"get":{"summary":"Check Permit Api","description":"Simple permit check endpoint.\n\nReturns:\n    has_permit: bool\n    permission_group: str\n    party_id: str","operationId":"check_permit_api_permit_api_check__permission_group___party_id__get","parameters":[{"name":"permission_group","in":"path","required":true,"schema":{"type":"string","title":"Permission Group"}},{"name":"party_id","in":"path","required":true,"schema":{"type":"string","title":"Party Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/catalog":{"get":{"summary":"Catalog","description":"Serve the catalog UI with timeline filtering","operationId":"catalog_catalog_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/catalog/items":{"get":{"summary":"Catalog Items","description":"Returns catalog items as JSON for the modern UI\nSupports filtering by date range and categories","operationId":"catalog_items_catalog_items_get","parameters":[{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End Date"}},{"name":"categories","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Categories"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/catalog/items/{id}":{"get":{"summary":"Catalog Item Data","description":"Returns JSON data for a single catalog item.","operationId":"catalog_item_data_catalog_items__id__get","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","title":"Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/catalog/timeline":{"get":{"summary":"Catalog Timeline","operationId":"catalog_timeline_catalog_timeline_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/catalog/bridge":{"get":{"summary":"Catalog Bridge","operationId":"catalog_bridge_catalog_bridge_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/catalog/anniversary":{"get":{"summary":"Catalog Anniversary","operationId":"catalog_anniversary_catalog_anniversary_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/catalog/timeline-stats":{"get":{"summary":"Catalog Timeline Stats","description":"Get timeline statistics for catalog visualization","operationId":"catalog_timeline_stats_catalog_timeline_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/catalog/flag":{"post":{"summary":"Catalog Flag","description":"Create or update a flag for a catalog item","operationId":"catalog_flag_catalog_flag_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FlagRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/catalog/flag/{concrete_id}":{"delete":{"summary":"Catalog Unflag","description":"Remove flag from a catalog item","operationId":"catalog_unflag_catalog_flag__concrete_id__delete","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/catalog/timeline":{"get":{"summary":"Get Timeline Data","description":"Get catalog timeline data for audio/video records","operationId":"get_timeline_data_api_catalog_timeline_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/catalog/items/{item_id}":{"put":{"summary":"Update Catalog Item","description":"Update catalog item metadata","operationId":"update_catalog_item_catalog_items__item_id__put","parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"integer","title":"Item Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/catalog/items/{item_id}/annotations":{"get":{"summary":"Get Catalog Item Annotations","description":"Return active ANNOTATION rows linked to this concrete item's merged_record.","operationId":"get_catalog_item_annotations_api_catalog_items__item_id__annotations_get","parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"integer","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/catalog/items/{item_id}/relationships":{"get":{"summary":"Get Catalog Item Relationships","description":"Compute cross-source relatedness via shared FTS tokens and annotations in how.db.","operationId":"get_catalog_item_relationships_api_catalog_items__item_id__relationships_get","parameters":[{"name":"item_id","in":"path","required":true,"schema":{"type":"integer","title":"Item Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript":{"get":{"summary":"Serve Latest Panel","description":"Redirect /transcript to the latest playable/transcribed concrete item (fallback 245122).","operationId":"serve_latest_panel_transcript_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/transcript/{concrete_id}":{"get":{"summary":"Serve Panel","description":"Serve static HTML - let frontend handle the rest","operationId":"serve_panel_transcript__concrete_id__get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/api/data/{concrete_id}":{"get":{"summary":"Get Transcript Data","description":"Get segments - simple query, trust the schema","operationId":"get_transcript_data_transcript_api_data__concrete_id__get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/update-field":{"post":{"summary":"Update Field","description":"Generic field update - trust database, use content_history for edits","operationId":"update_field_transcript_update_field_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/transcript/assign-party":{"post":{"summary":"Assign Party","description":"Assign speaker to segment","operationId":"assign_party_transcript_assign_party_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/transcript/sidecar/{file_hash}":{"get":{"summary":"Serve Sidecar Panel","description":"Serve the same panel.html for sidecar transcripts","operationId":"serve_sidecar_panel_transcript_sidecar__file_hash__get","parameters":[{"name":"file_hash","in":"path","required":true,"schema":{"type":"string","title":"File Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/api/sidecar/{file_hash}":{"get":{"summary":"Get Sidecar Transcript Data","description":"Get transcript data from sidecar database.\nReturns same format as /transcript/api/data/{concrete_id} for panel.js compatibility.","operationId":"get_sidecar_transcript_data_transcript_api_sidecar__file_hash__get","parameters":[{"name":"file_hash","in":"path","required":true,"schema":{"type":"string","title":"File Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/api/field":{"post":{"summary":"Save Field","operationId":"save_field_transcript_api_field_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/transcript/api/history/{concrete_id}":{"get":{"summary":"History Route","operationId":"history_route_transcript_api_history__concrete_id__get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/api/events":{"get":{"summary":"Events Route","operationId":"events_route_transcript_api_events_get","parameters":[{"name":"id","in":"query","required":false,"schema":{"type":"integer","title":"Id"}},{"name":"parent","in":"query","required":false,"schema":{"type":"integer","title":"Parent"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","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"}}}}}}},"/transcript/{concrete_id}/epoch":{"get":{"summary":"Epoch Page","operationId":"epoch_page_transcript__concrete_id__epoch_get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/api/epoch/{concrete_id}":{"get":{"summary":"Epoch Data","operationId":"epoch_data_transcript_api_epoch__concrete_id__get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/process-ml":{"post":{"summary":"Process Ml","description":"Classify one segment (the original Flask/FastAPI route, same name). Takes the text the\npage has (after an edit) or reads the current text; writes the ml columns; returns the\nlabels, the scores and the rendered score tables for the page to drop in.","operationId":"process_ml_transcript_process_ml_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/transcript/api/epoch/{concrete_id}/classify":{"post":{"summary":"Classify Recording","description":"Classify every segment of the recording that has no scores yet (?all=1 redoes all).","operationId":"classify_recording_transcript_api_epoch__concrete_id__classify_post","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/transcript/epoch/notes":{"post":{"summary":"Save Notes","operationId":"save_notes_transcript_epoch_notes_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/annotation":{"post":{"summary":"Create Annotation","description":"Create a new annotation","operationId":"create_annotation_api_annotation_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/annotation/{source_table}/{source_id}":{"get":{"summary":"Get Annotations","description":"Get all annotations for a source","operationId":"get_annotations_api_annotation__source_table___source_id__get","parameters":[{"name":"source_table","in":"path","required":true,"schema":{"type":"string","title":"Source Table"}},{"name":"source_id","in":"path","required":true,"schema":{"type":"integer","title":"Source Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/annotation/merged_records/{merged_record_id}":{"get":{"summary":"Get Merged Record Annotations","description":"Get annotations for a merged record (convenience endpoint)","operationId":"get_merged_record_annotations_api_annotation_merged_records__merged_record_id__get","parameters":[{"name":"merged_record_id","in":"path","required":true,"schema":{"type":"integer","title":"Merged Record Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/annotation/{annotation_id}":{"put":{"summary":"Update Annotation","description":"DISABLED: Annotations are append-only/immutable\n\nTo modify an annotation, create a new one instead.\nThis endpoint is disabled to enforce immutable design.","operationId":"update_annotation_api_annotation__annotation_id__put","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"integer","title":"Annotation Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"summary":"Delete Annotation","description":"Soft delete an annotation","operationId":"delete_annotation_api_annotation__annotation_id__delete","parameters":[{"name":"annotation_id","in":"path","required":true,"schema":{"type":"integer","title":"Annotation Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/transcript/annotation":{"post":{"summary":"Create Transcript Annotation","description":"Create annotation for transcript segment (convenience endpoint)","operationId":"create_transcript_annotation_api_transcript_annotation_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/transcript/annotation/{concrete_id}":{"get":{"summary":"Get Transcript Annotation","description":"Get annotation for transcript segment (convenience endpoint)","operationId":"get_transcript_annotation_api_transcript_annotation__concrete_id__get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/upload":{"get":{"summary":"Upload Page","description":"Serve the upload panel","operationId":"upload_page_upload_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"summary":"Unified Upload","description":"Unified scoped file upload - auto-detects file type and routes to workspace storage.\nEnforces `ties_scope` authentication (`upload_scoped`).","operationId":"unified_upload_upload_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_unified_upload_upload_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/transformer/upload":{"post":{"summary":"Upload","description":"Upload and process audio/video files via pipeline.\nRequires authenticated `ties_scope` token (`upload_scoped`).","operationId":"upload_api_transformer_upload_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_api_transformer_upload_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/unified/upload":{"post":{"summary":"Unified Upload","description":"Unified scoped file upload - auto-detects file type and routes to workspace storage.\nEnforces `ties_scope` authentication (`upload_scoped`).","operationId":"unified_upload_api_unified_upload_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_unified_upload_api_unified_upload_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/presign-upload":{"post":{"summary":"Presign Upload","description":"Issue a workspace-scoped presigned S3 PUT URL for direct large uploads (>8 MB).","operationId":"presign_upload_api_presign_upload_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/ingest-s3":{"post":{"summary":"Ingest S3 Upload","description":"Ingest a file uploaded directly to workspace S3 via `/api/presign-upload`.","operationId":"ingest_s3_upload_api_ingest_s3_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/recording/{concrete_id}/companion":{"get":{"summary":"Get Recording Companion","description":"Return out-of-band companion metadata and ANNOTATION notes for a workspace item.","operationId":"get_recording_companion_api_recording__concrete_id__companion_get","parameters":[{"name":"concrete_id","in":"path","required":true,"schema":{"type":"integer","title":"Concrete Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/unified/upload-stream":{"post":{"summary":"Unified Upload Stream","description":"Stream PDF processing with Server-Sent Events.\n\nReturns SSE stream showing each pipeline stage in real-time:\n- FIDO hardware check\n- EXIFTOOL metadata read\n- DEEPSEEK extraction\n- PDFTK bookmarks\n- FIDELITY comparison\n- CLAUDE QA (if enabled)\n- TOKEN building\n- SIDECAR write\n- XMP enrichment\n\nUser can watch registers populate and confirm at key stages.","operationId":"unified_upload_stream_api_unified_upload_stream_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_unified_upload_stream_api_unified_upload_stream_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/unified/confirm/{action_id}":{"post":{"summary":"Confirm Action","description":"Confirm a pending action in the streaming pipeline.\n\nCalled when user reviews fidelity diffs, QA results, etc.","operationId":"confirm_action_api_unified_confirm__action_id__post","parameters":[{"name":"action_id","in":"path","required":true,"schema":{"type":"string","title":"Action Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/transformer/trigger-metadata":{"post":{"summary":"Trigger Metadata","description":"Trigger metadata extraction for all parent records","operationId":"trigger_metadata_api_transformer_trigger_metadata_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/transformer/catalog":{"get":{"summary":"Catalog","description":"List all uploaded media files","operationId":"catalog_api_transformer_catalog_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/transformer/cascading-update":{"post":{"summary":"Cascading Update","description":"Sync transcription edits through word → segment → fulltext hierarchy","operationId":"cascading_update_api_transformer_cascading_update_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/transformer/process-ml":{"post":{"summary":"Process Ml","description":"Run sentiment and emotion analysis on a single record\n\nExpects JSON: {\"id\": record_id, \"display_content\": text}\nReturns: ML analysis results","operationId":"process_ml_api_transformer_process_ml_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/transformer/analyze-text":{"post":{"summary":"Analyze Text","description":"Analyze arbitrary text without saving to database\n\nExpects JSON: {\"text\": \"some text to analyze\"}\nReturns: Sentiment and emotion analysis results","operationId":"analyze_text_api_transformer_analyze_text_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/category/":{"get":{"tags":["category"],"summary":"List Categories","description":"List all categories with usage counts","operationId":"list_categories_api_category__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"tags":["category"],"summary":"Create Category","description":"Create a new category","operationId":"create_category_api_category__post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/category/labels":{"get":{"tags":["category"],"summary":"Get Category Labels","description":"Get all category labels - for backward compatibility with panel.js","operationId":"get_category_labels_api_category_labels_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/category/assign":{"post":{"tags":["category"],"summary":"Assign Category","description":"Link a merged_record to a category (tag a segment). Re-assigning an unlinked pair clears its soft delete.","operationId":"assign_category_api_category_assign_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/category/remove":{"post":{"tags":["category"],"summary":"Remove Category","description":"Unlink a merged_record from a category (soft delete, the row stays as history).","operationId":"remove_category_api_category_remove_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/editor/block":{"post":{"tags":["Editor"],"summary":"Create Block","description":"Create a new block via register_block().\n\nAppend-only: to \"edit\", create new block with derives_from pointing to previous.\nTo \"delete\", create archive block with derivation_type='archives'.","operationId":"create_block_api_editor_block_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/block/{block_hash}":{"get":{"tags":["Editor"],"summary":"Get Block","description":"Get a single block by hash.","operationId":"get_block_api_editor_block__block_hash__get","parameters":[{"name":"block_hash","in":"path","required":true,"schema":{"type":"string","title":"Block Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/tree":{"get":{"tags":["Editor"],"summary":"Get Tree","description":"Get hierarchical tree of blocks.\n\nBuilds tree from blocks where space = parent block hash.","operationId":"get_tree_api_editor_tree_get","parameters":[{"name":"space","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Parent hash to filter by","title":"Space"},"description":"Parent hash to filter by"},{"name":"object_type","in":"query","required":false,"schema":{"type":"string","description":"Block type to filter","default":"DRAFT","title":"Object Type"},"description":"Block type to filter"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/citations":{"get":{"tags":["Editor"],"summary":"Get Citations","description":"Get recent citations.","operationId":"get_citations_api_editor_citations_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","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"}}}}}}},"/api/editor/crossrefs/{block_hash}":{"get":{"tags":["Editor"],"summary":"Get Crossrefs","description":"Get crossrefs (citation links) for a block.","operationId":"get_crossrefs_api_editor_crossrefs__block_hash__get","parameters":[{"name":"block_hash","in":"path","required":true,"schema":{"type":"string","title":"Block Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files":{"get":{"tags":["Editor"],"summary":"Get Files","description":"Get files from user_files VIEW.\n\nWired to Kalie's literature files for the files-panel.js component.","operationId":"get_files_api_editor_files_get","parameters":[{"name":"path_filter","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by path substring","title":"Path Filter"},"description":"Filter by path substring"},{"name":"type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by type (FILE or FOLDER)","title":"Type"},"description":"Filter by type (FILE or FOLDER)"},{"name":"parent","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by parent folder block hash","title":"Parent"},"description":"Filter by parent folder block hash"},{"name":"project","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by project tag, e.g. kalie_dissertation","title":"Project"},"description":"Filter by project tag, e.g. kalie_dissertation"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files/{block_hash}":{"get":{"tags":["Editor"],"summary":"Get File","description":"Get a single file by block hash.","operationId":"get_file_api_editor_files__block_hash__get","parameters":[{"name":"block_hash","in":"path","required":true,"schema":{"type":"string","title":"Block Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files/set-role":{"post":{"tags":["Editor"],"summary":"Set Role","operationId":"set_role_api_editor_files_set_role_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetRole"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files/rename":{"post":{"tags":["Editor"],"summary":"Rename File","description":"Give a file a human-readable name. Append-only: stored as a display_name annotation.","operationId":"rename_file_api_editor_files_rename_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RenameRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files/correct-timestamp":{"post":{"tags":["Editor"],"summary":"Correct Timestamp","description":"Correct the date shown for a file. Append-only: stored as a timestamp annotation.","operationId":"correct_timestamp_api_editor_files_correct_timestamp_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimestampCorrection"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files/set-space":{"post":{"tags":["Editor"],"summary":"Set Space","description":"Set where a file belongs (spacetime). Append-only: stored as a space annotation.","operationId":"set_space_api_editor_files_set_space_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetSpace"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/files/add":{"post":{"tags":["Editor"],"summary":"Add File","description":"Add a file to the project. Saved under the project folder and registered as a FILE block.","operationId":"add_file_api_editor_files_add_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_add_file_api_editor_files_add_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/annotations":{"post":{"tags":["Editor"],"summary":"Create Annotation","description":"Create annotation on a file block. Uses SOP: sop_annotation_handling","operationId":"create_annotation_api_editor_annotations_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationCreate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/annotations/{block_hash}":{"get":{"tags":["Editor"],"summary":"Get File Annotations","description":"Get all annotations for a file block.","operationId":"get_file_annotations_api_editor_annotations__block_hash__get","parameters":[{"name":"block_hash","in":"path","required":true,"schema":{"type":"string","title":"Block Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/permits":{"get":{"tags":["Editor"],"summary":"Get Permits","description":"Signers for annotations - from the register (active permits + admins).","operationId":"get_permits_api_editor_permits_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/editor/projects":{"get":{"tags":["Editor"],"summary":"Get Projects","description":"Distinct project tags present in the register.","operationId":"get_projects_api_editor_projects_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/editor/sop/progress/{owner}":{"get":{"tags":["Editor"],"summary":"Get Sop Progress","description":"Get SOP checklist progress from v_sop_progress view.","operationId":"get_sop_progress_api_editor_sop_progress__owner__get","parameters":[{"name":"owner","in":"path","required":true,"schema":{"type":"string","title":"Owner"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/sop/step-status":{"post":{"tags":["Editor"],"summary":"Update Step Status","description":"Update SOP step status.","operationId":"update_step_status_api_editor_sop_step_status_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StepStatusUpdate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/editor/query":{"get":{"tags":["Editor"],"summary":"Query Register","description":"Execute read-only query on register (for dashboard).","operationId":"query_register_api_editor_query_get","parameters":[{"name":"sql","in":"query","required":true,"schema":{"type":"string","description":"SQL query","title":"Sql"},"description":"SQL query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/workshop/researcher":{"get":{"tags":["Workshop"],"summary":"Get Workshop Researcher","description":"Get researcher workspace resources (Kalie-facing).","operationId":"get_workshop_researcher_api_workshop_researcher_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/sources":{"get":{"tags":["Workshop"],"summary":"Get Workshop Sources","description":"Get source references (PDF → manuscript section links).","operationId":"get_workshop_sources_api_workshop_sources_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/outline":{"get":{"tags":["Workshop"],"summary":"Get Workshop Outline","description":"Get manuscript outline (headings from working_manuscript).","operationId":"get_workshop_outline_api_workshop_outline_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/engineering":{"get":{"tags":["Workshop"],"summary":"Get Workshop Engineering","description":"Get engineering workspace (SOPs, tools).","operationId":"get_workshop_engineering_api_workshop_engineering_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/folders":{"get":{"tags":["Workshop"],"summary":"Get Workshop Folders","description":"Get folder → ABD milestone mappings.","operationId":"get_workshop_folders_api_workshop_folders_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/message":{"post":{"tags":["Workshop"],"summary":"Send Workshop Message","description":"Send a message from the workshop to Claude Code.\nAuto-responds using context-aware logic.","operationId":"send_workshop_message_api_workshop_message_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkshopMessage"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/workshop/messages":{"get":{"tags":["Workshop"],"summary":"Get Workshop Messages","description":"Get workshop messages (both user messages and Claude responses).\n\nClaude Code can query this to see pending messages and respond.","operationId":"get_workshop_messages_api_workshop_messages_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","description":"Max messages to return","default":20,"title":"Limit"},"description":"Max messages to return"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status (pending, responded)","title":"Status"},"description":"Filter by status (pending, responded)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/workshop/messages/pending":{"get":{"tags":["Workshop"],"summary":"Get Pending Messages","description":"Get pending messages that need Claude's response.\n\nUse this from Claude Code to check for new messages:\ncurl http://localhost:8000/api/workshop/messages/pending","operationId":"get_pending_messages_api_workshop_messages_pending_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/respond":{"post":{"tags":["Workshop"],"summary":"Respond To Message","description":"Post Claude's response to a workshop message.\n\nThis marks the original message as responded and creates\na WORKSHOP_RESPONSE block.","operationId":"respond_to_message_api_workshop_respond_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkshopResponse"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/workshop/sessions":{"get":{"tags":["Workshop"],"summary":"Get Chat Sessions","description":"Get list of chat sessions for history restoration.\n\nReturns distinct session IDs with message counts and timestamps.","operationId":"get_chat_sessions_api_workshop_sessions_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/workshop/sessions/{session_id}":{"get":{"tags":["Workshop"],"summary":"Get Session Messages","description":"Get all messages for a specific chat session.","operationId":"get_session_messages_api_workshop_sessions__session_id__get","parameters":[{"name":"session_id","in":"path","required":true,"schema":{"type":"string","title":"Session Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/workshop/context":{"get":{"tags":["Workshop"],"summary":"Get Workspace Context","description":"Get the current workspace context for the user.\nReturns user identity, project info, current work, and contextual actions.","operationId":"get_workspace_context_api_workshop_context_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/nod/ontology":{"get":{"tags":["NoD Ontology"],"summary":"Get Nod Ontology","description":"Get all ontology entries with document metadata.","operationId":"get_nod_ontology_api_nod_ontology_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/nod/stats":{"get":{"tags":["NoD Ontology"],"summary":"Get Nod Stats","description":"Get ontology statistics.","operationId":"get_nod_stats_api_nod_stats_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/ops":{"get":{"tags":["operations"],"summary":"Ops Page","description":"Serve unified Event-Sourced TODO, Calendar/Worldline, SOPs, Chain & Syslog workspace.","operationId":"ops_page_ops_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/ops/calendar.ics":{"get":{"tags":["operations"],"summary":"Ops Calendar Ics","operationId":"ops_calendar_ics_ops_calendar_ics_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/ops/overview":{"get":{"tags":["operations"],"summary":"Ops Overview","operationId":"ops_overview_api_ops_overview_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/ops/todos":{"get":{"tags":["operations"],"summary":"Ops List Todos","operationId":"ops_list_todos_api_ops_todos_get","parameters":[{"name":"track","in":"query","required":false,"schema":{"type":"string","default":"all","title":"Track"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","default":"all","title":"Status"}},{"name":"scheduled_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Scheduled Only"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":200,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["operations"],"summary":"Ops Create Todo","operationId":"ops_create_todo_api_ops_todos_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TodoCreateReq"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/ops/todos/{todo_id}":{"put":{"tags":["operations"],"summary":"Ops Update Todo","operationId":"ops_update_todo_api_ops_todos__todo_id__put","parameters":[{"name":"todo_id","in":"path","required":true,"schema":{"type":"integer","title":"Todo Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TodoUpdateReq"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/ops/todos/{todo_id}/toggle":{"post":{"tags":["operations"],"summary":"Ops Toggle Todo","operationId":"ops_toggle_todo_api_ops_todos__todo_id__toggle_post","parameters":[{"name":"todo_id","in":"path","required":true,"schema":{"type":"integer","title":"Todo Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/ops/syslog":{"get":{"tags":["operations"],"summary":"Ops List Syslog","operationId":"ops_list_syslog_api_ops_syslog_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":80,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["operations"],"summary":"Ops Append Syslog","operationId":"ops_append_syslog_api_ops_syslog_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyslogCreateReq"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/ops/syslog/{entry_id}/clarify":{"post":{"tags":["operations"],"summary":"Ops Clarify Syslog","operationId":"ops_clarify_syslog_api_ops_syslog__entry_id__clarify_post","parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"integer","title":"Entry Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyslogClarifyReq"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/ops/syslog/{entry_id}/route-todo":{"post":{"tags":["operations"],"summary":"Ops Route Syslog Todo","operationId":"ops_route_syslog_todo_api_ops_syslog__entry_id__route_todo_post","parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"integer","title":"Entry Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyslogRouteTodoReq"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/ops/sop/{slug}/launch":{"post":{"tags":["operations"],"summary":"Ops Launch Sop","operationId":"ops_launch_sop_api_ops_sop__slug__launch_post","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/":{"get":{"tags":["manuscript"],"summary":"Panel","description":"Serve document tree panel","operationId":"panel_manuscript__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/manuscript/api/tree":{"get":{"tags":["manuscript"],"summary":"Get Tree","description":"Get document tree from document_block VIEW.\n\nT223541PDT: ?roots=1 returns the top-level documents only (nodes that have children, newest first, each with child_count and no children; parentless single blocks are counted in orphan_roots);\n?root=<block id or hash> returns that node's subtree. No parameters: the full tree (slow, 59k nodes).","operationId":"get_tree_manuscript_api_tree_get","parameters":[{"name":"roots","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Roots"}},{"name":"root","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/block":{"post":{"tags":["manuscript"],"summary":"Create Block","description":"Create a new document block","operationId":"create_block_manuscript_api_block_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewBlock"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/upload":{"post":{"tags":["manuscript"],"summary":"Upload Pdf","description":"Upload PDF, extract outline to document blocks.\n\nFlow: PDF → workbench.sh → markdown → parse → document_blocks","operationId":"upload_pdf_manuscript_api_upload_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_pdf_manuscript_api_upload_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/annotate":{"post":{"tags":["manuscript"],"summary":"Annotate Block","description":"Add annotation to a document block (memo field, append-style).\n\nFor user fidelity feedback.","operationId":"annotate_block_manuscript_api_annotate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnotationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/fidelity":{"post":{"tags":["manuscript"],"summary":"Add Fidelity Check","description":"Add fidelity check annotation (yes/no with comment).\n\nUser validation of block content accuracy.","operationId":"add_fidelity_check_manuscript_api_fidelity_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FidelityRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/annotations/{block_hash}":{"get":{"tags":["manuscript"],"summary":"Get Block Annotations","description":"Get annotations for a block","operationId":"get_block_annotations_manuscript_api_annotations__block_hash__get","parameters":[{"name":"block_hash","in":"path","required":true,"schema":{"type":"string","title":"Block Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/block/{block_hash}":{"get":{"tags":["manuscript"],"summary":"Get Block","description":"Get a single block by hash","operationId":"get_block_manuscript_api_block__block_hash__get","parameters":[{"name":"block_hash","in":"path","required":true,"schema":{"type":"string","title":"Block Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/outline":{"post":{"tags":["manuscript"],"summary":"Outline Upload","description":"Upload a PDF and get its detected headings back as a draft to verify or edit. Nothing is written to the register yet.","operationId":"outline_upload_manuscript_api_outline_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_outline_upload_manuscript_api_outline_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/outline/{draft_id}":{"get":{"tags":["manuscript"],"summary":"Outline Get","operationId":"outline_get_manuscript_api_outline__draft_id__get","parameters":[{"name":"draft_id","in":"path","required":true,"schema":{"type":"string","title":"Draft Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["manuscript"],"summary":"Outline Save","description":"Save the user's verified or edited headings on the draft (level 1-4, title, line, page).","operationId":"outline_save_manuscript_api_outline__draft_id__put","parameters":[{"name":"draft_id","in":"path","required":true,"schema":{"type":"string","title":"Draft Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/outline/{draft_id}/commit":{"post":{"tags":["manuscript"],"summary":"Outline Commit","description":"Create the document blocks from the verified headings. Pass {\"headings\": [...]} to save and commit in one call.","operationId":"outline_commit_manuscript_api_outline__draft_id__commit_post","parameters":[{"name":"draft_id","in":"path","required":true,"schema":{"type":"string","title":"Draft Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"type":"object","additionalProperties":true},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/workbench":{"get":{"tags":["manuscript"],"summary":"Workbench Page","description":"Serve APA 7th edition PDF Validation Workbench & Ghostwriter Outline UI.","operationId":"workbench_page_manuscript_workbench_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/manuscript/api/workbench/scan":{"post":{"tags":["manuscript"],"summary":"Workbench Scan","description":"Multi-pass non-LLM PDF/Text structure + image/table + trimmed-header scan.","operationId":"workbench_scan_manuscript_api_workbench_scan_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_workbench_scan_manuscript_api_workbench_scan_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/workbench/format-tokenize":{"post":{"tags":["manuscript"],"summary":"Workbench Format Tokenize","description":"Normalize validated Markdown with \\n\\n sentences & \\n\\n\\n paragraphs + Ghostwriter outline.","operationId":"workbench_format_tokenize_manuscript_api_workbench_format_tokenize_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkbenchFormatRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/workbench/competency/articles":{"get":{"tags":["manuscript"],"summary":"Workbench Competency Articles","description":"List verified benchmark articles + adopted ML F1 baseline (gemma-4-31b v2 = 0.97).","operationId":"workbench_competency_articles_manuscript_api_workbench_competency_articles_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/manuscript/api/workbench/competency/article/{name}":{"get":{"tags":["manuscript"],"summary":"Workbench Competency Article","operationId":"workbench_competency_article_manuscript_api_workbench_competency_article__name__get","parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/manuscript/api/workbench/competency/evaluate":{"post":{"tags":["manuscript"],"summary":"Workbench Competency Evaluate","description":"Score human trainee validated headings against Gold truth & ML pipeline benchmark.","operationId":"workbench_competency_evaluate_manuscript_api_workbench_competency_evaluate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompetencyEvalRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sidecar":{"get":{"summary":"Sidecar Index","description":"List all transcribed files in sidecar.","operationId":"sidecar_index_sidecar_get","responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}}}}},"/sidecar/transcript/{file_hash}":{"get":{"summary":"Sidecar Transcript","description":"View transcript for a specific file.","operationId":"sidecar_transcript_sidecar_transcript__file_hash__get","parameters":[{"name":"file_hash","in":"path","required":true,"schema":{"type":"string","title":"File Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"text/html":{"schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/sidecar/api/transcript/{file_hash}":{"get":{"summary":"Sidecar Transcript Api","description":"Get transcript data as JSON.","operationId":"sidecar_transcript_api_sidecar_api_transcript__file_hash__get","parameters":[{"name":"file_hash","in":"path","required":true,"schema":{"type":"string","title":"File Hash"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/query":{"get":{"tags":["query"],"summary":"Query Page","description":"Serve the unified Query & Relatedness panel.","operationId":"query_page_query_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/query/databases":{"get":{"tags":["query"],"summary":"Legacy Query Redirect","description":"Redirect legacy query navbar links to /query cleanly.","operationId":"legacy_query_redirect_api_query_databases_get","parameters":[{"name":"query","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/query/categories":{"get":{"tags":["query"],"summary":"Get Categories","operationId":"get_categories_api_query_categories_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/query/parties":{"get":{"tags":["query"],"summary":"Get Parties","operationId":"get_parties_api_query_parties_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/fts/merged":{"get":{"tags":["query"],"summary":"Fts Search Merged","description":"Full-text search across merged_records_fts with parent media & speaker metadata.","operationId":"fts_search_merged_api_fts_merged_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":1,"title":"Q"}},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"party_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Party Id"}},{"name":"parent_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Parent Id"}},{"name":"media_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Media Only"}},{"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":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/query/search":{"get":{"tags":["query"],"summary":"Search Records","description":"Structured + FTS query across merged_records.","operationId":"search_records_api_query_search_get","parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"party_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Party Id"}},{"name":"parent_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Parent Id"}},{"name":"media_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Media Only"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End Date"}},{"name":"sort","in":"query","required":false,"schema":{"type":"string","default":"desc","title":"Sort"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/sampler/build":{"post":{"tags":["sampler"],"summary":"Api Sampler Build","description":"Compose a chronological/relevance sampler mixtape manifest and Broadcast Spec Sheet.","operationId":"api_sampler_build_api_sampler_build_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplerBuildRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/query/sampler/build":{"post":{"tags":["sampler"],"summary":"Api Sampler Build","description":"Compose a chronological/relevance sampler mixtape manifest and Broadcast Spec Sheet.","operationId":"api_sampler_build_api_query_sampler_build_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplerBuildRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/sampler/export":{"post":{"tags":["sampler"],"summary":"Api Sampler Export","description":"Export built manifest as standalone HTML, JSON, CSV, or CMX-3600 EDL.","operationId":"api_sampler_export_api_sampler_export_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplerExportRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/query/sampler/export":{"post":{"tags":["sampler"],"summary":"Api Sampler Export","description":"Export built manifest as standalone HTML, JSON, CSV, or CMX-3600 EDL.","operationId":"api_sampler_export_api_query_sampler_export_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplerExportRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/sampler/save-to-catalog":{"post":{"tags":["sampler"],"summary":"Api Sampler Save To Catalog","description":"Build sampler mixtape + spec sheet, upload to S3 content-addressed storage, and persist in how.db catalog.","operationId":"api_sampler_save_to_catalog_api_sampler_save_to_catalog_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplerSaveRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/query/sampler/save-to-catalog":{"post":{"tags":["sampler"],"summary":"Api Sampler Save To Catalog","description":"Build sampler mixtape + spec sheet, upload to S3 content-addressed storage, and persist in how.db catalog.","operationId":"api_sampler_save_to_catalog_api_query_sampler_save_to_catalog_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SamplerSaveRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/passthrough/process":{"post":{"tags":["Passthrough"],"summary":"Passthrough Process","description":"Build and stream a self-contained portable delivery `.zip` with zero shared catalog mutation.","operationId":"passthrough_process_api_passthrough_process_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_passthrough_process_api_passthrough_process_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/upload/passthrough":{"post":{"tags":["Passthrough"],"summary":"Upload Passthrough Alias","description":"Alias for `POST /api/passthrough/process`.","operationId":"upload_passthrough_alias_upload_passthrough_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_passthrough_alias_upload_passthrough_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/auth/scope":{"get":{"summary":"Get Auth Scope","description":"Inspect active capability token scope verified locally by FastAPI.","operationId":"get_auth_scope_api_auth_scope_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/":{"get":{"summary":"Home","description":"Home: the hub page (catalog, transcript, manuscript, editor, upload)","operationId":"home__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/info":{"get":{"summary":"Root","description":"Hub info (was served at / before T223541PDT)","operationId":"root_info_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/ping":{"get":{"summary":"Ping","description":"Ghost Fossil compatibility health endpoint.","operationId":"ping_ping_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health":{"get":{"summary":"Health Check","description":"Database health check","operationId":"health_check_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/editor":{"get":{"summary":"Editor Hub","description":"Editor hub - lists available editor panels","operationId":"editor_hub_editor_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/editor/blocks":{"get":{"summary":"Editor Blocks","description":"Block editor panel - view/create register blocks","operationId":"editor_blocks_editor_blocks_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/editor/files":{"get":{"summary":"Editor Files","description":"Files panel - browse user files","operationId":"editor_files_editor_files_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/editor/workshop":{"get":{"summary":"Editor Workshop","description":"Manuscript Workshop - Kalie's dissertation workspace","operationId":"editor_workshop_editor_workshop_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/chat":{"get":{"summary":"Chat Interface","description":"Chat-first interface with Dr. How","operationId":"chat_interface_chat_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/how":{"get":{"summary":"How Workspace","description":"Dr. How workspace - unified stream","operationId":"how_workspace_how_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/content":{"get":{"summary":"Content Interface","description":"Workshop content - sources, sections","operationId":"content_interface_content_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/view":{"get":{"summary":"View Register","description":"Minimal register viewer","operationId":"view_register_view_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/tables":{"get":{"summary":"List Tables","description":"List all tables in how.db","operationId":"list_tables_tables_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"AnnotationCreate":{"properties":{"target_hash":{"type":"string","title":"Target Hash"},"content":{"type":"string","title":"Content"},"permit_id":{"type":"string","title":"Permit Id"},"username":{"type":"string","title":"Username"}},"type":"object","required":["target_hash","content","permit_id","username"],"title":"AnnotationCreate"},"AnnotationRequest":{"properties":{"target_hash":{"type":"string","title":"Target Hash"},"content":{"type":"string","title":"Content"},"annotation_type":{"type":"string","title":"Annotation Type","default":"memo"}},"type":"object","required":["target_hash","content"],"title":"AnnotationRequest"},"BlockCreate":{"properties":{"subject":{"type":"string","title":"Subject"},"predicate":{"type":"string","title":"Predicate"},"object":{"type":"string","title":"Object"},"space":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Space"},"derives_from":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Derives From"},"derivation_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Derivation Type"},"content":{"additionalProperties":true,"type":"object","title":"Content"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"memo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Memo"},"tags":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tags"}},"type":"object","required":["subject","predicate","object","content"],"title":"BlockCreate"},"BlockResponse":{"properties":{"hash":{"type":"string","title":"Hash"},"subject":{"type":"string","title":"Subject"},"predicate":{"type":"string","title":"Predicate"},"object":{"type":"string","title":"Object"},"space":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Space"},"content":{"additionalProperties":true,"type":"object","title":"Content"},"created_at":{"type":"string","title":"Created At"},"children":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Children"}},"type":"object","required":["hash","subject","predicate","object","space","content","created_at"],"title":"BlockResponse"},"Body_add_file_api_editor_files_add_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_add_file_api_editor_files_add_post"},"Body_outline_upload_manuscript_api_outline_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"permit_folder":{"type":"string","title":"Permit Folder","default":""},"party_id":{"type":"string","title":"Party Id","default":""}},"type":"object","required":["file"],"title":"Body_outline_upload_manuscript_api_outline_post"},"Body_passthrough_process_api_passthrough_process_post":{"properties":{"file":{"anyOf":[{"type":"string","format":"binary"},{"type":"null"}],"title":"File"},"s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Key"},"filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filename"},"retention_policy":{"type":"string","title":"Retention Policy","default":"RECEIPT_ONLY"}},"type":"object","title":"Body_passthrough_process_api_passthrough_process_post"},"Body_unified_upload_api_unified_upload_post":{"properties":{"files":{"items":{"type":"string","format":"binary"},"type":"array","title":"Files"},"confirm":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Confirm"},"permit_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Permit Id"},"folder":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Folder"},"party_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Party Id"}},"type":"object","required":["files"],"title":"Body_unified_upload_api_unified_upload_post"},"Body_unified_upload_stream_api_unified_upload_stream_post":{"properties":{"files":{"items":{"type":"string","format":"binary"},"type":"array","title":"Files"},"permit_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Permit Id"},"party_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Party Id"}},"type":"object","required":["files"],"title":"Body_unified_upload_stream_api_unified_upload_stream_post"},"Body_unified_upload_upload_post":{"properties":{"files":{"items":{"type":"string","format":"binary"},"type":"array","title":"Files"},"confirm":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Confirm"},"permit_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Permit Id"},"folder":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Folder"},"party_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Party Id"}},"type":"object","required":["files"],"title":"Body_unified_upload_upload_post"},"Body_upload_api_transformer_upload_post":{"properties":{"files":{"items":{"type":"string","format":"binary"},"type":"array","title":"Files"},"confirm":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Confirm"},"permit_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Permit Id"},"folder":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Folder"},"party_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Party Id"}},"type":"object","required":["files"],"title":"Body_upload_api_transformer_upload_post"},"Body_upload_passthrough_alias_upload_passthrough_post":{"properties":{"file":{"anyOf":[{"type":"string","format":"binary"},{"type":"null"}],"title":"File"},"s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"S3 Key"},"filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filename"},"retention_policy":{"type":"string","title":"Retention Policy","default":"RECEIPT_ONLY"}},"type":"object","title":"Body_upload_passthrough_alias_upload_passthrough_post"},"Body_upload_pdf_manuscript_api_upload_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"permit_folder":{"type":"string","title":"Permit Folder","default":""}},"type":"object","required":["file"],"title":"Body_upload_pdf_manuscript_api_upload_post"},"Body_workbench_scan_manuscript_api_workbench_scan_post":{"properties":{"file":{"anyOf":[{"type":"string","format":"binary"},{"type":"null"}],"title":"File"},"raw_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Raw Text"},"competency_article":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Competency Article"},"run_ocr":{"type":"boolean","title":"Run Ocr","default":false}},"type":"object","title":"Body_workbench_scan_manuscript_api_workbench_scan_post"},"CatalogUpdateRequest":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"artist":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artist"},"comment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Comment"}},"type":"object","title":"CatalogUpdateRequest"},"CompetencyEvalRequest":{"properties":{"article_name":{"type":"string","title":"Article Name"},"submitted_markdown":{"type":"string","title":"Submitted Markdown"}},"type":"object","required":["article_name","submitted_markdown"],"title":"CompetencyEvalRequest"},"FidelityRequest":{"properties":{"target_hash":{"type":"string","title":"Target Hash"},"response":{"type":"string","title":"Response"},"comment":{"type":"string","title":"Comment"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"}},"type":"object","required":["target_hash","response","comment"],"title":"FidelityRequest"},"FlagRequest":{"properties":{"concrete_id":{"type":"integer","title":"Concrete Id"},"label":{"type":"string","title":"Label","default":"catalog_flag"},"notes":{"type":"string","title":"Notes"}},"type":"object","required":["concrete_id"],"title":"FlagRequest"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"NewBlock":{"properties":{"block_type":{"type":"string","title":"Block Type"},"title":{"type":"string","title":"Title"},"content":{"type":"string","title":"Content","default":""},"parent_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Hash"},"order_index":{"type":"integer","title":"Order Index","default":0}},"type":"object","required":["block_type","title"],"title":"NewBlock"},"RenameRequest":{"properties":{"block_hash":{"type":"string","title":"Block Hash"},"new_name":{"type":"string","title":"New Name"}},"type":"object","required":["block_hash","new_name"],"title":"RenameRequest"},"SamplerBuildRequest":{"properties":{"title":{"type":"string","title":"Title","default":"TIES Broadcast Sampler Mixtape"},"query":{"type":"string","title":"Query","default":""},"segment_ids":{"items":{"type":"integer"},"type":"array","title":"Segment Ids"},"max_clips":{"type":"integer","maximum":200.0,"minimum":1.0,"title":"Max Clips","default":12},"max_duration_sec":{"type":"number","maximum":3600.0,"minimum":5.0,"title":"Max Duration Sec","default":180.0},"pad_before_sec":{"type":"number","maximum":30.0,"minimum":0.0,"title":"Pad Before Sec","default":0.5},"pad_after_sec":{"type":"number","maximum":30.0,"minimum":0.0,"title":"Pad After Sec","default":0.5},"sort_mode":{"type":"string","title":"Sort Mode","default":"relevance"},"scope_user":{"type":"string","title":"Scope User","default":"doctortheisen"},"scope_institution":{"type":"string","title":"Scope Institution","default":"tiesapi.com"},"scope_agreement":{"type":"string","title":"Scope Agreement","default":"WO-TIES-2026-SAMPLER"}},"type":"object","title":"SamplerBuildRequest"},"SamplerExportRequest":{"properties":{"manifest":{"additionalProperties":true,"type":"object","title":"Manifest"},"format":{"type":"string","title":"Format","default":"html"}},"type":"object","required":["manifest"],"title":"SamplerExportRequest"},"SamplerSaveRequest":{"properties":{"title":{"type":"string","title":"Title","default":"TIES Broadcast Sampler Mixtape"},"query":{"type":"string","title":"Query","default":""},"segment_ids":{"items":{"type":"integer"},"type":"array","title":"Segment Ids"},"max_clips":{"type":"integer","maximum":200.0,"minimum":1.0,"title":"Max Clips","default":12},"max_duration_sec":{"type":"number","maximum":3600.0,"minimum":5.0,"title":"Max Duration Sec","default":180.0},"pad_before_sec":{"type":"number","maximum":30.0,"minimum":0.0,"title":"Pad Before Sec","default":0.5},"pad_after_sec":{"type":"number","maximum":30.0,"minimum":0.0,"title":"Pad After Sec","default":0.5},"sort_mode":{"type":"string","title":"Sort Mode","default":"relevance"},"scope_user":{"type":"string","title":"Scope User","default":"doctortheisen"},"scope_institution":{"type":"string","title":"Scope Institution","default":"tiesapi.com"},"scope_agreement":{"type":"string","title":"Scope Agreement","default":"WO-TIES-2026-SAMPLER"},"notes":{"type":"string","title":"Notes","default":""}},"type":"object","title":"SamplerSaveRequest"},"SetRole":{"properties":{"block_hash":{"type":"string","title":"Block Hash"},"label":{"type":"string","title":"Label","default":""}},"type":"object","required":["block_hash"],"title":"SetRole"},"SetSpace":{"properties":{"block_hash":{"type":"string","title":"Block Hash"},"value":{"type":"string","title":"Value"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note","default":""}},"type":"object","required":["block_hash","value"],"title":"SetSpace"},"StepStatusUpdate":{"properties":{"block_id":{"type":"string","title":"Block Id"},"status":{"type":"string","title":"Status"}},"type":"object","required":["block_id","status"],"title":"StepStatusUpdate"},"SyslogClarifyReq":{"properties":{"new_body":{"type":"string","title":"New Body"},"entry_kind":{"type":"string","title":"Entry Kind","default":"clarification"},"author":{"type":"string","title":"Author","default":"doctortheisen"},"page_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Page Context"}},"type":"object","required":["new_body"],"title":"SyslogClarifyReq"},"SyslogCreateReq":{"properties":{"body":{"type":"string","title":"Body"},"entry_kind":{"type":"string","title":"Entry Kind","default":"log"},"author":{"type":"string","title":"Author","default":"doctortheisen"},"page_context":{"type":"string","title":"Page Context","default":"/"},"worldline_day":{"type":"string","title":"Worldline Day","default":"20261114"}},"type":"object","required":["body"],"title":"SyslogCreateReq"},"SyslogRouteTodoReq":{"properties":{"track":{"type":"string","title":"Track","default":"operational"},"priority":{"type":"integer","title":"Priority","default":2},"scheduled_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Date"},"scheduled_time":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Time"},"sop_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sop Slug"}},"type":"object","title":"SyslogRouteTodoReq"},"TimestampCorrection":{"properties":{"block_hash":{"type":"string","title":"Block Hash"},"value":{"type":"string","title":"Value"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note","default":""}},"type":"object","required":["block_hash","value"],"title":"TimestampCorrection"},"TodoCreateReq":{"properties":{"description":{"type":"string","title":"Description"},"track":{"type":"string","title":"Track","default":"operational"},"priority":{"type":"integer","title":"Priority","default":2},"scheduled_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Date"},"scheduled_time":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Time"},"sop_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sop Slug"},"catalog_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Catalog Ref"},"worldline_day":{"type":"string","title":"Worldline Day","default":"20261114"}},"type":"object","required":["description"],"title":"TodoCreateReq"},"TodoUpdateReq":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"priority":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Priority"},"scheduled_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Date"},"scheduled_time":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheduled Time"},"sop_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sop Slug"}},"type":"object","title":"TodoUpdateReq"},"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"},"WorkbenchFormatRequest":{"properties":{"validated_markdown":{"type":"string","title":"Validated Markdown"},"title":{"type":"string","title":"Title","default":"Untitled Manuscript"},"citation":{"type":"string","title":"Citation","default":""},"abstract":{"type":"string","title":"Abstract","default":""},"references":{"items":{"type":"string"},"type":"array","title":"References","default":[]},"figures":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Figures","default":[]},"tables":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Tables","default":[]}},"type":"object","required":["validated_markdown"],"title":"WorkbenchFormatRequest"},"WorkshopMessage":{"properties":{"content":{"type":"string","title":"Content"},"from_user":{"anyOf":[{"type":"string"},{"items":{"type":"string"},"type":"array"}],"title":"From User","default":"kalie"},"context":{"type":"string","title":"Context","default":"manuscript_workshop"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"}},"type":"object","required":["content"],"title":"WorkshopMessage"},"WorkshopResponse":{"properties":{"message_hash":{"type":"string","title":"Message Hash"},"response":{"type":"string","title":"Response"}},"type":"object","required":["message_hash","response"],"title":"WorkshopResponse"}}}}