phenoml 0.0.6__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.
- phenoml/__init__.py +30 -0
- phenoml/agent/__init__.py +56 -0
- phenoml/agent/client.py +939 -0
- phenoml/agent/errors/__init__.py +11 -0
- phenoml/agent/errors/bad_request_error.py +10 -0
- phenoml/agent/errors/forbidden_error.py +10 -0
- phenoml/agent/errors/internal_server_error.py +10 -0
- phenoml/agent/errors/not_found_error.py +10 -0
- phenoml/agent/errors/unauthorized_error.py +10 -0
- phenoml/agent/prompts/__init__.py +7 -0
- phenoml/agent/prompts/client.py +707 -0
- phenoml/agent/prompts/raw_client.py +1345 -0
- phenoml/agent/prompts/types/__init__.py +8 -0
- phenoml/agent/prompts/types/prompts_delete_response.py +20 -0
- phenoml/agent/prompts/types/prompts_list_response.py +22 -0
- phenoml/agent/raw_client.py +1668 -0
- phenoml/agent/types/__init__.py +43 -0
- phenoml/agent/types/agent_chat_response.py +33 -0
- phenoml/agent/types/agent_create_request.py +53 -0
- phenoml/agent/types/agent_create_request_provider.py +5 -0
- phenoml/agent/types/agent_delete_response.py +20 -0
- phenoml/agent/types/agent_get_chat_messages_request_order.py +5 -0
- phenoml/agent/types/agent_get_chat_messages_response.py +22 -0
- phenoml/agent/types/agent_list_response.py +22 -0
- phenoml/agent/types/agent_prompts_response.py +22 -0
- phenoml/agent/types/agent_response.py +22 -0
- phenoml/agent/types/agent_template.py +58 -0
- phenoml/agent/types/agent_template_provider.py +5 -0
- phenoml/agent/types/chat_message_template.py +72 -0
- phenoml/agent/types/chat_session_template.py +67 -0
- phenoml/agent/types/json_patch.py +7 -0
- phenoml/agent/types/json_patch_operation.py +40 -0
- phenoml/agent/types/json_patch_operation_op.py +5 -0
- phenoml/agent/types/prompt_template.py +52 -0
- phenoml/agent/types/success_response.py +20 -0
- phenoml/authtoken/__init__.py +17 -0
- phenoml/authtoken/auth/__init__.py +7 -0
- phenoml/authtoken/auth/client.py +129 -0
- phenoml/authtoken/auth/raw_client.py +173 -0
- phenoml/authtoken/auth/types/__init__.py +7 -0
- phenoml/authtoken/auth/types/auth_generate_token_response.py +22 -0
- phenoml/authtoken/client.py +39 -0
- phenoml/authtoken/errors/__init__.py +8 -0
- phenoml/authtoken/errors/bad_request_error.py +10 -0
- phenoml/authtoken/errors/unauthorized_error.py +10 -0
- phenoml/authtoken/raw_client.py +13 -0
- phenoml/authtoken/types/__init__.py +8 -0
- phenoml/authtoken/types/bad_request_error_body.py +21 -0
- phenoml/authtoken/types/unauthorized_error_body.py +21 -0
- phenoml/client.py +177 -0
- phenoml/cohort/__init__.py +8 -0
- phenoml/cohort/client.py +113 -0
- phenoml/cohort/errors/__init__.py +9 -0
- phenoml/cohort/errors/bad_request_error.py +10 -0
- phenoml/cohort/errors/internal_server_error.py +10 -0
- phenoml/cohort/errors/unauthorized_error.py +10 -0
- phenoml/cohort/raw_client.py +185 -0
- phenoml/cohort/types/__init__.py +8 -0
- phenoml/cohort/types/cohort_response.py +33 -0
- phenoml/cohort/types/search_concept.py +37 -0
- phenoml/construe/__init__.py +45 -0
- phenoml/construe/client.py +399 -0
- phenoml/construe/errors/__init__.py +11 -0
- phenoml/construe/errors/bad_request_error.py +10 -0
- phenoml/construe/errors/conflict_error.py +10 -0
- phenoml/construe/errors/failed_dependency_error.py +10 -0
- phenoml/construe/errors/internal_server_error.py +10 -0
- phenoml/construe/errors/unauthorized_error.py +10 -0
- phenoml/construe/raw_client.py +706 -0
- phenoml/construe/types/__init__.py +41 -0
- phenoml/construe/types/bad_request_error_body.py +27 -0
- phenoml/construe/types/construe_cohort_request_config.py +37 -0
- phenoml/construe/types/construe_cohort_response.py +33 -0
- phenoml/construe/types/construe_cohort_response_queries_item.py +49 -0
- phenoml/construe/types/construe_cohort_response_queries_item_code_extract_results_item.py +31 -0
- phenoml/construe/types/construe_cohort_response_queries_item_code_extract_results_item_codes_item.py +32 -0
- phenoml/construe/types/construe_upload_code_system_response.py +19 -0
- phenoml/construe/types/extract_codes_result.py +22 -0
- phenoml/construe/types/extract_request_config.py +23 -0
- phenoml/construe/types/extract_request_config_chunking_method.py +5 -0
- phenoml/construe/types/extract_request_system.py +37 -0
- phenoml/construe/types/extracted_code_result.py +41 -0
- phenoml/construe/types/internal_server_error_body.py +27 -0
- phenoml/construe/types/unauthorized_error_body.py +27 -0
- phenoml/construe/types/upload_request_format.py +5 -0
- phenoml/core/__init__.py +52 -0
- phenoml/core/api_error.py +23 -0
- phenoml/core/client_wrapper.py +87 -0
- phenoml/core/datetime_utils.py +28 -0
- phenoml/core/file.py +67 -0
- phenoml/core/force_multipart.py +16 -0
- phenoml/core/http_client.py +543 -0
- phenoml/core/http_response.py +55 -0
- phenoml/core/jsonable_encoder.py +100 -0
- phenoml/core/pydantic_utilities.py +255 -0
- phenoml/core/query_encoder.py +58 -0
- phenoml/core/remove_none_from_dict.py +11 -0
- phenoml/core/request_options.py +35 -0
- phenoml/core/serialization.py +276 -0
- phenoml/environment.py +7 -0
- phenoml/fhir/__init__.py +36 -0
- phenoml/fhir/client.py +970 -0
- phenoml/fhir/errors/__init__.py +10 -0
- phenoml/fhir/errors/bad_request_error.py +10 -0
- phenoml/fhir/errors/internal_server_error.py +10 -0
- phenoml/fhir/errors/not_found_error.py +10 -0
- phenoml/fhir/errors/unauthorized_error.py +10 -0
- phenoml/fhir/raw_client.py +1385 -0
- phenoml/fhir/types/__init__.py +29 -0
- phenoml/fhir/types/error_response.py +36 -0
- phenoml/fhir/types/fhir_bundle.py +43 -0
- phenoml/fhir/types/fhir_bundle_entry_item.py +34 -0
- phenoml/fhir/types/fhir_bundle_entry_item_request.py +25 -0
- phenoml/fhir/types/fhir_bundle_entry_item_request_method.py +5 -0
- phenoml/fhir/types/fhir_bundle_entry_item_response.py +24 -0
- phenoml/fhir/types/fhir_patch_request_body_item.py +40 -0
- phenoml/fhir/types/fhir_patch_request_body_item_op.py +7 -0
- phenoml/fhir/types/fhir_resource.py +40 -0
- phenoml/fhir/types/fhir_resource_meta.py +28 -0
- phenoml/fhir/types/fhir_search_response.py +8 -0
- phenoml/fhir_provider/__init__.py +43 -0
- phenoml/fhir_provider/client.py +731 -0
- phenoml/fhir_provider/errors/__init__.py +11 -0
- phenoml/fhir_provider/errors/bad_request_error.py +10 -0
- phenoml/fhir_provider/errors/forbidden_error.py +10 -0
- phenoml/fhir_provider/errors/internal_server_error.py +10 -0
- phenoml/fhir_provider/errors/not_found_error.py +10 -0
- phenoml/fhir_provider/errors/unauthorized_error.py +10 -0
- phenoml/fhir_provider/raw_client.py +1445 -0
- phenoml/fhir_provider/types/__init__.py +35 -0
- phenoml/fhir_provider/types/auth_method.py +7 -0
- phenoml/fhir_provider/types/fhir_provider_auth_config.py +53 -0
- phenoml/fhir_provider/types/fhir_provider_delete_response.py +20 -0
- phenoml/fhir_provider/types/fhir_provider_list_response.py +22 -0
- phenoml/fhir_provider/types/fhir_provider_remove_auth_config_response.py +22 -0
- phenoml/fhir_provider/types/fhir_provider_response.py +22 -0
- phenoml/fhir_provider/types/fhir_provider_set_active_auth_config_response.py +22 -0
- phenoml/fhir_provider/types/fhir_provider_template.py +66 -0
- phenoml/fhir_provider/types/fhir_query_response.py +27 -0
- phenoml/fhir_provider/types/fhir_query_response_data.py +5 -0
- phenoml/fhir_provider/types/json_web_key.py +51 -0
- phenoml/fhir_provider/types/provider.py +8 -0
- phenoml/fhir_provider/types/service_account_key.py +35 -0
- phenoml/fhir_provider/types/smart_configuration.py +46 -0
- phenoml/lang2fhir/__init__.py +27 -0
- phenoml/lang2fhir/client.py +430 -0
- phenoml/lang2fhir/errors/__init__.py +11 -0
- phenoml/lang2fhir/errors/bad_request_error.py +10 -0
- phenoml/lang2fhir/errors/failed_dependency_error.py +10 -0
- phenoml/lang2fhir/errors/forbidden_error.py +10 -0
- phenoml/lang2fhir/errors/internal_server_error.py +10 -0
- phenoml/lang2fhir/errors/unauthorized_error.py +10 -0
- phenoml/lang2fhir/raw_client.py +788 -0
- phenoml/lang2fhir/types/__init__.py +19 -0
- phenoml/lang2fhir/types/create_request_resource.py +25 -0
- phenoml/lang2fhir/types/document_request_file_type.py +7 -0
- phenoml/lang2fhir/types/document_request_resource.py +5 -0
- phenoml/lang2fhir/types/fhir_resource.py +5 -0
- phenoml/lang2fhir/types/lang2fhir_upload_profile_response.py +23 -0
- phenoml/lang2fhir/types/search_response.py +33 -0
- phenoml/py.typed +0 -0
- phenoml/tools/__init__.py +37 -0
- phenoml/tools/client.py +359 -0
- phenoml/tools/errors/__init__.py +11 -0
- phenoml/tools/errors/bad_request_error.py +10 -0
- phenoml/tools/errors/failed_dependency_error.py +10 -0
- phenoml/tools/errors/forbidden_error.py +10 -0
- phenoml/tools/errors/internal_server_error.py +10 -0
- phenoml/tools/errors/unauthorized_error.py +10 -0
- phenoml/tools/mcp_server/__init__.py +7 -0
- phenoml/tools/mcp_server/client.py +336 -0
- phenoml/tools/mcp_server/raw_client.py +641 -0
- phenoml/tools/mcp_server/tools/__init__.py +4 -0
- phenoml/tools/mcp_server/tools/client.py +358 -0
- phenoml/tools/mcp_server/tools/raw_client.py +656 -0
- phenoml/tools/raw_client.py +696 -0
- phenoml/tools/types/__init__.py +27 -0
- phenoml/tools/types/cohort_response.py +49 -0
- phenoml/tools/types/lang2fhir_and_create_request_resource.py +25 -0
- phenoml/tools/types/lang2fhir_and_create_response.py +33 -0
- phenoml/tools/types/lang2fhir_and_search_response.py +40 -0
- phenoml/tools/types/mcp_server_response.py +33 -0
- phenoml/tools/types/mcp_server_response_data.py +51 -0
- phenoml/tools/types/mcp_server_tool_call_response.py +37 -0
- phenoml/tools/types/mcp_server_tool_response.py +33 -0
- phenoml/tools/types/mcp_server_tool_response_data.py +61 -0
- phenoml/tools/types/search_concept.py +41 -0
- phenoml/types/__init__.py +21 -0
- phenoml/types/cohort_response.py +5 -0
- phenoml/types/lang2fhir_and_create_response.py +5 -0
- phenoml/types/lang2fhir_and_search_response.py +5 -0
- phenoml/types/mcp_server_response.py +5 -0
- phenoml/types/mcp_server_tool_call_response.py +5 -0
- phenoml/types/mcp_server_tool_response.py +5 -0
- phenoml/types/search_concept.py +5 -0
- phenoml/version.py +3 -0
- phenoml/workflows/__init__.py +66 -0
- phenoml/workflows/client.py +210 -0
- phenoml/workflows/errors/__init__.py +11 -0
- phenoml/workflows/errors/bad_request_error.py +10 -0
- phenoml/workflows/errors/forbidden_error.py +10 -0
- phenoml/workflows/errors/internal_server_error.py +10 -0
- phenoml/workflows/errors/not_found_error.py +10 -0
- phenoml/workflows/errors/unauthorized_error.py +10 -0
- phenoml/workflows/mcp_server/__init__.py +7 -0
- phenoml/workflows/mcp_server/client.py +274 -0
- phenoml/workflows/mcp_server/raw_client.py +226 -0
- phenoml/workflows/mcp_server/tools/__init__.py +4 -0
- phenoml/workflows/mcp_server/tools/client.py +287 -0
- phenoml/workflows/mcp_server/tools/raw_client.py +244 -0
- phenoml/workflows/raw_client.py +169 -0
- phenoml/workflows/types/__init__.py +43 -0
- phenoml/workflows/types/create_workflow_response.py +44 -0
- phenoml/workflows/types/decision_node_definition.py +32 -0
- phenoml/workflows/types/execute_workflow_response.py +30 -0
- phenoml/workflows/types/execute_workflow_response_results.py +22 -0
- phenoml/workflows/types/lang2fhir_create_definition.py +37 -0
- phenoml/workflows/types/lang2fhir_search_definition.py +42 -0
- phenoml/workflows/types/list_workflows_response.py +39 -0
- phenoml/workflows/types/step_operation.py +26 -0
- phenoml/workflows/types/sub_workflow_definition.py +32 -0
- phenoml/workflows/types/workflow_config.py +27 -0
- phenoml/workflows/types/workflow_definition.py +57 -0
- phenoml/workflows/types/workflow_graph.py +23 -0
- phenoml/workflows/types/workflow_response.py +61 -0
- phenoml/workflows/types/workflow_response_graph.py +23 -0
- phenoml/workflows/types/workflow_step.py +55 -0
- phenoml/workflows/types/workflow_step_summary.py +47 -0
- phenoml/workflows/types/workflow_step_summary_type.py +5 -0
- phenoml/workflows/types/workflow_step_type.py +5 -0
- phenoml/workflows/workflows/__init__.py +19 -0
- phenoml/workflows/workflows/client.py +694 -0
- phenoml/workflows/workflows/raw_client.py +1266 -0
- phenoml/workflows/workflows/types/__init__.py +17 -0
- phenoml/workflows/workflows/types/create_workflow_request_fhir_provider_id.py +5 -0
- phenoml/workflows/workflows/types/update_workflow_request_fhir_provider_id.py +5 -0
- phenoml/workflows/workflows/types/workflows_delete_response.py +20 -0
- phenoml/workflows/workflows/types/workflows_get_response.py +26 -0
- phenoml/workflows/workflows/types/workflows_update_response.py +31 -0
- phenoml/wrapper_client.py +123 -0
- phenoml-0.0.6.dist-info/LICENSE +21 -0
- phenoml-0.0.6.dist-info/METADATA +192 -0
- phenoml-0.0.6.dist-info/RECORD +244 -0
- phenoml-0.0.6.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
# isort: skip_file
|
|
4
|
+
|
|
5
|
+
from .agent_chat_response import AgentChatResponse
|
|
6
|
+
from .agent_create_request import AgentCreateRequest
|
|
7
|
+
from .agent_create_request_provider import AgentCreateRequestProvider
|
|
8
|
+
from .agent_delete_response import AgentDeleteResponse
|
|
9
|
+
from .agent_get_chat_messages_request_order import AgentGetChatMessagesRequestOrder
|
|
10
|
+
from .agent_get_chat_messages_response import AgentGetChatMessagesResponse
|
|
11
|
+
from .agent_list_response import AgentListResponse
|
|
12
|
+
from .agent_prompts_response import AgentPromptsResponse
|
|
13
|
+
from .agent_response import AgentResponse
|
|
14
|
+
from .agent_template import AgentTemplate
|
|
15
|
+
from .agent_template_provider import AgentTemplateProvider
|
|
16
|
+
from .chat_message_template import ChatMessageTemplate
|
|
17
|
+
from .chat_session_template import ChatSessionTemplate
|
|
18
|
+
from .json_patch import JsonPatch
|
|
19
|
+
from .json_patch_operation import JsonPatchOperation
|
|
20
|
+
from .json_patch_operation_op import JsonPatchOperationOp
|
|
21
|
+
from .prompt_template import PromptTemplate
|
|
22
|
+
from .success_response import SuccessResponse
|
|
23
|
+
|
|
24
|
+
__all__ = [
|
|
25
|
+
"AgentChatResponse",
|
|
26
|
+
"AgentCreateRequest",
|
|
27
|
+
"AgentCreateRequestProvider",
|
|
28
|
+
"AgentDeleteResponse",
|
|
29
|
+
"AgentGetChatMessagesRequestOrder",
|
|
30
|
+
"AgentGetChatMessagesResponse",
|
|
31
|
+
"AgentListResponse",
|
|
32
|
+
"AgentPromptsResponse",
|
|
33
|
+
"AgentResponse",
|
|
34
|
+
"AgentTemplate",
|
|
35
|
+
"AgentTemplateProvider",
|
|
36
|
+
"ChatMessageTemplate",
|
|
37
|
+
"ChatSessionTemplate",
|
|
38
|
+
"JsonPatch",
|
|
39
|
+
"JsonPatchOperation",
|
|
40
|
+
"JsonPatchOperationOp",
|
|
41
|
+
"PromptTemplate",
|
|
42
|
+
"SuccessResponse",
|
|
43
|
+
]
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class AgentChatResponse(UniversalBaseModel):
|
|
10
|
+
response: typing.Optional[str] = pydantic.Field(default=None)
|
|
11
|
+
"""
|
|
12
|
+
Agent's response
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
success: typing.Optional[bool] = None
|
|
16
|
+
message: typing.Optional[str] = pydantic.Field(default=None)
|
|
17
|
+
"""
|
|
18
|
+
Status message
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
session_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
22
|
+
"""
|
|
23
|
+
Chat session ID
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
if IS_PYDANTIC_V2:
|
|
27
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
28
|
+
else:
|
|
29
|
+
|
|
30
|
+
class Config:
|
|
31
|
+
frozen = True
|
|
32
|
+
smart_union = True
|
|
33
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
from .agent_create_request_provider import AgentCreateRequestProvider
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AgentCreateRequest(UniversalBaseModel):
|
|
11
|
+
name: str = pydantic.Field()
|
|
12
|
+
"""
|
|
13
|
+
Agent name
|
|
14
|
+
"""
|
|
15
|
+
|
|
16
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
17
|
+
"""
|
|
18
|
+
Agent description
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
prompts: typing.List[str] = pydantic.Field()
|
|
22
|
+
"""
|
|
23
|
+
Array of prompt IDs to use for this agent
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
tools: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
|
|
27
|
+
"""
|
|
28
|
+
Array of MCP server tool IDs to use for this agent
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
is_active: bool = pydantic.Field()
|
|
32
|
+
"""
|
|
33
|
+
Whether the agent is active
|
|
34
|
+
"""
|
|
35
|
+
|
|
36
|
+
tags: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
|
|
37
|
+
"""
|
|
38
|
+
Tags for categorizing the agent
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
provider: typing.Optional[AgentCreateRequestProvider] = pydantic.Field(default=None)
|
|
42
|
+
"""
|
|
43
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
if IS_PYDANTIC_V2:
|
|
47
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
48
|
+
else:
|
|
49
|
+
|
|
50
|
+
class Config:
|
|
51
|
+
frozen = True
|
|
52
|
+
smart_union = True
|
|
53
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class AgentDeleteResponse(UniversalBaseModel):
|
|
10
|
+
success: typing.Optional[bool] = None
|
|
11
|
+
message: typing.Optional[str] = None
|
|
12
|
+
|
|
13
|
+
if IS_PYDANTIC_V2:
|
|
14
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
15
|
+
else:
|
|
16
|
+
|
|
17
|
+
class Config:
|
|
18
|
+
frozen = True
|
|
19
|
+
smart_union = True
|
|
20
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
from .chat_message_template import ChatMessageTemplate
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AgentGetChatMessagesResponse(UniversalBaseModel):
|
|
11
|
+
messages: typing.Optional[typing.List[ChatMessageTemplate]] = None
|
|
12
|
+
total: typing.Optional[int] = None
|
|
13
|
+
session_id: typing.Optional[str] = None
|
|
14
|
+
|
|
15
|
+
if IS_PYDANTIC_V2:
|
|
16
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
17
|
+
else:
|
|
18
|
+
|
|
19
|
+
class Config:
|
|
20
|
+
frozen = True
|
|
21
|
+
smart_union = True
|
|
22
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
from .agent_template import AgentTemplate
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AgentListResponse(UniversalBaseModel):
|
|
11
|
+
success: typing.Optional[bool] = None
|
|
12
|
+
message: typing.Optional[str] = None
|
|
13
|
+
agents: typing.Optional[typing.List[AgentTemplate]] = None
|
|
14
|
+
|
|
15
|
+
if IS_PYDANTIC_V2:
|
|
16
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
17
|
+
else:
|
|
18
|
+
|
|
19
|
+
class Config:
|
|
20
|
+
frozen = True
|
|
21
|
+
smart_union = True
|
|
22
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
from .prompt_template import PromptTemplate
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AgentPromptsResponse(UniversalBaseModel):
|
|
11
|
+
success: typing.Optional[bool] = None
|
|
12
|
+
message: typing.Optional[str] = None
|
|
13
|
+
data: typing.Optional[PromptTemplate] = None
|
|
14
|
+
|
|
15
|
+
if IS_PYDANTIC_V2:
|
|
16
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
17
|
+
else:
|
|
18
|
+
|
|
19
|
+
class Config:
|
|
20
|
+
frozen = True
|
|
21
|
+
smart_union = True
|
|
22
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
from .agent_template import AgentTemplate
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AgentResponse(UniversalBaseModel):
|
|
11
|
+
success: typing.Optional[bool] = None
|
|
12
|
+
message: typing.Optional[str] = None
|
|
13
|
+
data: typing.Optional[AgentTemplate] = None
|
|
14
|
+
|
|
15
|
+
if IS_PYDANTIC_V2:
|
|
16
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
17
|
+
else:
|
|
18
|
+
|
|
19
|
+
class Config:
|
|
20
|
+
frozen = True
|
|
21
|
+
smart_union = True
|
|
22
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
from .agent_template_provider import AgentTemplateProvider
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AgentTemplate(UniversalBaseModel):
|
|
11
|
+
id: typing.Optional[str] = pydantic.Field(default=None)
|
|
12
|
+
"""
|
|
13
|
+
Agent ID
|
|
14
|
+
"""
|
|
15
|
+
|
|
16
|
+
name: typing.Optional[str] = pydantic.Field(default=None)
|
|
17
|
+
"""
|
|
18
|
+
Agent name
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
22
|
+
"""
|
|
23
|
+
Agent description
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
prompts: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
|
|
27
|
+
"""
|
|
28
|
+
Array of prompt IDs used by this agent
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
tools: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
|
|
32
|
+
"""
|
|
33
|
+
Array of MCP server tool IDs used by this agent
|
|
34
|
+
"""
|
|
35
|
+
|
|
36
|
+
is_active: typing.Optional[bool] = pydantic.Field(default=None)
|
|
37
|
+
"""
|
|
38
|
+
Whether the agent is active
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
tags: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
|
|
42
|
+
"""
|
|
43
|
+
Tags for categorizing the agent
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
provider: typing.Optional[AgentTemplateProvider] = pydantic.Field(default=None)
|
|
47
|
+
"""
|
|
48
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
49
|
+
"""
|
|
50
|
+
|
|
51
|
+
if IS_PYDANTIC_V2:
|
|
52
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
53
|
+
else:
|
|
54
|
+
|
|
55
|
+
class Config:
|
|
56
|
+
frozen = True
|
|
57
|
+
smart_union = True
|
|
58
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class ChatMessageTemplate(UniversalBaseModel):
|
|
10
|
+
id: typing.Optional[str] = pydantic.Field(default=None)
|
|
11
|
+
"""
|
|
12
|
+
Chat message ID
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
session_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
16
|
+
"""
|
|
17
|
+
Chat session ID
|
|
18
|
+
"""
|
|
19
|
+
|
|
20
|
+
role: typing.Optional[str] = pydantic.Field(default=None)
|
|
21
|
+
"""
|
|
22
|
+
Message role
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
content: typing.Optional[str] = pydantic.Field(default=None)
|
|
26
|
+
"""
|
|
27
|
+
Message content
|
|
28
|
+
"""
|
|
29
|
+
|
|
30
|
+
created: typing.Optional[str] = pydantic.Field(default=None)
|
|
31
|
+
"""
|
|
32
|
+
Message created time
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
updated: typing.Optional[str] = pydantic.Field(default=None)
|
|
36
|
+
"""
|
|
37
|
+
Message updated time
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
user_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
41
|
+
"""
|
|
42
|
+
User ID
|
|
43
|
+
"""
|
|
44
|
+
|
|
45
|
+
function_name: typing.Optional[str] = pydantic.Field(default=None)
|
|
46
|
+
"""
|
|
47
|
+
Function name
|
|
48
|
+
"""
|
|
49
|
+
|
|
50
|
+
function_args: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
|
|
51
|
+
"""
|
|
52
|
+
Function arguments
|
|
53
|
+
"""
|
|
54
|
+
|
|
55
|
+
function_result: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
|
|
56
|
+
"""
|
|
57
|
+
Function result
|
|
58
|
+
"""
|
|
59
|
+
|
|
60
|
+
message_order: typing.Optional[int] = pydantic.Field(default=None)
|
|
61
|
+
"""
|
|
62
|
+
Message order
|
|
63
|
+
"""
|
|
64
|
+
|
|
65
|
+
if IS_PYDANTIC_V2:
|
|
66
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
67
|
+
else:
|
|
68
|
+
|
|
69
|
+
class Config:
|
|
70
|
+
frozen = True
|
|
71
|
+
smart_union = True
|
|
72
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class ChatSessionTemplate(UniversalBaseModel):
|
|
10
|
+
id: typing.Optional[str] = pydantic.Field(default=None)
|
|
11
|
+
"""
|
|
12
|
+
Chat session ID
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
user_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
16
|
+
"""
|
|
17
|
+
User ID
|
|
18
|
+
"""
|
|
19
|
+
|
|
20
|
+
session_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
21
|
+
"""
|
|
22
|
+
Chat session ID
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
status: typing.Optional[str] = pydantic.Field(default=None)
|
|
26
|
+
"""
|
|
27
|
+
Chat session status
|
|
28
|
+
"""
|
|
29
|
+
|
|
30
|
+
system_prompt: typing.Optional[str] = pydantic.Field(default=None)
|
|
31
|
+
"""
|
|
32
|
+
System prompt
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
title: typing.Optional[str] = pydantic.Field(default=None)
|
|
36
|
+
"""
|
|
37
|
+
Chat session title
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
agent_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
41
|
+
"""
|
|
42
|
+
Agent ID
|
|
43
|
+
"""
|
|
44
|
+
|
|
45
|
+
created: typing.Optional[str] = pydantic.Field(default=None)
|
|
46
|
+
"""
|
|
47
|
+
Chat session created time
|
|
48
|
+
"""
|
|
49
|
+
|
|
50
|
+
last_message_at: typing.Optional[str] = pydantic.Field(default=None)
|
|
51
|
+
"""
|
|
52
|
+
Chat session last message time
|
|
53
|
+
"""
|
|
54
|
+
|
|
55
|
+
updated: typing.Optional[str] = pydantic.Field(default=None)
|
|
56
|
+
"""
|
|
57
|
+
Chat session updated time
|
|
58
|
+
"""
|
|
59
|
+
|
|
60
|
+
if IS_PYDANTIC_V2:
|
|
61
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
62
|
+
else:
|
|
63
|
+
|
|
64
|
+
class Config:
|
|
65
|
+
frozen = True
|
|
66
|
+
smart_union = True
|
|
67
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
import typing_extensions
|
|
7
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
8
|
+
from ...core.serialization import FieldMetadata
|
|
9
|
+
from .json_patch_operation_op import JsonPatchOperationOp
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class JsonPatchOperation(UniversalBaseModel):
|
|
13
|
+
op: JsonPatchOperationOp = pydantic.Field()
|
|
14
|
+
"""
|
|
15
|
+
The operation to be performed
|
|
16
|
+
"""
|
|
17
|
+
|
|
18
|
+
path: str = pydantic.Field()
|
|
19
|
+
"""
|
|
20
|
+
A JSON Pointer string specifying a location within the target document
|
|
21
|
+
"""
|
|
22
|
+
|
|
23
|
+
value: typing.Optional[typing.Optional[typing.Any]] = pydantic.Field(default=None)
|
|
24
|
+
"""
|
|
25
|
+
The value to be used within the operations
|
|
26
|
+
"""
|
|
27
|
+
|
|
28
|
+
from_: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="from")] = pydantic.Field(default=None)
|
|
29
|
+
"""
|
|
30
|
+
A JSON Pointer string specifying the location in the target document to move the value from (used with move and copy operations)
|
|
31
|
+
"""
|
|
32
|
+
|
|
33
|
+
if IS_PYDANTIC_V2:
|
|
34
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
35
|
+
else:
|
|
36
|
+
|
|
37
|
+
class Config:
|
|
38
|
+
frozen = True
|
|
39
|
+
smart_union = True
|
|
40
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class PromptTemplate(UniversalBaseModel):
|
|
10
|
+
id: typing.Optional[str] = pydantic.Field(default=None)
|
|
11
|
+
"""
|
|
12
|
+
Prompt ID
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
name: typing.Optional[str] = pydantic.Field(default=None)
|
|
16
|
+
"""
|
|
17
|
+
Prompt name
|
|
18
|
+
"""
|
|
19
|
+
|
|
20
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
21
|
+
"""
|
|
22
|
+
Prompt description
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
content: typing.Optional[str] = pydantic.Field(default=None)
|
|
26
|
+
"""
|
|
27
|
+
Prompt content
|
|
28
|
+
"""
|
|
29
|
+
|
|
30
|
+
is_default: typing.Optional[bool] = pydantic.Field(default=None)
|
|
31
|
+
"""
|
|
32
|
+
Whether this is a default prompt
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
is_active: typing.Optional[bool] = pydantic.Field(default=None)
|
|
36
|
+
"""
|
|
37
|
+
Whether the prompt is active
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
tags: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
|
|
41
|
+
"""
|
|
42
|
+
Tags for categorizing the prompt
|
|
43
|
+
"""
|
|
44
|
+
|
|
45
|
+
if IS_PYDANTIC_V2:
|
|
46
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
47
|
+
else:
|
|
48
|
+
|
|
49
|
+
class Config:
|
|
50
|
+
frozen = True
|
|
51
|
+
smart_union = True
|
|
52
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import pydantic
|
|
6
|
+
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class SuccessResponse(UniversalBaseModel):
|
|
10
|
+
success: typing.Optional[bool] = None
|
|
11
|
+
message: typing.Optional[str] = None
|
|
12
|
+
|
|
13
|
+
if IS_PYDANTIC_V2:
|
|
14
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
15
|
+
else:
|
|
16
|
+
|
|
17
|
+
class Config:
|
|
18
|
+
frozen = True
|
|
19
|
+
smart_union = True
|
|
20
|
+
extra = pydantic.Extra.allow
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
# isort: skip_file
|
|
4
|
+
|
|
5
|
+
from .types import BadRequestErrorBody, UnauthorizedErrorBody
|
|
6
|
+
from .errors import BadRequestError, UnauthorizedError
|
|
7
|
+
from . import auth
|
|
8
|
+
from .auth import AuthGenerateTokenResponse
|
|
9
|
+
|
|
10
|
+
__all__ = [
|
|
11
|
+
"AuthGenerateTokenResponse",
|
|
12
|
+
"BadRequestError",
|
|
13
|
+
"BadRequestErrorBody",
|
|
14
|
+
"UnauthorizedError",
|
|
15
|
+
"UnauthorizedErrorBody",
|
|
16
|
+
"auth",
|
|
17
|
+
]
|