phenoml 0.0.2__py3-none-any.whl → 0.0.17__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/agent/__init__.py +6 -8
- phenoml/agent/client.py +85 -67
- phenoml/agent/raw_client.py +61 -77
- phenoml/agent/types/__init__.py +6 -8
- phenoml/agent/types/agent_create_request.py +53 -0
- phenoml/agent/types/agent_create_request_provider.py +5 -0
- phenoml/agent/types/agent_template.py +3 -6
- phenoml/agent/types/agent_template_provider.py +5 -0
- phenoml/agent/types/json_patch_operation.py +5 -1
- phenoml/client.py +12 -0
- phenoml/construe/__init__.py +2 -16
- phenoml/construe/client.py +0 -90
- phenoml/construe/raw_client.py +0 -180
- phenoml/construe/types/__init__.py +2 -20
- phenoml/construe/types/extract_request_config.py +33 -4
- phenoml/construe/types/extract_request_config_chunking_method.py +3 -1
- phenoml/construe/types/extract_request_config_validation_method.py +5 -0
- phenoml/construe/types/extract_request_system.py +2 -0
- phenoml/core/client_wrapper.py +2 -2
- phenoml/fhir/__init__.py +36 -0
- phenoml/fhir/client.py +1072 -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 +1469 -0
- phenoml/fhir/types/__init__.py +29 -0
- phenoml/{agent/types/chat_fhir_client_config.py → fhir/types/error_response.py} +11 -6
- 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/{construe/types/bad_request_error_body.py → fhir/types/fhir_bundle_entry_item_response.py} +4 -7
- 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 +45 -0
- phenoml/fhir_provider/client.py +748 -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 +1462 -0
- phenoml/fhir_provider/types/__init__.py +37 -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/role.py +27 -0
- phenoml/fhir_provider/types/service_account_key.py +35 -0
- phenoml/fhir_provider/types/smart_configuration.py +46 -0
- phenoml/lang2fhir/__init__.py +10 -0
- phenoml/lang2fhir/client.py +111 -6
- phenoml/lang2fhir/raw_client.py +189 -0
- phenoml/lang2fhir/types/__init__.py +10 -0
- phenoml/lang2fhir/types/create_multi_response.py +39 -0
- phenoml/lang2fhir/types/create_multi_response_bundle.py +28 -0
- phenoml/lang2fhir/types/create_multi_response_bundle_entry_item.py +24 -0
- phenoml/lang2fhir/types/create_multi_response_bundle_entry_item_request.py +20 -0
- phenoml/{construe/types/construe_cohort_response_queries_item_code_extract_results_item_codes_item.py → lang2fhir/types/create_multi_response_resources_item.py} +13 -7
- phenoml/summary/__init__.py +41 -0
- phenoml/summary/client.py +668 -0
- phenoml/summary/errors/__init__.py +11 -0
- phenoml/summary/errors/bad_request_error.py +10 -0
- phenoml/summary/errors/forbidden_error.py +10 -0
- phenoml/summary/errors/internal_server_error.py +10 -0
- phenoml/summary/errors/not_found_error.py +10 -0
- phenoml/summary/errors/unauthorized_error.py +10 -0
- phenoml/summary/raw_client.py +1202 -0
- phenoml/summary/types/__init__.py +33 -0
- phenoml/summary/types/create_summary_request_fhir_resources.py +8 -0
- phenoml/summary/types/create_summary_request_mode.py +5 -0
- phenoml/{agent/types/agent_fhir_config.py → summary/types/create_summary_response.py} +7 -9
- phenoml/summary/types/create_summary_template_response.py +23 -0
- phenoml/{construe/types/unauthorized_error_body.py → summary/types/error_response.py} +4 -8
- phenoml/summary/types/fhir_bundle.py +23 -0
- phenoml/summary/types/fhir_bundle_entry_item.py +20 -0
- phenoml/summary/types/fhir_resource.py +24 -0
- phenoml/summary/types/summary_delete_template_response.py +20 -0
- phenoml/summary/types/summary_get_template_response.py +21 -0
- phenoml/summary/types/summary_list_templates_response.py +21 -0
- phenoml/summary/types/summary_template.py +41 -0
- phenoml/summary/types/summary_update_template_response.py +22 -0
- phenoml/tools/__init__.py +6 -8
- phenoml/tools/client.py +259 -44
- phenoml/tools/raw_client.py +347 -55
- phenoml/tools/types/__init__.py +6 -8
- phenoml/tools/types/lang2fhir_and_create_multi_response.py +41 -0
- phenoml/{construe/types/construe_cohort_response_queries_item_code_extract_results_item.py → tools/types/lang2fhir_and_create_multi_response_resource_info_item.py} +14 -7
- phenoml/tools/types/lang2fhir_and_create_multi_response_response_bundle.py +27 -0
- phenoml/workflows/__init__.py +61 -0
- phenoml/workflows/client.py +694 -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/raw_client.py +1266 -0
- phenoml/workflows/types/__init__.py +53 -0
- phenoml/workflows/types/create_workflow_request_fhir_provider_id.py +5 -0
- phenoml/workflows/types/create_workflow_response.py +44 -0
- phenoml/{tools/types/fhir_client_config.py → workflows/types/decision_node_definition.py} +7 -6
- phenoml/workflows/types/execute_workflow_response.py +30 -0
- phenoml/{construe/types/internal_server_error_body.py → workflows/types/execute_workflow_response_results.py} +3 -8
- 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/update_workflow_request_fhir_provider_id.py +5 -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/types/workflows_delete_response.py +20 -0
- phenoml/workflows/types/workflows_get_response.py +26 -0
- phenoml/workflows/types/workflows_update_response.py +31 -0
- phenoml-0.0.17.dist-info/LICENSE +21 -0
- {phenoml-0.0.2.dist-info → phenoml-0.0.17.dist-info}/METADATA +1 -1
- phenoml-0.0.17.dist-info/RECORD +251 -0
- phenoml/agent/types/agent_provider.py +0 -7
- phenoml/agent/types/provider_type.py +0 -5
- phenoml/construe/types/construe_cohort_request_config.py +0 -37
- phenoml/construe/types/construe_cohort_response.py +0 -33
- phenoml/construe/types/construe_cohort_response_queries_item.py +0 -49
- phenoml/tools/types/cohort_request_provider.py +0 -5
- phenoml/tools/types/lang2fhir_and_create_request_provider.py +0 -7
- phenoml/tools/types/lang2fhir_and_search_request_provider.py +0 -7
- phenoml-0.0.2.dist-info/RECORD +0 -153
- {phenoml-0.0.2.dist-info → phenoml-0.0.17.dist-info}/WHEEL +0 -0
phenoml/agent/raw_client.py
CHANGED
|
@@ -16,14 +16,12 @@ from .errors.internal_server_error import InternalServerError
|
|
|
16
16
|
from .errors.not_found_error import NotFoundError
|
|
17
17
|
from .errors.unauthorized_error import UnauthorizedError
|
|
18
18
|
from .types.agent_chat_response import AgentChatResponse
|
|
19
|
+
from .types.agent_create_request_provider import AgentCreateRequestProvider
|
|
19
20
|
from .types.agent_delete_response import AgentDeleteResponse
|
|
20
|
-
from .types.agent_fhir_config import AgentFhirConfig
|
|
21
21
|
from .types.agent_get_chat_messages_request_order import AgentGetChatMessagesRequestOrder
|
|
22
22
|
from .types.agent_get_chat_messages_response import AgentGetChatMessagesResponse
|
|
23
23
|
from .types.agent_list_response import AgentListResponse
|
|
24
|
-
from .types.agent_provider import AgentProvider
|
|
25
24
|
from .types.agent_response import AgentResponse
|
|
26
|
-
from .types.chat_fhir_client_config import ChatFhirClientConfig
|
|
27
25
|
from .types.json_patch import JsonPatch
|
|
28
26
|
|
|
29
27
|
# this is used as the default value for optional parameters
|
|
@@ -43,8 +41,7 @@ class RawAgentClient:
|
|
|
43
41
|
description: typing.Optional[str] = OMIT,
|
|
44
42
|
tools: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
45
43
|
tags: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
46
|
-
provider: typing.Optional[
|
|
47
|
-
meta: typing.Optional[AgentFhirConfig] = OMIT,
|
|
44
|
+
provider: typing.Optional[AgentCreateRequestProvider] = OMIT,
|
|
48
45
|
request_options: typing.Optional[RequestOptions] = None,
|
|
49
46
|
) -> HttpResponse[AgentResponse]:
|
|
50
47
|
"""
|
|
@@ -70,10 +67,8 @@ class RawAgentClient:
|
|
|
70
67
|
tags : typing.Optional[typing.Sequence[str]]
|
|
71
68
|
Tags for categorizing the agent
|
|
72
69
|
|
|
73
|
-
provider : typing.Optional[
|
|
74
|
-
FHIR provider
|
|
75
|
-
|
|
76
|
-
meta : typing.Optional[AgentFhirConfig]
|
|
70
|
+
provider : typing.Optional[AgentCreateRequestProvider]
|
|
71
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
77
72
|
|
|
78
73
|
request_options : typing.Optional[RequestOptions]
|
|
79
74
|
Request-specific configuration.
|
|
@@ -94,10 +89,7 @@ class RawAgentClient:
|
|
|
94
89
|
"is_active": is_active,
|
|
95
90
|
"tags": tags,
|
|
96
91
|
"provider": convert_and_respect_annotation_metadata(
|
|
97
|
-
object_=provider, annotation=
|
|
98
|
-
),
|
|
99
|
-
"meta": convert_and_respect_annotation_metadata(
|
|
100
|
-
object_=meta, annotation=AgentFhirConfig, direction="write"
|
|
92
|
+
object_=provider, annotation=AgentCreateRequestProvider, direction="write"
|
|
101
93
|
),
|
|
102
94
|
},
|
|
103
95
|
headers={
|
|
@@ -333,14 +325,13 @@ class RawAgentClient:
|
|
|
333
325
|
self,
|
|
334
326
|
id: str,
|
|
335
327
|
*,
|
|
336
|
-
name:
|
|
328
|
+
name: str,
|
|
329
|
+
prompts: typing.Sequence[str],
|
|
330
|
+
is_active: bool,
|
|
337
331
|
description: typing.Optional[str] = OMIT,
|
|
338
|
-
prompts: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
339
332
|
tools: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
340
|
-
is_active: typing.Optional[bool] = OMIT,
|
|
341
333
|
tags: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
342
|
-
provider: typing.Optional[
|
|
343
|
-
meta: typing.Optional[AgentFhirConfig] = OMIT,
|
|
334
|
+
provider: typing.Optional[AgentCreateRequestProvider] = OMIT,
|
|
344
335
|
request_options: typing.Optional[RequestOptions] = None,
|
|
345
336
|
) -> HttpResponse[AgentResponse]:
|
|
346
337
|
"""
|
|
@@ -351,28 +342,26 @@ class RawAgentClient:
|
|
|
351
342
|
id : str
|
|
352
343
|
Agent ID
|
|
353
344
|
|
|
354
|
-
name :
|
|
345
|
+
name : str
|
|
355
346
|
Agent name
|
|
356
347
|
|
|
348
|
+
prompts : typing.Sequence[str]
|
|
349
|
+
Array of prompt IDs to use for this agent
|
|
350
|
+
|
|
351
|
+
is_active : bool
|
|
352
|
+
Whether the agent is active
|
|
353
|
+
|
|
357
354
|
description : typing.Optional[str]
|
|
358
355
|
Agent description
|
|
359
356
|
|
|
360
|
-
prompts : typing.Optional[typing.Sequence[str]]
|
|
361
|
-
Array of prompt IDs to use for this agent
|
|
362
|
-
|
|
363
357
|
tools : typing.Optional[typing.Sequence[str]]
|
|
364
358
|
Array of MCP server tool IDs to use for this agent
|
|
365
359
|
|
|
366
|
-
is_active : typing.Optional[bool]
|
|
367
|
-
Whether the agent is active
|
|
368
|
-
|
|
369
360
|
tags : typing.Optional[typing.Sequence[str]]
|
|
370
361
|
Tags for categorizing the agent
|
|
371
362
|
|
|
372
|
-
provider : typing.Optional[
|
|
373
|
-
FHIR provider
|
|
374
|
-
|
|
375
|
-
meta : typing.Optional[AgentFhirConfig]
|
|
363
|
+
provider : typing.Optional[AgentCreateRequestProvider]
|
|
364
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
376
365
|
|
|
377
366
|
request_options : typing.Optional[RequestOptions]
|
|
378
367
|
Request-specific configuration.
|
|
@@ -393,10 +382,7 @@ class RawAgentClient:
|
|
|
393
382
|
"is_active": is_active,
|
|
394
383
|
"tags": tags,
|
|
395
384
|
"provider": convert_and_respect_annotation_metadata(
|
|
396
|
-
object_=provider, annotation=
|
|
397
|
-
),
|
|
398
|
-
"meta": convert_and_respect_annotation_metadata(
|
|
399
|
-
object_=meta, annotation=AgentFhirConfig, direction="write"
|
|
385
|
+
object_=provider, annotation=AgentCreateRequestProvider, direction="write"
|
|
400
386
|
),
|
|
401
387
|
},
|
|
402
388
|
headers={
|
|
@@ -664,9 +650,10 @@ class RawAgentClient:
|
|
|
664
650
|
*,
|
|
665
651
|
message: str,
|
|
666
652
|
agent_id: str,
|
|
653
|
+
phenoml_on_behalf_of: typing.Optional[str] = None,
|
|
654
|
+
phenoml_fhir_provider: typing.Optional[str] = None,
|
|
667
655
|
context: typing.Optional[str] = OMIT,
|
|
668
656
|
session_id: typing.Optional[str] = OMIT,
|
|
669
|
-
meta: typing.Optional[ChatFhirClientConfig] = OMIT,
|
|
670
657
|
request_options: typing.Optional[RequestOptions] = None,
|
|
671
658
|
) -> HttpResponse[AgentChatResponse]:
|
|
672
659
|
"""
|
|
@@ -680,15 +667,20 @@ class RawAgentClient:
|
|
|
680
667
|
agent_id : str
|
|
681
668
|
The ID of the agent to chat with
|
|
682
669
|
|
|
670
|
+
phenoml_on_behalf_of : typing.Optional[str]
|
|
671
|
+
Optional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity.
|
|
672
|
+
Must be in the format: Patient/{uuid} or Practitioner/{uuid}
|
|
673
|
+
|
|
674
|
+
phenoml_fhir_provider : typing.Optional[str]
|
|
675
|
+
Optional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}.
|
|
676
|
+
Multiple FHIR provider integrations can be provided as comma-separated values.
|
|
677
|
+
|
|
683
678
|
context : typing.Optional[str]
|
|
684
679
|
Optional context for the conversation
|
|
685
680
|
|
|
686
681
|
session_id : typing.Optional[str]
|
|
687
682
|
Optional session ID for conversation continuity
|
|
688
683
|
|
|
689
|
-
meta : typing.Optional[ChatFhirClientConfig]
|
|
690
|
-
Optional user-specific FHIR configuration overrides
|
|
691
|
-
|
|
692
684
|
request_options : typing.Optional[RequestOptions]
|
|
693
685
|
Request-specific configuration.
|
|
694
686
|
|
|
@@ -705,12 +697,11 @@ class RawAgentClient:
|
|
|
705
697
|
"context": context,
|
|
706
698
|
"session_id": session_id,
|
|
707
699
|
"agent_id": agent_id,
|
|
708
|
-
"meta": convert_and_respect_annotation_metadata(
|
|
709
|
-
object_=meta, annotation=ChatFhirClientConfig, direction="write"
|
|
710
|
-
),
|
|
711
700
|
},
|
|
712
701
|
headers={
|
|
713
702
|
"content-type": "application/json",
|
|
703
|
+
"X-Phenoml-On-Behalf-Of": str(phenoml_on_behalf_of) if phenoml_on_behalf_of is not None else None,
|
|
704
|
+
"X-Phenoml-Fhir-Provider": str(phenoml_fhir_provider) if phenoml_fhir_provider is not None else None,
|
|
714
705
|
},
|
|
715
706
|
request_options=request_options,
|
|
716
707
|
omit=OMIT,
|
|
@@ -881,8 +872,7 @@ class AsyncRawAgentClient:
|
|
|
881
872
|
description: typing.Optional[str] = OMIT,
|
|
882
873
|
tools: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
883
874
|
tags: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
884
|
-
provider: typing.Optional[
|
|
885
|
-
meta: typing.Optional[AgentFhirConfig] = OMIT,
|
|
875
|
+
provider: typing.Optional[AgentCreateRequestProvider] = OMIT,
|
|
886
876
|
request_options: typing.Optional[RequestOptions] = None,
|
|
887
877
|
) -> AsyncHttpResponse[AgentResponse]:
|
|
888
878
|
"""
|
|
@@ -908,10 +898,8 @@ class AsyncRawAgentClient:
|
|
|
908
898
|
tags : typing.Optional[typing.Sequence[str]]
|
|
909
899
|
Tags for categorizing the agent
|
|
910
900
|
|
|
911
|
-
provider : typing.Optional[
|
|
912
|
-
FHIR provider
|
|
913
|
-
|
|
914
|
-
meta : typing.Optional[AgentFhirConfig]
|
|
901
|
+
provider : typing.Optional[AgentCreateRequestProvider]
|
|
902
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
915
903
|
|
|
916
904
|
request_options : typing.Optional[RequestOptions]
|
|
917
905
|
Request-specific configuration.
|
|
@@ -932,10 +920,7 @@ class AsyncRawAgentClient:
|
|
|
932
920
|
"is_active": is_active,
|
|
933
921
|
"tags": tags,
|
|
934
922
|
"provider": convert_and_respect_annotation_metadata(
|
|
935
|
-
object_=provider, annotation=
|
|
936
|
-
),
|
|
937
|
-
"meta": convert_and_respect_annotation_metadata(
|
|
938
|
-
object_=meta, annotation=AgentFhirConfig, direction="write"
|
|
923
|
+
object_=provider, annotation=AgentCreateRequestProvider, direction="write"
|
|
939
924
|
),
|
|
940
925
|
},
|
|
941
926
|
headers={
|
|
@@ -1173,14 +1158,13 @@ class AsyncRawAgentClient:
|
|
|
1173
1158
|
self,
|
|
1174
1159
|
id: str,
|
|
1175
1160
|
*,
|
|
1176
|
-
name:
|
|
1161
|
+
name: str,
|
|
1162
|
+
prompts: typing.Sequence[str],
|
|
1163
|
+
is_active: bool,
|
|
1177
1164
|
description: typing.Optional[str] = OMIT,
|
|
1178
|
-
prompts: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
1179
1165
|
tools: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
1180
|
-
is_active: typing.Optional[bool] = OMIT,
|
|
1181
1166
|
tags: typing.Optional[typing.Sequence[str]] = OMIT,
|
|
1182
|
-
provider: typing.Optional[
|
|
1183
|
-
meta: typing.Optional[AgentFhirConfig] = OMIT,
|
|
1167
|
+
provider: typing.Optional[AgentCreateRequestProvider] = OMIT,
|
|
1184
1168
|
request_options: typing.Optional[RequestOptions] = None,
|
|
1185
1169
|
) -> AsyncHttpResponse[AgentResponse]:
|
|
1186
1170
|
"""
|
|
@@ -1191,28 +1175,26 @@ class AsyncRawAgentClient:
|
|
|
1191
1175
|
id : str
|
|
1192
1176
|
Agent ID
|
|
1193
1177
|
|
|
1194
|
-
name :
|
|
1178
|
+
name : str
|
|
1195
1179
|
Agent name
|
|
1196
1180
|
|
|
1181
|
+
prompts : typing.Sequence[str]
|
|
1182
|
+
Array of prompt IDs to use for this agent
|
|
1183
|
+
|
|
1184
|
+
is_active : bool
|
|
1185
|
+
Whether the agent is active
|
|
1186
|
+
|
|
1197
1187
|
description : typing.Optional[str]
|
|
1198
1188
|
Agent description
|
|
1199
1189
|
|
|
1200
|
-
prompts : typing.Optional[typing.Sequence[str]]
|
|
1201
|
-
Array of prompt IDs to use for this agent
|
|
1202
|
-
|
|
1203
1190
|
tools : typing.Optional[typing.Sequence[str]]
|
|
1204
1191
|
Array of MCP server tool IDs to use for this agent
|
|
1205
1192
|
|
|
1206
|
-
is_active : typing.Optional[bool]
|
|
1207
|
-
Whether the agent is active
|
|
1208
|
-
|
|
1209
1193
|
tags : typing.Optional[typing.Sequence[str]]
|
|
1210
1194
|
Tags for categorizing the agent
|
|
1211
1195
|
|
|
1212
|
-
provider : typing.Optional[
|
|
1213
|
-
FHIR provider
|
|
1214
|
-
|
|
1215
|
-
meta : typing.Optional[AgentFhirConfig]
|
|
1196
|
+
provider : typing.Optional[AgentCreateRequestProvider]
|
|
1197
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
1216
1198
|
|
|
1217
1199
|
request_options : typing.Optional[RequestOptions]
|
|
1218
1200
|
Request-specific configuration.
|
|
@@ -1233,10 +1215,7 @@ class AsyncRawAgentClient:
|
|
|
1233
1215
|
"is_active": is_active,
|
|
1234
1216
|
"tags": tags,
|
|
1235
1217
|
"provider": convert_and_respect_annotation_metadata(
|
|
1236
|
-
object_=provider, annotation=
|
|
1237
|
-
),
|
|
1238
|
-
"meta": convert_and_respect_annotation_metadata(
|
|
1239
|
-
object_=meta, annotation=AgentFhirConfig, direction="write"
|
|
1218
|
+
object_=provider, annotation=AgentCreateRequestProvider, direction="write"
|
|
1240
1219
|
),
|
|
1241
1220
|
},
|
|
1242
1221
|
headers={
|
|
@@ -1504,9 +1483,10 @@ class AsyncRawAgentClient:
|
|
|
1504
1483
|
*,
|
|
1505
1484
|
message: str,
|
|
1506
1485
|
agent_id: str,
|
|
1486
|
+
phenoml_on_behalf_of: typing.Optional[str] = None,
|
|
1487
|
+
phenoml_fhir_provider: typing.Optional[str] = None,
|
|
1507
1488
|
context: typing.Optional[str] = OMIT,
|
|
1508
1489
|
session_id: typing.Optional[str] = OMIT,
|
|
1509
|
-
meta: typing.Optional[ChatFhirClientConfig] = OMIT,
|
|
1510
1490
|
request_options: typing.Optional[RequestOptions] = None,
|
|
1511
1491
|
) -> AsyncHttpResponse[AgentChatResponse]:
|
|
1512
1492
|
"""
|
|
@@ -1520,15 +1500,20 @@ class AsyncRawAgentClient:
|
|
|
1520
1500
|
agent_id : str
|
|
1521
1501
|
The ID of the agent to chat with
|
|
1522
1502
|
|
|
1503
|
+
phenoml_on_behalf_of : typing.Optional[str]
|
|
1504
|
+
Optional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity.
|
|
1505
|
+
Must be in the format: Patient/{uuid} or Practitioner/{uuid}
|
|
1506
|
+
|
|
1507
|
+
phenoml_fhir_provider : typing.Optional[str]
|
|
1508
|
+
Optional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}.
|
|
1509
|
+
Multiple FHIR provider integrations can be provided as comma-separated values.
|
|
1510
|
+
|
|
1523
1511
|
context : typing.Optional[str]
|
|
1524
1512
|
Optional context for the conversation
|
|
1525
1513
|
|
|
1526
1514
|
session_id : typing.Optional[str]
|
|
1527
1515
|
Optional session ID for conversation continuity
|
|
1528
1516
|
|
|
1529
|
-
meta : typing.Optional[ChatFhirClientConfig]
|
|
1530
|
-
Optional user-specific FHIR configuration overrides
|
|
1531
|
-
|
|
1532
1517
|
request_options : typing.Optional[RequestOptions]
|
|
1533
1518
|
Request-specific configuration.
|
|
1534
1519
|
|
|
@@ -1545,12 +1530,11 @@ class AsyncRawAgentClient:
|
|
|
1545
1530
|
"context": context,
|
|
1546
1531
|
"session_id": session_id,
|
|
1547
1532
|
"agent_id": agent_id,
|
|
1548
|
-
"meta": convert_and_respect_annotation_metadata(
|
|
1549
|
-
object_=meta, annotation=ChatFhirClientConfig, direction="write"
|
|
1550
|
-
),
|
|
1551
1533
|
},
|
|
1552
1534
|
headers={
|
|
1553
1535
|
"content-type": "application/json",
|
|
1536
|
+
"X-Phenoml-On-Behalf-Of": str(phenoml_on_behalf_of) if phenoml_on_behalf_of is not None else None,
|
|
1537
|
+
"X-Phenoml-Fhir-Provider": str(phenoml_fhir_provider) if phenoml_fhir_provider is not None else None,
|
|
1554
1538
|
},
|
|
1555
1539
|
request_options=request_options,
|
|
1556
1540
|
omit=OMIT,
|
phenoml/agent/types/__init__.py
CHANGED
|
@@ -3,43 +3,41 @@
|
|
|
3
3
|
# isort: skip_file
|
|
4
4
|
|
|
5
5
|
from .agent_chat_response import AgentChatResponse
|
|
6
|
+
from .agent_create_request import AgentCreateRequest
|
|
7
|
+
from .agent_create_request_provider import AgentCreateRequestProvider
|
|
6
8
|
from .agent_delete_response import AgentDeleteResponse
|
|
7
|
-
from .agent_fhir_config import AgentFhirConfig
|
|
8
9
|
from .agent_get_chat_messages_request_order import AgentGetChatMessagesRequestOrder
|
|
9
10
|
from .agent_get_chat_messages_response import AgentGetChatMessagesResponse
|
|
10
11
|
from .agent_list_response import AgentListResponse
|
|
11
12
|
from .agent_prompts_response import AgentPromptsResponse
|
|
12
|
-
from .agent_provider import AgentProvider
|
|
13
13
|
from .agent_response import AgentResponse
|
|
14
14
|
from .agent_template import AgentTemplate
|
|
15
|
-
from .
|
|
15
|
+
from .agent_template_provider import AgentTemplateProvider
|
|
16
16
|
from .chat_message_template import ChatMessageTemplate
|
|
17
17
|
from .chat_session_template import ChatSessionTemplate
|
|
18
18
|
from .json_patch import JsonPatch
|
|
19
19
|
from .json_patch_operation import JsonPatchOperation
|
|
20
20
|
from .json_patch_operation_op import JsonPatchOperationOp
|
|
21
21
|
from .prompt_template import PromptTemplate
|
|
22
|
-
from .provider_type import ProviderType
|
|
23
22
|
from .success_response import SuccessResponse
|
|
24
23
|
|
|
25
24
|
__all__ = [
|
|
26
25
|
"AgentChatResponse",
|
|
26
|
+
"AgentCreateRequest",
|
|
27
|
+
"AgentCreateRequestProvider",
|
|
27
28
|
"AgentDeleteResponse",
|
|
28
|
-
"AgentFhirConfig",
|
|
29
29
|
"AgentGetChatMessagesRequestOrder",
|
|
30
30
|
"AgentGetChatMessagesResponse",
|
|
31
31
|
"AgentListResponse",
|
|
32
32
|
"AgentPromptsResponse",
|
|
33
|
-
"AgentProvider",
|
|
34
33
|
"AgentResponse",
|
|
35
34
|
"AgentTemplate",
|
|
36
|
-
"
|
|
35
|
+
"AgentTemplateProvider",
|
|
37
36
|
"ChatMessageTemplate",
|
|
38
37
|
"ChatSessionTemplate",
|
|
39
38
|
"JsonPatch",
|
|
40
39
|
"JsonPatchOperation",
|
|
41
40
|
"JsonPatchOperationOp",
|
|
42
41
|
"PromptTemplate",
|
|
43
|
-
"ProviderType",
|
|
44
42
|
"SuccessResponse",
|
|
45
43
|
]
|
|
@@ -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
|
|
@@ -4,8 +4,7 @@ import typing
|
|
|
4
4
|
|
|
5
5
|
import pydantic
|
|
6
6
|
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
-
from .
|
|
8
|
-
from .agent_provider import AgentProvider
|
|
7
|
+
from .agent_template_provider import AgentTemplateProvider
|
|
9
8
|
|
|
10
9
|
|
|
11
10
|
class AgentTemplate(UniversalBaseModel):
|
|
@@ -44,13 +43,11 @@ class AgentTemplate(UniversalBaseModel):
|
|
|
44
43
|
Tags for categorizing the agent
|
|
45
44
|
"""
|
|
46
45
|
|
|
47
|
-
provider: typing.Optional[
|
|
46
|
+
provider: typing.Optional[AgentTemplateProvider] = pydantic.Field(default=None)
|
|
48
47
|
"""
|
|
49
|
-
FHIR provider
|
|
48
|
+
FHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
|
|
50
49
|
"""
|
|
51
50
|
|
|
52
|
-
meta: typing.Optional[AgentFhirConfig] = None
|
|
53
|
-
|
|
54
51
|
if IS_PYDANTIC_V2:
|
|
55
52
|
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
56
53
|
else:
|
|
@@ -20,7 +20,11 @@ class JsonPatchOperation(UniversalBaseModel):
|
|
|
20
20
|
A JSON Pointer string specifying a location within the target document
|
|
21
21
|
"""
|
|
22
22
|
|
|
23
|
-
value: typing.Optional[typing.Optional[typing.Any]] = None
|
|
23
|
+
value: typing.Optional[typing.Optional[typing.Any]] = pydantic.Field(default=None)
|
|
24
|
+
"""
|
|
25
|
+
The value to be used within the operations
|
|
26
|
+
"""
|
|
27
|
+
|
|
24
28
|
from_: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="from")] = pydantic.Field(default=None)
|
|
25
29
|
"""
|
|
26
30
|
A JSON Pointer string specifying the location in the target document to move the value from (used with move and copy operations)
|
phenoml/client.py
CHANGED
|
@@ -9,8 +9,12 @@ from .cohort.client import AsyncCohortClient, CohortClient
|
|
|
9
9
|
from .construe.client import AsyncConstrueClient, ConstrueClient
|
|
10
10
|
from .core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
|
|
11
11
|
from .environment import phenomlEnvironment
|
|
12
|
+
from .fhir.client import AsyncFhirClient, FhirClient
|
|
13
|
+
from .fhir_provider.client import AsyncFhirProviderClient, FhirProviderClient
|
|
12
14
|
from .lang2fhir.client import AsyncLang2FhirClient, Lang2FhirClient
|
|
15
|
+
from .summary.client import AsyncSummaryClient, SummaryClient
|
|
13
16
|
from .tools.client import AsyncToolsClient, ToolsClient
|
|
17
|
+
from .workflows.client import AsyncWorkflowsClient, WorkflowsClient
|
|
14
18
|
|
|
15
19
|
|
|
16
20
|
class phenoml:
|
|
@@ -82,8 +86,12 @@ class phenoml:
|
|
|
82
86
|
self.authtoken = AuthtokenClient(client_wrapper=self._client_wrapper)
|
|
83
87
|
self.cohort = CohortClient(client_wrapper=self._client_wrapper)
|
|
84
88
|
self.construe = ConstrueClient(client_wrapper=self._client_wrapper)
|
|
89
|
+
self.fhir = FhirClient(client_wrapper=self._client_wrapper)
|
|
90
|
+
self.fhir_provider = FhirProviderClient(client_wrapper=self._client_wrapper)
|
|
85
91
|
self.lang2fhir = Lang2FhirClient(client_wrapper=self._client_wrapper)
|
|
92
|
+
self.summary = SummaryClient(client_wrapper=self._client_wrapper)
|
|
86
93
|
self.tools = ToolsClient(client_wrapper=self._client_wrapper)
|
|
94
|
+
self.workflows = WorkflowsClient(client_wrapper=self._client_wrapper)
|
|
87
95
|
|
|
88
96
|
|
|
89
97
|
class Asyncphenoml:
|
|
@@ -155,8 +163,12 @@ class Asyncphenoml:
|
|
|
155
163
|
self.authtoken = AsyncAuthtokenClient(client_wrapper=self._client_wrapper)
|
|
156
164
|
self.cohort = AsyncCohortClient(client_wrapper=self._client_wrapper)
|
|
157
165
|
self.construe = AsyncConstrueClient(client_wrapper=self._client_wrapper)
|
|
166
|
+
self.fhir = AsyncFhirClient(client_wrapper=self._client_wrapper)
|
|
167
|
+
self.fhir_provider = AsyncFhirProviderClient(client_wrapper=self._client_wrapper)
|
|
158
168
|
self.lang2fhir = AsyncLang2FhirClient(client_wrapper=self._client_wrapper)
|
|
169
|
+
self.summary = AsyncSummaryClient(client_wrapper=self._client_wrapper)
|
|
159
170
|
self.tools = AsyncToolsClient(client_wrapper=self._client_wrapper)
|
|
171
|
+
self.workflows = AsyncWorkflowsClient(client_wrapper=self._client_wrapper)
|
|
160
172
|
|
|
161
173
|
|
|
162
174
|
def _get_base_url(*, base_url: typing.Optional[str] = None, environment: phenomlEnvironment) -> str:
|
phenoml/construe/__init__.py
CHANGED
|
@@ -3,43 +3,29 @@
|
|
|
3
3
|
# isort: skip_file
|
|
4
4
|
|
|
5
5
|
from .types import (
|
|
6
|
-
BadRequestErrorBody,
|
|
7
|
-
ConstrueCohortRequestConfig,
|
|
8
|
-
ConstrueCohortResponse,
|
|
9
|
-
ConstrueCohortResponseQueriesItem,
|
|
10
|
-
ConstrueCohortResponseQueriesItemCodeExtractResultsItem,
|
|
11
|
-
ConstrueCohortResponseQueriesItemCodeExtractResultsItemCodesItem,
|
|
12
6
|
ConstrueUploadCodeSystemResponse,
|
|
13
7
|
ExtractCodesResult,
|
|
14
8
|
ExtractRequestConfig,
|
|
15
9
|
ExtractRequestConfigChunkingMethod,
|
|
10
|
+
ExtractRequestConfigValidationMethod,
|
|
16
11
|
ExtractRequestSystem,
|
|
17
12
|
ExtractedCodeResult,
|
|
18
|
-
InternalServerErrorBody,
|
|
19
|
-
UnauthorizedErrorBody,
|
|
20
13
|
UploadRequestFormat,
|
|
21
14
|
)
|
|
22
15
|
from .errors import BadRequestError, ConflictError, FailedDependencyError, InternalServerError, UnauthorizedError
|
|
23
16
|
|
|
24
17
|
__all__ = [
|
|
25
18
|
"BadRequestError",
|
|
26
|
-
"BadRequestErrorBody",
|
|
27
19
|
"ConflictError",
|
|
28
|
-
"ConstrueCohortRequestConfig",
|
|
29
|
-
"ConstrueCohortResponse",
|
|
30
|
-
"ConstrueCohortResponseQueriesItem",
|
|
31
|
-
"ConstrueCohortResponseQueriesItemCodeExtractResultsItem",
|
|
32
|
-
"ConstrueCohortResponseQueriesItemCodeExtractResultsItemCodesItem",
|
|
33
20
|
"ConstrueUploadCodeSystemResponse",
|
|
34
21
|
"ExtractCodesResult",
|
|
35
22
|
"ExtractRequestConfig",
|
|
36
23
|
"ExtractRequestConfigChunkingMethod",
|
|
24
|
+
"ExtractRequestConfigValidationMethod",
|
|
37
25
|
"ExtractRequestSystem",
|
|
38
26
|
"ExtractedCodeResult",
|
|
39
27
|
"FailedDependencyError",
|
|
40
28
|
"InternalServerError",
|
|
41
|
-
"InternalServerErrorBody",
|
|
42
29
|
"UnauthorizedError",
|
|
43
|
-
"UnauthorizedErrorBody",
|
|
44
30
|
"UploadRequestFormat",
|
|
45
31
|
]
|
phenoml/construe/client.py
CHANGED
|
@@ -5,8 +5,6 @@ import typing
|
|
|
5
5
|
from ..core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
|
|
6
6
|
from ..core.request_options import RequestOptions
|
|
7
7
|
from .raw_client import AsyncRawConstrueClient, RawConstrueClient
|
|
8
|
-
from .types.construe_cohort_request_config import ConstrueCohortRequestConfig
|
|
9
|
-
from .types.construe_cohort_response import ConstrueCohortResponse
|
|
10
8
|
from .types.construe_upload_code_system_response import ConstrueUploadCodeSystemResponse
|
|
11
9
|
from .types.extract_codes_result import ExtractCodesResult
|
|
12
10
|
from .types.extract_request_config import ExtractRequestConfig
|
|
@@ -155,46 +153,6 @@ class ConstrueClient:
|
|
|
155
153
|
)
|
|
156
154
|
return _response.data
|
|
157
155
|
|
|
158
|
-
def cohort(
|
|
159
|
-
self,
|
|
160
|
-
*,
|
|
161
|
-
text: str,
|
|
162
|
-
config: typing.Optional[ConstrueCohortRequestConfig] = OMIT,
|
|
163
|
-
request_options: typing.Optional[RequestOptions] = None,
|
|
164
|
-
) -> ConstrueCohortResponse:
|
|
165
|
-
"""
|
|
166
|
-
Creates a patient cohort based on a natural language description.
|
|
167
|
-
Translates the description into FHIR search queries and optional SQL queries.
|
|
168
|
-
|
|
169
|
-
Parameters
|
|
170
|
-
----------
|
|
171
|
-
text : str
|
|
172
|
-
Natural language description of the desired patient cohort.
|
|
173
|
-
|
|
174
|
-
config : typing.Optional[ConstrueCohortRequestConfig]
|
|
175
|
-
|
|
176
|
-
request_options : typing.Optional[RequestOptions]
|
|
177
|
-
Request-specific configuration.
|
|
178
|
-
|
|
179
|
-
Returns
|
|
180
|
-
-------
|
|
181
|
-
ConstrueCohortResponse
|
|
182
|
-
Cohort creation successful
|
|
183
|
-
|
|
184
|
-
Examples
|
|
185
|
-
--------
|
|
186
|
-
from phenoml import phenoml
|
|
187
|
-
|
|
188
|
-
client = phenoml(
|
|
189
|
-
token="YOUR_TOKEN",
|
|
190
|
-
)
|
|
191
|
-
client.construe.cohort(
|
|
192
|
-
text="Between 20 and 40 years old with hyperlipidemia",
|
|
193
|
-
)
|
|
194
|
-
"""
|
|
195
|
-
_response = self._raw_client.cohort(text=text, config=config, request_options=request_options)
|
|
196
|
-
return _response.data
|
|
197
|
-
|
|
198
156
|
|
|
199
157
|
class AsyncConstrueClient:
|
|
200
158
|
def __init__(self, *, client_wrapper: AsyncClientWrapper):
|
|
@@ -349,51 +307,3 @@ class AsyncConstrueClient:
|
|
|
349
307
|
text=text, system=system, config=config, request_options=request_options
|
|
350
308
|
)
|
|
351
309
|
return _response.data
|
|
352
|
-
|
|
353
|
-
async def cohort(
|
|
354
|
-
self,
|
|
355
|
-
*,
|
|
356
|
-
text: str,
|
|
357
|
-
config: typing.Optional[ConstrueCohortRequestConfig] = OMIT,
|
|
358
|
-
request_options: typing.Optional[RequestOptions] = None,
|
|
359
|
-
) -> ConstrueCohortResponse:
|
|
360
|
-
"""
|
|
361
|
-
Creates a patient cohort based on a natural language description.
|
|
362
|
-
Translates the description into FHIR search queries and optional SQL queries.
|
|
363
|
-
|
|
364
|
-
Parameters
|
|
365
|
-
----------
|
|
366
|
-
text : str
|
|
367
|
-
Natural language description of the desired patient cohort.
|
|
368
|
-
|
|
369
|
-
config : typing.Optional[ConstrueCohortRequestConfig]
|
|
370
|
-
|
|
371
|
-
request_options : typing.Optional[RequestOptions]
|
|
372
|
-
Request-specific configuration.
|
|
373
|
-
|
|
374
|
-
Returns
|
|
375
|
-
-------
|
|
376
|
-
ConstrueCohortResponse
|
|
377
|
-
Cohort creation successful
|
|
378
|
-
|
|
379
|
-
Examples
|
|
380
|
-
--------
|
|
381
|
-
import asyncio
|
|
382
|
-
|
|
383
|
-
from phenoml import Asyncphenoml
|
|
384
|
-
|
|
385
|
-
client = Asyncphenoml(
|
|
386
|
-
token="YOUR_TOKEN",
|
|
387
|
-
)
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
async def main() -> None:
|
|
391
|
-
await client.construe.cohort(
|
|
392
|
-
text="Between 20 and 40 years old with hyperlipidemia",
|
|
393
|
-
)
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
asyncio.run(main())
|
|
397
|
-
"""
|
|
398
|
-
_response = await self._raw_client.cohort(text=text, config=config, request_options=request_options)
|
|
399
|
-
return _response.data
|