h2ogpte 1.6.54rc4__py3-none-any.whl → 1.7.0rc1__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 (39) hide show
  1. h2ogpte/__init__.py +1 -1
  2. h2ogpte/h2ogpte.py +184 -20
  3. h2ogpte/h2ogpte_async.py +184 -20
  4. h2ogpte/rest_async/__init__.py +3 -2
  5. h2ogpte/rest_async/api/agents_api.py +25 -25
  6. h2ogpte/rest_async/api/chat_api.py +1077 -21
  7. h2ogpte/rest_async/api/models_api.py +35 -67
  8. h2ogpte/rest_async/api_client.py +1 -1
  9. h2ogpte/rest_async/configuration.py +1 -1
  10. h2ogpte/rest_async/models/__init__.py +2 -1
  11. h2ogpte/rest_async/models/chat_completion_request.py +6 -2
  12. h2ogpte/rest_async/models/chat_settings.py +6 -2
  13. h2ogpte/rest_async/models/chat_settings_tags.py +140 -0
  14. h2ogpte/rest_async/models/extractor.py +26 -2
  15. h2ogpte/rest_async/models/extractor_create_request.py +29 -5
  16. h2ogpte/rest_async/models/ingest_from_confluence_body.py +4 -2
  17. h2ogpte/rest_async/models/{create_topic_model_job_request.py → tag_filter.py} +11 -9
  18. h2ogpte/rest_sync/__init__.py +3 -2
  19. h2ogpte/rest_sync/api/agents_api.py +25 -25
  20. h2ogpte/rest_sync/api/chat_api.py +1077 -21
  21. h2ogpte/rest_sync/api/models_api.py +35 -67
  22. h2ogpte/rest_sync/api_client.py +1 -1
  23. h2ogpte/rest_sync/configuration.py +1 -1
  24. h2ogpte/rest_sync/models/__init__.py +2 -1
  25. h2ogpte/rest_sync/models/chat_completion_request.py +6 -2
  26. h2ogpte/rest_sync/models/chat_settings.py +6 -2
  27. h2ogpte/rest_sync/models/chat_settings_tags.py +140 -0
  28. h2ogpte/rest_sync/models/extractor.py +26 -2
  29. h2ogpte/rest_sync/models/extractor_create_request.py +29 -5
  30. h2ogpte/rest_sync/models/ingest_from_confluence_body.py +4 -2
  31. h2ogpte/rest_sync/models/{create_topic_model_job_request.py → tag_filter.py} +11 -9
  32. h2ogpte/session.py +13 -6
  33. h2ogpte/session_async.py +11 -3
  34. h2ogpte/types.py +27 -1
  35. {h2ogpte-1.6.54rc4.dist-info → h2ogpte-1.7.0rc1.dist-info}/METADATA +1 -1
  36. {h2ogpte-1.6.54rc4.dist-info → h2ogpte-1.7.0rc1.dist-info}/RECORD +39 -37
  37. {h2ogpte-1.6.54rc4.dist-info → h2ogpte-1.7.0rc1.dist-info}/WHEEL +1 -1
  38. {h2ogpte-1.6.54rc4.dist-info → h2ogpte-1.7.0rc1.dist-info}/entry_points.txt +0 -0
  39. {h2ogpte-1.6.54rc4.dist-info → h2ogpte-1.7.0rc1.dist-info}/top_level.txt +0 -0
@@ -16,7 +16,7 @@ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
16
  from typing import Any, Dict, List, Optional, Tuple, Union
17
17
  from typing_extensions import Annotated
18
18
 
19
- from pydantic import Field, StrictBytes, StrictInt, StrictStr
19
+ from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
20
20
  from typing import List, Optional, Tuple, Union
21
21
  from typing_extensions import Annotated
22
22
  from h2ogpte.rest_async.models.add_custom_agent_tool201_response_inner import AddCustomAgentTool201ResponseInner
@@ -54,11 +54,11 @@ class AgentsApi:
54
54
  @validate_call
55
55
  async def add_custom_agent_tool(
56
56
  self,
57
- tool_type: StrictStr,
58
- tool_args: StrictStr,
59
- file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
57
+ tool_type: Annotated[StrictStr, Field(description="The type of custom tool being added: - local_mcp: Model Context Protocol server running locally - remote_mcp: Model Context Protocol server running remotely - browser_action: Custom browser automation actions - general_code: General purpose code execution tools ")],
58
+ tool_args: Annotated[StrictStr, Field(description="JSON string containing tool-specific arguments. The structure varies by tool_type: For remote_mcp: { \\\"mcp_config_json\\\": \\\"JSON string with MCP server configuration\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true) } For local_mcp, browser_action, and general_code: { \\\"tool_name\\\": \\\"string (optional, defaults to filename without extension)\\\", \\\"description\\\": \\\"string (optional, tool description)\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true), \\\"should_unzip\\\": true/false (optional, for general_code .zip files only), \\\"tool_usage_mode\\\": [\\\"runner\\\", \\\"creator\\\"] (optional list of strings) } ")],
59
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="The tool file to upload. Requirements vary by tool_type: - local_mcp: .zip file containing MCP server code - remote_mcp: Optional .json file with MCP configuration - browser_action: .py file (must start with 'browser_') or .zip containing browser action scripts - general_code: .py or .zip file with custom code ")] = None,
60
60
  custom_tool_path: Optional[StrictStr] = None,
61
- filename: Optional[StrictStr] = None,
61
+ filename: Annotated[Optional[StrictStr], Field(description="Optional filename to use when storing the uploaded file")] = None,
62
62
  _request_timeout: Union[
63
63
  None,
64
64
  Annotated[StrictFloat, Field(gt=0)],
@@ -76,15 +76,15 @@ class AgentsApi:
76
76
 
77
77
  Add Custom Agent Tools
78
78
 
79
- :param tool_type: (required)
79
+ :param tool_type: The type of custom tool being added: - local_mcp: Model Context Protocol server running locally - remote_mcp: Model Context Protocol server running remotely - browser_action: Custom browser automation actions - general_code: General purpose code execution tools (required)
80
80
  :type tool_type: str
81
- :param tool_args: (required)
81
+ :param tool_args: JSON string containing tool-specific arguments. The structure varies by tool_type: For remote_mcp: { \\\"mcp_config_json\\\": \\\"JSON string with MCP server configuration\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true) } For local_mcp, browser_action, and general_code: { \\\"tool_name\\\": \\\"string (optional, defaults to filename without extension)\\\", \\\"description\\\": \\\"string (optional, tool description)\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true), \\\"should_unzip\\\": true/false (optional, for general_code .zip files only), \\\"tool_usage_mode\\\": [\\\"runner\\\", \\\"creator\\\"] (optional list of strings) } (required)
82
82
  :type tool_args: str
83
- :param file:
83
+ :param file: The tool file to upload. Requirements vary by tool_type: - local_mcp: .zip file containing MCP server code - remote_mcp: Optional .json file with MCP configuration - browser_action: .py file (must start with 'browser_') or .zip containing browser action scripts - general_code: .py or .zip file with custom code
84
84
  :type file: bytearray
85
85
  :param custom_tool_path:
86
86
  :type custom_tool_path: str
87
- :param filename:
87
+ :param filename: Optional filename to use when storing the uploaded file
88
88
  :type filename: str
89
89
  :param _request_timeout: timeout setting for this request. If one
90
90
  number provided, it will be total request
@@ -138,11 +138,11 @@ class AgentsApi:
138
138
  @validate_call
139
139
  async def add_custom_agent_tool_with_http_info(
140
140
  self,
141
- tool_type: StrictStr,
142
- tool_args: StrictStr,
143
- file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
141
+ tool_type: Annotated[StrictStr, Field(description="The type of custom tool being added: - local_mcp: Model Context Protocol server running locally - remote_mcp: Model Context Protocol server running remotely - browser_action: Custom browser automation actions - general_code: General purpose code execution tools ")],
142
+ tool_args: Annotated[StrictStr, Field(description="JSON string containing tool-specific arguments. The structure varies by tool_type: For remote_mcp: { \\\"mcp_config_json\\\": \\\"JSON string with MCP server configuration\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true) } For local_mcp, browser_action, and general_code: { \\\"tool_name\\\": \\\"string (optional, defaults to filename without extension)\\\", \\\"description\\\": \\\"string (optional, tool description)\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true), \\\"should_unzip\\\": true/false (optional, for general_code .zip files only), \\\"tool_usage_mode\\\": [\\\"runner\\\", \\\"creator\\\"] (optional list of strings) } ")],
143
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="The tool file to upload. Requirements vary by tool_type: - local_mcp: .zip file containing MCP server code - remote_mcp: Optional .json file with MCP configuration - browser_action: .py file (must start with 'browser_') or .zip containing browser action scripts - general_code: .py or .zip file with custom code ")] = None,
144
144
  custom_tool_path: Optional[StrictStr] = None,
145
- filename: Optional[StrictStr] = None,
145
+ filename: Annotated[Optional[StrictStr], Field(description="Optional filename to use when storing the uploaded file")] = None,
146
146
  _request_timeout: Union[
147
147
  None,
148
148
  Annotated[StrictFloat, Field(gt=0)],
@@ -160,15 +160,15 @@ class AgentsApi:
160
160
 
161
161
  Add Custom Agent Tools
162
162
 
163
- :param tool_type: (required)
163
+ :param tool_type: The type of custom tool being added: - local_mcp: Model Context Protocol server running locally - remote_mcp: Model Context Protocol server running remotely - browser_action: Custom browser automation actions - general_code: General purpose code execution tools (required)
164
164
  :type tool_type: str
165
- :param tool_args: (required)
165
+ :param tool_args: JSON string containing tool-specific arguments. The structure varies by tool_type: For remote_mcp: { \\\"mcp_config_json\\\": \\\"JSON string with MCP server configuration\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true) } For local_mcp, browser_action, and general_code: { \\\"tool_name\\\": \\\"string (optional, defaults to filename without extension)\\\", \\\"description\\\": \\\"string (optional, tool description)\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true), \\\"should_unzip\\\": true/false (optional, for general_code .zip files only), \\\"tool_usage_mode\\\": [\\\"runner\\\", \\\"creator\\\"] (optional list of strings) } (required)
166
166
  :type tool_args: str
167
- :param file:
167
+ :param file: The tool file to upload. Requirements vary by tool_type: - local_mcp: .zip file containing MCP server code - remote_mcp: Optional .json file with MCP configuration - browser_action: .py file (must start with 'browser_') or .zip containing browser action scripts - general_code: .py or .zip file with custom code
168
168
  :type file: bytearray
169
169
  :param custom_tool_path:
170
170
  :type custom_tool_path: str
171
- :param filename:
171
+ :param filename: Optional filename to use when storing the uploaded file
172
172
  :type filename: str
173
173
  :param _request_timeout: timeout setting for this request. If one
174
174
  number provided, it will be total request
@@ -222,11 +222,11 @@ class AgentsApi:
222
222
  @validate_call
223
223
  async def add_custom_agent_tool_without_preload_content(
224
224
  self,
225
- tool_type: StrictStr,
226
- tool_args: StrictStr,
227
- file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None,
225
+ tool_type: Annotated[StrictStr, Field(description="The type of custom tool being added: - local_mcp: Model Context Protocol server running locally - remote_mcp: Model Context Protocol server running remotely - browser_action: Custom browser automation actions - general_code: General purpose code execution tools ")],
226
+ tool_args: Annotated[StrictStr, Field(description="JSON string containing tool-specific arguments. The structure varies by tool_type: For remote_mcp: { \\\"mcp_config_json\\\": \\\"JSON string with MCP server configuration\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true) } For local_mcp, browser_action, and general_code: { \\\"tool_name\\\": \\\"string (optional, defaults to filename without extension)\\\", \\\"description\\\": \\\"string (optional, tool description)\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true), \\\"should_unzip\\\": true/false (optional, for general_code .zip files only), \\\"tool_usage_mode\\\": [\\\"runner\\\", \\\"creator\\\"] (optional list of strings) } ")],
227
+ file: Annotated[Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]], Field(description="The tool file to upload. Requirements vary by tool_type: - local_mcp: .zip file containing MCP server code - remote_mcp: Optional .json file with MCP configuration - browser_action: .py file (must start with 'browser_') or .zip containing browser action scripts - general_code: .py or .zip file with custom code ")] = None,
228
228
  custom_tool_path: Optional[StrictStr] = None,
229
- filename: Optional[StrictStr] = None,
229
+ filename: Annotated[Optional[StrictStr], Field(description="Optional filename to use when storing the uploaded file")] = None,
230
230
  _request_timeout: Union[
231
231
  None,
232
232
  Annotated[StrictFloat, Field(gt=0)],
@@ -244,15 +244,15 @@ class AgentsApi:
244
244
 
245
245
  Add Custom Agent Tools
246
246
 
247
- :param tool_type: (required)
247
+ :param tool_type: The type of custom tool being added: - local_mcp: Model Context Protocol server running locally - remote_mcp: Model Context Protocol server running remotely - browser_action: Custom browser automation actions - general_code: General purpose code execution tools (required)
248
248
  :type tool_type: str
249
- :param tool_args: (required)
249
+ :param tool_args: JSON string containing tool-specific arguments. The structure varies by tool_type: For remote_mcp: { \\\"mcp_config_json\\\": \\\"JSON string with MCP server configuration\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true) } For local_mcp, browser_action, and general_code: { \\\"tool_name\\\": \\\"string (optional, defaults to filename without extension)\\\", \\\"description\\\": \\\"string (optional, tool description)\\\", \\\"enable_by_default\\\": true/false (optional, defaults to true), \\\"should_unzip\\\": true/false (optional, for general_code .zip files only), \\\"tool_usage_mode\\\": [\\\"runner\\\", \\\"creator\\\"] (optional list of strings) } (required)
250
250
  :type tool_args: str
251
- :param file:
251
+ :param file: The tool file to upload. Requirements vary by tool_type: - local_mcp: .zip file containing MCP server code - remote_mcp: Optional .json file with MCP configuration - browser_action: .py file (must start with 'browser_') or .zip containing browser action scripts - general_code: .py or .zip file with custom code
252
252
  :type file: bytearray
253
253
  :param custom_tool_path:
254
254
  :type custom_tool_path: str
255
- :param filename:
255
+ :param filename: Optional filename to use when storing the uploaded file
256
256
  :type filename: str
257
257
  :param _request_timeout: timeout setting for this request. If one
258
258
  number provided, it will be total request