qanswer-sdk 0.46.0.dev0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (624) hide show
  1. qanswer_sdk/__init__.py +1268 -0
  2. qanswer_sdk/api/__init__.py +64 -0
  3. qanswer_sdk/api/admin_api.py +7383 -0
  4. qanswer_sdk/api/ai_assistant_access_rights_api.py +5879 -0
  5. qanswer_sdk/api/ai_assistant_api.py +8960 -0
  6. qanswer_sdk/api/auto_complete_api.py +612 -0
  7. qanswer_sdk/api/bot_slack_api.py +1069 -0
  8. qanswer_sdk/api/branding_api.py +5723 -0
  9. qanswer_sdk/api/chatbot_api.py +1102 -0
  10. qanswer_sdk/api/connector_audio_api.py +3264 -0
  11. qanswer_sdk/api/connector_document_api.py +1990 -0
  12. qanswer_sdk/api/connector_e_consilium_api.py +313 -0
  13. qanswer_sdk/api/connector_e_consilium_search_index_api_api.py +1164 -0
  14. qanswer_sdk/api/connector_google_drive_api.py +1896 -0
  15. qanswer_sdk/api/connector_imapapi_api.py +1775 -0
  16. qanswer_sdk/api/connector_one_drive_api.py +1579 -0
  17. qanswer_sdk/api/connector_onenote_api.py +1596 -0
  18. qanswer_sdk/api/connector_pinecone_api.py +893 -0
  19. qanswer_sdk/api/connector_publication_office_api_api.py +1230 -0
  20. qanswer_sdk/api/connector_qn_a_api.py +1521 -0
  21. qanswer_sdk/api/connector_rdf_answer_api.py +1393 -0
  22. qanswer_sdk/api/connector_rdf_api.py +5093 -0
  23. qanswer_sdk/api/connector_sharepoint_api.py +3445 -0
  24. qanswer_sdk/api/connector_websearch_api.py +332 -0
  25. qanswer_sdk/api/connector_website_api.py +2829 -0
  26. qanswer_sdk/api/connectors_api.py +6824 -0
  27. qanswer_sdk/api/connectors_data_api.py +5415 -0
  28. qanswer_sdk/api/conversation_logs_api.py +13159 -0
  29. qanswer_sdk/api/dataset_api.py +6487 -0
  30. qanswer_sdk/api/dataset_config_api.py +4643 -0
  31. qanswer_sdk/api/debug_api.py +278 -0
  32. qanswer_sdk/api/default_api.py +763 -0
  33. qanswer_sdk/api/embedder_endpoint_api.py +3330 -0
  34. qanswer_sdk/api/frontend_config_api.py +270 -0
  35. qanswer_sdk/api/health_check_api_api.py +278 -0
  36. qanswer_sdk/api/llm_endpoint_api.py +4660 -0
  37. qanswer_sdk/api/mcp_api.py +11201 -0
  38. qanswer_sdk/api/metadata_api.py +2070 -0
  39. qanswer_sdk/api/notifications_api.py +1841 -0
  40. qanswer_sdk/api/o_auth2_api.py +648 -0
  41. qanswer_sdk/api/payment_api.py +1852 -0
  42. qanswer_sdk/api/socket_api.py +4220 -0
  43. qanswer_sdk/api/speech_to_text_api.py +919 -0
  44. qanswer_sdk/api/task_ai_excel_api.py +7541 -0
  45. qanswer_sdk/api/task_chat_api.py +2598 -0
  46. qanswer_sdk/api/task_document_parsing_api.py +619 -0
  47. qanswer_sdk/api/task_entity_linking_api.py +315 -0
  48. qanswer_sdk/api/task_rdf_linker_api.py +4408 -0
  49. qanswer_sdk/api/task_rdf_sparql_endpoint_api.py +3189 -0
  50. qanswer_sdk/api/task_rdf_text_linker_api.py +1452 -0
  51. qanswer_sdk/api/task_report_copilot_api.py +7010 -0
  52. qanswer_sdk/api/task_search_api.py +2012 -0
  53. qanswer_sdk/api/task_text2sparql_api.py +902 -0
  54. qanswer_sdk/api/task_text_classification_api.py +592 -0
  55. qanswer_sdk/api/tasks_api.py +318 -0
  56. qanswer_sdk/api/tool_embedder_api.py +5208 -0
  57. qanswer_sdk/api/tool_llm_api.py +6518 -0
  58. qanswer_sdk/api/unit_organizations_api.py +7086 -0
  59. qanswer_sdk/api/unit_teams_api.py +4255 -0
  60. qanswer_sdk/api/unit_user_api.py +11948 -0
  61. qanswer_sdk/api/v1_chat_completion_api.py +330 -0
  62. qanswer_sdk/api/v1_embeddings_api.py +297 -0
  63. qanswer_sdk/api_client.py +804 -0
  64. qanswer_sdk/api_response.py +21 -0
  65. qanswer_sdk/configuration.py +614 -0
  66. qanswer_sdk/exceptions.py +216 -0
  67. qanswer_sdk/models/__init__.py +567 -0
  68. qanswer_sdk/models/access_audio_spans_response_model.py +91 -0
  69. qanswer_sdk/models/access_pdf_payload_model.py +111 -0
  70. qanswer_sdk/models/access_type.py +42 -0
  71. qanswer_sdk/models/access_type_shared.py +38 -0
  72. qanswer_sdk/models/add_qn_a_request.py +103 -0
  73. qanswer_sdk/models/add_synonyms.py +93 -0
  74. qanswer_sdk/models/add_synonyms_resp.py +89 -0
  75. qanswer_sdk/models/admin_overall_stats_response.py +105 -0
  76. qanswer_sdk/models/admin_user_overall_stats.py +99 -0
  77. qanswer_sdk/models/advanced_o_auth2_mcp_authentication_config.py +95 -0
  78. qanswer_sdk/models/aggregate.py +93 -0
  79. qanswer_sdk/models/aggregation.py +116 -0
  80. qanswer_sdk/models/aggregation_type.py +41 -0
  81. qanswer_sdk/models/aggregations_group.py +102 -0
  82. qanswer_sdk/models/ai_assistant_clone_response.py +91 -0
  83. qanswer_sdk/models/ai_assistant_dto.py +122 -0
  84. qanswer_sdk/models/ai_assistant_filter_dto.py +113 -0
  85. qanswer_sdk/models/ai_assistant_list.py +101 -0
  86. qanswer_sdk/models/ai_assistant_share_response.py +93 -0
  87. qanswer_sdk/models/ai_assistant_shared_access.py +113 -0
  88. qanswer_sdk/models/ai_excel_task_settings.py +125 -0
  89. qanswer_sdk/models/ai_excel_task_update.py +125 -0
  90. qanswer_sdk/models/ai_task_settings_update_payload.py +95 -0
  91. qanswer_sdk/models/ai_template_base_with_id.py +95 -0
  92. qanswer_sdk/models/ai_template_cell.py +113 -0
  93. qanswer_sdk/models/ai_template_cell_base.py +87 -0
  94. qanswer_sdk/models/ai_template_cell_update_payload.py +95 -0
  95. qanswer_sdk/models/ai_template_column.py +99 -0
  96. qanswer_sdk/models/ai_template_column_base.py +93 -0
  97. qanswer_sdk/models/ai_template_column_update_payload.py +109 -0
  98. qanswer_sdk/models/ai_template_column_with_cells.py +109 -0
  99. qanswer_sdk/models/ai_template_create_payload.py +128 -0
  100. qanswer_sdk/models/ai_template_row.py +93 -0
  101. qanswer_sdk/models/ai_template_row_base.py +87 -0
  102. qanswer_sdk/models/ai_template_row_update_payload.py +103 -0
  103. qanswer_sdk/models/ai_template_row_with_cells.py +103 -0
  104. qanswer_sdk/models/ai_template_with_cells.py +134 -0
  105. qanswer_sdk/models/ai_template_with_cells_new_column_id.py +136 -0
  106. qanswer_sdk/models/allowed_extension.py +53 -0
  107. qanswer_sdk/models/allowed_file_extensions.py +98 -0
  108. qanswer_sdk/models/api_key_header_type.py +38 -0
  109. qanswer_sdk/models/api_key_mcp_authentication_config.py +94 -0
  110. qanswer_sdk/models/applied_filter_type.py +37 -0
  111. qanswer_sdk/models/applied_metadata_filter.py +103 -0
  112. qanswer_sdk/models/apply_template_task_settings_to_slots_response.py +89 -0
  113. qanswer_sdk/models/assistant_category_color_definition.py +89 -0
  114. qanswer_sdk/models/assistant_category_color_item.py +89 -0
  115. qanswer_sdk/models/assistant_category_colors_update_payload.py +95 -0
  116. qanswer_sdk/models/assistant_category_count.py +91 -0
  117. qanswer_sdk/models/assistant_message_stop.py +93 -0
  118. qanswer_sdk/models/assistant_task.py +43 -0
  119. qanswer_sdk/models/assistant_template.py +111 -0
  120. qanswer_sdk/models/assistant_template_filter_dto.py +120 -0
  121. qanswer_sdk/models/assistant_template_with_tools_selection_dto.py +121 -0
  122. qanswer_sdk/models/audio_allowed_file_extensions.py +87 -0
  123. qanswer_sdk/models/audio_file_upload_payload.py +107 -0
  124. qanswer_sdk/models/audio_format.py +37 -0
  125. qanswer_sdk/models/audio_segment.py +95 -0
  126. qanswer_sdk/models/audio_segment_update_payload.py +97 -0
  127. qanswer_sdk/models/audio_segment_update_response.py +91 -0
  128. qanswer_sdk/models/audio_speaker_update_payload.py +99 -0
  129. qanswer_sdk/models/audio_speaker_update_response.py +91 -0
  130. qanswer_sdk/models/audio_transcription_list_response.py +101 -0
  131. qanswer_sdk/models/audio_transcription_mode.py +37 -0
  132. qanswer_sdk/models/audio_transcription_record.py +101 -0
  133. qanswer_sdk/models/audio_upload_response.py +99 -0
  134. qanswer_sdk/models/audio_upload_transcription.py +99 -0
  135. qanswer_sdk/models/audio_word_segment.py +93 -0
  136. qanswer_sdk/models/audio_word_span_change.py +94 -0
  137. qanswer_sdk/models/audio_word_span_update_payload.py +104 -0
  138. qanswer_sdk/models/audio_word_span_update_response.py +91 -0
  139. qanswer_sdk/models/audio_word_update_payload.py +100 -0
  140. qanswer_sdk/models/audio_word_update_response.py +91 -0
  141. qanswer_sdk/models/auth_link_response.py +91 -0
  142. qanswer_sdk/models/auto_bot_description_request.py +89 -0
  143. qanswer_sdk/models/auto_bot_description_response.py +87 -0
  144. qanswer_sdk/models/available_aggregation.py +98 -0
  145. qanswer_sdk/models/available_connectors_response.py +99 -0
  146. qanswer_sdk/models/available_embedding_models_response.py +95 -0
  147. qanswer_sdk/models/available_endpoints_response.py +95 -0
  148. qanswer_sdk/models/available_logs_visibility_policy.py +103 -0
  149. qanswer_sdk/models/available_space_quota_for_dataset.py +95 -0
  150. qanswer_sdk/models/available_storage_preference.py +103 -0
  151. qanswer_sdk/models/base_connectors_response.py +89 -0
  152. qanswer_sdk/models/base_conversation_response.py +89 -0
  153. qanswer_sdk/models/base_feedback_response.py +89 -0
  154. qanswer_sdk/models/bot_answer_length.py +38 -0
  155. qanswer_sdk/models/branding_app_title.py +87 -0
  156. qanswer_sdk/models/branding_system_message.py +87 -0
  157. qanswer_sdk/models/bulk_update_tool_selections_request.py +87 -0
  158. qanswer_sdk/models/capability_type.py +37 -0
  159. qanswer_sdk/models/cell.py +89 -0
  160. qanswer_sdk/models/change_password.py +89 -0
  161. qanswer_sdk/models/change_password_admin.py +89 -0
  162. qanswer_sdk/models/change_role.py +96 -0
  163. qanswer_sdk/models/chat_task_settings.py +141 -0
  164. qanswer_sdk/models/chat_task_settings_update_payload.py +95 -0
  165. qanswer_sdk/models/chat_task_update.py +139 -0
  166. qanswer_sdk/models/chatbot_chat_payload.py +148 -0
  167. qanswer_sdk/models/chatbot_default_settings_response.py +95 -0
  168. qanswer_sdk/models/chatbot_llm_dto.py +147 -0
  169. qanswer_sdk/models/chatbot_response.py +151 -0
  170. qanswer_sdk/models/chatbot_setting_dto.py +99 -0
  171. qanswer_sdk/models/chatbot_setting_request.py +91 -0
  172. qanswer_sdk/models/class_info.py +89 -0
  173. qanswer_sdk/models/clone_dataset_request.py +104 -0
  174. qanswer_sdk/models/clone_dataset_response.py +91 -0
  175. qanswer_sdk/models/config.py +228 -0
  176. qanswer_sdk/models/config1.py +138 -0
  177. qanswer_sdk/models/connector_config_list_response.py +99 -0
  178. qanswer_sdk/models/connector_config_model.py +102 -0
  179. qanswer_sdk/models/connector_config_patch_payload.py +93 -0
  180. qanswer_sdk/models/connector_config_response.py +95 -0
  181. qanswer_sdk/models/connector_config_sync_response.py +93 -0
  182. qanswer_sdk/models/connector_config_type.py +37 -0
  183. qanswer_sdk/models/connector_model.py +118 -0
  184. qanswer_sdk/models/connector_type.py +50 -0
  185. qanswer_sdk/models/connector_type_dto.py +98 -0
  186. qanswer_sdk/models/connector_type_list_dto.py +95 -0
  187. qanswer_sdk/models/content_item.py +130 -0
  188. qanswer_sdk/models/content_item_type.py +39 -0
  189. qanswer_sdk/models/conversation_message.py +259 -0
  190. qanswer_sdk/models/conversation_message_error_key.py +52 -0
  191. qanswer_sdk/models/conversation_message_search_result.py +121 -0
  192. qanswer_sdk/models/conversation_model.py +169 -0
  193. qanswer_sdk/models/conversation_overall_stats.py +97 -0
  194. qanswer_sdk/models/conversation_overall_stats_response.py +95 -0
  195. qanswer_sdk/models/conversation_retention_response.py +91 -0
  196. qanswer_sdk/models/conversation_statistics.py +95 -0
  197. qanswer_sdk/models/conversation_update.py +93 -0
  198. qanswer_sdk/models/conversation_users_stats.py +99 -0
  199. qanswer_sdk/models/conversation_users_stats_response.py +99 -0
  200. qanswer_sdk/models/coordinates.py +89 -0
  201. qanswer_sdk/models/cost_summary_dto.py +99 -0
  202. qanswer_sdk/models/create_connector_request.py +95 -0
  203. qanswer_sdk/models/create_connector_response.py +95 -0
  204. qanswer_sdk/models/create_dataset_request.py +145 -0
  205. qanswer_sdk/models/create_imap_connector_request.py +105 -0
  206. qanswer_sdk/models/create_pinecone_connector_request.py +97 -0
  207. qanswer_sdk/models/create_sharepoint_connector_from_certificate_request.py +105 -0
  208. qanswer_sdk/models/create_sharepoint_connector_request.py +103 -0
  209. qanswer_sdk/models/credits_info_global_dto.py +97 -0
  210. qanswer_sdk/models/credits_info_organization_dto.py +95 -0
  211. qanswer_sdk/models/currency.py +38 -0
  212. qanswer_sdk/models/data_filling_mode.py +39 -0
  213. qanswer_sdk/models/data_storage_preference.py +38 -0
  214. qanswer_sdk/models/dataset_config_request.py +138 -0
  215. qanswer_sdk/models/dataset_default_values_model.py +138 -0
  216. qanswer_sdk/models/dataset_detail.py +137 -0
  217. qanswer_sdk/models/dataset_detail_kg.py +97 -0
  218. qanswer_sdk/models/dataset_schema.py +242 -0
  219. qanswer_sdk/models/dataset_size_response.py +91 -0
  220. qanswer_sdk/models/dataset_type.py +38 -0
  221. qanswer_sdk/models/dataset_update_object.py +216 -0
  222. qanswer_sdk/models/dataset_users_response.py +87 -0
  223. qanswer_sdk/models/default_prompt.py +106 -0
  224. qanswer_sdk/models/delete_connector_model.py +96 -0
  225. qanswer_sdk/models/delete_connector_request.py +99 -0
  226. qanswer_sdk/models/delete_connectors_response.py +89 -0
  227. qanswer_sdk/models/delete_files_status_response.py +91 -0
  228. qanswer_sdk/models/delete_index.py +91 -0
  229. qanswer_sdk/models/delete_index_resp.py +89 -0
  230. qanswer_sdk/models/delete_qn_a_pair_request.py +95 -0
  231. qanswer_sdk/models/delete_qn_a_pair_response.py +89 -0
  232. qanswer_sdk/models/delete_synonym.py +93 -0
  233. qanswer_sdk/models/delete_synonym_resp.py +89 -0
  234. qanswer_sdk/models/delete_synonyms.py +91 -0
  235. qanswer_sdk/models/delete_user_response.py +89 -0
  236. qanswer_sdk/models/diarization_queue_status.py +99 -0
  237. qanswer_sdk/models/document_content_response.py +91 -0
  238. qanswer_sdk/models/document_content_update_model.py +99 -0
  239. qanswer_sdk/models/document_file_delete_by_connector_model.py +101 -0
  240. qanswer_sdk/models/document_file_delete_by_id_model.py +91 -0
  241. qanswer_sdk/models/document_metadata.py +173 -0
  242. qanswer_sdk/models/document_metadata_list_wrapper.py +100 -0
  243. qanswer_sdk/models/document_parsing_task_settings.py +130 -0
  244. qanswer_sdk/models/document_parsing_task_settings_update_payload.py +95 -0
  245. qanswer_sdk/models/document_parsing_task_update.py +127 -0
  246. qanswer_sdk/models/document_status_response.py +89 -0
  247. qanswer_sdk/models/dummy_error.py +89 -0
  248. qanswer_sdk/models/duplicate_report_template_payload.py +97 -0
  249. qanswer_sdk/models/duplicate_report_template_response.py +87 -0
  250. qanswer_sdk/models/e_consilium_connector_config.py +108 -0
  251. qanswer_sdk/models/e_consilium_search_index_search_response.py +113 -0
  252. qanswer_sdk/models/econsilium_file_metadata.py +105 -0
  253. qanswer_sdk/models/econsilium_search_index_add_payload.py +107 -0
  254. qanswer_sdk/models/econsilium_search_index_additional_fields.py +103 -0
  255. qanswer_sdk/models/email_folder.py +91 -0
  256. qanswer_sdk/models/email_request.py +87 -0
  257. qanswer_sdk/models/embedder_cost_entry.py +91 -0
  258. qanswer_sdk/models/embedder_cost_filter.py +112 -0
  259. qanswer_sdk/models/embedder_cost_list.py +111 -0
  260. qanswer_sdk/models/embedder_create_dto.py +149 -0
  261. qanswer_sdk/models/embedder_detailed_dto.py +171 -0
  262. qanswer_sdk/models/embedder_dto.py +101 -0
  263. qanswer_sdk/models/embedder_list_dto.py +101 -0
  264. qanswer_sdk/models/embedder_update_dto.py +143 -0
  265. qanswer_sdk/models/embedding_endpoint.py +149 -0
  266. qanswer_sdk/models/embedding_endpoint_create.py +147 -0
  267. qanswer_sdk/models/embedding_endpoint_export_payload.py +87 -0
  268. qanswer_sdk/models/embedding_endpoint_import_failure.py +89 -0
  269. qanswer_sdk/models/embedding_endpoint_import_response.py +99 -0
  270. qanswer_sdk/models/embedding_endpoint_modality.py +37 -0
  271. qanswer_sdk/models/embedding_endpoint_names_validation_payload.py +87 -0
  272. qanswer_sdk/models/embedding_endpoint_update.py +141 -0
  273. qanswer_sdk/models/embedding_endpoint_validation_response.py +96 -0
  274. qanswer_sdk/models/embedding_model.py +96 -0
  275. qanswer_sdk/models/embedding_provider.py +44 -0
  276. qanswer_sdk/models/enable_enhanced_context_payload.py +91 -0
  277. qanswer_sdk/models/enable_enhanced_context_response.py +87 -0
  278. qanswer_sdk/models/endpoint_status.py +38 -0
  279. qanswer_sdk/models/entity_description.py +93 -0
  280. qanswer_sdk/models/entity_description_dto.py +93 -0
  281. qanswer_sdk/models/entity_linking_payload.py +97 -0
  282. qanswer_sdk/models/entity_linking_response.py +97 -0
  283. qanswer_sdk/models/entity_model_in_linking.py +95 -0
  284. qanswer_sdk/models/es_meta_data.py +98 -0
  285. qanswer_sdk/models/es_meta_data_value.py +87 -0
  286. qanswer_sdk/models/evaluate_feedback_response.py +109 -0
  287. qanswer_sdk/models/evaluate_single_feedback_response.py +97 -0
  288. qanswer_sdk/models/external_sources_quota_request.py +91 -0
  289. qanswer_sdk/models/external_sources_quota_response.py +89 -0
  290. qanswer_sdk/models/extra_body.py +91 -0
  291. qanswer_sdk/models/extract_hyper_links_payload.py +100 -0
  292. qanswer_sdk/models/extract_robot_links_payload.py +88 -0
  293. qanswer_sdk/models/extract_robot_links_response.py +88 -0
  294. qanswer_sdk/models/fact.py +96 -0
  295. qanswer_sdk/models/feedback_evaluation_history_entries_response.py +101 -0
  296. qanswer_sdk/models/feedback_evaluation_history_entry_model.py +105 -0
  297. qanswer_sdk/models/feedback_model.py +141 -0
  298. qanswer_sdk/models/feedback_response.py +95 -0
  299. qanswer_sdk/models/feedback_update.py +105 -0
  300. qanswer_sdk/models/file_es_meta_data.py +116 -0
  301. qanswer_sdk/models/file_failure_reason.py +48 -0
  302. qanswer_sdk/models/file_folder_model.py +115 -0
  303. qanswer_sdk/models/file_model.py +130 -0
  304. qanswer_sdk/models/file_status.py +43 -0
  305. qanswer_sdk/models/file_type.py +37 -0
  306. qanswer_sdk/models/file_upload_payload.py +107 -0
  307. qanswer_sdk/models/files_by_connector_model.py +89 -0
  308. qanswer_sdk/models/g_drive_connector_info.py +96 -0
  309. qanswer_sdk/models/g_drive_download_by_ids.py +89 -0
  310. qanswer_sdk/models/g_drive_download_request.py +103 -0
  311. qanswer_sdk/models/generate_ai_cells_by_dimension_payload.py +91 -0
  312. qanswer_sdk/models/generate_ai_cells_payload.py +95 -0
  313. qanswer_sdk/models/generation_params.py +89 -0
  314. qanswer_sdk/models/get_aggregations_payload.py +104 -0
  315. qanswer_sdk/models/get_connector_by_id_response.py +91 -0
  316. qanswer_sdk/models/get_conversation_response.py +95 -0
  317. qanswer_sdk/models/global_config_dto.py +135 -0
  318. qanswer_sdk/models/google_drive_connector_config.py +110 -0
  319. qanswer_sdk/models/guardrail_endpoint.py +121 -0
  320. qanswer_sdk/models/guardrail_mode.py +38 -0
  321. qanswer_sdk/models/highlight_audio_payload_model.py +109 -0
  322. qanswer_sdk/models/http_validation_error.py +95 -0
  323. qanswer_sdk/models/iframe_strategy.py +38 -0
  324. qanswer_sdk/models/image_url_detail.py +38 -0
  325. qanswer_sdk/models/imap_add_payload.py +105 -0
  326. qanswer_sdk/models/imap_additional_fields.py +101 -0
  327. qanswer_sdk/models/imap_file_metadata.py +114 -0
  328. qanswer_sdk/models/imap_search_response.py +113 -0
  329. qanswer_sdk/models/index_config.py +89 -0
  330. qanswer_sdk/models/install_response.py +89 -0
  331. qanswer_sdk/models/interface_origin.py +48 -0
  332. qanswer_sdk/models/ip2_geo_response.py +91 -0
  333. qanswer_sdk/models/is_enabled_response.py +87 -0
  334. qanswer_sdk/models/jwt_authentication_response.py +93 -0
  335. qanswer_sdk/models/label.py +89 -0
  336. qanswer_sdk/models/labeled_node.py +89 -0
  337. qanswer_sdk/models/language.py +42 -0
  338. qanswer_sdk/models/last_updated_template_conversation_id_response.py +87 -0
  339. qanswer_sdk/models/link.py +99 -0
  340. qanswer_sdk/models/link_extraction_response.py +97 -0
  341. qanswer_sdk/models/link_result_paginated.py +97 -0
  342. qanswer_sdk/models/linked_entity_model_in_linking.py +99 -0
  343. qanswer_sdk/models/linker.py +103 -0
  344. qanswer_sdk/models/linking_result_input.py +95 -0
  345. qanswer_sdk/models/linking_result_output.py +95 -0
  346. qanswer_sdk/models/links.py +99 -0
  347. qanswer_sdk/models/list_ai_templates_response.py +101 -0
  348. qanswer_sdk/models/list_connectors_response.py +95 -0
  349. qanswer_sdk/models/list_conversation_response.py +105 -0
  350. qanswer_sdk/models/list_feedback_response.py +105 -0
  351. qanswer_sdk/models/list_files_connector_response.py +107 -0
  352. qanswer_sdk/models/list_published_assistants_payload.py +115 -0
  353. qanswer_sdk/models/list_socket_events.py +95 -0
  354. qanswer_sdk/models/list_synonyms_model.py +95 -0
  355. qanswer_sdk/models/llm_context_ranges.py +93 -0
  356. qanswer_sdk/models/llm_context_ranges_response.py +93 -0
  357. qanswer_sdk/models/llm_cost_entry.py +97 -0
  358. qanswer_sdk/models/llm_cost_filter.py +112 -0
  359. qanswer_sdk/models/llm_cost_list.py +111 -0
  360. qanswer_sdk/models/llm_create_dto.py +208 -0
  361. qanswer_sdk/models/llm_detailed_dto.py +231 -0
  362. qanswer_sdk/models/llm_details.py +123 -0
  363. qanswer_sdk/models/llm_dto.py +147 -0
  364. qanswer_sdk/models/llm_endpoint.py +212 -0
  365. qanswer_sdk/models/llm_endpoint_create.py +204 -0
  366. qanswer_sdk/models/llm_endpoint_default_prompts.py +93 -0
  367. qanswer_sdk/models/llm_endpoint_export_payload.py +87 -0
  368. qanswer_sdk/models/llm_endpoint_import_failure.py +89 -0
  369. qanswer_sdk/models/llm_endpoint_import_response.py +99 -0
  370. qanswer_sdk/models/llm_endpoint_input.py +212 -0
  371. qanswer_sdk/models/llm_endpoint_modality.py +37 -0
  372. qanswer_sdk/models/llm_endpoint_names_validation_payload.py +87 -0
  373. qanswer_sdk/models/llm_endpoint_provider.py +44 -0
  374. qanswer_sdk/models/llm_endpoint_read_input.py +212 -0
  375. qanswer_sdk/models/llm_endpoint_read_output.py +212 -0
  376. qanswer_sdk/models/llm_endpoint_update.py +204 -0
  377. qanswer_sdk/models/llm_endpoint_usage_migration_response.py +93 -0
  378. qanswer_sdk/models/llm_endpoint_validation_response.py +96 -0
  379. qanswer_sdk/models/llm_filter_dto.py +111 -0
  380. qanswer_sdk/models/llm_health_response.py +89 -0
  381. qanswer_sdk/models/llm_list_detailed_dto.py +101 -0
  382. qanswer_sdk/models/llm_list_dto.py +101 -0
  383. qanswer_sdk/models/llm_update_dto.py +208 -0
  384. qanswer_sdk/models/llm_usage_origin.py +63 -0
  385. qanswer_sdk/models/location_details.py +97 -0
  386. qanswer_sdk/models/log_request.py +125 -0
  387. qanswer_sdk/models/login_request.py +89 -0
  388. qanswer_sdk/models/logs_visibility_policy.py +38 -0
  389. qanswer_sdk/models/logs_visibility_policy_payload.py +98 -0
  390. qanswer_sdk/models/logs_visibility_policy_response.py +98 -0
  391. qanswer_sdk/models/mcp_authentication_type.py +39 -0
  392. qanswer_sdk/models/mcp_connection.py +105 -0
  393. qanswer_sdk/models/mcp_connection_create.py +98 -0
  394. qanswer_sdk/models/mcp_server.py +167 -0
  395. qanswer_sdk/models/mcp_server0.py +167 -0
  396. qanswer_sdk/models/mcp_server_create.py +133 -0
  397. qanswer_sdk/models/mcp_server_dto.py +167 -0
  398. qanswer_sdk/models/mcp_server_type.py +37 -0
  399. qanswer_sdk/models/mcp_server_update.py +131 -0
  400. qanswer_sdk/models/mcp_tool_dto.py +141 -0
  401. qanswer_sdk/models/mcp_tool_info.py +95 -0
  402. qanswer_sdk/models/mcp_tool_selection_source.py +37 -0
  403. qanswer_sdk/models/mcp_tool_update.py +91 -0
  404. qanswer_sdk/models/mcp_transport.py +37 -0
  405. qanswer_sdk/models/mcp_visibility.py +38 -0
  406. qanswer_sdk/models/mcpo_auth2_initiating_origin.py +42 -0
  407. qanswer_sdk/models/message_role.py +38 -0
  408. qanswer_sdk/models/messages_stats_per_day_response.py +99 -0
  409. qanswer_sdk/models/microsoft_connector_config.py +110 -0
  410. qanswer_sdk/models/modify_connector_request.py +107 -0
  411. qanswer_sdk/models/modify_file_display_name_request.py +97 -0
  412. qanswer_sdk/models/notification_dto.py +137 -0
  413. qanswer_sdk/models/notification_filter.py +116 -0
  414. qanswer_sdk/models/notification_list_dto.py +101 -0
  415. qanswer_sdk/models/notification_payload_add_to_org_dto.py +87 -0
  416. qanswer_sdk/models/notification_payload_add_to_team_dto.py +89 -0
  417. qanswer_sdk/models/notification_payload_ai_assistant_shared_dto.py +109 -0
  418. qanswer_sdk/models/notification_payload_conversation_shared_dto.py +105 -0
  419. qanswer_sdk/models/notification_payload_dto.py +193 -0
  420. qanswer_sdk/models/notification_payload_human_takeover_requested_dto.py +89 -0
  421. qanswer_sdk/models/notification_payload_quota_reaching_dto.py +91 -0
  422. qanswer_sdk/models/notification_read_dto.py +89 -0
  423. qanswer_sdk/models/notification_type.py +44 -0
  424. qanswer_sdk/models/o_auth_redirect_response.py +89 -0
  425. qanswer_sdk/models/o_auth_service_dto.py +89 -0
  426. qanswer_sdk/models/one_drive_download_by_ids.py +89 -0
  427. qanswer_sdk/models/one_drive_download_request.py +103 -0
  428. qanswer_sdk/models/one_note_download_by_ids.py +91 -0
  429. qanswer_sdk/models/one_note_download_request.py +103 -0
  430. qanswer_sdk/models/org_llm_detailed_dto.py +105 -0
  431. qanswer_sdk/models/organization.py +93 -0
  432. qanswer_sdk/models/organization_creation.py +91 -0
  433. qanswer_sdk/models/organization_dto.py +93 -0
  434. qanswer_sdk/models/organization_filter_dto.py +134 -0
  435. qanswer_sdk/models/organization_list_dto.py +101 -0
  436. qanswer_sdk/models/paginated_report_templates.py +101 -0
  437. qanswer_sdk/models/password.py +89 -0
  438. qanswer_sdk/models/pinecone_index_model.py +91 -0
  439. qanswer_sdk/models/plan_dto.py +132 -0
  440. qanswer_sdk/models/predicted_class.py +89 -0
  441. qanswer_sdk/models/prepare_synonyms_upload_resp.py +99 -0
  442. qanswer_sdk/models/prepared_synonym_group.py +87 -0
  443. qanswer_sdk/models/pricing_plan.py +51 -0
  444. qanswer_sdk/models/pricing_type.py +38 -0
  445. qanswer_sdk/models/prompt_type.py +51 -0
  446. qanswer_sdk/models/provider.py +87 -0
  447. qanswer_sdk/models/publication_add_payload.py +105 -0
  448. qanswer_sdk/models/publication_file_metadata.py +105 -0
  449. qanswer_sdk/models/publication_office_additional_fields.py +111 -0
  450. qanswer_sdk/models/publication_office_connector_config.py +110 -0
  451. qanswer_sdk/models/publication_search_index_search_response.py +113 -0
  452. qanswer_sdk/models/published_assistant_from_java.py +94 -0
  453. qanswer_sdk/models/put_cell_payload.py +89 -0
  454. qanswer_sdk/models/qa_context.py +129 -0
  455. qanswer_sdk/models/qa_context_display_type.py +44 -0
  456. qanswer_sdk/models/qa_contexts.py +116 -0
  457. qanswer_sdk/models/qa_table.py +100 -0
  458. qanswer_sdk/models/qn_a_pair_model.py +103 -0
  459. qanswer_sdk/models/qn_a_pair_response.py +95 -0
  460. qanswer_sdk/models/question_suggestion_response.py +87 -0
  461. qanswer_sdk/models/rag_params.py +89 -0
  462. qanswer_sdk/models/rag_payload.py +186 -0
  463. qanswer_sdk/models/rag_response.py +155 -0
  464. qanswer_sdk/models/rdf_entity_linker_response.py +99 -0
  465. qanswer_sdk/models/rdf_linked_entity.py +97 -0
  466. qanswer_sdk/models/reasoning_effort.py +39 -0
  467. qanswer_sdk/models/reference_model.py +99 -0
  468. qanswer_sdk/models/refresh_frequency.py +39 -0
  469. qanswer_sdk/models/refresh_token_request.py +87 -0
  470. qanswer_sdk/models/refresh_website_connector_payload.py +94 -0
  471. qanswer_sdk/models/register_pinecone_connector_request.py +95 -0
  472. qanswer_sdk/models/report_copilot_generation_from_slots_ack.py +91 -0
  473. qanswer_sdk/models/report_copilot_generation_from_slots_payload.py +95 -0
  474. qanswer_sdk/models/report_copilot_refinement_payload.py +106 -0
  475. qanswer_sdk/models/report_copilot_refinement_response.py +87 -0
  476. qanswer_sdk/models/report_copilot_slot_feedback_update.py +95 -0
  477. qanswer_sdk/models/report_copilot_slot_feedback_update_response.py +95 -0
  478. qanswer_sdk/models/report_copilot_slot_task_settings.py +127 -0
  479. qanswer_sdk/models/report_copilot_slot_task_settings_update.py +127 -0
  480. qanswer_sdk/models/report_copilot_task_settings.py +125 -0
  481. qanswer_sdk/models/report_copilot_task_settings_update_payload.py +95 -0
  482. qanswer_sdk/models/report_copilot_task_update.py +125 -0
  483. qanswer_sdk/models/report_template.py +139 -0
  484. qanswer_sdk/models/report_template_create_payload.py +117 -0
  485. qanswer_sdk/models/report_template_image_upload_response.py +87 -0
  486. qanswer_sdk/models/report_template_simplified.py +115 -0
  487. qanswer_sdk/models/report_template_simplified_payload.py +91 -0
  488. qanswer_sdk/models/report_template_task_settings_update_payload.py +91 -0
  489. qanswer_sdk/models/report_template_update_payload.py +121 -0
  490. qanswer_sdk/models/report_templates_search_payload.py +106 -0
  491. qanswer_sdk/models/reset_password.py +87 -0
  492. qanswer_sdk/models/response_audit_model.py +99 -0
  493. qanswer_sdk/models/response_audit_stats_response.py +101 -0
  494. qanswer_sdk/models/response_get_dummy_union_connector_config_model_backend_api_connectors_config_dummy_models_union_get.py +228 -0
  495. qanswer_sdk/models/retreive_all_synonyms_resp.py +99 -0
  496. qanswer_sdk/models/retry_params.py +89 -0
  497. qanswer_sdk/models/return_type.py +38 -0
  498. qanswer_sdk/models/role.py +99 -0
  499. qanswer_sdk/models/role_name.py +37 -0
  500. qanswer_sdk/models/scrolling_strategy.py +37 -0
  501. qanswer_sdk/models/search_conversation_messages_response.py +105 -0
  502. qanswer_sdk/models/search_document_response.py +105 -0
  503. qanswer_sdk/models/search_index_payload.py +114 -0
  504. qanswer_sdk/models/search_metadata_filter.py +94 -0
  505. qanswer_sdk/models/search_payload.py +146 -0
  506. qanswer_sdk/models/search_response.py +125 -0
  507. qanswer_sdk/models/search_synonyms_resp.py +91 -0
  508. qanswer_sdk/models/search_task_settings.py +139 -0
  509. qanswer_sdk/models/search_task_settings_update_payload.py +95 -0
  510. qanswer_sdk/models/search_task_update.py +137 -0
  511. qanswer_sdk/models/sender_type.py +38 -0
  512. qanswer_sdk/models/share_point_connector_settings.py +94 -0
  513. qanswer_sdk/models/share_point_download_by_ids.py +99 -0
  514. qanswer_sdk/models/share_point_download_request.py +103 -0
  515. qanswer_sdk/models/shared_by.py +38 -0
  516. qanswer_sdk/models/shared_entity_type.py +38 -0
  517. qanswer_sdk/models/shared_organization_access.py +125 -0
  518. qanswer_sdk/models/shared_organization_access_dto.py +125 -0
  519. qanswer_sdk/models/shared_team_access.py +125 -0
  520. qanswer_sdk/models/shared_team_access_dto.py +125 -0
  521. qanswer_sdk/models/shared_user.py +99 -0
  522. qanswer_sdk/models/sign_up_request.py +108 -0
  523. qanswer_sdk/models/signout_request.py +87 -0
  524. qanswer_sdk/models/slot.py +162 -0
  525. qanswer_sdk/models/slot_history_entry.py +127 -0
  526. qanswer_sdk/models/slot_in_prompt.py +91 -0
  527. qanswer_sdk/models/slot_info_with_latest_version.py +95 -0
  528. qanswer_sdk/models/slot_update.py +142 -0
  529. qanswer_sdk/models/socker_join_user.py +91 -0
  530. qanswer_sdk/models/socket_ai_cell_generation.py +99 -0
  531. qanswer_sdk/models/socket_conversation_message.py +280 -0
  532. qanswer_sdk/models/socket_events_q_answer.py +51 -0
  533. qanswer_sdk/models/socket_feedback_evaluation_progress.py +114 -0
  534. qanswer_sdk/models/socket_file_metadata.py +207 -0
  535. qanswer_sdk/models/socket_join_conversation.py +97 -0
  536. qanswer_sdk/models/socket_join_dataset.py +93 -0
  537. qanswer_sdk/models/socket_message_status.py +40 -0
  538. qanswer_sdk/models/socket_notification.py +127 -0
  539. qanswer_sdk/models/socket_report_continuation_response.py +106 -0
  540. qanswer_sdk/models/socket_report_copilot_generation_from_slots_response.py +122 -0
  541. qanswer_sdk/models/socket_report_copilot_generation_from_template_response.py +122 -0
  542. qanswer_sdk/models/socket_report_copilot_refinement_response.py +108 -0
  543. qanswer_sdk/models/socket_speech2_text_response.py +131 -0
  544. qanswer_sdk/models/socket_stop_conversation.py +97 -0
  545. qanswer_sdk/models/source.py +125 -0
  546. qanswer_sdk/models/source_metadata.py +109 -0
  547. qanswer_sdk/models/speech2_text_response.py +119 -0
  548. qanswer_sdk/models/stat_per_date.py +89 -0
  549. qanswer_sdk/models/status_response.py +89 -0
  550. qanswer_sdk/models/stop_template_generation_payload.py +91 -0
  551. qanswer_sdk/models/storage_active_status.py +37 -0
  552. qanswer_sdk/models/subscription_response.py +101 -0
  553. qanswer_sdk/models/subscription_status.py +39 -0
  554. qanswer_sdk/models/suggestion_list_response.py +87 -0
  555. qanswer_sdk/models/summa_server.py +101 -0
  556. qanswer_sdk/models/task_category.py +58 -0
  557. qanswer_sdk/models/task_name.py +43 -0
  558. qanswer_sdk/models/team.py +93 -0
  559. qanswer_sdk/models/team_creation.py +89 -0
  560. qanswer_sdk/models/team_creation_dto.py +89 -0
  561. qanswer_sdk/models/team_dto.py +93 -0
  562. qanswer_sdk/models/team_filter_dto.py +141 -0
  563. qanswer_sdk/models/team_list_dto.py +101 -0
  564. qanswer_sdk/models/template_clip_structure.py +114 -0
  565. qanswer_sdk/models/template_toggle_request.py +93 -0
  566. qanswer_sdk/models/terms_bucket.py +94 -0
  567. qanswer_sdk/models/test_imap_connection_payload.py +95 -0
  568. qanswer_sdk/models/text2_sparql_payload.py +188 -0
  569. qanswer_sdk/models/text2_sparql_task_settings.py +125 -0
  570. qanswer_sdk/models/text2_sparql_task_settings_update_payload.py +95 -0
  571. qanswer_sdk/models/text2_sparql_task_update.py +125 -0
  572. qanswer_sdk/models/text_classification_payload.py +99 -0
  573. qanswer_sdk/models/text_classification_response.py +87 -0
  574. qanswer_sdk/models/text_classification_v2_payload.py +99 -0
  575. qanswer_sdk/models/text_classification_v2_response.py +95 -0
  576. qanswer_sdk/models/thinking_block.py +91 -0
  577. qanswer_sdk/models/tool_selection.py +89 -0
  578. qanswer_sdk/models/total_stat.py +96 -0
  579. qanswer_sdk/models/ui_mappings.py +141 -0
  580. qanswer_sdk/models/update_cells_payload.py +93 -0
  581. qanswer_sdk/models/update_file_es_meta_data.py +116 -0
  582. qanswer_sdk/models/update_metadata_model_input.py +97 -0
  583. qanswer_sdk/models/update_metadata_model_output.py +97 -0
  584. qanswer_sdk/models/update_qn_a_pair_request.py +101 -0
  585. qanswer_sdk/models/update_qn_a_pair_response.py +89 -0
  586. qanswer_sdk/models/update_synonyms.py +95 -0
  587. qanswer_sdk/models/update_synonyms_resp.py +89 -0
  588. qanswer_sdk/models/update_template_cells_payload.py +101 -0
  589. qanswer_sdk/models/upload_metadata.py +115 -0
  590. qanswer_sdk/models/user.py +91 -0
  591. qanswer_sdk/models/user_credits_config_dto.py +99 -0
  592. qanswer_sdk/models/user_credits_dto.py +106 -0
  593. qanswer_sdk/models/user_dataset_api_key.py +120 -0
  594. qanswer_sdk/models/user_dataset_api_key_dto.py +120 -0
  595. qanswer_sdk/models/user_dataset_mcp_tool_selection_dto.py +102 -0
  596. qanswer_sdk/models/user_dto.py +91 -0
  597. qanswer_sdk/models/user_filter_dto.py +155 -0
  598. qanswer_sdk/models/user_identity_availability.py +87 -0
  599. qanswer_sdk/models/user_info_dto.py +95 -0
  600. qanswer_sdk/models/user_list_dto.py +101 -0
  601. qanswer_sdk/models/user_log.py +102 -0
  602. qanswer_sdk/models/user_log_dto.py +102 -0
  603. qanswer_sdk/models/user_logs_list_dto.py +97 -0
  604. qanswer_sdk/models/user_mcp_tool_selection_dto.py +118 -0
  605. qanswer_sdk/models/user_oauth_token.py +96 -0
  606. qanswer_sdk/models/user_oauth_token_dto.py +96 -0
  607. qanswer_sdk/models/user_profile_dto.py +200 -0
  608. qanswer_sdk/models/user_profile_list_dto.py +101 -0
  609. qanswer_sdk/models/user_stat_per_date.py +90 -0
  610. qanswer_sdk/models/validation_error.py +108 -0
  611. qanswer_sdk/models/validation_error_loc_inner.py +138 -0
  612. qanswer_sdk/models/warn_visibility.py +40 -0
  613. qanswer_sdk/models/websearch_connector_config.py +102 -0
  614. qanswer_sdk/models/websearch_scraping_site.py +91 -0
  615. qanswer_sdk/models/website_add_payload.py +102 -0
  616. qanswer_sdk/models/website_connector_config.py +102 -0
  617. qanswer_sdk/models/website_connector_settings.py +160 -0
  618. qanswer_sdk/models/widget_configs.py +109 -0
  619. qanswer_sdk/py.typed +0 -0
  620. qanswer_sdk/rest.py +258 -0
  621. qanswer_sdk-0.46.0.dev0.dist-info/METADATA +252 -0
  622. qanswer_sdk-0.46.0.dev0.dist-info/RECORD +624 -0
  623. qanswer_sdk-0.46.0.dev0.dist-info/WHEEL +5 -0
  624. qanswer_sdk-0.46.0.dev0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,4408 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ free-text-client
5
+
6
+ QAnswer 2.0 API
7
+
8
+ The version of the OpenAPI document: 2.0.0
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import warnings
15
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
+ from typing import Any, Dict, List, Optional, Tuple, Union
17
+ from typing_extensions import Annotated
18
+
19
+ from pydantic import StrictBytes, StrictFloat, StrictInt, StrictStr
20
+ from typing import Any, Dict, List, Optional, Tuple, Union
21
+ from qanswer_sdk.models.aggregate import Aggregate
22
+ from qanswer_sdk.models.link_result_paginated import LinkResultPaginated
23
+ from qanswer_sdk.models.linker import Linker
24
+ from qanswer_sdk.models.linking_result_input import LinkingResultInput
25
+ from qanswer_sdk.models.linking_result_output import LinkingResultOutput
26
+
27
+ from qanswer_sdk.api_client import ApiClient, RequestSerialized
28
+ from qanswer_sdk.api_response import ApiResponse
29
+ from qanswer_sdk.rest import RESTResponseType
30
+
31
+
32
+ class TaskRDFLinkerApi:
33
+ """NOTE: This class is auto generated by OpenAPI Generator
34
+ Ref: https://openapi-generator.tech
35
+
36
+ Do not edit the class manually.
37
+ """
38
+
39
+ def __init__(self, api_client=None) -> None:
40
+ if api_client is None:
41
+ api_client = ApiClient.get_default()
42
+ self.api_client = api_client
43
+
44
+
45
+ @validate_call
46
+ def aggregate(
47
+ self,
48
+ username: StrictStr,
49
+ dataset: StrictStr,
50
+ linker: StrictStr,
51
+ _request_timeout: Union[
52
+ None,
53
+ Annotated[StrictFloat, Field(gt=0)],
54
+ Tuple[
55
+ Annotated[StrictFloat, Field(gt=0)],
56
+ Annotated[StrictFloat, Field(gt=0)]
57
+ ]
58
+ ] = None,
59
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
60
+ _content_type: Optional[StrictStr] = None,
61
+ _headers: Optional[Dict[StrictStr, Any]] = None,
62
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
63
+ ) -> List[Aggregate]:
64
+ """Get aggregation results
65
+
66
+
67
+ :param username: (required)
68
+ :type username: str
69
+ :param dataset: (required)
70
+ :type dataset: str
71
+ :param linker: (required)
72
+ :type linker: str
73
+ :param _request_timeout: timeout setting for this request. If one
74
+ number provided, it will be total request
75
+ timeout. It can also be a pair (tuple) of
76
+ (connection, read) timeouts.
77
+ :type _request_timeout: int, tuple(int, int), optional
78
+ :param _request_auth: set to override the auth_settings for an a single
79
+ request; this effectively ignores the
80
+ authentication in the spec for a single request.
81
+ :type _request_auth: dict, optional
82
+ :param _content_type: force content-type for the request.
83
+ :type _content_type: str, Optional
84
+ :param _headers: set to override the headers for a single
85
+ request; this effectively ignores the headers
86
+ in the spec for a single request.
87
+ :type _headers: dict, optional
88
+ :param _host_index: set to override the host_index for a single
89
+ request; this effectively ignores the host_index
90
+ in the spec for a single request.
91
+ :type _host_index: int, optional
92
+ :return: Returns the result object.
93
+ """ # noqa: E501
94
+
95
+ _param = self._aggregate_serialize(
96
+ username=username,
97
+ dataset=dataset,
98
+ linker=linker,
99
+ _request_auth=_request_auth,
100
+ _content_type=_content_type,
101
+ _headers=_headers,
102
+ _host_index=_host_index
103
+ )
104
+
105
+ _response_types_map: Dict[str, Optional[str]] = {
106
+ '200': "List[Aggregate]",
107
+ '422': "HTTPValidationError",
108
+ }
109
+ response_data = self.api_client.call_api(
110
+ *_param,
111
+ _request_timeout=_request_timeout
112
+ )
113
+ response_data.read()
114
+ return self.api_client.response_deserialize(
115
+ response_data=response_data,
116
+ response_types_map=_response_types_map,
117
+ ).data
118
+
119
+
120
+ @validate_call
121
+ def aggregate_with_http_info(
122
+ self,
123
+ username: StrictStr,
124
+ dataset: StrictStr,
125
+ linker: StrictStr,
126
+ _request_timeout: Union[
127
+ None,
128
+ Annotated[StrictFloat, Field(gt=0)],
129
+ Tuple[
130
+ Annotated[StrictFloat, Field(gt=0)],
131
+ Annotated[StrictFloat, Field(gt=0)]
132
+ ]
133
+ ] = None,
134
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
135
+ _content_type: Optional[StrictStr] = None,
136
+ _headers: Optional[Dict[StrictStr, Any]] = None,
137
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
138
+ ) -> ApiResponse[List[Aggregate]]:
139
+ """Get aggregation results
140
+
141
+
142
+ :param username: (required)
143
+ :type username: str
144
+ :param dataset: (required)
145
+ :type dataset: str
146
+ :param linker: (required)
147
+ :type linker: str
148
+ :param _request_timeout: timeout setting for this request. If one
149
+ number provided, it will be total request
150
+ timeout. It can also be a pair (tuple) of
151
+ (connection, read) timeouts.
152
+ :type _request_timeout: int, tuple(int, int), optional
153
+ :param _request_auth: set to override the auth_settings for an a single
154
+ request; this effectively ignores the
155
+ authentication in the spec for a single request.
156
+ :type _request_auth: dict, optional
157
+ :param _content_type: force content-type for the request.
158
+ :type _content_type: str, Optional
159
+ :param _headers: set to override the headers for a single
160
+ request; this effectively ignores the headers
161
+ in the spec for a single request.
162
+ :type _headers: dict, optional
163
+ :param _host_index: set to override the host_index for a single
164
+ request; this effectively ignores the host_index
165
+ in the spec for a single request.
166
+ :type _host_index: int, optional
167
+ :return: Returns the result object.
168
+ """ # noqa: E501
169
+
170
+ _param = self._aggregate_serialize(
171
+ username=username,
172
+ dataset=dataset,
173
+ linker=linker,
174
+ _request_auth=_request_auth,
175
+ _content_type=_content_type,
176
+ _headers=_headers,
177
+ _host_index=_host_index
178
+ )
179
+
180
+ _response_types_map: Dict[str, Optional[str]] = {
181
+ '200': "List[Aggregate]",
182
+ '422': "HTTPValidationError",
183
+ }
184
+ response_data = self.api_client.call_api(
185
+ *_param,
186
+ _request_timeout=_request_timeout
187
+ )
188
+ response_data.read()
189
+ return self.api_client.response_deserialize(
190
+ response_data=response_data,
191
+ response_types_map=_response_types_map,
192
+ )
193
+
194
+
195
+ @validate_call
196
+ def aggregate_without_preload_content(
197
+ self,
198
+ username: StrictStr,
199
+ dataset: StrictStr,
200
+ linker: StrictStr,
201
+ _request_timeout: Union[
202
+ None,
203
+ Annotated[StrictFloat, Field(gt=0)],
204
+ Tuple[
205
+ Annotated[StrictFloat, Field(gt=0)],
206
+ Annotated[StrictFloat, Field(gt=0)]
207
+ ]
208
+ ] = None,
209
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
210
+ _content_type: Optional[StrictStr] = None,
211
+ _headers: Optional[Dict[StrictStr, Any]] = None,
212
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
213
+ ) -> RESTResponseType:
214
+ """Get aggregation results
215
+
216
+
217
+ :param username: (required)
218
+ :type username: str
219
+ :param dataset: (required)
220
+ :type dataset: str
221
+ :param linker: (required)
222
+ :type linker: str
223
+ :param _request_timeout: timeout setting for this request. If one
224
+ number provided, it will be total request
225
+ timeout. It can also be a pair (tuple) of
226
+ (connection, read) timeouts.
227
+ :type _request_timeout: int, tuple(int, int), optional
228
+ :param _request_auth: set to override the auth_settings for an a single
229
+ request; this effectively ignores the
230
+ authentication in the spec for a single request.
231
+ :type _request_auth: dict, optional
232
+ :param _content_type: force content-type for the request.
233
+ :type _content_type: str, Optional
234
+ :param _headers: set to override the headers for a single
235
+ request; this effectively ignores the headers
236
+ in the spec for a single request.
237
+ :type _headers: dict, optional
238
+ :param _host_index: set to override the host_index for a single
239
+ request; this effectively ignores the host_index
240
+ in the spec for a single request.
241
+ :type _host_index: int, optional
242
+ :return: Returns the result object.
243
+ """ # noqa: E501
244
+
245
+ _param = self._aggregate_serialize(
246
+ username=username,
247
+ dataset=dataset,
248
+ linker=linker,
249
+ _request_auth=_request_auth,
250
+ _content_type=_content_type,
251
+ _headers=_headers,
252
+ _host_index=_host_index
253
+ )
254
+
255
+ _response_types_map: Dict[str, Optional[str]] = {
256
+ '200': "List[Aggregate]",
257
+ '422': "HTTPValidationError",
258
+ }
259
+ response_data = self.api_client.call_api(
260
+ *_param,
261
+ _request_timeout=_request_timeout
262
+ )
263
+ return response_data.response
264
+
265
+
266
+ def _aggregate_serialize(
267
+ self,
268
+ username,
269
+ dataset,
270
+ linker,
271
+ _request_auth,
272
+ _content_type,
273
+ _headers,
274
+ _host_index,
275
+ ) -> RequestSerialized:
276
+
277
+ _host = None
278
+
279
+ _collection_formats: Dict[str, str] = {
280
+ }
281
+
282
+ _path_params: Dict[str, str] = {}
283
+ _query_params: List[Tuple[str, str]] = []
284
+ _header_params: Dict[str, Optional[str]] = _headers or {}
285
+ _form_params: List[Tuple[str, str]] = []
286
+ _files: Dict[
287
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
288
+ ] = {}
289
+ _body_params: Optional[bytes] = None
290
+
291
+ # process the path parameters
292
+ # process the query parameters
293
+ if username is not None:
294
+
295
+ _query_params.append(('username', username))
296
+
297
+ if dataset is not None:
298
+
299
+ _query_params.append(('dataset', dataset))
300
+
301
+ if linker is not None:
302
+
303
+ _query_params.append(('linker', linker))
304
+
305
+ # process the header parameters
306
+ # process the form parameters
307
+ # process the body parameter
308
+
309
+
310
+ # set the HTTP header `Accept`
311
+ if 'Accept' not in _header_params:
312
+ _header_params['Accept'] = self.api_client.select_header_accept(
313
+ [
314
+ 'application/json'
315
+ ]
316
+ )
317
+
318
+
319
+ # authentication setting
320
+ _auth_settings: List[str] = [
321
+ 'QAnswer-Api-Key',
322
+ 'Bearer token'
323
+ ]
324
+
325
+ return self.api_client.param_serialize(
326
+ method='GET',
327
+ resource_path='/backend/api/tasks/rdf/linker/aggregate',
328
+ path_params=_path_params,
329
+ query_params=_query_params,
330
+ header_params=_header_params,
331
+ body=_body_params,
332
+ post_params=_form_params,
333
+ files=_files,
334
+ auth_settings=_auth_settings,
335
+ collection_formats=_collection_formats,
336
+ _host=_host,
337
+ _request_auth=_request_auth
338
+ )
339
+
340
+
341
+
342
+
343
+ @validate_call
344
+ def analyze(
345
+ self,
346
+ username: StrictStr,
347
+ dataset: StrictStr,
348
+ linker: StrictStr,
349
+ _request_timeout: Union[
350
+ None,
351
+ Annotated[StrictFloat, Field(gt=0)],
352
+ Tuple[
353
+ Annotated[StrictFloat, Field(gt=0)],
354
+ Annotated[StrictFloat, Field(gt=0)]
355
+ ]
356
+ ] = None,
357
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
358
+ _content_type: Optional[StrictStr] = None,
359
+ _headers: Optional[Dict[StrictStr, Any]] = None,
360
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
361
+ ) -> LinkingResultOutput:
362
+ """Analyze data for linking
363
+
364
+
365
+ :param username: (required)
366
+ :type username: str
367
+ :param dataset: (required)
368
+ :type dataset: str
369
+ :param linker: (required)
370
+ :type linker: str
371
+ :param _request_timeout: timeout setting for this request. If one
372
+ number provided, it will be total request
373
+ timeout. It can also be a pair (tuple) of
374
+ (connection, read) timeouts.
375
+ :type _request_timeout: int, tuple(int, int), optional
376
+ :param _request_auth: set to override the auth_settings for an a single
377
+ request; this effectively ignores the
378
+ authentication in the spec for a single request.
379
+ :type _request_auth: dict, optional
380
+ :param _content_type: force content-type for the request.
381
+ :type _content_type: str, Optional
382
+ :param _headers: set to override the headers for a single
383
+ request; this effectively ignores the headers
384
+ in the spec for a single request.
385
+ :type _headers: dict, optional
386
+ :param _host_index: set to override the host_index for a single
387
+ request; this effectively ignores the host_index
388
+ in the spec for a single request.
389
+ :type _host_index: int, optional
390
+ :return: Returns the result object.
391
+ """ # noqa: E501
392
+
393
+ _param = self._analyze_serialize(
394
+ username=username,
395
+ dataset=dataset,
396
+ linker=linker,
397
+ _request_auth=_request_auth,
398
+ _content_type=_content_type,
399
+ _headers=_headers,
400
+ _host_index=_host_index
401
+ )
402
+
403
+ _response_types_map: Dict[str, Optional[str]] = {
404
+ '200': "LinkingResultOutput",
405
+ '422': "HTTPValidationError",
406
+ }
407
+ response_data = self.api_client.call_api(
408
+ *_param,
409
+ _request_timeout=_request_timeout
410
+ )
411
+ response_data.read()
412
+ return self.api_client.response_deserialize(
413
+ response_data=response_data,
414
+ response_types_map=_response_types_map,
415
+ ).data
416
+
417
+
418
+ @validate_call
419
+ def analyze_with_http_info(
420
+ self,
421
+ username: StrictStr,
422
+ dataset: StrictStr,
423
+ linker: StrictStr,
424
+ _request_timeout: Union[
425
+ None,
426
+ Annotated[StrictFloat, Field(gt=0)],
427
+ Tuple[
428
+ Annotated[StrictFloat, Field(gt=0)],
429
+ Annotated[StrictFloat, Field(gt=0)]
430
+ ]
431
+ ] = None,
432
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
433
+ _content_type: Optional[StrictStr] = None,
434
+ _headers: Optional[Dict[StrictStr, Any]] = None,
435
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
436
+ ) -> ApiResponse[LinkingResultOutput]:
437
+ """Analyze data for linking
438
+
439
+
440
+ :param username: (required)
441
+ :type username: str
442
+ :param dataset: (required)
443
+ :type dataset: str
444
+ :param linker: (required)
445
+ :type linker: str
446
+ :param _request_timeout: timeout setting for this request. If one
447
+ number provided, it will be total request
448
+ timeout. It can also be a pair (tuple) of
449
+ (connection, read) timeouts.
450
+ :type _request_timeout: int, tuple(int, int), optional
451
+ :param _request_auth: set to override the auth_settings for an a single
452
+ request; this effectively ignores the
453
+ authentication in the spec for a single request.
454
+ :type _request_auth: dict, optional
455
+ :param _content_type: force content-type for the request.
456
+ :type _content_type: str, Optional
457
+ :param _headers: set to override the headers for a single
458
+ request; this effectively ignores the headers
459
+ in the spec for a single request.
460
+ :type _headers: dict, optional
461
+ :param _host_index: set to override the host_index for a single
462
+ request; this effectively ignores the host_index
463
+ in the spec for a single request.
464
+ :type _host_index: int, optional
465
+ :return: Returns the result object.
466
+ """ # noqa: E501
467
+
468
+ _param = self._analyze_serialize(
469
+ username=username,
470
+ dataset=dataset,
471
+ linker=linker,
472
+ _request_auth=_request_auth,
473
+ _content_type=_content_type,
474
+ _headers=_headers,
475
+ _host_index=_host_index
476
+ )
477
+
478
+ _response_types_map: Dict[str, Optional[str]] = {
479
+ '200': "LinkingResultOutput",
480
+ '422': "HTTPValidationError",
481
+ }
482
+ response_data = self.api_client.call_api(
483
+ *_param,
484
+ _request_timeout=_request_timeout
485
+ )
486
+ response_data.read()
487
+ return self.api_client.response_deserialize(
488
+ response_data=response_data,
489
+ response_types_map=_response_types_map,
490
+ )
491
+
492
+
493
+ @validate_call
494
+ def analyze_without_preload_content(
495
+ self,
496
+ username: StrictStr,
497
+ dataset: StrictStr,
498
+ linker: StrictStr,
499
+ _request_timeout: Union[
500
+ None,
501
+ Annotated[StrictFloat, Field(gt=0)],
502
+ Tuple[
503
+ Annotated[StrictFloat, Field(gt=0)],
504
+ Annotated[StrictFloat, Field(gt=0)]
505
+ ]
506
+ ] = None,
507
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
508
+ _content_type: Optional[StrictStr] = None,
509
+ _headers: Optional[Dict[StrictStr, Any]] = None,
510
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
511
+ ) -> RESTResponseType:
512
+ """Analyze data for linking
513
+
514
+
515
+ :param username: (required)
516
+ :type username: str
517
+ :param dataset: (required)
518
+ :type dataset: str
519
+ :param linker: (required)
520
+ :type linker: str
521
+ :param _request_timeout: timeout setting for this request. If one
522
+ number provided, it will be total request
523
+ timeout. It can also be a pair (tuple) of
524
+ (connection, read) timeouts.
525
+ :type _request_timeout: int, tuple(int, int), optional
526
+ :param _request_auth: set to override the auth_settings for an a single
527
+ request; this effectively ignores the
528
+ authentication in the spec for a single request.
529
+ :type _request_auth: dict, optional
530
+ :param _content_type: force content-type for the request.
531
+ :type _content_type: str, Optional
532
+ :param _headers: set to override the headers for a single
533
+ request; this effectively ignores the headers
534
+ in the spec for a single request.
535
+ :type _headers: dict, optional
536
+ :param _host_index: set to override the host_index for a single
537
+ request; this effectively ignores the host_index
538
+ in the spec for a single request.
539
+ :type _host_index: int, optional
540
+ :return: Returns the result object.
541
+ """ # noqa: E501
542
+
543
+ _param = self._analyze_serialize(
544
+ username=username,
545
+ dataset=dataset,
546
+ linker=linker,
547
+ _request_auth=_request_auth,
548
+ _content_type=_content_type,
549
+ _headers=_headers,
550
+ _host_index=_host_index
551
+ )
552
+
553
+ _response_types_map: Dict[str, Optional[str]] = {
554
+ '200': "LinkingResultOutput",
555
+ '422': "HTTPValidationError",
556
+ }
557
+ response_data = self.api_client.call_api(
558
+ *_param,
559
+ _request_timeout=_request_timeout
560
+ )
561
+ return response_data.response
562
+
563
+
564
+ def _analyze_serialize(
565
+ self,
566
+ username,
567
+ dataset,
568
+ linker,
569
+ _request_auth,
570
+ _content_type,
571
+ _headers,
572
+ _host_index,
573
+ ) -> RequestSerialized:
574
+
575
+ _host = None
576
+
577
+ _collection_formats: Dict[str, str] = {
578
+ }
579
+
580
+ _path_params: Dict[str, str] = {}
581
+ _query_params: List[Tuple[str, str]] = []
582
+ _header_params: Dict[str, Optional[str]] = _headers or {}
583
+ _form_params: List[Tuple[str, str]] = []
584
+ _files: Dict[
585
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
586
+ ] = {}
587
+ _body_params: Optional[bytes] = None
588
+
589
+ # process the path parameters
590
+ # process the query parameters
591
+ if username is not None:
592
+
593
+ _query_params.append(('username', username))
594
+
595
+ if dataset is not None:
596
+
597
+ _query_params.append(('dataset', dataset))
598
+
599
+ if linker is not None:
600
+
601
+ _query_params.append(('linker', linker))
602
+
603
+ # process the header parameters
604
+ # process the form parameters
605
+ # process the body parameter
606
+
607
+
608
+ # set the HTTP header `Accept`
609
+ if 'Accept' not in _header_params:
610
+ _header_params['Accept'] = self.api_client.select_header_accept(
611
+ [
612
+ 'application/json'
613
+ ]
614
+ )
615
+
616
+
617
+ # authentication setting
618
+ _auth_settings: List[str] = [
619
+ 'QAnswer-Api-Key',
620
+ 'Bearer token'
621
+ ]
622
+
623
+ return self.api_client.param_serialize(
624
+ method='POST',
625
+ resource_path='/backend/api/tasks/rdf/linker/analyze',
626
+ path_params=_path_params,
627
+ query_params=_query_params,
628
+ header_params=_header_params,
629
+ body=_body_params,
630
+ post_params=_form_params,
631
+ files=_files,
632
+ auth_settings=_auth_settings,
633
+ collection_formats=_collection_formats,
634
+ _host=_host,
635
+ _request_auth=_request_auth
636
+ )
637
+
638
+
639
+
640
+
641
+ @validate_call
642
+ def delete_linker(
643
+ self,
644
+ username: StrictStr,
645
+ dataset: StrictStr,
646
+ linker: StrictStr,
647
+ _request_timeout: Union[
648
+ None,
649
+ Annotated[StrictFloat, Field(gt=0)],
650
+ Tuple[
651
+ Annotated[StrictFloat, Field(gt=0)],
652
+ Annotated[StrictFloat, Field(gt=0)]
653
+ ]
654
+ ] = None,
655
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
656
+ _content_type: Optional[StrictStr] = None,
657
+ _headers: Optional[Dict[StrictStr, Any]] = None,
658
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
659
+ ) -> str:
660
+ """Delete a linker
661
+
662
+
663
+ :param username: (required)
664
+ :type username: str
665
+ :param dataset: (required)
666
+ :type dataset: str
667
+ :param linker: (required)
668
+ :type linker: str
669
+ :param _request_timeout: timeout setting for this request. If one
670
+ number provided, it will be total request
671
+ timeout. It can also be a pair (tuple) of
672
+ (connection, read) timeouts.
673
+ :type _request_timeout: int, tuple(int, int), optional
674
+ :param _request_auth: set to override the auth_settings for an a single
675
+ request; this effectively ignores the
676
+ authentication in the spec for a single request.
677
+ :type _request_auth: dict, optional
678
+ :param _content_type: force content-type for the request.
679
+ :type _content_type: str, Optional
680
+ :param _headers: set to override the headers for a single
681
+ request; this effectively ignores the headers
682
+ in the spec for a single request.
683
+ :type _headers: dict, optional
684
+ :param _host_index: set to override the host_index for a single
685
+ request; this effectively ignores the host_index
686
+ in the spec for a single request.
687
+ :type _host_index: int, optional
688
+ :return: Returns the result object.
689
+ """ # noqa: E501
690
+
691
+ _param = self._delete_linker_serialize(
692
+ username=username,
693
+ dataset=dataset,
694
+ linker=linker,
695
+ _request_auth=_request_auth,
696
+ _content_type=_content_type,
697
+ _headers=_headers,
698
+ _host_index=_host_index
699
+ )
700
+
701
+ _response_types_map: Dict[str, Optional[str]] = {
702
+ '200': "str",
703
+ '422': "HTTPValidationError",
704
+ }
705
+ response_data = self.api_client.call_api(
706
+ *_param,
707
+ _request_timeout=_request_timeout
708
+ )
709
+ response_data.read()
710
+ return self.api_client.response_deserialize(
711
+ response_data=response_data,
712
+ response_types_map=_response_types_map,
713
+ ).data
714
+
715
+
716
+ @validate_call
717
+ def delete_linker_with_http_info(
718
+ self,
719
+ username: StrictStr,
720
+ dataset: StrictStr,
721
+ linker: StrictStr,
722
+ _request_timeout: Union[
723
+ None,
724
+ Annotated[StrictFloat, Field(gt=0)],
725
+ Tuple[
726
+ Annotated[StrictFloat, Field(gt=0)],
727
+ Annotated[StrictFloat, Field(gt=0)]
728
+ ]
729
+ ] = None,
730
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
731
+ _content_type: Optional[StrictStr] = None,
732
+ _headers: Optional[Dict[StrictStr, Any]] = None,
733
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
734
+ ) -> ApiResponse[str]:
735
+ """Delete a linker
736
+
737
+
738
+ :param username: (required)
739
+ :type username: str
740
+ :param dataset: (required)
741
+ :type dataset: str
742
+ :param linker: (required)
743
+ :type linker: str
744
+ :param _request_timeout: timeout setting for this request. If one
745
+ number provided, it will be total request
746
+ timeout. It can also be a pair (tuple) of
747
+ (connection, read) timeouts.
748
+ :type _request_timeout: int, tuple(int, int), optional
749
+ :param _request_auth: set to override the auth_settings for an a single
750
+ request; this effectively ignores the
751
+ authentication in the spec for a single request.
752
+ :type _request_auth: dict, optional
753
+ :param _content_type: force content-type for the request.
754
+ :type _content_type: str, Optional
755
+ :param _headers: set to override the headers for a single
756
+ request; this effectively ignores the headers
757
+ in the spec for a single request.
758
+ :type _headers: dict, optional
759
+ :param _host_index: set to override the host_index for a single
760
+ request; this effectively ignores the host_index
761
+ in the spec for a single request.
762
+ :type _host_index: int, optional
763
+ :return: Returns the result object.
764
+ """ # noqa: E501
765
+
766
+ _param = self._delete_linker_serialize(
767
+ username=username,
768
+ dataset=dataset,
769
+ linker=linker,
770
+ _request_auth=_request_auth,
771
+ _content_type=_content_type,
772
+ _headers=_headers,
773
+ _host_index=_host_index
774
+ )
775
+
776
+ _response_types_map: Dict[str, Optional[str]] = {
777
+ '200': "str",
778
+ '422': "HTTPValidationError",
779
+ }
780
+ response_data = self.api_client.call_api(
781
+ *_param,
782
+ _request_timeout=_request_timeout
783
+ )
784
+ response_data.read()
785
+ return self.api_client.response_deserialize(
786
+ response_data=response_data,
787
+ response_types_map=_response_types_map,
788
+ )
789
+
790
+
791
+ @validate_call
792
+ def delete_linker_without_preload_content(
793
+ self,
794
+ username: StrictStr,
795
+ dataset: StrictStr,
796
+ linker: StrictStr,
797
+ _request_timeout: Union[
798
+ None,
799
+ Annotated[StrictFloat, Field(gt=0)],
800
+ Tuple[
801
+ Annotated[StrictFloat, Field(gt=0)],
802
+ Annotated[StrictFloat, Field(gt=0)]
803
+ ]
804
+ ] = None,
805
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
806
+ _content_type: Optional[StrictStr] = None,
807
+ _headers: Optional[Dict[StrictStr, Any]] = None,
808
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
809
+ ) -> RESTResponseType:
810
+ """Delete a linker
811
+
812
+
813
+ :param username: (required)
814
+ :type username: str
815
+ :param dataset: (required)
816
+ :type dataset: str
817
+ :param linker: (required)
818
+ :type linker: str
819
+ :param _request_timeout: timeout setting for this request. If one
820
+ number provided, it will be total request
821
+ timeout. It can also be a pair (tuple) of
822
+ (connection, read) timeouts.
823
+ :type _request_timeout: int, tuple(int, int), optional
824
+ :param _request_auth: set to override the auth_settings for an a single
825
+ request; this effectively ignores the
826
+ authentication in the spec for a single request.
827
+ :type _request_auth: dict, optional
828
+ :param _content_type: force content-type for the request.
829
+ :type _content_type: str, Optional
830
+ :param _headers: set to override the headers for a single
831
+ request; this effectively ignores the headers
832
+ in the spec for a single request.
833
+ :type _headers: dict, optional
834
+ :param _host_index: set to override the host_index for a single
835
+ request; this effectively ignores the host_index
836
+ in the spec for a single request.
837
+ :type _host_index: int, optional
838
+ :return: Returns the result object.
839
+ """ # noqa: E501
840
+
841
+ _param = self._delete_linker_serialize(
842
+ username=username,
843
+ dataset=dataset,
844
+ linker=linker,
845
+ _request_auth=_request_auth,
846
+ _content_type=_content_type,
847
+ _headers=_headers,
848
+ _host_index=_host_index
849
+ )
850
+
851
+ _response_types_map: Dict[str, Optional[str]] = {
852
+ '200': "str",
853
+ '422': "HTTPValidationError",
854
+ }
855
+ response_data = self.api_client.call_api(
856
+ *_param,
857
+ _request_timeout=_request_timeout
858
+ )
859
+ return response_data.response
860
+
861
+
862
+ def _delete_linker_serialize(
863
+ self,
864
+ username,
865
+ dataset,
866
+ linker,
867
+ _request_auth,
868
+ _content_type,
869
+ _headers,
870
+ _host_index,
871
+ ) -> RequestSerialized:
872
+
873
+ _host = None
874
+
875
+ _collection_formats: Dict[str, str] = {
876
+ }
877
+
878
+ _path_params: Dict[str, str] = {}
879
+ _query_params: List[Tuple[str, str]] = []
880
+ _header_params: Dict[str, Optional[str]] = _headers or {}
881
+ _form_params: List[Tuple[str, str]] = []
882
+ _files: Dict[
883
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
884
+ ] = {}
885
+ _body_params: Optional[bytes] = None
886
+
887
+ # process the path parameters
888
+ # process the query parameters
889
+ if username is not None:
890
+
891
+ _query_params.append(('username', username))
892
+
893
+ if dataset is not None:
894
+
895
+ _query_params.append(('dataset', dataset))
896
+
897
+ if linker is not None:
898
+
899
+ _query_params.append(('linker', linker))
900
+
901
+ # process the header parameters
902
+ # process the form parameters
903
+ # process the body parameter
904
+
905
+
906
+ # set the HTTP header `Accept`
907
+ if 'Accept' not in _header_params:
908
+ _header_params['Accept'] = self.api_client.select_header_accept(
909
+ [
910
+ 'application/json'
911
+ ]
912
+ )
913
+
914
+
915
+ # authentication setting
916
+ _auth_settings: List[str] = [
917
+ 'QAnswer-Api-Key',
918
+ 'Bearer token'
919
+ ]
920
+
921
+ return self.api_client.param_serialize(
922
+ method='DELETE',
923
+ resource_path='/backend/api/tasks/rdf/linker/delete',
924
+ path_params=_path_params,
925
+ query_params=_query_params,
926
+ header_params=_header_params,
927
+ body=_body_params,
928
+ post_params=_form_params,
929
+ files=_files,
930
+ auth_settings=_auth_settings,
931
+ collection_formats=_collection_formats,
932
+ _host=_host,
933
+ _request_auth=_request_auth
934
+ )
935
+
936
+
937
+
938
+
939
+ @validate_call
940
+ def evaluate_csv(
941
+ self,
942
+ username: StrictStr,
943
+ dataset: StrictStr,
944
+ linker: StrictStr,
945
+ _request_timeout: Union[
946
+ None,
947
+ Annotated[StrictFloat, Field(gt=0)],
948
+ Tuple[
949
+ Annotated[StrictFloat, Field(gt=0)],
950
+ Annotated[StrictFloat, Field(gt=0)]
951
+ ]
952
+ ] = None,
953
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
954
+ _content_type: Optional[StrictStr] = None,
955
+ _headers: Optional[Dict[StrictStr, Any]] = None,
956
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
957
+ ) -> object:
958
+ """Download linker data as CSV
959
+
960
+
961
+ :param username: (required)
962
+ :type username: str
963
+ :param dataset: (required)
964
+ :type dataset: str
965
+ :param linker: (required)
966
+ :type linker: str
967
+ :param _request_timeout: timeout setting for this request. If one
968
+ number provided, it will be total request
969
+ timeout. It can also be a pair (tuple) of
970
+ (connection, read) timeouts.
971
+ :type _request_timeout: int, tuple(int, int), optional
972
+ :param _request_auth: set to override the auth_settings for an a single
973
+ request; this effectively ignores the
974
+ authentication in the spec for a single request.
975
+ :type _request_auth: dict, optional
976
+ :param _content_type: force content-type for the request.
977
+ :type _content_type: str, Optional
978
+ :param _headers: set to override the headers for a single
979
+ request; this effectively ignores the headers
980
+ in the spec for a single request.
981
+ :type _headers: dict, optional
982
+ :param _host_index: set to override the host_index for a single
983
+ request; this effectively ignores the host_index
984
+ in the spec for a single request.
985
+ :type _host_index: int, optional
986
+ :return: Returns the result object.
987
+ """ # noqa: E501
988
+
989
+ _param = self._evaluate_csv_serialize(
990
+ username=username,
991
+ dataset=dataset,
992
+ linker=linker,
993
+ _request_auth=_request_auth,
994
+ _content_type=_content_type,
995
+ _headers=_headers,
996
+ _host_index=_host_index
997
+ )
998
+
999
+ _response_types_map: Dict[str, Optional[str]] = {
1000
+ '200': "object",
1001
+ '422': "HTTPValidationError",
1002
+ }
1003
+ response_data = self.api_client.call_api(
1004
+ *_param,
1005
+ _request_timeout=_request_timeout
1006
+ )
1007
+ response_data.read()
1008
+ return self.api_client.response_deserialize(
1009
+ response_data=response_data,
1010
+ response_types_map=_response_types_map,
1011
+ ).data
1012
+
1013
+
1014
+ @validate_call
1015
+ def evaluate_csv_with_http_info(
1016
+ self,
1017
+ username: StrictStr,
1018
+ dataset: StrictStr,
1019
+ linker: StrictStr,
1020
+ _request_timeout: Union[
1021
+ None,
1022
+ Annotated[StrictFloat, Field(gt=0)],
1023
+ Tuple[
1024
+ Annotated[StrictFloat, Field(gt=0)],
1025
+ Annotated[StrictFloat, Field(gt=0)]
1026
+ ]
1027
+ ] = None,
1028
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1029
+ _content_type: Optional[StrictStr] = None,
1030
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1031
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1032
+ ) -> ApiResponse[object]:
1033
+ """Download linker data as CSV
1034
+
1035
+
1036
+ :param username: (required)
1037
+ :type username: str
1038
+ :param dataset: (required)
1039
+ :type dataset: str
1040
+ :param linker: (required)
1041
+ :type linker: str
1042
+ :param _request_timeout: timeout setting for this request. If one
1043
+ number provided, it will be total request
1044
+ timeout. It can also be a pair (tuple) of
1045
+ (connection, read) timeouts.
1046
+ :type _request_timeout: int, tuple(int, int), optional
1047
+ :param _request_auth: set to override the auth_settings for an a single
1048
+ request; this effectively ignores the
1049
+ authentication in the spec for a single request.
1050
+ :type _request_auth: dict, optional
1051
+ :param _content_type: force content-type for the request.
1052
+ :type _content_type: str, Optional
1053
+ :param _headers: set to override the headers for a single
1054
+ request; this effectively ignores the headers
1055
+ in the spec for a single request.
1056
+ :type _headers: dict, optional
1057
+ :param _host_index: set to override the host_index for a single
1058
+ request; this effectively ignores the host_index
1059
+ in the spec for a single request.
1060
+ :type _host_index: int, optional
1061
+ :return: Returns the result object.
1062
+ """ # noqa: E501
1063
+
1064
+ _param = self._evaluate_csv_serialize(
1065
+ username=username,
1066
+ dataset=dataset,
1067
+ linker=linker,
1068
+ _request_auth=_request_auth,
1069
+ _content_type=_content_type,
1070
+ _headers=_headers,
1071
+ _host_index=_host_index
1072
+ )
1073
+
1074
+ _response_types_map: Dict[str, Optional[str]] = {
1075
+ '200': "object",
1076
+ '422': "HTTPValidationError",
1077
+ }
1078
+ response_data = self.api_client.call_api(
1079
+ *_param,
1080
+ _request_timeout=_request_timeout
1081
+ )
1082
+ response_data.read()
1083
+ return self.api_client.response_deserialize(
1084
+ response_data=response_data,
1085
+ response_types_map=_response_types_map,
1086
+ )
1087
+
1088
+
1089
+ @validate_call
1090
+ def evaluate_csv_without_preload_content(
1091
+ self,
1092
+ username: StrictStr,
1093
+ dataset: StrictStr,
1094
+ linker: StrictStr,
1095
+ _request_timeout: Union[
1096
+ None,
1097
+ Annotated[StrictFloat, Field(gt=0)],
1098
+ Tuple[
1099
+ Annotated[StrictFloat, Field(gt=0)],
1100
+ Annotated[StrictFloat, Field(gt=0)]
1101
+ ]
1102
+ ] = None,
1103
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1104
+ _content_type: Optional[StrictStr] = None,
1105
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1106
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1107
+ ) -> RESTResponseType:
1108
+ """Download linker data as CSV
1109
+
1110
+
1111
+ :param username: (required)
1112
+ :type username: str
1113
+ :param dataset: (required)
1114
+ :type dataset: str
1115
+ :param linker: (required)
1116
+ :type linker: str
1117
+ :param _request_timeout: timeout setting for this request. If one
1118
+ number provided, it will be total request
1119
+ timeout. It can also be a pair (tuple) of
1120
+ (connection, read) timeouts.
1121
+ :type _request_timeout: int, tuple(int, int), optional
1122
+ :param _request_auth: set to override the auth_settings for an a single
1123
+ request; this effectively ignores the
1124
+ authentication in the spec for a single request.
1125
+ :type _request_auth: dict, optional
1126
+ :param _content_type: force content-type for the request.
1127
+ :type _content_type: str, Optional
1128
+ :param _headers: set to override the headers for a single
1129
+ request; this effectively ignores the headers
1130
+ in the spec for a single request.
1131
+ :type _headers: dict, optional
1132
+ :param _host_index: set to override the host_index for a single
1133
+ request; this effectively ignores the host_index
1134
+ in the spec for a single request.
1135
+ :type _host_index: int, optional
1136
+ :return: Returns the result object.
1137
+ """ # noqa: E501
1138
+
1139
+ _param = self._evaluate_csv_serialize(
1140
+ username=username,
1141
+ dataset=dataset,
1142
+ linker=linker,
1143
+ _request_auth=_request_auth,
1144
+ _content_type=_content_type,
1145
+ _headers=_headers,
1146
+ _host_index=_host_index
1147
+ )
1148
+
1149
+ _response_types_map: Dict[str, Optional[str]] = {
1150
+ '200': "object",
1151
+ '422': "HTTPValidationError",
1152
+ }
1153
+ response_data = self.api_client.call_api(
1154
+ *_param,
1155
+ _request_timeout=_request_timeout
1156
+ )
1157
+ return response_data.response
1158
+
1159
+
1160
+ def _evaluate_csv_serialize(
1161
+ self,
1162
+ username,
1163
+ dataset,
1164
+ linker,
1165
+ _request_auth,
1166
+ _content_type,
1167
+ _headers,
1168
+ _host_index,
1169
+ ) -> RequestSerialized:
1170
+
1171
+ _host = None
1172
+
1173
+ _collection_formats: Dict[str, str] = {
1174
+ }
1175
+
1176
+ _path_params: Dict[str, str] = {}
1177
+ _query_params: List[Tuple[str, str]] = []
1178
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1179
+ _form_params: List[Tuple[str, str]] = []
1180
+ _files: Dict[
1181
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1182
+ ] = {}
1183
+ _body_params: Optional[bytes] = None
1184
+
1185
+ # process the path parameters
1186
+ # process the query parameters
1187
+ if username is not None:
1188
+
1189
+ _query_params.append(('username', username))
1190
+
1191
+ if dataset is not None:
1192
+
1193
+ _query_params.append(('dataset', dataset))
1194
+
1195
+ if linker is not None:
1196
+
1197
+ _query_params.append(('linker', linker))
1198
+
1199
+ # process the header parameters
1200
+ # process the form parameters
1201
+ # process the body parameter
1202
+
1203
+
1204
+ # set the HTTP header `Accept`
1205
+ if 'Accept' not in _header_params:
1206
+ _header_params['Accept'] = self.api_client.select_header_accept(
1207
+ [
1208
+ 'application/json'
1209
+ ]
1210
+ )
1211
+
1212
+
1213
+ # authentication setting
1214
+ _auth_settings: List[str] = [
1215
+ 'QAnswer-Api-Key',
1216
+ 'Bearer token'
1217
+ ]
1218
+
1219
+ return self.api_client.param_serialize(
1220
+ method='GET',
1221
+ resource_path='/backend/api/tasks/rdf/linker/download-csv',
1222
+ path_params=_path_params,
1223
+ query_params=_query_params,
1224
+ header_params=_header_params,
1225
+ body=_body_params,
1226
+ post_params=_form_params,
1227
+ files=_files,
1228
+ auth_settings=_auth_settings,
1229
+ collection_formats=_collection_formats,
1230
+ _host=_host,
1231
+ _request_auth=_request_auth
1232
+ )
1233
+
1234
+
1235
+
1236
+
1237
+ @validate_call
1238
+ def evaluate_skos(
1239
+ self,
1240
+ username: StrictStr,
1241
+ dataset: StrictStr,
1242
+ linker: StrictStr,
1243
+ confidence: Union[StrictFloat, StrictInt],
1244
+ _request_timeout: Union[
1245
+ None,
1246
+ Annotated[StrictFloat, Field(gt=0)],
1247
+ Tuple[
1248
+ Annotated[StrictFloat, Field(gt=0)],
1249
+ Annotated[StrictFloat, Field(gt=0)]
1250
+ ]
1251
+ ] = None,
1252
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1253
+ _content_type: Optional[StrictStr] = None,
1254
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1255
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1256
+ ) -> object:
1257
+ """Download linker data as SKOS N-Triples
1258
+
1259
+
1260
+ :param username: (required)
1261
+ :type username: str
1262
+ :param dataset: (required)
1263
+ :type dataset: str
1264
+ :param linker: (required)
1265
+ :type linker: str
1266
+ :param confidence: (required)
1267
+ :type confidence: float
1268
+ :param _request_timeout: timeout setting for this request. If one
1269
+ number provided, it will be total request
1270
+ timeout. It can also be a pair (tuple) of
1271
+ (connection, read) timeouts.
1272
+ :type _request_timeout: int, tuple(int, int), optional
1273
+ :param _request_auth: set to override the auth_settings for an a single
1274
+ request; this effectively ignores the
1275
+ authentication in the spec for a single request.
1276
+ :type _request_auth: dict, optional
1277
+ :param _content_type: force content-type for the request.
1278
+ :type _content_type: str, Optional
1279
+ :param _headers: set to override the headers for a single
1280
+ request; this effectively ignores the headers
1281
+ in the spec for a single request.
1282
+ :type _headers: dict, optional
1283
+ :param _host_index: set to override the host_index for a single
1284
+ request; this effectively ignores the host_index
1285
+ in the spec for a single request.
1286
+ :type _host_index: int, optional
1287
+ :return: Returns the result object.
1288
+ """ # noqa: E501
1289
+
1290
+ _param = self._evaluate_skos_serialize(
1291
+ username=username,
1292
+ dataset=dataset,
1293
+ linker=linker,
1294
+ confidence=confidence,
1295
+ _request_auth=_request_auth,
1296
+ _content_type=_content_type,
1297
+ _headers=_headers,
1298
+ _host_index=_host_index
1299
+ )
1300
+
1301
+ _response_types_map: Dict[str, Optional[str]] = {
1302
+ '200': "object",
1303
+ '422': "HTTPValidationError",
1304
+ }
1305
+ response_data = self.api_client.call_api(
1306
+ *_param,
1307
+ _request_timeout=_request_timeout
1308
+ )
1309
+ response_data.read()
1310
+ return self.api_client.response_deserialize(
1311
+ response_data=response_data,
1312
+ response_types_map=_response_types_map,
1313
+ ).data
1314
+
1315
+
1316
+ @validate_call
1317
+ def evaluate_skos_with_http_info(
1318
+ self,
1319
+ username: StrictStr,
1320
+ dataset: StrictStr,
1321
+ linker: StrictStr,
1322
+ confidence: Union[StrictFloat, StrictInt],
1323
+ _request_timeout: Union[
1324
+ None,
1325
+ Annotated[StrictFloat, Field(gt=0)],
1326
+ Tuple[
1327
+ Annotated[StrictFloat, Field(gt=0)],
1328
+ Annotated[StrictFloat, Field(gt=0)]
1329
+ ]
1330
+ ] = None,
1331
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1332
+ _content_type: Optional[StrictStr] = None,
1333
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1334
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1335
+ ) -> ApiResponse[object]:
1336
+ """Download linker data as SKOS N-Triples
1337
+
1338
+
1339
+ :param username: (required)
1340
+ :type username: str
1341
+ :param dataset: (required)
1342
+ :type dataset: str
1343
+ :param linker: (required)
1344
+ :type linker: str
1345
+ :param confidence: (required)
1346
+ :type confidence: float
1347
+ :param _request_timeout: timeout setting for this request. If one
1348
+ number provided, it will be total request
1349
+ timeout. It can also be a pair (tuple) of
1350
+ (connection, read) timeouts.
1351
+ :type _request_timeout: int, tuple(int, int), optional
1352
+ :param _request_auth: set to override the auth_settings for an a single
1353
+ request; this effectively ignores the
1354
+ authentication in the spec for a single request.
1355
+ :type _request_auth: dict, optional
1356
+ :param _content_type: force content-type for the request.
1357
+ :type _content_type: str, Optional
1358
+ :param _headers: set to override the headers for a single
1359
+ request; this effectively ignores the headers
1360
+ in the spec for a single request.
1361
+ :type _headers: dict, optional
1362
+ :param _host_index: set to override the host_index for a single
1363
+ request; this effectively ignores the host_index
1364
+ in the spec for a single request.
1365
+ :type _host_index: int, optional
1366
+ :return: Returns the result object.
1367
+ """ # noqa: E501
1368
+
1369
+ _param = self._evaluate_skos_serialize(
1370
+ username=username,
1371
+ dataset=dataset,
1372
+ linker=linker,
1373
+ confidence=confidence,
1374
+ _request_auth=_request_auth,
1375
+ _content_type=_content_type,
1376
+ _headers=_headers,
1377
+ _host_index=_host_index
1378
+ )
1379
+
1380
+ _response_types_map: Dict[str, Optional[str]] = {
1381
+ '200': "object",
1382
+ '422': "HTTPValidationError",
1383
+ }
1384
+ response_data = self.api_client.call_api(
1385
+ *_param,
1386
+ _request_timeout=_request_timeout
1387
+ )
1388
+ response_data.read()
1389
+ return self.api_client.response_deserialize(
1390
+ response_data=response_data,
1391
+ response_types_map=_response_types_map,
1392
+ )
1393
+
1394
+
1395
+ @validate_call
1396
+ def evaluate_skos_without_preload_content(
1397
+ self,
1398
+ username: StrictStr,
1399
+ dataset: StrictStr,
1400
+ linker: StrictStr,
1401
+ confidence: Union[StrictFloat, StrictInt],
1402
+ _request_timeout: Union[
1403
+ None,
1404
+ Annotated[StrictFloat, Field(gt=0)],
1405
+ Tuple[
1406
+ Annotated[StrictFloat, Field(gt=0)],
1407
+ Annotated[StrictFloat, Field(gt=0)]
1408
+ ]
1409
+ ] = None,
1410
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1411
+ _content_type: Optional[StrictStr] = None,
1412
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1413
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1414
+ ) -> RESTResponseType:
1415
+ """Download linker data as SKOS N-Triples
1416
+
1417
+
1418
+ :param username: (required)
1419
+ :type username: str
1420
+ :param dataset: (required)
1421
+ :type dataset: str
1422
+ :param linker: (required)
1423
+ :type linker: str
1424
+ :param confidence: (required)
1425
+ :type confidence: float
1426
+ :param _request_timeout: timeout setting for this request. If one
1427
+ number provided, it will be total request
1428
+ timeout. It can also be a pair (tuple) of
1429
+ (connection, read) timeouts.
1430
+ :type _request_timeout: int, tuple(int, int), optional
1431
+ :param _request_auth: set to override the auth_settings for an a single
1432
+ request; this effectively ignores the
1433
+ authentication in the spec for a single request.
1434
+ :type _request_auth: dict, optional
1435
+ :param _content_type: force content-type for the request.
1436
+ :type _content_type: str, Optional
1437
+ :param _headers: set to override the headers for a single
1438
+ request; this effectively ignores the headers
1439
+ in the spec for a single request.
1440
+ :type _headers: dict, optional
1441
+ :param _host_index: set to override the host_index for a single
1442
+ request; this effectively ignores the host_index
1443
+ in the spec for a single request.
1444
+ :type _host_index: int, optional
1445
+ :return: Returns the result object.
1446
+ """ # noqa: E501
1447
+
1448
+ _param = self._evaluate_skos_serialize(
1449
+ username=username,
1450
+ dataset=dataset,
1451
+ linker=linker,
1452
+ confidence=confidence,
1453
+ _request_auth=_request_auth,
1454
+ _content_type=_content_type,
1455
+ _headers=_headers,
1456
+ _host_index=_host_index
1457
+ )
1458
+
1459
+ _response_types_map: Dict[str, Optional[str]] = {
1460
+ '200': "object",
1461
+ '422': "HTTPValidationError",
1462
+ }
1463
+ response_data = self.api_client.call_api(
1464
+ *_param,
1465
+ _request_timeout=_request_timeout
1466
+ )
1467
+ return response_data.response
1468
+
1469
+
1470
+ def _evaluate_skos_serialize(
1471
+ self,
1472
+ username,
1473
+ dataset,
1474
+ linker,
1475
+ confidence,
1476
+ _request_auth,
1477
+ _content_type,
1478
+ _headers,
1479
+ _host_index,
1480
+ ) -> RequestSerialized:
1481
+
1482
+ _host = None
1483
+
1484
+ _collection_formats: Dict[str, str] = {
1485
+ }
1486
+
1487
+ _path_params: Dict[str, str] = {}
1488
+ _query_params: List[Tuple[str, str]] = []
1489
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1490
+ _form_params: List[Tuple[str, str]] = []
1491
+ _files: Dict[
1492
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1493
+ ] = {}
1494
+ _body_params: Optional[bytes] = None
1495
+
1496
+ # process the path parameters
1497
+ # process the query parameters
1498
+ if username is not None:
1499
+
1500
+ _query_params.append(('username', username))
1501
+
1502
+ if dataset is not None:
1503
+
1504
+ _query_params.append(('dataset', dataset))
1505
+
1506
+ if linker is not None:
1507
+
1508
+ _query_params.append(('linker', linker))
1509
+
1510
+ if confidence is not None:
1511
+
1512
+ _query_params.append(('confidence', confidence))
1513
+
1514
+ # process the header parameters
1515
+ # process the form parameters
1516
+ # process the body parameter
1517
+
1518
+
1519
+ # set the HTTP header `Accept`
1520
+ if 'Accept' not in _header_params:
1521
+ _header_params['Accept'] = self.api_client.select_header_accept(
1522
+ [
1523
+ 'application/json'
1524
+ ]
1525
+ )
1526
+
1527
+
1528
+ # authentication setting
1529
+ _auth_settings: List[str] = [
1530
+ 'QAnswer-Api-Key',
1531
+ 'Bearer token'
1532
+ ]
1533
+
1534
+ return self.api_client.param_serialize(
1535
+ method='GET',
1536
+ resource_path='/backend/api/tasks/rdf/linker/download-skos',
1537
+ path_params=_path_params,
1538
+ query_params=_query_params,
1539
+ header_params=_header_params,
1540
+ body=_body_params,
1541
+ post_params=_form_params,
1542
+ files=_files,
1543
+ auth_settings=_auth_settings,
1544
+ collection_formats=_collection_formats,
1545
+ _host=_host,
1546
+ _request_auth=_request_auth
1547
+ )
1548
+
1549
+
1550
+
1551
+
1552
+ @validate_call
1553
+ def link_text(
1554
+ self,
1555
+ username: StrictStr,
1556
+ dataset: StrictStr,
1557
+ linker: StrictStr,
1558
+ text: StrictStr,
1559
+ _request_timeout: Union[
1560
+ None,
1561
+ Annotated[StrictFloat, Field(gt=0)],
1562
+ Tuple[
1563
+ Annotated[StrictFloat, Field(gt=0)],
1564
+ Annotated[StrictFloat, Field(gt=0)]
1565
+ ]
1566
+ ] = None,
1567
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1568
+ _content_type: Optional[StrictStr] = None,
1569
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1570
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1571
+ ) -> List[Dict[str, object]]:
1572
+ """Link text using a trained linker
1573
+
1574
+
1575
+ :param username: (required)
1576
+ :type username: str
1577
+ :param dataset: (required)
1578
+ :type dataset: str
1579
+ :param linker: (required)
1580
+ :type linker: str
1581
+ :param text: (required)
1582
+ :type text: str
1583
+ :param _request_timeout: timeout setting for this request. If one
1584
+ number provided, it will be total request
1585
+ timeout. It can also be a pair (tuple) of
1586
+ (connection, read) timeouts.
1587
+ :type _request_timeout: int, tuple(int, int), optional
1588
+ :param _request_auth: set to override the auth_settings for an a single
1589
+ request; this effectively ignores the
1590
+ authentication in the spec for a single request.
1591
+ :type _request_auth: dict, optional
1592
+ :param _content_type: force content-type for the request.
1593
+ :type _content_type: str, Optional
1594
+ :param _headers: set to override the headers for a single
1595
+ request; this effectively ignores the headers
1596
+ in the spec for a single request.
1597
+ :type _headers: dict, optional
1598
+ :param _host_index: set to override the host_index for a single
1599
+ request; this effectively ignores the host_index
1600
+ in the spec for a single request.
1601
+ :type _host_index: int, optional
1602
+ :return: Returns the result object.
1603
+ """ # noqa: E501
1604
+
1605
+ _param = self._link_text_serialize(
1606
+ username=username,
1607
+ dataset=dataset,
1608
+ linker=linker,
1609
+ text=text,
1610
+ _request_auth=_request_auth,
1611
+ _content_type=_content_type,
1612
+ _headers=_headers,
1613
+ _host_index=_host_index
1614
+ )
1615
+
1616
+ _response_types_map: Dict[str, Optional[str]] = {
1617
+ '200': "List[Dict[str, object]]",
1618
+ '422': "HTTPValidationError",
1619
+ }
1620
+ response_data = self.api_client.call_api(
1621
+ *_param,
1622
+ _request_timeout=_request_timeout
1623
+ )
1624
+ response_data.read()
1625
+ return self.api_client.response_deserialize(
1626
+ response_data=response_data,
1627
+ response_types_map=_response_types_map,
1628
+ ).data
1629
+
1630
+
1631
+ @validate_call
1632
+ def link_text_with_http_info(
1633
+ self,
1634
+ username: StrictStr,
1635
+ dataset: StrictStr,
1636
+ linker: StrictStr,
1637
+ text: StrictStr,
1638
+ _request_timeout: Union[
1639
+ None,
1640
+ Annotated[StrictFloat, Field(gt=0)],
1641
+ Tuple[
1642
+ Annotated[StrictFloat, Field(gt=0)],
1643
+ Annotated[StrictFloat, Field(gt=0)]
1644
+ ]
1645
+ ] = None,
1646
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1647
+ _content_type: Optional[StrictStr] = None,
1648
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1649
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1650
+ ) -> ApiResponse[List[Dict[str, object]]]:
1651
+ """Link text using a trained linker
1652
+
1653
+
1654
+ :param username: (required)
1655
+ :type username: str
1656
+ :param dataset: (required)
1657
+ :type dataset: str
1658
+ :param linker: (required)
1659
+ :type linker: str
1660
+ :param text: (required)
1661
+ :type text: str
1662
+ :param _request_timeout: timeout setting for this request. If one
1663
+ number provided, it will be total request
1664
+ timeout. It can also be a pair (tuple) of
1665
+ (connection, read) timeouts.
1666
+ :type _request_timeout: int, tuple(int, int), optional
1667
+ :param _request_auth: set to override the auth_settings for an a single
1668
+ request; this effectively ignores the
1669
+ authentication in the spec for a single request.
1670
+ :type _request_auth: dict, optional
1671
+ :param _content_type: force content-type for the request.
1672
+ :type _content_type: str, Optional
1673
+ :param _headers: set to override the headers for a single
1674
+ request; this effectively ignores the headers
1675
+ in the spec for a single request.
1676
+ :type _headers: dict, optional
1677
+ :param _host_index: set to override the host_index for a single
1678
+ request; this effectively ignores the host_index
1679
+ in the spec for a single request.
1680
+ :type _host_index: int, optional
1681
+ :return: Returns the result object.
1682
+ """ # noqa: E501
1683
+
1684
+ _param = self._link_text_serialize(
1685
+ username=username,
1686
+ dataset=dataset,
1687
+ linker=linker,
1688
+ text=text,
1689
+ _request_auth=_request_auth,
1690
+ _content_type=_content_type,
1691
+ _headers=_headers,
1692
+ _host_index=_host_index
1693
+ )
1694
+
1695
+ _response_types_map: Dict[str, Optional[str]] = {
1696
+ '200': "List[Dict[str, object]]",
1697
+ '422': "HTTPValidationError",
1698
+ }
1699
+ response_data = self.api_client.call_api(
1700
+ *_param,
1701
+ _request_timeout=_request_timeout
1702
+ )
1703
+ response_data.read()
1704
+ return self.api_client.response_deserialize(
1705
+ response_data=response_data,
1706
+ response_types_map=_response_types_map,
1707
+ )
1708
+
1709
+
1710
+ @validate_call
1711
+ def link_text_without_preload_content(
1712
+ self,
1713
+ username: StrictStr,
1714
+ dataset: StrictStr,
1715
+ linker: StrictStr,
1716
+ text: StrictStr,
1717
+ _request_timeout: Union[
1718
+ None,
1719
+ Annotated[StrictFloat, Field(gt=0)],
1720
+ Tuple[
1721
+ Annotated[StrictFloat, Field(gt=0)],
1722
+ Annotated[StrictFloat, Field(gt=0)]
1723
+ ]
1724
+ ] = None,
1725
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1726
+ _content_type: Optional[StrictStr] = None,
1727
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1728
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1729
+ ) -> RESTResponseType:
1730
+ """Link text using a trained linker
1731
+
1732
+
1733
+ :param username: (required)
1734
+ :type username: str
1735
+ :param dataset: (required)
1736
+ :type dataset: str
1737
+ :param linker: (required)
1738
+ :type linker: str
1739
+ :param text: (required)
1740
+ :type text: str
1741
+ :param _request_timeout: timeout setting for this request. If one
1742
+ number provided, it will be total request
1743
+ timeout. It can also be a pair (tuple) of
1744
+ (connection, read) timeouts.
1745
+ :type _request_timeout: int, tuple(int, int), optional
1746
+ :param _request_auth: set to override the auth_settings for an a single
1747
+ request; this effectively ignores the
1748
+ authentication in the spec for a single request.
1749
+ :type _request_auth: dict, optional
1750
+ :param _content_type: force content-type for the request.
1751
+ :type _content_type: str, Optional
1752
+ :param _headers: set to override the headers for a single
1753
+ request; this effectively ignores the headers
1754
+ in the spec for a single request.
1755
+ :type _headers: dict, optional
1756
+ :param _host_index: set to override the host_index for a single
1757
+ request; this effectively ignores the host_index
1758
+ in the spec for a single request.
1759
+ :type _host_index: int, optional
1760
+ :return: Returns the result object.
1761
+ """ # noqa: E501
1762
+
1763
+ _param = self._link_text_serialize(
1764
+ username=username,
1765
+ dataset=dataset,
1766
+ linker=linker,
1767
+ text=text,
1768
+ _request_auth=_request_auth,
1769
+ _content_type=_content_type,
1770
+ _headers=_headers,
1771
+ _host_index=_host_index
1772
+ )
1773
+
1774
+ _response_types_map: Dict[str, Optional[str]] = {
1775
+ '200': "List[Dict[str, object]]",
1776
+ '422': "HTTPValidationError",
1777
+ }
1778
+ response_data = self.api_client.call_api(
1779
+ *_param,
1780
+ _request_timeout=_request_timeout
1781
+ )
1782
+ return response_data.response
1783
+
1784
+
1785
+ def _link_text_serialize(
1786
+ self,
1787
+ username,
1788
+ dataset,
1789
+ linker,
1790
+ text,
1791
+ _request_auth,
1792
+ _content_type,
1793
+ _headers,
1794
+ _host_index,
1795
+ ) -> RequestSerialized:
1796
+
1797
+ _host = None
1798
+
1799
+ _collection_formats: Dict[str, str] = {
1800
+ }
1801
+
1802
+ _path_params: Dict[str, str] = {}
1803
+ _query_params: List[Tuple[str, str]] = []
1804
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1805
+ _form_params: List[Tuple[str, str]] = []
1806
+ _files: Dict[
1807
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1808
+ ] = {}
1809
+ _body_params: Optional[bytes] = None
1810
+
1811
+ # process the path parameters
1812
+ # process the query parameters
1813
+ if username is not None:
1814
+
1815
+ _query_params.append(('username', username))
1816
+
1817
+ if dataset is not None:
1818
+
1819
+ _query_params.append(('dataset', dataset))
1820
+
1821
+ if linker is not None:
1822
+
1823
+ _query_params.append(('linker', linker))
1824
+
1825
+ if text is not None:
1826
+
1827
+ _query_params.append(('text', text))
1828
+
1829
+ # process the header parameters
1830
+ # process the form parameters
1831
+ # process the body parameter
1832
+
1833
+
1834
+ # set the HTTP header `Accept`
1835
+ if 'Accept' not in _header_params:
1836
+ _header_params['Accept'] = self.api_client.select_header_accept(
1837
+ [
1838
+ 'application/json'
1839
+ ]
1840
+ )
1841
+
1842
+
1843
+ # authentication setting
1844
+ _auth_settings: List[str] = [
1845
+ 'QAnswer-Api-Key',
1846
+ 'Bearer token'
1847
+ ]
1848
+
1849
+ return self.api_client.param_serialize(
1850
+ method='GET',
1851
+ resource_path='/backend/api/tasks/rdf/linker/link',
1852
+ path_params=_path_params,
1853
+ query_params=_query_params,
1854
+ header_params=_header_params,
1855
+ body=_body_params,
1856
+ post_params=_form_params,
1857
+ files=_files,
1858
+ auth_settings=_auth_settings,
1859
+ collection_formats=_collection_formats,
1860
+ _host=_host,
1861
+ _request_auth=_request_auth
1862
+ )
1863
+
1864
+
1865
+
1866
+
1867
+ @validate_call
1868
+ def list(
1869
+ self,
1870
+ username: StrictStr,
1871
+ dataset: StrictStr,
1872
+ _request_timeout: Union[
1873
+ None,
1874
+ Annotated[StrictFloat, Field(gt=0)],
1875
+ Tuple[
1876
+ Annotated[StrictFloat, Field(gt=0)],
1877
+ Annotated[StrictFloat, Field(gt=0)]
1878
+ ]
1879
+ ] = None,
1880
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1881
+ _content_type: Optional[StrictStr] = None,
1882
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1883
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1884
+ ) -> List[Optional[str]]:
1885
+ """List available linkers for a dataset
1886
+
1887
+
1888
+ :param username: (required)
1889
+ :type username: str
1890
+ :param dataset: (required)
1891
+ :type dataset: str
1892
+ :param _request_timeout: timeout setting for this request. If one
1893
+ number provided, it will be total request
1894
+ timeout. It can also be a pair (tuple) of
1895
+ (connection, read) timeouts.
1896
+ :type _request_timeout: int, tuple(int, int), optional
1897
+ :param _request_auth: set to override the auth_settings for an a single
1898
+ request; this effectively ignores the
1899
+ authentication in the spec for a single request.
1900
+ :type _request_auth: dict, optional
1901
+ :param _content_type: force content-type for the request.
1902
+ :type _content_type: str, Optional
1903
+ :param _headers: set to override the headers for a single
1904
+ request; this effectively ignores the headers
1905
+ in the spec for a single request.
1906
+ :type _headers: dict, optional
1907
+ :param _host_index: set to override the host_index for a single
1908
+ request; this effectively ignores the host_index
1909
+ in the spec for a single request.
1910
+ :type _host_index: int, optional
1911
+ :return: Returns the result object.
1912
+ """ # noqa: E501
1913
+
1914
+ _param = self._list_serialize(
1915
+ username=username,
1916
+ dataset=dataset,
1917
+ _request_auth=_request_auth,
1918
+ _content_type=_content_type,
1919
+ _headers=_headers,
1920
+ _host_index=_host_index
1921
+ )
1922
+
1923
+ _response_types_map: Dict[str, Optional[str]] = {
1924
+ '200': "List[Optional[str]]",
1925
+ '422': "HTTPValidationError",
1926
+ }
1927
+ response_data = self.api_client.call_api(
1928
+ *_param,
1929
+ _request_timeout=_request_timeout
1930
+ )
1931
+ response_data.read()
1932
+ return self.api_client.response_deserialize(
1933
+ response_data=response_data,
1934
+ response_types_map=_response_types_map,
1935
+ ).data
1936
+
1937
+
1938
+ @validate_call
1939
+ def list_with_http_info(
1940
+ self,
1941
+ username: StrictStr,
1942
+ dataset: StrictStr,
1943
+ _request_timeout: Union[
1944
+ None,
1945
+ Annotated[StrictFloat, Field(gt=0)],
1946
+ Tuple[
1947
+ Annotated[StrictFloat, Field(gt=0)],
1948
+ Annotated[StrictFloat, Field(gt=0)]
1949
+ ]
1950
+ ] = None,
1951
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1952
+ _content_type: Optional[StrictStr] = None,
1953
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1954
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1955
+ ) -> ApiResponse[List[Optional[str]]]:
1956
+ """List available linkers for a dataset
1957
+
1958
+
1959
+ :param username: (required)
1960
+ :type username: str
1961
+ :param dataset: (required)
1962
+ :type dataset: str
1963
+ :param _request_timeout: timeout setting for this request. If one
1964
+ number provided, it will be total request
1965
+ timeout. It can also be a pair (tuple) of
1966
+ (connection, read) timeouts.
1967
+ :type _request_timeout: int, tuple(int, int), optional
1968
+ :param _request_auth: set to override the auth_settings for an a single
1969
+ request; this effectively ignores the
1970
+ authentication in the spec for a single request.
1971
+ :type _request_auth: dict, optional
1972
+ :param _content_type: force content-type for the request.
1973
+ :type _content_type: str, Optional
1974
+ :param _headers: set to override the headers for a single
1975
+ request; this effectively ignores the headers
1976
+ in the spec for a single request.
1977
+ :type _headers: dict, optional
1978
+ :param _host_index: set to override the host_index for a single
1979
+ request; this effectively ignores the host_index
1980
+ in the spec for a single request.
1981
+ :type _host_index: int, optional
1982
+ :return: Returns the result object.
1983
+ """ # noqa: E501
1984
+
1985
+ _param = self._list_serialize(
1986
+ username=username,
1987
+ dataset=dataset,
1988
+ _request_auth=_request_auth,
1989
+ _content_type=_content_type,
1990
+ _headers=_headers,
1991
+ _host_index=_host_index
1992
+ )
1993
+
1994
+ _response_types_map: Dict[str, Optional[str]] = {
1995
+ '200': "List[Optional[str]]",
1996
+ '422': "HTTPValidationError",
1997
+ }
1998
+ response_data = self.api_client.call_api(
1999
+ *_param,
2000
+ _request_timeout=_request_timeout
2001
+ )
2002
+ response_data.read()
2003
+ return self.api_client.response_deserialize(
2004
+ response_data=response_data,
2005
+ response_types_map=_response_types_map,
2006
+ )
2007
+
2008
+
2009
+ @validate_call
2010
+ def list_without_preload_content(
2011
+ self,
2012
+ username: StrictStr,
2013
+ dataset: StrictStr,
2014
+ _request_timeout: Union[
2015
+ None,
2016
+ Annotated[StrictFloat, Field(gt=0)],
2017
+ Tuple[
2018
+ Annotated[StrictFloat, Field(gt=0)],
2019
+ Annotated[StrictFloat, Field(gt=0)]
2020
+ ]
2021
+ ] = None,
2022
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2023
+ _content_type: Optional[StrictStr] = None,
2024
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2025
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2026
+ ) -> RESTResponseType:
2027
+ """List available linkers for a dataset
2028
+
2029
+
2030
+ :param username: (required)
2031
+ :type username: str
2032
+ :param dataset: (required)
2033
+ :type dataset: str
2034
+ :param _request_timeout: timeout setting for this request. If one
2035
+ number provided, it will be total request
2036
+ timeout. It can also be a pair (tuple) of
2037
+ (connection, read) timeouts.
2038
+ :type _request_timeout: int, tuple(int, int), optional
2039
+ :param _request_auth: set to override the auth_settings for an a single
2040
+ request; this effectively ignores the
2041
+ authentication in the spec for a single request.
2042
+ :type _request_auth: dict, optional
2043
+ :param _content_type: force content-type for the request.
2044
+ :type _content_type: str, Optional
2045
+ :param _headers: set to override the headers for a single
2046
+ request; this effectively ignores the headers
2047
+ in the spec for a single request.
2048
+ :type _headers: dict, optional
2049
+ :param _host_index: set to override the host_index for a single
2050
+ request; this effectively ignores the host_index
2051
+ in the spec for a single request.
2052
+ :type _host_index: int, optional
2053
+ :return: Returns the result object.
2054
+ """ # noqa: E501
2055
+
2056
+ _param = self._list_serialize(
2057
+ username=username,
2058
+ dataset=dataset,
2059
+ _request_auth=_request_auth,
2060
+ _content_type=_content_type,
2061
+ _headers=_headers,
2062
+ _host_index=_host_index
2063
+ )
2064
+
2065
+ _response_types_map: Dict[str, Optional[str]] = {
2066
+ '200': "List[Optional[str]]",
2067
+ '422': "HTTPValidationError",
2068
+ }
2069
+ response_data = self.api_client.call_api(
2070
+ *_param,
2071
+ _request_timeout=_request_timeout
2072
+ )
2073
+ return response_data.response
2074
+
2075
+
2076
+ def _list_serialize(
2077
+ self,
2078
+ username,
2079
+ dataset,
2080
+ _request_auth,
2081
+ _content_type,
2082
+ _headers,
2083
+ _host_index,
2084
+ ) -> RequestSerialized:
2085
+
2086
+ _host = None
2087
+
2088
+ _collection_formats: Dict[str, str] = {
2089
+ }
2090
+
2091
+ _path_params: Dict[str, str] = {}
2092
+ _query_params: List[Tuple[str, str]] = []
2093
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2094
+ _form_params: List[Tuple[str, str]] = []
2095
+ _files: Dict[
2096
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2097
+ ] = {}
2098
+ _body_params: Optional[bytes] = None
2099
+
2100
+ # process the path parameters
2101
+ # process the query parameters
2102
+ if username is not None:
2103
+
2104
+ _query_params.append(('username', username))
2105
+
2106
+ if dataset is not None:
2107
+
2108
+ _query_params.append(('dataset', dataset))
2109
+
2110
+ # process the header parameters
2111
+ # process the form parameters
2112
+ # process the body parameter
2113
+
2114
+
2115
+ # set the HTTP header `Accept`
2116
+ if 'Accept' not in _header_params:
2117
+ _header_params['Accept'] = self.api_client.select_header_accept(
2118
+ [
2119
+ 'application/json'
2120
+ ]
2121
+ )
2122
+
2123
+
2124
+ # authentication setting
2125
+ _auth_settings: List[str] = [
2126
+ 'QAnswer-Api-Key',
2127
+ 'Bearer token'
2128
+ ]
2129
+
2130
+ return self.api_client.param_serialize(
2131
+ method='GET',
2132
+ resource_path='/backend/api/tasks/rdf/linker/list',
2133
+ path_params=_path_params,
2134
+ query_params=_query_params,
2135
+ header_params=_header_params,
2136
+ body=_body_params,
2137
+ post_params=_form_params,
2138
+ files=_files,
2139
+ auth_settings=_auth_settings,
2140
+ collection_formats=_collection_formats,
2141
+ _host=_host,
2142
+ _request_auth=_request_auth
2143
+ )
2144
+
2145
+
2146
+
2147
+
2148
+ @validate_call
2149
+ def order_evaluate(
2150
+ self,
2151
+ username: StrictStr,
2152
+ dataset: StrictStr,
2153
+ linker: StrictStr,
2154
+ sort_by: Optional[StrictStr] = None,
2155
+ sort_dir: Optional[StrictStr] = None,
2156
+ page: Optional[StrictInt] = None,
2157
+ size: Optional[StrictInt] = None,
2158
+ _request_timeout: Union[
2159
+ None,
2160
+ Annotated[StrictFloat, Field(gt=0)],
2161
+ Tuple[
2162
+ Annotated[StrictFloat, Field(gt=0)],
2163
+ Annotated[StrictFloat, Field(gt=0)]
2164
+ ]
2165
+ ] = None,
2166
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2167
+ _content_type: Optional[StrictStr] = None,
2168
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2169
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2170
+ ) -> LinkResultPaginated:
2171
+ """Get evaluation results
2172
+
2173
+
2174
+ :param username: (required)
2175
+ :type username: str
2176
+ :param dataset: (required)
2177
+ :type dataset: str
2178
+ :param linker: (required)
2179
+ :type linker: str
2180
+ :param sort_by:
2181
+ :type sort_by: str
2182
+ :param sort_dir:
2183
+ :type sort_dir: str
2184
+ :param page:
2185
+ :type page: int
2186
+ :param size:
2187
+ :type size: int
2188
+ :param _request_timeout: timeout setting for this request. If one
2189
+ number provided, it will be total request
2190
+ timeout. It can also be a pair (tuple) of
2191
+ (connection, read) timeouts.
2192
+ :type _request_timeout: int, tuple(int, int), optional
2193
+ :param _request_auth: set to override the auth_settings for an a single
2194
+ request; this effectively ignores the
2195
+ authentication in the spec for a single request.
2196
+ :type _request_auth: dict, optional
2197
+ :param _content_type: force content-type for the request.
2198
+ :type _content_type: str, Optional
2199
+ :param _headers: set to override the headers for a single
2200
+ request; this effectively ignores the headers
2201
+ in the spec for a single request.
2202
+ :type _headers: dict, optional
2203
+ :param _host_index: set to override the host_index for a single
2204
+ request; this effectively ignores the host_index
2205
+ in the spec for a single request.
2206
+ :type _host_index: int, optional
2207
+ :return: Returns the result object.
2208
+ """ # noqa: E501
2209
+
2210
+ _param = self._order_evaluate_serialize(
2211
+ username=username,
2212
+ dataset=dataset,
2213
+ linker=linker,
2214
+ sort_by=sort_by,
2215
+ sort_dir=sort_dir,
2216
+ page=page,
2217
+ size=size,
2218
+ _request_auth=_request_auth,
2219
+ _content_type=_content_type,
2220
+ _headers=_headers,
2221
+ _host_index=_host_index
2222
+ )
2223
+
2224
+ _response_types_map: Dict[str, Optional[str]] = {
2225
+ '200': "LinkResultPaginated",
2226
+ '422': "HTTPValidationError",
2227
+ }
2228
+ response_data = self.api_client.call_api(
2229
+ *_param,
2230
+ _request_timeout=_request_timeout
2231
+ )
2232
+ response_data.read()
2233
+ return self.api_client.response_deserialize(
2234
+ response_data=response_data,
2235
+ response_types_map=_response_types_map,
2236
+ ).data
2237
+
2238
+
2239
+ @validate_call
2240
+ def order_evaluate_with_http_info(
2241
+ self,
2242
+ username: StrictStr,
2243
+ dataset: StrictStr,
2244
+ linker: StrictStr,
2245
+ sort_by: Optional[StrictStr] = None,
2246
+ sort_dir: Optional[StrictStr] = None,
2247
+ page: Optional[StrictInt] = None,
2248
+ size: Optional[StrictInt] = None,
2249
+ _request_timeout: Union[
2250
+ None,
2251
+ Annotated[StrictFloat, Field(gt=0)],
2252
+ Tuple[
2253
+ Annotated[StrictFloat, Field(gt=0)],
2254
+ Annotated[StrictFloat, Field(gt=0)]
2255
+ ]
2256
+ ] = None,
2257
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2258
+ _content_type: Optional[StrictStr] = None,
2259
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2260
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2261
+ ) -> ApiResponse[LinkResultPaginated]:
2262
+ """Get evaluation results
2263
+
2264
+
2265
+ :param username: (required)
2266
+ :type username: str
2267
+ :param dataset: (required)
2268
+ :type dataset: str
2269
+ :param linker: (required)
2270
+ :type linker: str
2271
+ :param sort_by:
2272
+ :type sort_by: str
2273
+ :param sort_dir:
2274
+ :type sort_dir: str
2275
+ :param page:
2276
+ :type page: int
2277
+ :param size:
2278
+ :type size: int
2279
+ :param _request_timeout: timeout setting for this request. If one
2280
+ number provided, it will be total request
2281
+ timeout. It can also be a pair (tuple) of
2282
+ (connection, read) timeouts.
2283
+ :type _request_timeout: int, tuple(int, int), optional
2284
+ :param _request_auth: set to override the auth_settings for an a single
2285
+ request; this effectively ignores the
2286
+ authentication in the spec for a single request.
2287
+ :type _request_auth: dict, optional
2288
+ :param _content_type: force content-type for the request.
2289
+ :type _content_type: str, Optional
2290
+ :param _headers: set to override the headers for a single
2291
+ request; this effectively ignores the headers
2292
+ in the spec for a single request.
2293
+ :type _headers: dict, optional
2294
+ :param _host_index: set to override the host_index for a single
2295
+ request; this effectively ignores the host_index
2296
+ in the spec for a single request.
2297
+ :type _host_index: int, optional
2298
+ :return: Returns the result object.
2299
+ """ # noqa: E501
2300
+
2301
+ _param = self._order_evaluate_serialize(
2302
+ username=username,
2303
+ dataset=dataset,
2304
+ linker=linker,
2305
+ sort_by=sort_by,
2306
+ sort_dir=sort_dir,
2307
+ page=page,
2308
+ size=size,
2309
+ _request_auth=_request_auth,
2310
+ _content_type=_content_type,
2311
+ _headers=_headers,
2312
+ _host_index=_host_index
2313
+ )
2314
+
2315
+ _response_types_map: Dict[str, Optional[str]] = {
2316
+ '200': "LinkResultPaginated",
2317
+ '422': "HTTPValidationError",
2318
+ }
2319
+ response_data = self.api_client.call_api(
2320
+ *_param,
2321
+ _request_timeout=_request_timeout
2322
+ )
2323
+ response_data.read()
2324
+ return self.api_client.response_deserialize(
2325
+ response_data=response_data,
2326
+ response_types_map=_response_types_map,
2327
+ )
2328
+
2329
+
2330
+ @validate_call
2331
+ def order_evaluate_without_preload_content(
2332
+ self,
2333
+ username: StrictStr,
2334
+ dataset: StrictStr,
2335
+ linker: StrictStr,
2336
+ sort_by: Optional[StrictStr] = None,
2337
+ sort_dir: Optional[StrictStr] = None,
2338
+ page: Optional[StrictInt] = None,
2339
+ size: Optional[StrictInt] = None,
2340
+ _request_timeout: Union[
2341
+ None,
2342
+ Annotated[StrictFloat, Field(gt=0)],
2343
+ Tuple[
2344
+ Annotated[StrictFloat, Field(gt=0)],
2345
+ Annotated[StrictFloat, Field(gt=0)]
2346
+ ]
2347
+ ] = None,
2348
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2349
+ _content_type: Optional[StrictStr] = None,
2350
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2351
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2352
+ ) -> RESTResponseType:
2353
+ """Get evaluation results
2354
+
2355
+
2356
+ :param username: (required)
2357
+ :type username: str
2358
+ :param dataset: (required)
2359
+ :type dataset: str
2360
+ :param linker: (required)
2361
+ :type linker: str
2362
+ :param sort_by:
2363
+ :type sort_by: str
2364
+ :param sort_dir:
2365
+ :type sort_dir: str
2366
+ :param page:
2367
+ :type page: int
2368
+ :param size:
2369
+ :type size: int
2370
+ :param _request_timeout: timeout setting for this request. If one
2371
+ number provided, it will be total request
2372
+ timeout. It can also be a pair (tuple) of
2373
+ (connection, read) timeouts.
2374
+ :type _request_timeout: int, tuple(int, int), optional
2375
+ :param _request_auth: set to override the auth_settings for an a single
2376
+ request; this effectively ignores the
2377
+ authentication in the spec for a single request.
2378
+ :type _request_auth: dict, optional
2379
+ :param _content_type: force content-type for the request.
2380
+ :type _content_type: str, Optional
2381
+ :param _headers: set to override the headers for a single
2382
+ request; this effectively ignores the headers
2383
+ in the spec for a single request.
2384
+ :type _headers: dict, optional
2385
+ :param _host_index: set to override the host_index for a single
2386
+ request; this effectively ignores the host_index
2387
+ in the spec for a single request.
2388
+ :type _host_index: int, optional
2389
+ :return: Returns the result object.
2390
+ """ # noqa: E501
2391
+
2392
+ _param = self._order_evaluate_serialize(
2393
+ username=username,
2394
+ dataset=dataset,
2395
+ linker=linker,
2396
+ sort_by=sort_by,
2397
+ sort_dir=sort_dir,
2398
+ page=page,
2399
+ size=size,
2400
+ _request_auth=_request_auth,
2401
+ _content_type=_content_type,
2402
+ _headers=_headers,
2403
+ _host_index=_host_index
2404
+ )
2405
+
2406
+ _response_types_map: Dict[str, Optional[str]] = {
2407
+ '200': "LinkResultPaginated",
2408
+ '422': "HTTPValidationError",
2409
+ }
2410
+ response_data = self.api_client.call_api(
2411
+ *_param,
2412
+ _request_timeout=_request_timeout
2413
+ )
2414
+ return response_data.response
2415
+
2416
+
2417
+ def _order_evaluate_serialize(
2418
+ self,
2419
+ username,
2420
+ dataset,
2421
+ linker,
2422
+ sort_by,
2423
+ sort_dir,
2424
+ page,
2425
+ size,
2426
+ _request_auth,
2427
+ _content_type,
2428
+ _headers,
2429
+ _host_index,
2430
+ ) -> RequestSerialized:
2431
+
2432
+ _host = None
2433
+
2434
+ _collection_formats: Dict[str, str] = {
2435
+ }
2436
+
2437
+ _path_params: Dict[str, str] = {}
2438
+ _query_params: List[Tuple[str, str]] = []
2439
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2440
+ _form_params: List[Tuple[str, str]] = []
2441
+ _files: Dict[
2442
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2443
+ ] = {}
2444
+ _body_params: Optional[bytes] = None
2445
+
2446
+ # process the path parameters
2447
+ # process the query parameters
2448
+ if username is not None:
2449
+
2450
+ _query_params.append(('username', username))
2451
+
2452
+ if dataset is not None:
2453
+
2454
+ _query_params.append(('dataset', dataset))
2455
+
2456
+ if linker is not None:
2457
+
2458
+ _query_params.append(('linker', linker))
2459
+
2460
+ if sort_by is not None:
2461
+
2462
+ _query_params.append(('sortBy', sort_by))
2463
+
2464
+ if sort_dir is not None:
2465
+
2466
+ _query_params.append(('sortDir', sort_dir))
2467
+
2468
+ if page is not None:
2469
+
2470
+ _query_params.append(('page', page))
2471
+
2472
+ if size is not None:
2473
+
2474
+ _query_params.append(('size', size))
2475
+
2476
+ # process the header parameters
2477
+ # process the form parameters
2478
+ # process the body parameter
2479
+
2480
+
2481
+ # set the HTTP header `Accept`
2482
+ if 'Accept' not in _header_params:
2483
+ _header_params['Accept'] = self.api_client.select_header_accept(
2484
+ [
2485
+ 'application/json'
2486
+ ]
2487
+ )
2488
+
2489
+
2490
+ # authentication setting
2491
+ _auth_settings: List[str] = [
2492
+ 'QAnswer-Api-Key',
2493
+ 'Bearer token'
2494
+ ]
2495
+
2496
+ return self.api_client.param_serialize(
2497
+ method='GET',
2498
+ resource_path='/backend/api/tasks/rdf/linker/evaluate',
2499
+ path_params=_path_params,
2500
+ query_params=_query_params,
2501
+ header_params=_header_params,
2502
+ body=_body_params,
2503
+ post_params=_form_params,
2504
+ files=_files,
2505
+ auth_settings=_auth_settings,
2506
+ collection_formats=_collection_formats,
2507
+ _host=_host,
2508
+ _request_auth=_request_auth
2509
+ )
2510
+
2511
+
2512
+
2513
+
2514
+ @validate_call
2515
+ def post_aggregate(
2516
+ self,
2517
+ username: StrictStr,
2518
+ dataset: StrictStr,
2519
+ linker: StrictStr,
2520
+ aggregate: List[Aggregate],
2521
+ _request_timeout: Union[
2522
+ None,
2523
+ Annotated[StrictFloat, Field(gt=0)],
2524
+ Tuple[
2525
+ Annotated[StrictFloat, Field(gt=0)],
2526
+ Annotated[StrictFloat, Field(gt=0)]
2527
+ ]
2528
+ ] = None,
2529
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2530
+ _content_type: Optional[StrictStr] = None,
2531
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2532
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2533
+ ) -> str:
2534
+ """Save aggregation list
2535
+
2536
+
2537
+ :param username: (required)
2538
+ :type username: str
2539
+ :param dataset: (required)
2540
+ :type dataset: str
2541
+ :param linker: (required)
2542
+ :type linker: str
2543
+ :param aggregate: (required)
2544
+ :type aggregate: List[Aggregate]
2545
+ :param _request_timeout: timeout setting for this request. If one
2546
+ number provided, it will be total request
2547
+ timeout. It can also be a pair (tuple) of
2548
+ (connection, read) timeouts.
2549
+ :type _request_timeout: int, tuple(int, int), optional
2550
+ :param _request_auth: set to override the auth_settings for an a single
2551
+ request; this effectively ignores the
2552
+ authentication in the spec for a single request.
2553
+ :type _request_auth: dict, optional
2554
+ :param _content_type: force content-type for the request.
2555
+ :type _content_type: str, Optional
2556
+ :param _headers: set to override the headers for a single
2557
+ request; this effectively ignores the headers
2558
+ in the spec for a single request.
2559
+ :type _headers: dict, optional
2560
+ :param _host_index: set to override the host_index for a single
2561
+ request; this effectively ignores the host_index
2562
+ in the spec for a single request.
2563
+ :type _host_index: int, optional
2564
+ :return: Returns the result object.
2565
+ """ # noqa: E501
2566
+
2567
+ _param = self._post_aggregate_serialize(
2568
+ username=username,
2569
+ dataset=dataset,
2570
+ linker=linker,
2571
+ aggregate=aggregate,
2572
+ _request_auth=_request_auth,
2573
+ _content_type=_content_type,
2574
+ _headers=_headers,
2575
+ _host_index=_host_index
2576
+ )
2577
+
2578
+ _response_types_map: Dict[str, Optional[str]] = {
2579
+ '200': "str",
2580
+ '422': "HTTPValidationError",
2581
+ }
2582
+ response_data = self.api_client.call_api(
2583
+ *_param,
2584
+ _request_timeout=_request_timeout
2585
+ )
2586
+ response_data.read()
2587
+ return self.api_client.response_deserialize(
2588
+ response_data=response_data,
2589
+ response_types_map=_response_types_map,
2590
+ ).data
2591
+
2592
+
2593
+ @validate_call
2594
+ def post_aggregate_with_http_info(
2595
+ self,
2596
+ username: StrictStr,
2597
+ dataset: StrictStr,
2598
+ linker: StrictStr,
2599
+ aggregate: List[Aggregate],
2600
+ _request_timeout: Union[
2601
+ None,
2602
+ Annotated[StrictFloat, Field(gt=0)],
2603
+ Tuple[
2604
+ Annotated[StrictFloat, Field(gt=0)],
2605
+ Annotated[StrictFloat, Field(gt=0)]
2606
+ ]
2607
+ ] = None,
2608
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2609
+ _content_type: Optional[StrictStr] = None,
2610
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2611
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2612
+ ) -> ApiResponse[str]:
2613
+ """Save aggregation list
2614
+
2615
+
2616
+ :param username: (required)
2617
+ :type username: str
2618
+ :param dataset: (required)
2619
+ :type dataset: str
2620
+ :param linker: (required)
2621
+ :type linker: str
2622
+ :param aggregate: (required)
2623
+ :type aggregate: List[Aggregate]
2624
+ :param _request_timeout: timeout setting for this request. If one
2625
+ number provided, it will be total request
2626
+ timeout. It can also be a pair (tuple) of
2627
+ (connection, read) timeouts.
2628
+ :type _request_timeout: int, tuple(int, int), optional
2629
+ :param _request_auth: set to override the auth_settings for an a single
2630
+ request; this effectively ignores the
2631
+ authentication in the spec for a single request.
2632
+ :type _request_auth: dict, optional
2633
+ :param _content_type: force content-type for the request.
2634
+ :type _content_type: str, Optional
2635
+ :param _headers: set to override the headers for a single
2636
+ request; this effectively ignores the headers
2637
+ in the spec for a single request.
2638
+ :type _headers: dict, optional
2639
+ :param _host_index: set to override the host_index for a single
2640
+ request; this effectively ignores the host_index
2641
+ in the spec for a single request.
2642
+ :type _host_index: int, optional
2643
+ :return: Returns the result object.
2644
+ """ # noqa: E501
2645
+
2646
+ _param = self._post_aggregate_serialize(
2647
+ username=username,
2648
+ dataset=dataset,
2649
+ linker=linker,
2650
+ aggregate=aggregate,
2651
+ _request_auth=_request_auth,
2652
+ _content_type=_content_type,
2653
+ _headers=_headers,
2654
+ _host_index=_host_index
2655
+ )
2656
+
2657
+ _response_types_map: Dict[str, Optional[str]] = {
2658
+ '200': "str",
2659
+ '422': "HTTPValidationError",
2660
+ }
2661
+ response_data = self.api_client.call_api(
2662
+ *_param,
2663
+ _request_timeout=_request_timeout
2664
+ )
2665
+ response_data.read()
2666
+ return self.api_client.response_deserialize(
2667
+ response_data=response_data,
2668
+ response_types_map=_response_types_map,
2669
+ )
2670
+
2671
+
2672
+ @validate_call
2673
+ def post_aggregate_without_preload_content(
2674
+ self,
2675
+ username: StrictStr,
2676
+ dataset: StrictStr,
2677
+ linker: StrictStr,
2678
+ aggregate: List[Aggregate],
2679
+ _request_timeout: Union[
2680
+ None,
2681
+ Annotated[StrictFloat, Field(gt=0)],
2682
+ Tuple[
2683
+ Annotated[StrictFloat, Field(gt=0)],
2684
+ Annotated[StrictFloat, Field(gt=0)]
2685
+ ]
2686
+ ] = None,
2687
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2688
+ _content_type: Optional[StrictStr] = None,
2689
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2690
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2691
+ ) -> RESTResponseType:
2692
+ """Save aggregation list
2693
+
2694
+
2695
+ :param username: (required)
2696
+ :type username: str
2697
+ :param dataset: (required)
2698
+ :type dataset: str
2699
+ :param linker: (required)
2700
+ :type linker: str
2701
+ :param aggregate: (required)
2702
+ :type aggregate: List[Aggregate]
2703
+ :param _request_timeout: timeout setting for this request. If one
2704
+ number provided, it will be total request
2705
+ timeout. It can also be a pair (tuple) of
2706
+ (connection, read) timeouts.
2707
+ :type _request_timeout: int, tuple(int, int), optional
2708
+ :param _request_auth: set to override the auth_settings for an a single
2709
+ request; this effectively ignores the
2710
+ authentication in the spec for a single request.
2711
+ :type _request_auth: dict, optional
2712
+ :param _content_type: force content-type for the request.
2713
+ :type _content_type: str, Optional
2714
+ :param _headers: set to override the headers for a single
2715
+ request; this effectively ignores the headers
2716
+ in the spec for a single request.
2717
+ :type _headers: dict, optional
2718
+ :param _host_index: set to override the host_index for a single
2719
+ request; this effectively ignores the host_index
2720
+ in the spec for a single request.
2721
+ :type _host_index: int, optional
2722
+ :return: Returns the result object.
2723
+ """ # noqa: E501
2724
+
2725
+ _param = self._post_aggregate_serialize(
2726
+ username=username,
2727
+ dataset=dataset,
2728
+ linker=linker,
2729
+ aggregate=aggregate,
2730
+ _request_auth=_request_auth,
2731
+ _content_type=_content_type,
2732
+ _headers=_headers,
2733
+ _host_index=_host_index
2734
+ )
2735
+
2736
+ _response_types_map: Dict[str, Optional[str]] = {
2737
+ '200': "str",
2738
+ '422': "HTTPValidationError",
2739
+ }
2740
+ response_data = self.api_client.call_api(
2741
+ *_param,
2742
+ _request_timeout=_request_timeout
2743
+ )
2744
+ return response_data.response
2745
+
2746
+
2747
+ def _post_aggregate_serialize(
2748
+ self,
2749
+ username,
2750
+ dataset,
2751
+ linker,
2752
+ aggregate,
2753
+ _request_auth,
2754
+ _content_type,
2755
+ _headers,
2756
+ _host_index,
2757
+ ) -> RequestSerialized:
2758
+
2759
+ _host = None
2760
+
2761
+ _collection_formats: Dict[str, str] = {
2762
+ 'Aggregate': '',
2763
+ }
2764
+
2765
+ _path_params: Dict[str, str] = {}
2766
+ _query_params: List[Tuple[str, str]] = []
2767
+ _header_params: Dict[str, Optional[str]] = _headers or {}
2768
+ _form_params: List[Tuple[str, str]] = []
2769
+ _files: Dict[
2770
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
2771
+ ] = {}
2772
+ _body_params: Optional[bytes] = None
2773
+
2774
+ # process the path parameters
2775
+ # process the query parameters
2776
+ if username is not None:
2777
+
2778
+ _query_params.append(('username', username))
2779
+
2780
+ if dataset is not None:
2781
+
2782
+ _query_params.append(('dataset', dataset))
2783
+
2784
+ if linker is not None:
2785
+
2786
+ _query_params.append(('linker', linker))
2787
+
2788
+ # process the header parameters
2789
+ # process the form parameters
2790
+ # process the body parameter
2791
+ if aggregate is not None:
2792
+ _body_params = aggregate
2793
+
2794
+
2795
+ # set the HTTP header `Accept`
2796
+ if 'Accept' not in _header_params:
2797
+ _header_params['Accept'] = self.api_client.select_header_accept(
2798
+ [
2799
+ 'application/json'
2800
+ ]
2801
+ )
2802
+
2803
+ # set the HTTP header `Content-Type`
2804
+ if _content_type:
2805
+ _header_params['Content-Type'] = _content_type
2806
+ else:
2807
+ _default_content_type = (
2808
+ self.api_client.select_header_content_type(
2809
+ [
2810
+ 'application/json'
2811
+ ]
2812
+ )
2813
+ )
2814
+ if _default_content_type is not None:
2815
+ _header_params['Content-Type'] = _default_content_type
2816
+
2817
+ # authentication setting
2818
+ _auth_settings: List[str] = [
2819
+ 'QAnswer-Api-Key',
2820
+ 'Bearer token'
2821
+ ]
2822
+
2823
+ return self.api_client.param_serialize(
2824
+ method='POST',
2825
+ resource_path='/backend/api/tasks/rdf/linker/aggregate',
2826
+ path_params=_path_params,
2827
+ query_params=_query_params,
2828
+ header_params=_header_params,
2829
+ body=_body_params,
2830
+ post_params=_form_params,
2831
+ files=_files,
2832
+ auth_settings=_auth_settings,
2833
+ collection_formats=_collection_formats,
2834
+ _host=_host,
2835
+ _request_auth=_request_auth
2836
+ )
2837
+
2838
+
2839
+
2840
+
2841
+ @validate_call
2842
+ def post_order_evaluate(
2843
+ self,
2844
+ username: StrictStr,
2845
+ dataset: StrictStr,
2846
+ linker: StrictStr,
2847
+ linking_result_input: LinkingResultInput,
2848
+ _request_timeout: Union[
2849
+ None,
2850
+ Annotated[StrictFloat, Field(gt=0)],
2851
+ Tuple[
2852
+ Annotated[StrictFloat, Field(gt=0)],
2853
+ Annotated[StrictFloat, Field(gt=0)]
2854
+ ]
2855
+ ] = None,
2856
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2857
+ _content_type: Optional[StrictStr] = None,
2858
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2859
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2860
+ ) -> str:
2861
+ """Save evaluation results
2862
+
2863
+
2864
+ :param username: (required)
2865
+ :type username: str
2866
+ :param dataset: (required)
2867
+ :type dataset: str
2868
+ :param linker: (required)
2869
+ :type linker: str
2870
+ :param linking_result_input: (required)
2871
+ :type linking_result_input: LinkingResultInput
2872
+ :param _request_timeout: timeout setting for this request. If one
2873
+ number provided, it will be total request
2874
+ timeout. It can also be a pair (tuple) of
2875
+ (connection, read) timeouts.
2876
+ :type _request_timeout: int, tuple(int, int), optional
2877
+ :param _request_auth: set to override the auth_settings for an a single
2878
+ request; this effectively ignores the
2879
+ authentication in the spec for a single request.
2880
+ :type _request_auth: dict, optional
2881
+ :param _content_type: force content-type for the request.
2882
+ :type _content_type: str, Optional
2883
+ :param _headers: set to override the headers for a single
2884
+ request; this effectively ignores the headers
2885
+ in the spec for a single request.
2886
+ :type _headers: dict, optional
2887
+ :param _host_index: set to override the host_index for a single
2888
+ request; this effectively ignores the host_index
2889
+ in the spec for a single request.
2890
+ :type _host_index: int, optional
2891
+ :return: Returns the result object.
2892
+ """ # noqa: E501
2893
+
2894
+ _param = self._post_order_evaluate_serialize(
2895
+ username=username,
2896
+ dataset=dataset,
2897
+ linker=linker,
2898
+ linking_result_input=linking_result_input,
2899
+ _request_auth=_request_auth,
2900
+ _content_type=_content_type,
2901
+ _headers=_headers,
2902
+ _host_index=_host_index
2903
+ )
2904
+
2905
+ _response_types_map: Dict[str, Optional[str]] = {
2906
+ '200': "str",
2907
+ '422': "HTTPValidationError",
2908
+ }
2909
+ response_data = self.api_client.call_api(
2910
+ *_param,
2911
+ _request_timeout=_request_timeout
2912
+ )
2913
+ response_data.read()
2914
+ return self.api_client.response_deserialize(
2915
+ response_data=response_data,
2916
+ response_types_map=_response_types_map,
2917
+ ).data
2918
+
2919
+
2920
+ @validate_call
2921
+ def post_order_evaluate_with_http_info(
2922
+ self,
2923
+ username: StrictStr,
2924
+ dataset: StrictStr,
2925
+ linker: StrictStr,
2926
+ linking_result_input: LinkingResultInput,
2927
+ _request_timeout: Union[
2928
+ None,
2929
+ Annotated[StrictFloat, Field(gt=0)],
2930
+ Tuple[
2931
+ Annotated[StrictFloat, Field(gt=0)],
2932
+ Annotated[StrictFloat, Field(gt=0)]
2933
+ ]
2934
+ ] = None,
2935
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2936
+ _content_type: Optional[StrictStr] = None,
2937
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2938
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2939
+ ) -> ApiResponse[str]:
2940
+ """Save evaluation results
2941
+
2942
+
2943
+ :param username: (required)
2944
+ :type username: str
2945
+ :param dataset: (required)
2946
+ :type dataset: str
2947
+ :param linker: (required)
2948
+ :type linker: str
2949
+ :param linking_result_input: (required)
2950
+ :type linking_result_input: LinkingResultInput
2951
+ :param _request_timeout: timeout setting for this request. If one
2952
+ number provided, it will be total request
2953
+ timeout. It can also be a pair (tuple) of
2954
+ (connection, read) timeouts.
2955
+ :type _request_timeout: int, tuple(int, int), optional
2956
+ :param _request_auth: set to override the auth_settings for an a single
2957
+ request; this effectively ignores the
2958
+ authentication in the spec for a single request.
2959
+ :type _request_auth: dict, optional
2960
+ :param _content_type: force content-type for the request.
2961
+ :type _content_type: str, Optional
2962
+ :param _headers: set to override the headers for a single
2963
+ request; this effectively ignores the headers
2964
+ in the spec for a single request.
2965
+ :type _headers: dict, optional
2966
+ :param _host_index: set to override the host_index for a single
2967
+ request; this effectively ignores the host_index
2968
+ in the spec for a single request.
2969
+ :type _host_index: int, optional
2970
+ :return: Returns the result object.
2971
+ """ # noqa: E501
2972
+
2973
+ _param = self._post_order_evaluate_serialize(
2974
+ username=username,
2975
+ dataset=dataset,
2976
+ linker=linker,
2977
+ linking_result_input=linking_result_input,
2978
+ _request_auth=_request_auth,
2979
+ _content_type=_content_type,
2980
+ _headers=_headers,
2981
+ _host_index=_host_index
2982
+ )
2983
+
2984
+ _response_types_map: Dict[str, Optional[str]] = {
2985
+ '200': "str",
2986
+ '422': "HTTPValidationError",
2987
+ }
2988
+ response_data = self.api_client.call_api(
2989
+ *_param,
2990
+ _request_timeout=_request_timeout
2991
+ )
2992
+ response_data.read()
2993
+ return self.api_client.response_deserialize(
2994
+ response_data=response_data,
2995
+ response_types_map=_response_types_map,
2996
+ )
2997
+
2998
+
2999
+ @validate_call
3000
+ def post_order_evaluate_without_preload_content(
3001
+ self,
3002
+ username: StrictStr,
3003
+ dataset: StrictStr,
3004
+ linker: StrictStr,
3005
+ linking_result_input: LinkingResultInput,
3006
+ _request_timeout: Union[
3007
+ None,
3008
+ Annotated[StrictFloat, Field(gt=0)],
3009
+ Tuple[
3010
+ Annotated[StrictFloat, Field(gt=0)],
3011
+ Annotated[StrictFloat, Field(gt=0)]
3012
+ ]
3013
+ ] = None,
3014
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3015
+ _content_type: Optional[StrictStr] = None,
3016
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3017
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3018
+ ) -> RESTResponseType:
3019
+ """Save evaluation results
3020
+
3021
+
3022
+ :param username: (required)
3023
+ :type username: str
3024
+ :param dataset: (required)
3025
+ :type dataset: str
3026
+ :param linker: (required)
3027
+ :type linker: str
3028
+ :param linking_result_input: (required)
3029
+ :type linking_result_input: LinkingResultInput
3030
+ :param _request_timeout: timeout setting for this request. If one
3031
+ number provided, it will be total request
3032
+ timeout. It can also be a pair (tuple) of
3033
+ (connection, read) timeouts.
3034
+ :type _request_timeout: int, tuple(int, int), optional
3035
+ :param _request_auth: set to override the auth_settings for an a single
3036
+ request; this effectively ignores the
3037
+ authentication in the spec for a single request.
3038
+ :type _request_auth: dict, optional
3039
+ :param _content_type: force content-type for the request.
3040
+ :type _content_type: str, Optional
3041
+ :param _headers: set to override the headers for a single
3042
+ request; this effectively ignores the headers
3043
+ in the spec for a single request.
3044
+ :type _headers: dict, optional
3045
+ :param _host_index: set to override the host_index for a single
3046
+ request; this effectively ignores the host_index
3047
+ in the spec for a single request.
3048
+ :type _host_index: int, optional
3049
+ :return: Returns the result object.
3050
+ """ # noqa: E501
3051
+
3052
+ _param = self._post_order_evaluate_serialize(
3053
+ username=username,
3054
+ dataset=dataset,
3055
+ linker=linker,
3056
+ linking_result_input=linking_result_input,
3057
+ _request_auth=_request_auth,
3058
+ _content_type=_content_type,
3059
+ _headers=_headers,
3060
+ _host_index=_host_index
3061
+ )
3062
+
3063
+ _response_types_map: Dict[str, Optional[str]] = {
3064
+ '200': "str",
3065
+ '422': "HTTPValidationError",
3066
+ }
3067
+ response_data = self.api_client.call_api(
3068
+ *_param,
3069
+ _request_timeout=_request_timeout
3070
+ )
3071
+ return response_data.response
3072
+
3073
+
3074
+ def _post_order_evaluate_serialize(
3075
+ self,
3076
+ username,
3077
+ dataset,
3078
+ linker,
3079
+ linking_result_input,
3080
+ _request_auth,
3081
+ _content_type,
3082
+ _headers,
3083
+ _host_index,
3084
+ ) -> RequestSerialized:
3085
+
3086
+ _host = None
3087
+
3088
+ _collection_formats: Dict[str, str] = {
3089
+ }
3090
+
3091
+ _path_params: Dict[str, str] = {}
3092
+ _query_params: List[Tuple[str, str]] = []
3093
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3094
+ _form_params: List[Tuple[str, str]] = []
3095
+ _files: Dict[
3096
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3097
+ ] = {}
3098
+ _body_params: Optional[bytes] = None
3099
+
3100
+ # process the path parameters
3101
+ # process the query parameters
3102
+ if username is not None:
3103
+
3104
+ _query_params.append(('username', username))
3105
+
3106
+ if dataset is not None:
3107
+
3108
+ _query_params.append(('dataset', dataset))
3109
+
3110
+ if linker is not None:
3111
+
3112
+ _query_params.append(('linker', linker))
3113
+
3114
+ # process the header parameters
3115
+ # process the form parameters
3116
+ # process the body parameter
3117
+ if linking_result_input is not None:
3118
+ _body_params = linking_result_input
3119
+
3120
+
3121
+ # set the HTTP header `Accept`
3122
+ if 'Accept' not in _header_params:
3123
+ _header_params['Accept'] = self.api_client.select_header_accept(
3124
+ [
3125
+ 'application/json'
3126
+ ]
3127
+ )
3128
+
3129
+ # set the HTTP header `Content-Type`
3130
+ if _content_type:
3131
+ _header_params['Content-Type'] = _content_type
3132
+ else:
3133
+ _default_content_type = (
3134
+ self.api_client.select_header_content_type(
3135
+ [
3136
+ 'application/json'
3137
+ ]
3138
+ )
3139
+ )
3140
+ if _default_content_type is not None:
3141
+ _header_params['Content-Type'] = _default_content_type
3142
+
3143
+ # authentication setting
3144
+ _auth_settings: List[str] = [
3145
+ 'QAnswer-Api-Key',
3146
+ 'Bearer token'
3147
+ ]
3148
+
3149
+ return self.api_client.param_serialize(
3150
+ method='POST',
3151
+ resource_path='/backend/api/tasks/rdf/linker/evaluate',
3152
+ path_params=_path_params,
3153
+ query_params=_query_params,
3154
+ header_params=_header_params,
3155
+ body=_body_params,
3156
+ post_params=_form_params,
3157
+ files=_files,
3158
+ auth_settings=_auth_settings,
3159
+ collection_formats=_collection_formats,
3160
+ _host=_host,
3161
+ _request_auth=_request_auth
3162
+ )
3163
+
3164
+
3165
+
3166
+
3167
+ @validate_call
3168
+ def put_aggregate(
3169
+ self,
3170
+ username: StrictStr,
3171
+ dataset: StrictStr,
3172
+ linker: StrictStr,
3173
+ aggregate: List[Aggregate],
3174
+ _request_timeout: Union[
3175
+ None,
3176
+ Annotated[StrictFloat, Field(gt=0)],
3177
+ Tuple[
3178
+ Annotated[StrictFloat, Field(gt=0)],
3179
+ Annotated[StrictFloat, Field(gt=0)]
3180
+ ]
3181
+ ] = None,
3182
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3183
+ _content_type: Optional[StrictStr] = None,
3184
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3185
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3186
+ ) -> str:
3187
+ """Update aggregation
3188
+
3189
+
3190
+ :param username: (required)
3191
+ :type username: str
3192
+ :param dataset: (required)
3193
+ :type dataset: str
3194
+ :param linker: (required)
3195
+ :type linker: str
3196
+ :param aggregate: (required)
3197
+ :type aggregate: List[Aggregate]
3198
+ :param _request_timeout: timeout setting for this request. If one
3199
+ number provided, it will be total request
3200
+ timeout. It can also be a pair (tuple) of
3201
+ (connection, read) timeouts.
3202
+ :type _request_timeout: int, tuple(int, int), optional
3203
+ :param _request_auth: set to override the auth_settings for an a single
3204
+ request; this effectively ignores the
3205
+ authentication in the spec for a single request.
3206
+ :type _request_auth: dict, optional
3207
+ :param _content_type: force content-type for the request.
3208
+ :type _content_type: str, Optional
3209
+ :param _headers: set to override the headers for a single
3210
+ request; this effectively ignores the headers
3211
+ in the spec for a single request.
3212
+ :type _headers: dict, optional
3213
+ :param _host_index: set to override the host_index for a single
3214
+ request; this effectively ignores the host_index
3215
+ in the spec for a single request.
3216
+ :type _host_index: int, optional
3217
+ :return: Returns the result object.
3218
+ """ # noqa: E501
3219
+
3220
+ _param = self._put_aggregate_serialize(
3221
+ username=username,
3222
+ dataset=dataset,
3223
+ linker=linker,
3224
+ aggregate=aggregate,
3225
+ _request_auth=_request_auth,
3226
+ _content_type=_content_type,
3227
+ _headers=_headers,
3228
+ _host_index=_host_index
3229
+ )
3230
+
3231
+ _response_types_map: Dict[str, Optional[str]] = {
3232
+ '200': "str",
3233
+ '422': "HTTPValidationError",
3234
+ }
3235
+ response_data = self.api_client.call_api(
3236
+ *_param,
3237
+ _request_timeout=_request_timeout
3238
+ )
3239
+ response_data.read()
3240
+ return self.api_client.response_deserialize(
3241
+ response_data=response_data,
3242
+ response_types_map=_response_types_map,
3243
+ ).data
3244
+
3245
+
3246
+ @validate_call
3247
+ def put_aggregate_with_http_info(
3248
+ self,
3249
+ username: StrictStr,
3250
+ dataset: StrictStr,
3251
+ linker: StrictStr,
3252
+ aggregate: List[Aggregate],
3253
+ _request_timeout: Union[
3254
+ None,
3255
+ Annotated[StrictFloat, Field(gt=0)],
3256
+ Tuple[
3257
+ Annotated[StrictFloat, Field(gt=0)],
3258
+ Annotated[StrictFloat, Field(gt=0)]
3259
+ ]
3260
+ ] = None,
3261
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3262
+ _content_type: Optional[StrictStr] = None,
3263
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3264
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3265
+ ) -> ApiResponse[str]:
3266
+ """Update aggregation
3267
+
3268
+
3269
+ :param username: (required)
3270
+ :type username: str
3271
+ :param dataset: (required)
3272
+ :type dataset: str
3273
+ :param linker: (required)
3274
+ :type linker: str
3275
+ :param aggregate: (required)
3276
+ :type aggregate: List[Aggregate]
3277
+ :param _request_timeout: timeout setting for this request. If one
3278
+ number provided, it will be total request
3279
+ timeout. It can also be a pair (tuple) of
3280
+ (connection, read) timeouts.
3281
+ :type _request_timeout: int, tuple(int, int), optional
3282
+ :param _request_auth: set to override the auth_settings for an a single
3283
+ request; this effectively ignores the
3284
+ authentication in the spec for a single request.
3285
+ :type _request_auth: dict, optional
3286
+ :param _content_type: force content-type for the request.
3287
+ :type _content_type: str, Optional
3288
+ :param _headers: set to override the headers for a single
3289
+ request; this effectively ignores the headers
3290
+ in the spec for a single request.
3291
+ :type _headers: dict, optional
3292
+ :param _host_index: set to override the host_index for a single
3293
+ request; this effectively ignores the host_index
3294
+ in the spec for a single request.
3295
+ :type _host_index: int, optional
3296
+ :return: Returns the result object.
3297
+ """ # noqa: E501
3298
+
3299
+ _param = self._put_aggregate_serialize(
3300
+ username=username,
3301
+ dataset=dataset,
3302
+ linker=linker,
3303
+ aggregate=aggregate,
3304
+ _request_auth=_request_auth,
3305
+ _content_type=_content_type,
3306
+ _headers=_headers,
3307
+ _host_index=_host_index
3308
+ )
3309
+
3310
+ _response_types_map: Dict[str, Optional[str]] = {
3311
+ '200': "str",
3312
+ '422': "HTTPValidationError",
3313
+ }
3314
+ response_data = self.api_client.call_api(
3315
+ *_param,
3316
+ _request_timeout=_request_timeout
3317
+ )
3318
+ response_data.read()
3319
+ return self.api_client.response_deserialize(
3320
+ response_data=response_data,
3321
+ response_types_map=_response_types_map,
3322
+ )
3323
+
3324
+
3325
+ @validate_call
3326
+ def put_aggregate_without_preload_content(
3327
+ self,
3328
+ username: StrictStr,
3329
+ dataset: StrictStr,
3330
+ linker: StrictStr,
3331
+ aggregate: List[Aggregate],
3332
+ _request_timeout: Union[
3333
+ None,
3334
+ Annotated[StrictFloat, Field(gt=0)],
3335
+ Tuple[
3336
+ Annotated[StrictFloat, Field(gt=0)],
3337
+ Annotated[StrictFloat, Field(gt=0)]
3338
+ ]
3339
+ ] = None,
3340
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3341
+ _content_type: Optional[StrictStr] = None,
3342
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3343
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3344
+ ) -> RESTResponseType:
3345
+ """Update aggregation
3346
+
3347
+
3348
+ :param username: (required)
3349
+ :type username: str
3350
+ :param dataset: (required)
3351
+ :type dataset: str
3352
+ :param linker: (required)
3353
+ :type linker: str
3354
+ :param aggregate: (required)
3355
+ :type aggregate: List[Aggregate]
3356
+ :param _request_timeout: timeout setting for this request. If one
3357
+ number provided, it will be total request
3358
+ timeout. It can also be a pair (tuple) of
3359
+ (connection, read) timeouts.
3360
+ :type _request_timeout: int, tuple(int, int), optional
3361
+ :param _request_auth: set to override the auth_settings for an a single
3362
+ request; this effectively ignores the
3363
+ authentication in the spec for a single request.
3364
+ :type _request_auth: dict, optional
3365
+ :param _content_type: force content-type for the request.
3366
+ :type _content_type: str, Optional
3367
+ :param _headers: set to override the headers for a single
3368
+ request; this effectively ignores the headers
3369
+ in the spec for a single request.
3370
+ :type _headers: dict, optional
3371
+ :param _host_index: set to override the host_index for a single
3372
+ request; this effectively ignores the host_index
3373
+ in the spec for a single request.
3374
+ :type _host_index: int, optional
3375
+ :return: Returns the result object.
3376
+ """ # noqa: E501
3377
+
3378
+ _param = self._put_aggregate_serialize(
3379
+ username=username,
3380
+ dataset=dataset,
3381
+ linker=linker,
3382
+ aggregate=aggregate,
3383
+ _request_auth=_request_auth,
3384
+ _content_type=_content_type,
3385
+ _headers=_headers,
3386
+ _host_index=_host_index
3387
+ )
3388
+
3389
+ _response_types_map: Dict[str, Optional[str]] = {
3390
+ '200': "str",
3391
+ '422': "HTTPValidationError",
3392
+ }
3393
+ response_data = self.api_client.call_api(
3394
+ *_param,
3395
+ _request_timeout=_request_timeout
3396
+ )
3397
+ return response_data.response
3398
+
3399
+
3400
+ def _put_aggregate_serialize(
3401
+ self,
3402
+ username,
3403
+ dataset,
3404
+ linker,
3405
+ aggregate,
3406
+ _request_auth,
3407
+ _content_type,
3408
+ _headers,
3409
+ _host_index,
3410
+ ) -> RequestSerialized:
3411
+
3412
+ _host = None
3413
+
3414
+ _collection_formats: Dict[str, str] = {
3415
+ 'Aggregate': '',
3416
+ }
3417
+
3418
+ _path_params: Dict[str, str] = {}
3419
+ _query_params: List[Tuple[str, str]] = []
3420
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3421
+ _form_params: List[Tuple[str, str]] = []
3422
+ _files: Dict[
3423
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3424
+ ] = {}
3425
+ _body_params: Optional[bytes] = None
3426
+
3427
+ # process the path parameters
3428
+ # process the query parameters
3429
+ if username is not None:
3430
+
3431
+ _query_params.append(('username', username))
3432
+
3433
+ if dataset is not None:
3434
+
3435
+ _query_params.append(('dataset', dataset))
3436
+
3437
+ if linker is not None:
3438
+
3439
+ _query_params.append(('linker', linker))
3440
+
3441
+ # process the header parameters
3442
+ # process the form parameters
3443
+ # process the body parameter
3444
+ if aggregate is not None:
3445
+ _body_params = aggregate
3446
+
3447
+
3448
+ # set the HTTP header `Accept`
3449
+ if 'Accept' not in _header_params:
3450
+ _header_params['Accept'] = self.api_client.select_header_accept(
3451
+ [
3452
+ 'application/json'
3453
+ ]
3454
+ )
3455
+
3456
+ # set the HTTP header `Content-Type`
3457
+ if _content_type:
3458
+ _header_params['Content-Type'] = _content_type
3459
+ else:
3460
+ _default_content_type = (
3461
+ self.api_client.select_header_content_type(
3462
+ [
3463
+ 'application/json'
3464
+ ]
3465
+ )
3466
+ )
3467
+ if _default_content_type is not None:
3468
+ _header_params['Content-Type'] = _default_content_type
3469
+
3470
+ # authentication setting
3471
+ _auth_settings: List[str] = [
3472
+ 'QAnswer-Api-Key',
3473
+ 'Bearer token'
3474
+ ]
3475
+
3476
+ return self.api_client.param_serialize(
3477
+ method='PUT',
3478
+ resource_path='/backend/api/tasks/rdf/linker/aggregate',
3479
+ path_params=_path_params,
3480
+ query_params=_query_params,
3481
+ header_params=_header_params,
3482
+ body=_body_params,
3483
+ post_params=_form_params,
3484
+ files=_files,
3485
+ auth_settings=_auth_settings,
3486
+ collection_formats=_collection_formats,
3487
+ _host=_host,
3488
+ _request_auth=_request_auth
3489
+ )
3490
+
3491
+
3492
+
3493
+
3494
+ @validate_call
3495
+ def train(
3496
+ self,
3497
+ username: StrictStr,
3498
+ dataset: StrictStr,
3499
+ linker: StrictStr,
3500
+ _request_timeout: Union[
3501
+ None,
3502
+ Annotated[StrictFloat, Field(gt=0)],
3503
+ Tuple[
3504
+ Annotated[StrictFloat, Field(gt=0)],
3505
+ Annotated[StrictFloat, Field(gt=0)]
3506
+ ]
3507
+ ] = None,
3508
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3509
+ _content_type: Optional[StrictStr] = None,
3510
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3511
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3512
+ ) -> str:
3513
+ """Train a linker
3514
+
3515
+
3516
+ :param username: (required)
3517
+ :type username: str
3518
+ :param dataset: (required)
3519
+ :type dataset: str
3520
+ :param linker: (required)
3521
+ :type linker: str
3522
+ :param _request_timeout: timeout setting for this request. If one
3523
+ number provided, it will be total request
3524
+ timeout. It can also be a pair (tuple) of
3525
+ (connection, read) timeouts.
3526
+ :type _request_timeout: int, tuple(int, int), optional
3527
+ :param _request_auth: set to override the auth_settings for an a single
3528
+ request; this effectively ignores the
3529
+ authentication in the spec for a single request.
3530
+ :type _request_auth: dict, optional
3531
+ :param _content_type: force content-type for the request.
3532
+ :type _content_type: str, Optional
3533
+ :param _headers: set to override the headers for a single
3534
+ request; this effectively ignores the headers
3535
+ in the spec for a single request.
3536
+ :type _headers: dict, optional
3537
+ :param _host_index: set to override the host_index for a single
3538
+ request; this effectively ignores the host_index
3539
+ in the spec for a single request.
3540
+ :type _host_index: int, optional
3541
+ :return: Returns the result object.
3542
+ """ # noqa: E501
3543
+
3544
+ _param = self._train_serialize(
3545
+ username=username,
3546
+ dataset=dataset,
3547
+ linker=linker,
3548
+ _request_auth=_request_auth,
3549
+ _content_type=_content_type,
3550
+ _headers=_headers,
3551
+ _host_index=_host_index
3552
+ )
3553
+
3554
+ _response_types_map: Dict[str, Optional[str]] = {
3555
+ '200': "str",
3556
+ '422': "HTTPValidationError",
3557
+ }
3558
+ response_data = self.api_client.call_api(
3559
+ *_param,
3560
+ _request_timeout=_request_timeout
3561
+ )
3562
+ response_data.read()
3563
+ return self.api_client.response_deserialize(
3564
+ response_data=response_data,
3565
+ response_types_map=_response_types_map,
3566
+ ).data
3567
+
3568
+
3569
+ @validate_call
3570
+ def train_with_http_info(
3571
+ self,
3572
+ username: StrictStr,
3573
+ dataset: StrictStr,
3574
+ linker: StrictStr,
3575
+ _request_timeout: Union[
3576
+ None,
3577
+ Annotated[StrictFloat, Field(gt=0)],
3578
+ Tuple[
3579
+ Annotated[StrictFloat, Field(gt=0)],
3580
+ Annotated[StrictFloat, Field(gt=0)]
3581
+ ]
3582
+ ] = None,
3583
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3584
+ _content_type: Optional[StrictStr] = None,
3585
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3586
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3587
+ ) -> ApiResponse[str]:
3588
+ """Train a linker
3589
+
3590
+
3591
+ :param username: (required)
3592
+ :type username: str
3593
+ :param dataset: (required)
3594
+ :type dataset: str
3595
+ :param linker: (required)
3596
+ :type linker: str
3597
+ :param _request_timeout: timeout setting for this request. If one
3598
+ number provided, it will be total request
3599
+ timeout. It can also be a pair (tuple) of
3600
+ (connection, read) timeouts.
3601
+ :type _request_timeout: int, tuple(int, int), optional
3602
+ :param _request_auth: set to override the auth_settings for an a single
3603
+ request; this effectively ignores the
3604
+ authentication in the spec for a single request.
3605
+ :type _request_auth: dict, optional
3606
+ :param _content_type: force content-type for the request.
3607
+ :type _content_type: str, Optional
3608
+ :param _headers: set to override the headers for a single
3609
+ request; this effectively ignores the headers
3610
+ in the spec for a single request.
3611
+ :type _headers: dict, optional
3612
+ :param _host_index: set to override the host_index for a single
3613
+ request; this effectively ignores the host_index
3614
+ in the spec for a single request.
3615
+ :type _host_index: int, optional
3616
+ :return: Returns the result object.
3617
+ """ # noqa: E501
3618
+
3619
+ _param = self._train_serialize(
3620
+ username=username,
3621
+ dataset=dataset,
3622
+ linker=linker,
3623
+ _request_auth=_request_auth,
3624
+ _content_type=_content_type,
3625
+ _headers=_headers,
3626
+ _host_index=_host_index
3627
+ )
3628
+
3629
+ _response_types_map: Dict[str, Optional[str]] = {
3630
+ '200': "str",
3631
+ '422': "HTTPValidationError",
3632
+ }
3633
+ response_data = self.api_client.call_api(
3634
+ *_param,
3635
+ _request_timeout=_request_timeout
3636
+ )
3637
+ response_data.read()
3638
+ return self.api_client.response_deserialize(
3639
+ response_data=response_data,
3640
+ response_types_map=_response_types_map,
3641
+ )
3642
+
3643
+
3644
+ @validate_call
3645
+ def train_without_preload_content(
3646
+ self,
3647
+ username: StrictStr,
3648
+ dataset: StrictStr,
3649
+ linker: StrictStr,
3650
+ _request_timeout: Union[
3651
+ None,
3652
+ Annotated[StrictFloat, Field(gt=0)],
3653
+ Tuple[
3654
+ Annotated[StrictFloat, Field(gt=0)],
3655
+ Annotated[StrictFloat, Field(gt=0)]
3656
+ ]
3657
+ ] = None,
3658
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3659
+ _content_type: Optional[StrictStr] = None,
3660
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3661
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3662
+ ) -> RESTResponseType:
3663
+ """Train a linker
3664
+
3665
+
3666
+ :param username: (required)
3667
+ :type username: str
3668
+ :param dataset: (required)
3669
+ :type dataset: str
3670
+ :param linker: (required)
3671
+ :type linker: str
3672
+ :param _request_timeout: timeout setting for this request. If one
3673
+ number provided, it will be total request
3674
+ timeout. It can also be a pair (tuple) of
3675
+ (connection, read) timeouts.
3676
+ :type _request_timeout: int, tuple(int, int), optional
3677
+ :param _request_auth: set to override the auth_settings for an a single
3678
+ request; this effectively ignores the
3679
+ authentication in the spec for a single request.
3680
+ :type _request_auth: dict, optional
3681
+ :param _content_type: force content-type for the request.
3682
+ :type _content_type: str, Optional
3683
+ :param _headers: set to override the headers for a single
3684
+ request; this effectively ignores the headers
3685
+ in the spec for a single request.
3686
+ :type _headers: dict, optional
3687
+ :param _host_index: set to override the host_index for a single
3688
+ request; this effectively ignores the host_index
3689
+ in the spec for a single request.
3690
+ :type _host_index: int, optional
3691
+ :return: Returns the result object.
3692
+ """ # noqa: E501
3693
+
3694
+ _param = self._train_serialize(
3695
+ username=username,
3696
+ dataset=dataset,
3697
+ linker=linker,
3698
+ _request_auth=_request_auth,
3699
+ _content_type=_content_type,
3700
+ _headers=_headers,
3701
+ _host_index=_host_index
3702
+ )
3703
+
3704
+ _response_types_map: Dict[str, Optional[str]] = {
3705
+ '200': "str",
3706
+ '422': "HTTPValidationError",
3707
+ }
3708
+ response_data = self.api_client.call_api(
3709
+ *_param,
3710
+ _request_timeout=_request_timeout
3711
+ )
3712
+ return response_data.response
3713
+
3714
+
3715
+ def _train_serialize(
3716
+ self,
3717
+ username,
3718
+ dataset,
3719
+ linker,
3720
+ _request_auth,
3721
+ _content_type,
3722
+ _headers,
3723
+ _host_index,
3724
+ ) -> RequestSerialized:
3725
+
3726
+ _host = None
3727
+
3728
+ _collection_formats: Dict[str, str] = {
3729
+ }
3730
+
3731
+ _path_params: Dict[str, str] = {}
3732
+ _query_params: List[Tuple[str, str]] = []
3733
+ _header_params: Dict[str, Optional[str]] = _headers or {}
3734
+ _form_params: List[Tuple[str, str]] = []
3735
+ _files: Dict[
3736
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
3737
+ ] = {}
3738
+ _body_params: Optional[bytes] = None
3739
+
3740
+ # process the path parameters
3741
+ # process the query parameters
3742
+ if username is not None:
3743
+
3744
+ _query_params.append(('username', username))
3745
+
3746
+ if dataset is not None:
3747
+
3748
+ _query_params.append(('dataset', dataset))
3749
+
3750
+ if linker is not None:
3751
+
3752
+ _query_params.append(('linker', linker))
3753
+
3754
+ # process the header parameters
3755
+ # process the form parameters
3756
+ # process the body parameter
3757
+
3758
+
3759
+ # set the HTTP header `Accept`
3760
+ if 'Accept' not in _header_params:
3761
+ _header_params['Accept'] = self.api_client.select_header_accept(
3762
+ [
3763
+ 'application/json'
3764
+ ]
3765
+ )
3766
+
3767
+
3768
+ # authentication setting
3769
+ _auth_settings: List[str] = [
3770
+ 'QAnswer-Api-Key',
3771
+ 'Bearer token'
3772
+ ]
3773
+
3774
+ return self.api_client.param_serialize(
3775
+ method='POST',
3776
+ resource_path='/backend/api/tasks/rdf/linker/train',
3777
+ path_params=_path_params,
3778
+ query_params=_query_params,
3779
+ header_params=_header_params,
3780
+ body=_body_params,
3781
+ post_params=_form_params,
3782
+ files=_files,
3783
+ auth_settings=_auth_settings,
3784
+ collection_formats=_collection_formats,
3785
+ _host=_host,
3786
+ _request_auth=_request_auth
3787
+ )
3788
+
3789
+
3790
+
3791
+
3792
+ @validate_call
3793
+ def upload_labels(
3794
+ self,
3795
+ username: StrictStr,
3796
+ dataset: StrictStr,
3797
+ linker: StrictStr,
3798
+ languages: List[StrictStr],
3799
+ file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]],
3800
+ _request_timeout: Union[
3801
+ None,
3802
+ Annotated[StrictFloat, Field(gt=0)],
3803
+ Tuple[
3804
+ Annotated[StrictFloat, Field(gt=0)],
3805
+ Annotated[StrictFloat, Field(gt=0)]
3806
+ ]
3807
+ ] = None,
3808
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3809
+ _content_type: Optional[StrictStr] = None,
3810
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3811
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3812
+ ) -> str:
3813
+ """Upload labels for a linker
3814
+
3815
+
3816
+ :param username: (required)
3817
+ :type username: str
3818
+ :param dataset: (required)
3819
+ :type dataset: str
3820
+ :param linker: (required)
3821
+ :type linker: str
3822
+ :param languages: (required)
3823
+ :type languages: List[str]
3824
+ :param file: (required)
3825
+ :type file: bytearray
3826
+ :param _request_timeout: timeout setting for this request. If one
3827
+ number provided, it will be total request
3828
+ timeout. It can also be a pair (tuple) of
3829
+ (connection, read) timeouts.
3830
+ :type _request_timeout: int, tuple(int, int), optional
3831
+ :param _request_auth: set to override the auth_settings for an a single
3832
+ request; this effectively ignores the
3833
+ authentication in the spec for a single request.
3834
+ :type _request_auth: dict, optional
3835
+ :param _content_type: force content-type for the request.
3836
+ :type _content_type: str, Optional
3837
+ :param _headers: set to override the headers for a single
3838
+ request; this effectively ignores the headers
3839
+ in the spec for a single request.
3840
+ :type _headers: dict, optional
3841
+ :param _host_index: set to override the host_index for a single
3842
+ request; this effectively ignores the host_index
3843
+ in the spec for a single request.
3844
+ :type _host_index: int, optional
3845
+ :return: Returns the result object.
3846
+ """ # noqa: E501
3847
+
3848
+ _param = self._upload_labels_serialize(
3849
+ username=username,
3850
+ dataset=dataset,
3851
+ linker=linker,
3852
+ languages=languages,
3853
+ file=file,
3854
+ _request_auth=_request_auth,
3855
+ _content_type=_content_type,
3856
+ _headers=_headers,
3857
+ _host_index=_host_index
3858
+ )
3859
+
3860
+ _response_types_map: Dict[str, Optional[str]] = {
3861
+ '200': "str",
3862
+ '422': "HTTPValidationError",
3863
+ }
3864
+ response_data = self.api_client.call_api(
3865
+ *_param,
3866
+ _request_timeout=_request_timeout
3867
+ )
3868
+ response_data.read()
3869
+ return self.api_client.response_deserialize(
3870
+ response_data=response_data,
3871
+ response_types_map=_response_types_map,
3872
+ ).data
3873
+
3874
+
3875
+ @validate_call
3876
+ def upload_labels_with_http_info(
3877
+ self,
3878
+ username: StrictStr,
3879
+ dataset: StrictStr,
3880
+ linker: StrictStr,
3881
+ languages: List[StrictStr],
3882
+ file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]],
3883
+ _request_timeout: Union[
3884
+ None,
3885
+ Annotated[StrictFloat, Field(gt=0)],
3886
+ Tuple[
3887
+ Annotated[StrictFloat, Field(gt=0)],
3888
+ Annotated[StrictFloat, Field(gt=0)]
3889
+ ]
3890
+ ] = None,
3891
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3892
+ _content_type: Optional[StrictStr] = None,
3893
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3894
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3895
+ ) -> ApiResponse[str]:
3896
+ """Upload labels for a linker
3897
+
3898
+
3899
+ :param username: (required)
3900
+ :type username: str
3901
+ :param dataset: (required)
3902
+ :type dataset: str
3903
+ :param linker: (required)
3904
+ :type linker: str
3905
+ :param languages: (required)
3906
+ :type languages: List[str]
3907
+ :param file: (required)
3908
+ :type file: bytearray
3909
+ :param _request_timeout: timeout setting for this request. If one
3910
+ number provided, it will be total request
3911
+ timeout. It can also be a pair (tuple) of
3912
+ (connection, read) timeouts.
3913
+ :type _request_timeout: int, tuple(int, int), optional
3914
+ :param _request_auth: set to override the auth_settings for an a single
3915
+ request; this effectively ignores the
3916
+ authentication in the spec for a single request.
3917
+ :type _request_auth: dict, optional
3918
+ :param _content_type: force content-type for the request.
3919
+ :type _content_type: str, Optional
3920
+ :param _headers: set to override the headers for a single
3921
+ request; this effectively ignores the headers
3922
+ in the spec for a single request.
3923
+ :type _headers: dict, optional
3924
+ :param _host_index: set to override the host_index for a single
3925
+ request; this effectively ignores the host_index
3926
+ in the spec for a single request.
3927
+ :type _host_index: int, optional
3928
+ :return: Returns the result object.
3929
+ """ # noqa: E501
3930
+
3931
+ _param = self._upload_labels_serialize(
3932
+ username=username,
3933
+ dataset=dataset,
3934
+ linker=linker,
3935
+ languages=languages,
3936
+ file=file,
3937
+ _request_auth=_request_auth,
3938
+ _content_type=_content_type,
3939
+ _headers=_headers,
3940
+ _host_index=_host_index
3941
+ )
3942
+
3943
+ _response_types_map: Dict[str, Optional[str]] = {
3944
+ '200': "str",
3945
+ '422': "HTTPValidationError",
3946
+ }
3947
+ response_data = self.api_client.call_api(
3948
+ *_param,
3949
+ _request_timeout=_request_timeout
3950
+ )
3951
+ response_data.read()
3952
+ return self.api_client.response_deserialize(
3953
+ response_data=response_data,
3954
+ response_types_map=_response_types_map,
3955
+ )
3956
+
3957
+
3958
+ @validate_call
3959
+ def upload_labels_without_preload_content(
3960
+ self,
3961
+ username: StrictStr,
3962
+ dataset: StrictStr,
3963
+ linker: StrictStr,
3964
+ languages: List[StrictStr],
3965
+ file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]],
3966
+ _request_timeout: Union[
3967
+ None,
3968
+ Annotated[StrictFloat, Field(gt=0)],
3969
+ Tuple[
3970
+ Annotated[StrictFloat, Field(gt=0)],
3971
+ Annotated[StrictFloat, Field(gt=0)]
3972
+ ]
3973
+ ] = None,
3974
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
3975
+ _content_type: Optional[StrictStr] = None,
3976
+ _headers: Optional[Dict[StrictStr, Any]] = None,
3977
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
3978
+ ) -> RESTResponseType:
3979
+ """Upload labels for a linker
3980
+
3981
+
3982
+ :param username: (required)
3983
+ :type username: str
3984
+ :param dataset: (required)
3985
+ :type dataset: str
3986
+ :param linker: (required)
3987
+ :type linker: str
3988
+ :param languages: (required)
3989
+ :type languages: List[str]
3990
+ :param file: (required)
3991
+ :type file: bytearray
3992
+ :param _request_timeout: timeout setting for this request. If one
3993
+ number provided, it will be total request
3994
+ timeout. It can also be a pair (tuple) of
3995
+ (connection, read) timeouts.
3996
+ :type _request_timeout: int, tuple(int, int), optional
3997
+ :param _request_auth: set to override the auth_settings for an a single
3998
+ request; this effectively ignores the
3999
+ authentication in the spec for a single request.
4000
+ :type _request_auth: dict, optional
4001
+ :param _content_type: force content-type for the request.
4002
+ :type _content_type: str, Optional
4003
+ :param _headers: set to override the headers for a single
4004
+ request; this effectively ignores the headers
4005
+ in the spec for a single request.
4006
+ :type _headers: dict, optional
4007
+ :param _host_index: set to override the host_index for a single
4008
+ request; this effectively ignores the host_index
4009
+ in the spec for a single request.
4010
+ :type _host_index: int, optional
4011
+ :return: Returns the result object.
4012
+ """ # noqa: E501
4013
+
4014
+ _param = self._upload_labels_serialize(
4015
+ username=username,
4016
+ dataset=dataset,
4017
+ linker=linker,
4018
+ languages=languages,
4019
+ file=file,
4020
+ _request_auth=_request_auth,
4021
+ _content_type=_content_type,
4022
+ _headers=_headers,
4023
+ _host_index=_host_index
4024
+ )
4025
+
4026
+ _response_types_map: Dict[str, Optional[str]] = {
4027
+ '200': "str",
4028
+ '422': "HTTPValidationError",
4029
+ }
4030
+ response_data = self.api_client.call_api(
4031
+ *_param,
4032
+ _request_timeout=_request_timeout
4033
+ )
4034
+ return response_data.response
4035
+
4036
+
4037
+ def _upload_labels_serialize(
4038
+ self,
4039
+ username,
4040
+ dataset,
4041
+ linker,
4042
+ languages,
4043
+ file,
4044
+ _request_auth,
4045
+ _content_type,
4046
+ _headers,
4047
+ _host_index,
4048
+ ) -> RequestSerialized:
4049
+
4050
+ _host = None
4051
+
4052
+ _collection_formats: Dict[str, str] = {
4053
+ 'languages': 'multi',
4054
+ }
4055
+
4056
+ _path_params: Dict[str, str] = {}
4057
+ _query_params: List[Tuple[str, str]] = []
4058
+ _header_params: Dict[str, Optional[str]] = _headers or {}
4059
+ _form_params: List[Tuple[str, str]] = []
4060
+ _files: Dict[
4061
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
4062
+ ] = {}
4063
+ _body_params: Optional[bytes] = None
4064
+
4065
+ # process the path parameters
4066
+ # process the query parameters
4067
+ if username is not None:
4068
+
4069
+ _query_params.append(('username', username))
4070
+
4071
+ if dataset is not None:
4072
+
4073
+ _query_params.append(('dataset', dataset))
4074
+
4075
+ if linker is not None:
4076
+
4077
+ _query_params.append(('linker', linker))
4078
+
4079
+ if languages is not None:
4080
+
4081
+ _query_params.append(('languages', languages))
4082
+
4083
+ # process the header parameters
4084
+ # process the form parameters
4085
+ if file is not None:
4086
+ _files['file'] = file
4087
+ # process the body parameter
4088
+
4089
+
4090
+ # set the HTTP header `Accept`
4091
+ if 'Accept' not in _header_params:
4092
+ _header_params['Accept'] = self.api_client.select_header_accept(
4093
+ [
4094
+ 'application/json'
4095
+ ]
4096
+ )
4097
+
4098
+ # set the HTTP header `Content-Type`
4099
+ if _content_type:
4100
+ _header_params['Content-Type'] = _content_type
4101
+ else:
4102
+ _default_content_type = (
4103
+ self.api_client.select_header_content_type(
4104
+ [
4105
+ 'multipart/form-data'
4106
+ ]
4107
+ )
4108
+ )
4109
+ if _default_content_type is not None:
4110
+ _header_params['Content-Type'] = _default_content_type
4111
+
4112
+ # authentication setting
4113
+ _auth_settings: List[str] = [
4114
+ 'QAnswer-Api-Key',
4115
+ 'Bearer token'
4116
+ ]
4117
+
4118
+ return self.api_client.param_serialize(
4119
+ method='POST',
4120
+ resource_path='/backend/api/tasks/rdf/linker/upload_labels',
4121
+ path_params=_path_params,
4122
+ query_params=_query_params,
4123
+ header_params=_header_params,
4124
+ body=_body_params,
4125
+ post_params=_form_params,
4126
+ files=_files,
4127
+ auth_settings=_auth_settings,
4128
+ collection_formats=_collection_formats,
4129
+ _host=_host,
4130
+ _request_auth=_request_auth
4131
+ )
4132
+
4133
+
4134
+
4135
+
4136
+ @validate_call
4137
+ def upload_labels_text(
4138
+ self,
4139
+ linker: Linker,
4140
+ _request_timeout: Union[
4141
+ None,
4142
+ Annotated[StrictFloat, Field(gt=0)],
4143
+ Tuple[
4144
+ Annotated[StrictFloat, Field(gt=0)],
4145
+ Annotated[StrictFloat, Field(gt=0)]
4146
+ ]
4147
+ ] = None,
4148
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
4149
+ _content_type: Optional[StrictStr] = None,
4150
+ _headers: Optional[Dict[StrictStr, Any]] = None,
4151
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
4152
+ ) -> str:
4153
+ """Upload labels as text for a linker
4154
+
4155
+
4156
+ :param linker: (required)
4157
+ :type linker: Linker
4158
+ :param _request_timeout: timeout setting for this request. If one
4159
+ number provided, it will be total request
4160
+ timeout. It can also be a pair (tuple) of
4161
+ (connection, read) timeouts.
4162
+ :type _request_timeout: int, tuple(int, int), optional
4163
+ :param _request_auth: set to override the auth_settings for an a single
4164
+ request; this effectively ignores the
4165
+ authentication in the spec for a single request.
4166
+ :type _request_auth: dict, optional
4167
+ :param _content_type: force content-type for the request.
4168
+ :type _content_type: str, Optional
4169
+ :param _headers: set to override the headers for a single
4170
+ request; this effectively ignores the headers
4171
+ in the spec for a single request.
4172
+ :type _headers: dict, optional
4173
+ :param _host_index: set to override the host_index for a single
4174
+ request; this effectively ignores the host_index
4175
+ in the spec for a single request.
4176
+ :type _host_index: int, optional
4177
+ :return: Returns the result object.
4178
+ """ # noqa: E501
4179
+
4180
+ _param = self._upload_labels_text_serialize(
4181
+ linker=linker,
4182
+ _request_auth=_request_auth,
4183
+ _content_type=_content_type,
4184
+ _headers=_headers,
4185
+ _host_index=_host_index
4186
+ )
4187
+
4188
+ _response_types_map: Dict[str, Optional[str]] = {
4189
+ '200': "str",
4190
+ '422': "HTTPValidationError",
4191
+ }
4192
+ response_data = self.api_client.call_api(
4193
+ *_param,
4194
+ _request_timeout=_request_timeout
4195
+ )
4196
+ response_data.read()
4197
+ return self.api_client.response_deserialize(
4198
+ response_data=response_data,
4199
+ response_types_map=_response_types_map,
4200
+ ).data
4201
+
4202
+
4203
+ @validate_call
4204
+ def upload_labels_text_with_http_info(
4205
+ self,
4206
+ linker: Linker,
4207
+ _request_timeout: Union[
4208
+ None,
4209
+ Annotated[StrictFloat, Field(gt=0)],
4210
+ Tuple[
4211
+ Annotated[StrictFloat, Field(gt=0)],
4212
+ Annotated[StrictFloat, Field(gt=0)]
4213
+ ]
4214
+ ] = None,
4215
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
4216
+ _content_type: Optional[StrictStr] = None,
4217
+ _headers: Optional[Dict[StrictStr, Any]] = None,
4218
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
4219
+ ) -> ApiResponse[str]:
4220
+ """Upload labels as text for a linker
4221
+
4222
+
4223
+ :param linker: (required)
4224
+ :type linker: Linker
4225
+ :param _request_timeout: timeout setting for this request. If one
4226
+ number provided, it will be total request
4227
+ timeout. It can also be a pair (tuple) of
4228
+ (connection, read) timeouts.
4229
+ :type _request_timeout: int, tuple(int, int), optional
4230
+ :param _request_auth: set to override the auth_settings for an a single
4231
+ request; this effectively ignores the
4232
+ authentication in the spec for a single request.
4233
+ :type _request_auth: dict, optional
4234
+ :param _content_type: force content-type for the request.
4235
+ :type _content_type: str, Optional
4236
+ :param _headers: set to override the headers for a single
4237
+ request; this effectively ignores the headers
4238
+ in the spec for a single request.
4239
+ :type _headers: dict, optional
4240
+ :param _host_index: set to override the host_index for a single
4241
+ request; this effectively ignores the host_index
4242
+ in the spec for a single request.
4243
+ :type _host_index: int, optional
4244
+ :return: Returns the result object.
4245
+ """ # noqa: E501
4246
+
4247
+ _param = self._upload_labels_text_serialize(
4248
+ linker=linker,
4249
+ _request_auth=_request_auth,
4250
+ _content_type=_content_type,
4251
+ _headers=_headers,
4252
+ _host_index=_host_index
4253
+ )
4254
+
4255
+ _response_types_map: Dict[str, Optional[str]] = {
4256
+ '200': "str",
4257
+ '422': "HTTPValidationError",
4258
+ }
4259
+ response_data = self.api_client.call_api(
4260
+ *_param,
4261
+ _request_timeout=_request_timeout
4262
+ )
4263
+ response_data.read()
4264
+ return self.api_client.response_deserialize(
4265
+ response_data=response_data,
4266
+ response_types_map=_response_types_map,
4267
+ )
4268
+
4269
+
4270
+ @validate_call
4271
+ def upload_labels_text_without_preload_content(
4272
+ self,
4273
+ linker: Linker,
4274
+ _request_timeout: Union[
4275
+ None,
4276
+ Annotated[StrictFloat, Field(gt=0)],
4277
+ Tuple[
4278
+ Annotated[StrictFloat, Field(gt=0)],
4279
+ Annotated[StrictFloat, Field(gt=0)]
4280
+ ]
4281
+ ] = None,
4282
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
4283
+ _content_type: Optional[StrictStr] = None,
4284
+ _headers: Optional[Dict[StrictStr, Any]] = None,
4285
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
4286
+ ) -> RESTResponseType:
4287
+ """Upload labels as text for a linker
4288
+
4289
+
4290
+ :param linker: (required)
4291
+ :type linker: Linker
4292
+ :param _request_timeout: timeout setting for this request. If one
4293
+ number provided, it will be total request
4294
+ timeout. It can also be a pair (tuple) of
4295
+ (connection, read) timeouts.
4296
+ :type _request_timeout: int, tuple(int, int), optional
4297
+ :param _request_auth: set to override the auth_settings for an a single
4298
+ request; this effectively ignores the
4299
+ authentication in the spec for a single request.
4300
+ :type _request_auth: dict, optional
4301
+ :param _content_type: force content-type for the request.
4302
+ :type _content_type: str, Optional
4303
+ :param _headers: set to override the headers for a single
4304
+ request; this effectively ignores the headers
4305
+ in the spec for a single request.
4306
+ :type _headers: dict, optional
4307
+ :param _host_index: set to override the host_index for a single
4308
+ request; this effectively ignores the host_index
4309
+ in the spec for a single request.
4310
+ :type _host_index: int, optional
4311
+ :return: Returns the result object.
4312
+ """ # noqa: E501
4313
+
4314
+ _param = self._upload_labels_text_serialize(
4315
+ linker=linker,
4316
+ _request_auth=_request_auth,
4317
+ _content_type=_content_type,
4318
+ _headers=_headers,
4319
+ _host_index=_host_index
4320
+ )
4321
+
4322
+ _response_types_map: Dict[str, Optional[str]] = {
4323
+ '200': "str",
4324
+ '422': "HTTPValidationError",
4325
+ }
4326
+ response_data = self.api_client.call_api(
4327
+ *_param,
4328
+ _request_timeout=_request_timeout
4329
+ )
4330
+ return response_data.response
4331
+
4332
+
4333
+ def _upload_labels_text_serialize(
4334
+ self,
4335
+ linker,
4336
+ _request_auth,
4337
+ _content_type,
4338
+ _headers,
4339
+ _host_index,
4340
+ ) -> RequestSerialized:
4341
+
4342
+ _host = None
4343
+
4344
+ _collection_formats: Dict[str, str] = {
4345
+ }
4346
+
4347
+ _path_params: Dict[str, str] = {}
4348
+ _query_params: List[Tuple[str, str]] = []
4349
+ _header_params: Dict[str, Optional[str]] = _headers or {}
4350
+ _form_params: List[Tuple[str, str]] = []
4351
+ _files: Dict[
4352
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
4353
+ ] = {}
4354
+ _body_params: Optional[bytes] = None
4355
+
4356
+ # process the path parameters
4357
+ # process the query parameters
4358
+ # process the header parameters
4359
+ # process the form parameters
4360
+ # process the body parameter
4361
+ if linker is not None:
4362
+ _body_params = linker
4363
+
4364
+
4365
+ # set the HTTP header `Accept`
4366
+ if 'Accept' not in _header_params:
4367
+ _header_params['Accept'] = self.api_client.select_header_accept(
4368
+ [
4369
+ 'application/json'
4370
+ ]
4371
+ )
4372
+
4373
+ # set the HTTP header `Content-Type`
4374
+ if _content_type:
4375
+ _header_params['Content-Type'] = _content_type
4376
+ else:
4377
+ _default_content_type = (
4378
+ self.api_client.select_header_content_type(
4379
+ [
4380
+ 'application/json'
4381
+ ]
4382
+ )
4383
+ )
4384
+ if _default_content_type is not None:
4385
+ _header_params['Content-Type'] = _default_content_type
4386
+
4387
+ # authentication setting
4388
+ _auth_settings: List[str] = [
4389
+ 'QAnswer-Api-Key',
4390
+ 'Bearer token'
4391
+ ]
4392
+
4393
+ return self.api_client.param_serialize(
4394
+ method='POST',
4395
+ resource_path='/backend/api/tasks/rdf/linker/upload_labels_text',
4396
+ path_params=_path_params,
4397
+ query_params=_query_params,
4398
+ header_params=_header_params,
4399
+ body=_body_params,
4400
+ post_params=_form_params,
4401
+ files=_files,
4402
+ auth_settings=_auth_settings,
4403
+ collection_formats=_collection_formats,
4404
+ _host=_host,
4405
+ _request_auth=_request_auth
4406
+ )
4407
+
4408
+