arbi 0.1.0__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.
Potentially problematic release.
This version of arbi might be problematic. Click here for more details.
- arbi/__init__.py +90 -0
- arbi/_base_client.py +1995 -0
- arbi/_client.py +394 -0
- arbi/_compat.py +219 -0
- arbi/_constants.py +14 -0
- arbi/_exceptions.py +108 -0
- arbi/_files.py +123 -0
- arbi/_models.py +829 -0
- arbi/_qs.py +150 -0
- arbi/_resource.py +43 -0
- arbi/_response.py +830 -0
- arbi/_streaming.py +333 -0
- arbi/_types.py +219 -0
- arbi/_utils/__init__.py +57 -0
- arbi/_utils/_logs.py +25 -0
- arbi/_utils/_proxy.py +65 -0
- arbi/_utils/_reflection.py +42 -0
- arbi/_utils/_resources_proxy.py +24 -0
- arbi/_utils/_streams.py +12 -0
- arbi/_utils/_sync.py +86 -0
- arbi/_utils/_transform.py +447 -0
- arbi/_utils/_typing.py +151 -0
- arbi/_utils/_utils.py +422 -0
- arbi/_version.py +4 -0
- arbi/lib/.keep +4 -0
- arbi/py.typed +0 -0
- arbi/resources/__init__.py +19 -0
- arbi/resources/api/__init__.py +145 -0
- arbi/resources/api/api.py +422 -0
- arbi/resources/api/assistant.py +300 -0
- arbi/resources/api/configs.py +499 -0
- arbi/resources/api/conversation/__init__.py +33 -0
- arbi/resources/api/conversation/conversation.py +555 -0
- arbi/resources/api/conversation/user.py +270 -0
- arbi/resources/api/document/__init__.py +33 -0
- arbi/resources/api/document/annotation.py +384 -0
- arbi/resources/api/document/document.py +873 -0
- arbi/resources/api/health.py +304 -0
- arbi/resources/api/sso.py +333 -0
- arbi/resources/api/tag.py +614 -0
- arbi/resources/api/user/__init__.py +33 -0
- arbi/resources/api/user/settings.py +251 -0
- arbi/resources/api/user/user.py +532 -0
- arbi/resources/api/workspace.py +1061 -0
- arbi/types/__init__.py +8 -0
- arbi/types/api/__init__.py +84 -0
- arbi/types/api/assistant_query_params.py +59 -0
- arbi/types/api/assistant_retrieve_params.py +59 -0
- arbi/types/api/chunker_config_param.py +9 -0
- arbi/types/api/config_create_params.py +45 -0
- arbi/types/api/config_create_response.py +15 -0
- arbi/types/api/config_delete_response.py +11 -0
- arbi/types/api/config_get_versions_response.py +19 -0
- arbi/types/api/config_retrieve_response.py +46 -0
- arbi/types/api/conversation/__init__.py +8 -0
- arbi/types/api/conversation/user_add_params.py +11 -0
- arbi/types/api/conversation/user_add_response.py +11 -0
- arbi/types/api/conversation/user_remove_params.py +11 -0
- arbi/types/api/conversation/user_remove_response.py +11 -0
- arbi/types/api/conversation_delete_message_response.py +11 -0
- arbi/types/api/conversation_delete_response.py +11 -0
- arbi/types/api/conversation_retrieve_threads_response.py +91 -0
- arbi/types/api/conversation_share_response.py +11 -0
- arbi/types/api/conversation_update_title_params.py +12 -0
- arbi/types/api/conversation_update_title_response.py +13 -0
- arbi/types/api/doc_response.py +48 -0
- arbi/types/api/document/__init__.py +8 -0
- arbi/types/api/document/annotation_create_params.py +16 -0
- arbi/types/api/document/annotation_delete_response.py +11 -0
- arbi/types/api/document/annotation_update_params.py +16 -0
- arbi/types/api/document/doc_tag_response.py +26 -0
- arbi/types/api/document_date_extractor_llm_config.py +29 -0
- arbi/types/api/document_date_extractor_llm_config_param.py +28 -0
- arbi/types/api/document_delete_response.py +11 -0
- arbi/types/api/document_get_parsed_response.py +26 -0
- arbi/types/api/document_get_tags_response.py +10 -0
- arbi/types/api/document_update_params.py +19 -0
- arbi/types/api/document_update_response.py +22 -0
- arbi/types/api/document_upload_params.py +23 -0
- arbi/types/api/document_view_params.py +13 -0
- arbi/types/api/embedder_config.py +18 -0
- arbi/types/api/embedder_config_param.py +17 -0
- arbi/types/api/health_check_app_response.py +9 -0
- arbi/types/api/health_check_models_response.py +21 -0
- arbi/types/api/health_check_services_response.py +23 -0
- arbi/types/api/health_get_models_response.py +19 -0
- arbi/types/api/model_citation_config.py +23 -0
- arbi/types/api/model_citation_config_param.py +23 -0
- arbi/types/api/parser_config_param.py +9 -0
- arbi/types/api/query_llm_config.py +30 -0
- arbi/types/api/query_llm_config_param.py +29 -0
- arbi/types/api/reranker_config.py +21 -0
- arbi/types/api/reranker_config_param.py +20 -0
- arbi/types/api/retriever_config.py +23 -0
- arbi/types/api/retriever_config_param.py +23 -0
- arbi/types/api/sso_invite_params.py +11 -0
- arbi/types/api/sso_invite_response.py +11 -0
- arbi/types/api/sso_login_params.py +16 -0
- arbi/types/api/sso_login_response.py +15 -0
- arbi/types/api/sso_rotate_passcode_response.py +11 -0
- arbi/types/api/tag_apply_to_docs_params.py +12 -0
- arbi/types/api/tag_apply_to_docs_response.py +13 -0
- arbi/types/api/tag_create_params.py +18 -0
- arbi/types/api/tag_create_response.py +11 -0
- arbi/types/api/tag_delete_response.py +9 -0
- arbi/types/api/tag_get_docs_response.py +10 -0
- arbi/types/api/tag_remove_from_docs_params.py +12 -0
- arbi/types/api/tag_remove_from_docs_response.py +13 -0
- arbi/types/api/tag_update_params.py +14 -0
- arbi/types/api/tag_update_response.py +17 -0
- arbi/types/api/title_llm_config.py +29 -0
- arbi/types/api/title_llm_config_param.py +28 -0
- arbi/types/api/token.py +13 -0
- arbi/types/api/user/__init__.py +6 -0
- arbi/types/api/user/setting_retrieve_response.py +36 -0
- arbi/types/api/user/setting_update_params.py +24 -0
- arbi/types/api/user_list_workspaces_response.py +10 -0
- arbi/types/api/user_login_params.py +13 -0
- arbi/types/api/user_logout_response.py +9 -0
- arbi/types/api/user_register_params.py +17 -0
- arbi/types/api/user_response.py +19 -0
- arbi/types/api/workspace_create_protected_params.py +14 -0
- arbi/types/api/workspace_delete_response.py +9 -0
- arbi/types/api/workspace_get_conversations_response.py +28 -0
- arbi/types/api/workspace_get_doctags_response.py +10 -0
- arbi/types/api/workspace_get_documents_response.py +10 -0
- arbi/types/api/workspace_get_stats_response.py +13 -0
- arbi/types/api/workspace_get_tags_response.py +30 -0
- arbi/types/api/workspace_get_users_response.py +17 -0
- arbi/types/api/workspace_remove_user_params.py +11 -0
- arbi/types/api/workspace_remove_user_response.py +11 -0
- arbi/types/api/workspace_response.py +24 -0
- arbi/types/api/workspace_share_params.py +11 -0
- arbi/types/api/workspace_share_response.py +21 -0
- arbi/types/api/workspace_update_params.py +14 -0
- arbi/types/chunk.py +12 -0
- arbi/types/chunk_metadata.py +31 -0
- arbi/types/chunk_metadata_param.py +32 -0
- arbi/types/chunk_param.py +15 -0
- arbi-0.1.0.dist-info/METADATA +410 -0
- arbi-0.1.0.dist-info/RECORD +143 -0
- arbi-0.1.0.dist-info/WHEEL +4 -0
- arbi-0.1.0.dist-info/licenses/LICENSE +201 -0
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from .api import (
|
|
4
|
+
APIResource,
|
|
5
|
+
AsyncAPIResource,
|
|
6
|
+
APIResourceWithRawResponse,
|
|
7
|
+
AsyncAPIResourceWithRawResponse,
|
|
8
|
+
APIResourceWithStreamingResponse,
|
|
9
|
+
AsyncAPIResourceWithStreamingResponse,
|
|
10
|
+
)
|
|
11
|
+
from .sso import (
|
|
12
|
+
SSOResource,
|
|
13
|
+
AsyncSSOResource,
|
|
14
|
+
SSOResourceWithRawResponse,
|
|
15
|
+
AsyncSSOResourceWithRawResponse,
|
|
16
|
+
SSOResourceWithStreamingResponse,
|
|
17
|
+
AsyncSSOResourceWithStreamingResponse,
|
|
18
|
+
)
|
|
19
|
+
from .tag import (
|
|
20
|
+
TagResource,
|
|
21
|
+
AsyncTagResource,
|
|
22
|
+
TagResourceWithRawResponse,
|
|
23
|
+
AsyncTagResourceWithRawResponse,
|
|
24
|
+
TagResourceWithStreamingResponse,
|
|
25
|
+
AsyncTagResourceWithStreamingResponse,
|
|
26
|
+
)
|
|
27
|
+
from .user import (
|
|
28
|
+
UserResource,
|
|
29
|
+
AsyncUserResource,
|
|
30
|
+
UserResourceWithRawResponse,
|
|
31
|
+
AsyncUserResourceWithRawResponse,
|
|
32
|
+
UserResourceWithStreamingResponse,
|
|
33
|
+
AsyncUserResourceWithStreamingResponse,
|
|
34
|
+
)
|
|
35
|
+
from .health import (
|
|
36
|
+
HealthResource,
|
|
37
|
+
AsyncHealthResource,
|
|
38
|
+
HealthResourceWithRawResponse,
|
|
39
|
+
AsyncHealthResourceWithRawResponse,
|
|
40
|
+
HealthResourceWithStreamingResponse,
|
|
41
|
+
AsyncHealthResourceWithStreamingResponse,
|
|
42
|
+
)
|
|
43
|
+
from .configs import (
|
|
44
|
+
ConfigsResource,
|
|
45
|
+
AsyncConfigsResource,
|
|
46
|
+
ConfigsResourceWithRawResponse,
|
|
47
|
+
AsyncConfigsResourceWithRawResponse,
|
|
48
|
+
ConfigsResourceWithStreamingResponse,
|
|
49
|
+
AsyncConfigsResourceWithStreamingResponse,
|
|
50
|
+
)
|
|
51
|
+
from .document import (
|
|
52
|
+
DocumentResource,
|
|
53
|
+
AsyncDocumentResource,
|
|
54
|
+
DocumentResourceWithRawResponse,
|
|
55
|
+
AsyncDocumentResourceWithRawResponse,
|
|
56
|
+
DocumentResourceWithStreamingResponse,
|
|
57
|
+
AsyncDocumentResourceWithStreamingResponse,
|
|
58
|
+
)
|
|
59
|
+
from .assistant import (
|
|
60
|
+
AssistantResource,
|
|
61
|
+
AsyncAssistantResource,
|
|
62
|
+
AssistantResourceWithRawResponse,
|
|
63
|
+
AsyncAssistantResourceWithRawResponse,
|
|
64
|
+
AssistantResourceWithStreamingResponse,
|
|
65
|
+
AsyncAssistantResourceWithStreamingResponse,
|
|
66
|
+
)
|
|
67
|
+
from .workspace import (
|
|
68
|
+
WorkspaceResource,
|
|
69
|
+
AsyncWorkspaceResource,
|
|
70
|
+
WorkspaceResourceWithRawResponse,
|
|
71
|
+
AsyncWorkspaceResourceWithRawResponse,
|
|
72
|
+
WorkspaceResourceWithStreamingResponse,
|
|
73
|
+
AsyncWorkspaceResourceWithStreamingResponse,
|
|
74
|
+
)
|
|
75
|
+
from .conversation import (
|
|
76
|
+
ConversationResource,
|
|
77
|
+
AsyncConversationResource,
|
|
78
|
+
ConversationResourceWithRawResponse,
|
|
79
|
+
AsyncConversationResourceWithRawResponse,
|
|
80
|
+
ConversationResourceWithStreamingResponse,
|
|
81
|
+
AsyncConversationResourceWithStreamingResponse,
|
|
82
|
+
)
|
|
83
|
+
|
|
84
|
+
__all__ = [
|
|
85
|
+
"UserResource",
|
|
86
|
+
"AsyncUserResource",
|
|
87
|
+
"UserResourceWithRawResponse",
|
|
88
|
+
"AsyncUserResourceWithRawResponse",
|
|
89
|
+
"UserResourceWithStreamingResponse",
|
|
90
|
+
"AsyncUserResourceWithStreamingResponse",
|
|
91
|
+
"SSOResource",
|
|
92
|
+
"AsyncSSOResource",
|
|
93
|
+
"SSOResourceWithRawResponse",
|
|
94
|
+
"AsyncSSOResourceWithRawResponse",
|
|
95
|
+
"SSOResourceWithStreamingResponse",
|
|
96
|
+
"AsyncSSOResourceWithStreamingResponse",
|
|
97
|
+
"WorkspaceResource",
|
|
98
|
+
"AsyncWorkspaceResource",
|
|
99
|
+
"WorkspaceResourceWithRawResponse",
|
|
100
|
+
"AsyncWorkspaceResourceWithRawResponse",
|
|
101
|
+
"WorkspaceResourceWithStreamingResponse",
|
|
102
|
+
"AsyncWorkspaceResourceWithStreamingResponse",
|
|
103
|
+
"DocumentResource",
|
|
104
|
+
"AsyncDocumentResource",
|
|
105
|
+
"DocumentResourceWithRawResponse",
|
|
106
|
+
"AsyncDocumentResourceWithRawResponse",
|
|
107
|
+
"DocumentResourceWithStreamingResponse",
|
|
108
|
+
"AsyncDocumentResourceWithStreamingResponse",
|
|
109
|
+
"ConversationResource",
|
|
110
|
+
"AsyncConversationResource",
|
|
111
|
+
"ConversationResourceWithRawResponse",
|
|
112
|
+
"AsyncConversationResourceWithRawResponse",
|
|
113
|
+
"ConversationResourceWithStreamingResponse",
|
|
114
|
+
"AsyncConversationResourceWithStreamingResponse",
|
|
115
|
+
"AssistantResource",
|
|
116
|
+
"AsyncAssistantResource",
|
|
117
|
+
"AssistantResourceWithRawResponse",
|
|
118
|
+
"AsyncAssistantResourceWithRawResponse",
|
|
119
|
+
"AssistantResourceWithStreamingResponse",
|
|
120
|
+
"AsyncAssistantResourceWithStreamingResponse",
|
|
121
|
+
"HealthResource",
|
|
122
|
+
"AsyncHealthResource",
|
|
123
|
+
"HealthResourceWithRawResponse",
|
|
124
|
+
"AsyncHealthResourceWithRawResponse",
|
|
125
|
+
"HealthResourceWithStreamingResponse",
|
|
126
|
+
"AsyncHealthResourceWithStreamingResponse",
|
|
127
|
+
"TagResource",
|
|
128
|
+
"AsyncTagResource",
|
|
129
|
+
"TagResourceWithRawResponse",
|
|
130
|
+
"AsyncTagResourceWithRawResponse",
|
|
131
|
+
"TagResourceWithStreamingResponse",
|
|
132
|
+
"AsyncTagResourceWithStreamingResponse",
|
|
133
|
+
"ConfigsResource",
|
|
134
|
+
"AsyncConfigsResource",
|
|
135
|
+
"ConfigsResourceWithRawResponse",
|
|
136
|
+
"AsyncConfigsResourceWithRawResponse",
|
|
137
|
+
"ConfigsResourceWithStreamingResponse",
|
|
138
|
+
"AsyncConfigsResourceWithStreamingResponse",
|
|
139
|
+
"APIResource",
|
|
140
|
+
"AsyncAPIResource",
|
|
141
|
+
"APIResourceWithRawResponse",
|
|
142
|
+
"AsyncAPIResourceWithRawResponse",
|
|
143
|
+
"APIResourceWithStreamingResponse",
|
|
144
|
+
"AsyncAPIResourceWithStreamingResponse",
|
|
145
|
+
]
|
|
@@ -0,0 +1,422 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
import httpx
|
|
6
|
+
|
|
7
|
+
from ... import _resource
|
|
8
|
+
from .sso import (
|
|
9
|
+
SSOResource,
|
|
10
|
+
AsyncSSOResource,
|
|
11
|
+
SSOResourceWithRawResponse,
|
|
12
|
+
AsyncSSOResourceWithRawResponse,
|
|
13
|
+
SSOResourceWithStreamingResponse,
|
|
14
|
+
AsyncSSOResourceWithStreamingResponse,
|
|
15
|
+
)
|
|
16
|
+
from .tag import (
|
|
17
|
+
TagResource,
|
|
18
|
+
AsyncTagResource,
|
|
19
|
+
TagResourceWithRawResponse,
|
|
20
|
+
AsyncTagResourceWithRawResponse,
|
|
21
|
+
TagResourceWithStreamingResponse,
|
|
22
|
+
AsyncTagResourceWithStreamingResponse,
|
|
23
|
+
)
|
|
24
|
+
from .health import (
|
|
25
|
+
HealthResource,
|
|
26
|
+
AsyncHealthResource,
|
|
27
|
+
HealthResourceWithRawResponse,
|
|
28
|
+
AsyncHealthResourceWithRawResponse,
|
|
29
|
+
HealthResourceWithStreamingResponse,
|
|
30
|
+
AsyncHealthResourceWithStreamingResponse,
|
|
31
|
+
)
|
|
32
|
+
from .configs import (
|
|
33
|
+
ConfigsResource,
|
|
34
|
+
AsyncConfigsResource,
|
|
35
|
+
ConfigsResourceWithRawResponse,
|
|
36
|
+
AsyncConfigsResourceWithRawResponse,
|
|
37
|
+
ConfigsResourceWithStreamingResponse,
|
|
38
|
+
AsyncConfigsResourceWithStreamingResponse,
|
|
39
|
+
)
|
|
40
|
+
from ..._types import NOT_GIVEN, Body, Query, Headers, NotGiven
|
|
41
|
+
from ..._compat import cached_property
|
|
42
|
+
from .assistant import (
|
|
43
|
+
AssistantResource,
|
|
44
|
+
AsyncAssistantResource,
|
|
45
|
+
AssistantResourceWithRawResponse,
|
|
46
|
+
AsyncAssistantResourceWithRawResponse,
|
|
47
|
+
AssistantResourceWithStreamingResponse,
|
|
48
|
+
AsyncAssistantResourceWithStreamingResponse,
|
|
49
|
+
)
|
|
50
|
+
from .user.user import (
|
|
51
|
+
UserResource,
|
|
52
|
+
AsyncUserResource,
|
|
53
|
+
UserResourceWithRawResponse,
|
|
54
|
+
AsyncUserResourceWithRawResponse,
|
|
55
|
+
UserResourceWithStreamingResponse,
|
|
56
|
+
AsyncUserResourceWithStreamingResponse,
|
|
57
|
+
)
|
|
58
|
+
from .workspace import (
|
|
59
|
+
WorkspaceResource,
|
|
60
|
+
AsyncWorkspaceResource,
|
|
61
|
+
WorkspaceResourceWithRawResponse,
|
|
62
|
+
AsyncWorkspaceResourceWithRawResponse,
|
|
63
|
+
WorkspaceResourceWithStreamingResponse,
|
|
64
|
+
AsyncWorkspaceResourceWithStreamingResponse,
|
|
65
|
+
)
|
|
66
|
+
from ..._response import (
|
|
67
|
+
to_raw_response_wrapper,
|
|
68
|
+
to_streamed_response_wrapper,
|
|
69
|
+
async_to_raw_response_wrapper,
|
|
70
|
+
async_to_streamed_response_wrapper,
|
|
71
|
+
)
|
|
72
|
+
from ..._base_client import make_request_options
|
|
73
|
+
from .document.document import (
|
|
74
|
+
DocumentResource,
|
|
75
|
+
AsyncDocumentResource,
|
|
76
|
+
DocumentResourceWithRawResponse,
|
|
77
|
+
AsyncDocumentResourceWithRawResponse,
|
|
78
|
+
DocumentResourceWithStreamingResponse,
|
|
79
|
+
AsyncDocumentResourceWithStreamingResponse,
|
|
80
|
+
)
|
|
81
|
+
from .conversation.conversation import (
|
|
82
|
+
ConversationResource,
|
|
83
|
+
AsyncConversationResource,
|
|
84
|
+
ConversationResourceWithRawResponse,
|
|
85
|
+
AsyncConversationResourceWithRawResponse,
|
|
86
|
+
ConversationResourceWithStreamingResponse,
|
|
87
|
+
AsyncConversationResourceWithStreamingResponse,
|
|
88
|
+
)
|
|
89
|
+
|
|
90
|
+
__all__ = ["APIResource", "AsyncAPIResource"]
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
class APIResource(_resource.SyncAPIResource):
|
|
94
|
+
@cached_property
|
|
95
|
+
def user(self) -> UserResource:
|
|
96
|
+
return UserResource(self._client)
|
|
97
|
+
|
|
98
|
+
@cached_property
|
|
99
|
+
def sso(self) -> SSOResource:
|
|
100
|
+
return SSOResource(self._client)
|
|
101
|
+
|
|
102
|
+
@cached_property
|
|
103
|
+
def workspace(self) -> WorkspaceResource:
|
|
104
|
+
return WorkspaceResource(self._client)
|
|
105
|
+
|
|
106
|
+
@cached_property
|
|
107
|
+
def document(self) -> DocumentResource:
|
|
108
|
+
return DocumentResource(self._client)
|
|
109
|
+
|
|
110
|
+
@cached_property
|
|
111
|
+
def conversation(self) -> ConversationResource:
|
|
112
|
+
return ConversationResource(self._client)
|
|
113
|
+
|
|
114
|
+
@cached_property
|
|
115
|
+
def assistant(self) -> AssistantResource:
|
|
116
|
+
return AssistantResource(self._client)
|
|
117
|
+
|
|
118
|
+
@cached_property
|
|
119
|
+
def health(self) -> HealthResource:
|
|
120
|
+
return HealthResource(self._client)
|
|
121
|
+
|
|
122
|
+
@cached_property
|
|
123
|
+
def tag(self) -> TagResource:
|
|
124
|
+
return TagResource(self._client)
|
|
125
|
+
|
|
126
|
+
@cached_property
|
|
127
|
+
def configs(self) -> ConfigsResource:
|
|
128
|
+
return ConfigsResource(self._client)
|
|
129
|
+
|
|
130
|
+
@cached_property
|
|
131
|
+
def with_raw_response(self) -> APIResourceWithRawResponse:
|
|
132
|
+
"""
|
|
133
|
+
This property can be used as a prefix for any HTTP method call to return
|
|
134
|
+
the raw response object instead of the parsed content.
|
|
135
|
+
|
|
136
|
+
For more information, see https://www.github.com/arbitrationcity/arbi-python#accessing-raw-response-data-eg-headers
|
|
137
|
+
"""
|
|
138
|
+
return APIResourceWithRawResponse(self)
|
|
139
|
+
|
|
140
|
+
@cached_property
|
|
141
|
+
def with_streaming_response(self) -> APIResourceWithStreamingResponse:
|
|
142
|
+
"""
|
|
143
|
+
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
144
|
+
|
|
145
|
+
For more information, see https://www.github.com/arbitrationcity/arbi-python#with_streaming_response
|
|
146
|
+
"""
|
|
147
|
+
return APIResourceWithStreamingResponse(self)
|
|
148
|
+
|
|
149
|
+
def index(
|
|
150
|
+
self,
|
|
151
|
+
*,
|
|
152
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
153
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
154
|
+
extra_headers: Headers | None = None,
|
|
155
|
+
extra_query: Query | None = None,
|
|
156
|
+
extra_body: Body | None = None,
|
|
157
|
+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
158
|
+
) -> object:
|
|
159
|
+
"""Serves the admin application page with necessary configuration variables."""
|
|
160
|
+
return self._get(
|
|
161
|
+
"/api",
|
|
162
|
+
options=make_request_options(
|
|
163
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
164
|
+
),
|
|
165
|
+
cast_to=object,
|
|
166
|
+
)
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
class AsyncAPIResource(_resource.AsyncAPIResource):
|
|
170
|
+
@cached_property
|
|
171
|
+
def user(self) -> AsyncUserResource:
|
|
172
|
+
return AsyncUserResource(self._client)
|
|
173
|
+
|
|
174
|
+
@cached_property
|
|
175
|
+
def sso(self) -> AsyncSSOResource:
|
|
176
|
+
return AsyncSSOResource(self._client)
|
|
177
|
+
|
|
178
|
+
@cached_property
|
|
179
|
+
def workspace(self) -> AsyncWorkspaceResource:
|
|
180
|
+
return AsyncWorkspaceResource(self._client)
|
|
181
|
+
|
|
182
|
+
@cached_property
|
|
183
|
+
def document(self) -> AsyncDocumentResource:
|
|
184
|
+
return AsyncDocumentResource(self._client)
|
|
185
|
+
|
|
186
|
+
@cached_property
|
|
187
|
+
def conversation(self) -> AsyncConversationResource:
|
|
188
|
+
return AsyncConversationResource(self._client)
|
|
189
|
+
|
|
190
|
+
@cached_property
|
|
191
|
+
def assistant(self) -> AsyncAssistantResource:
|
|
192
|
+
return AsyncAssistantResource(self._client)
|
|
193
|
+
|
|
194
|
+
@cached_property
|
|
195
|
+
def health(self) -> AsyncHealthResource:
|
|
196
|
+
return AsyncHealthResource(self._client)
|
|
197
|
+
|
|
198
|
+
@cached_property
|
|
199
|
+
def tag(self) -> AsyncTagResource:
|
|
200
|
+
return AsyncTagResource(self._client)
|
|
201
|
+
|
|
202
|
+
@cached_property
|
|
203
|
+
def configs(self) -> AsyncConfigsResource:
|
|
204
|
+
return AsyncConfigsResource(self._client)
|
|
205
|
+
|
|
206
|
+
@cached_property
|
|
207
|
+
def with_raw_response(self) -> AsyncAPIResourceWithRawResponse:
|
|
208
|
+
"""
|
|
209
|
+
This property can be used as a prefix for any HTTP method call to return
|
|
210
|
+
the raw response object instead of the parsed content.
|
|
211
|
+
|
|
212
|
+
For more information, see https://www.github.com/arbitrationcity/arbi-python#accessing-raw-response-data-eg-headers
|
|
213
|
+
"""
|
|
214
|
+
return AsyncAPIResourceWithRawResponse(self)
|
|
215
|
+
|
|
216
|
+
@cached_property
|
|
217
|
+
def with_streaming_response(self) -> AsyncAPIResourceWithStreamingResponse:
|
|
218
|
+
"""
|
|
219
|
+
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
220
|
+
|
|
221
|
+
For more information, see https://www.github.com/arbitrationcity/arbi-python#with_streaming_response
|
|
222
|
+
"""
|
|
223
|
+
return AsyncAPIResourceWithStreamingResponse(self)
|
|
224
|
+
|
|
225
|
+
async def index(
|
|
226
|
+
self,
|
|
227
|
+
*,
|
|
228
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
229
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
230
|
+
extra_headers: Headers | None = None,
|
|
231
|
+
extra_query: Query | None = None,
|
|
232
|
+
extra_body: Body | None = None,
|
|
233
|
+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
|
234
|
+
) -> object:
|
|
235
|
+
"""Serves the admin application page with necessary configuration variables."""
|
|
236
|
+
return await self._get(
|
|
237
|
+
"/api",
|
|
238
|
+
options=make_request_options(
|
|
239
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
240
|
+
),
|
|
241
|
+
cast_to=object,
|
|
242
|
+
)
|
|
243
|
+
|
|
244
|
+
|
|
245
|
+
class APIResourceWithRawResponse:
|
|
246
|
+
def __init__(self, api: APIResource) -> None:
|
|
247
|
+
self._api = api
|
|
248
|
+
|
|
249
|
+
self.index = to_raw_response_wrapper(
|
|
250
|
+
api.index,
|
|
251
|
+
)
|
|
252
|
+
|
|
253
|
+
@cached_property
|
|
254
|
+
def user(self) -> UserResourceWithRawResponse:
|
|
255
|
+
return UserResourceWithRawResponse(self._api.user)
|
|
256
|
+
|
|
257
|
+
@cached_property
|
|
258
|
+
def sso(self) -> SSOResourceWithRawResponse:
|
|
259
|
+
return SSOResourceWithRawResponse(self._api.sso)
|
|
260
|
+
|
|
261
|
+
@cached_property
|
|
262
|
+
def workspace(self) -> WorkspaceResourceWithRawResponse:
|
|
263
|
+
return WorkspaceResourceWithRawResponse(self._api.workspace)
|
|
264
|
+
|
|
265
|
+
@cached_property
|
|
266
|
+
def document(self) -> DocumentResourceWithRawResponse:
|
|
267
|
+
return DocumentResourceWithRawResponse(self._api.document)
|
|
268
|
+
|
|
269
|
+
@cached_property
|
|
270
|
+
def conversation(self) -> ConversationResourceWithRawResponse:
|
|
271
|
+
return ConversationResourceWithRawResponse(self._api.conversation)
|
|
272
|
+
|
|
273
|
+
@cached_property
|
|
274
|
+
def assistant(self) -> AssistantResourceWithRawResponse:
|
|
275
|
+
return AssistantResourceWithRawResponse(self._api.assistant)
|
|
276
|
+
|
|
277
|
+
@cached_property
|
|
278
|
+
def health(self) -> HealthResourceWithRawResponse:
|
|
279
|
+
return HealthResourceWithRawResponse(self._api.health)
|
|
280
|
+
|
|
281
|
+
@cached_property
|
|
282
|
+
def tag(self) -> TagResourceWithRawResponse:
|
|
283
|
+
return TagResourceWithRawResponse(self._api.tag)
|
|
284
|
+
|
|
285
|
+
@cached_property
|
|
286
|
+
def configs(self) -> ConfigsResourceWithRawResponse:
|
|
287
|
+
return ConfigsResourceWithRawResponse(self._api.configs)
|
|
288
|
+
|
|
289
|
+
|
|
290
|
+
class AsyncAPIResourceWithRawResponse:
|
|
291
|
+
def __init__(self, api: AsyncAPIResource) -> None:
|
|
292
|
+
self._api = api
|
|
293
|
+
|
|
294
|
+
self.index = async_to_raw_response_wrapper(
|
|
295
|
+
api.index,
|
|
296
|
+
)
|
|
297
|
+
|
|
298
|
+
@cached_property
|
|
299
|
+
def user(self) -> AsyncUserResourceWithRawResponse:
|
|
300
|
+
return AsyncUserResourceWithRawResponse(self._api.user)
|
|
301
|
+
|
|
302
|
+
@cached_property
|
|
303
|
+
def sso(self) -> AsyncSSOResourceWithRawResponse:
|
|
304
|
+
return AsyncSSOResourceWithRawResponse(self._api.sso)
|
|
305
|
+
|
|
306
|
+
@cached_property
|
|
307
|
+
def workspace(self) -> AsyncWorkspaceResourceWithRawResponse:
|
|
308
|
+
return AsyncWorkspaceResourceWithRawResponse(self._api.workspace)
|
|
309
|
+
|
|
310
|
+
@cached_property
|
|
311
|
+
def document(self) -> AsyncDocumentResourceWithRawResponse:
|
|
312
|
+
return AsyncDocumentResourceWithRawResponse(self._api.document)
|
|
313
|
+
|
|
314
|
+
@cached_property
|
|
315
|
+
def conversation(self) -> AsyncConversationResourceWithRawResponse:
|
|
316
|
+
return AsyncConversationResourceWithRawResponse(self._api.conversation)
|
|
317
|
+
|
|
318
|
+
@cached_property
|
|
319
|
+
def assistant(self) -> AsyncAssistantResourceWithRawResponse:
|
|
320
|
+
return AsyncAssistantResourceWithRawResponse(self._api.assistant)
|
|
321
|
+
|
|
322
|
+
@cached_property
|
|
323
|
+
def health(self) -> AsyncHealthResourceWithRawResponse:
|
|
324
|
+
return AsyncHealthResourceWithRawResponse(self._api.health)
|
|
325
|
+
|
|
326
|
+
@cached_property
|
|
327
|
+
def tag(self) -> AsyncTagResourceWithRawResponse:
|
|
328
|
+
return AsyncTagResourceWithRawResponse(self._api.tag)
|
|
329
|
+
|
|
330
|
+
@cached_property
|
|
331
|
+
def configs(self) -> AsyncConfigsResourceWithRawResponse:
|
|
332
|
+
return AsyncConfigsResourceWithRawResponse(self._api.configs)
|
|
333
|
+
|
|
334
|
+
|
|
335
|
+
class APIResourceWithStreamingResponse:
|
|
336
|
+
def __init__(self, api: APIResource) -> None:
|
|
337
|
+
self._api = api
|
|
338
|
+
|
|
339
|
+
self.index = to_streamed_response_wrapper(
|
|
340
|
+
api.index,
|
|
341
|
+
)
|
|
342
|
+
|
|
343
|
+
@cached_property
|
|
344
|
+
def user(self) -> UserResourceWithStreamingResponse:
|
|
345
|
+
return UserResourceWithStreamingResponse(self._api.user)
|
|
346
|
+
|
|
347
|
+
@cached_property
|
|
348
|
+
def sso(self) -> SSOResourceWithStreamingResponse:
|
|
349
|
+
return SSOResourceWithStreamingResponse(self._api.sso)
|
|
350
|
+
|
|
351
|
+
@cached_property
|
|
352
|
+
def workspace(self) -> WorkspaceResourceWithStreamingResponse:
|
|
353
|
+
return WorkspaceResourceWithStreamingResponse(self._api.workspace)
|
|
354
|
+
|
|
355
|
+
@cached_property
|
|
356
|
+
def document(self) -> DocumentResourceWithStreamingResponse:
|
|
357
|
+
return DocumentResourceWithStreamingResponse(self._api.document)
|
|
358
|
+
|
|
359
|
+
@cached_property
|
|
360
|
+
def conversation(self) -> ConversationResourceWithStreamingResponse:
|
|
361
|
+
return ConversationResourceWithStreamingResponse(self._api.conversation)
|
|
362
|
+
|
|
363
|
+
@cached_property
|
|
364
|
+
def assistant(self) -> AssistantResourceWithStreamingResponse:
|
|
365
|
+
return AssistantResourceWithStreamingResponse(self._api.assistant)
|
|
366
|
+
|
|
367
|
+
@cached_property
|
|
368
|
+
def health(self) -> HealthResourceWithStreamingResponse:
|
|
369
|
+
return HealthResourceWithStreamingResponse(self._api.health)
|
|
370
|
+
|
|
371
|
+
@cached_property
|
|
372
|
+
def tag(self) -> TagResourceWithStreamingResponse:
|
|
373
|
+
return TagResourceWithStreamingResponse(self._api.tag)
|
|
374
|
+
|
|
375
|
+
@cached_property
|
|
376
|
+
def configs(self) -> ConfigsResourceWithStreamingResponse:
|
|
377
|
+
return ConfigsResourceWithStreamingResponse(self._api.configs)
|
|
378
|
+
|
|
379
|
+
|
|
380
|
+
class AsyncAPIResourceWithStreamingResponse:
|
|
381
|
+
def __init__(self, api: AsyncAPIResource) -> None:
|
|
382
|
+
self._api = api
|
|
383
|
+
|
|
384
|
+
self.index = async_to_streamed_response_wrapper(
|
|
385
|
+
api.index,
|
|
386
|
+
)
|
|
387
|
+
|
|
388
|
+
@cached_property
|
|
389
|
+
def user(self) -> AsyncUserResourceWithStreamingResponse:
|
|
390
|
+
return AsyncUserResourceWithStreamingResponse(self._api.user)
|
|
391
|
+
|
|
392
|
+
@cached_property
|
|
393
|
+
def sso(self) -> AsyncSSOResourceWithStreamingResponse:
|
|
394
|
+
return AsyncSSOResourceWithStreamingResponse(self._api.sso)
|
|
395
|
+
|
|
396
|
+
@cached_property
|
|
397
|
+
def workspace(self) -> AsyncWorkspaceResourceWithStreamingResponse:
|
|
398
|
+
return AsyncWorkspaceResourceWithStreamingResponse(self._api.workspace)
|
|
399
|
+
|
|
400
|
+
@cached_property
|
|
401
|
+
def document(self) -> AsyncDocumentResourceWithStreamingResponse:
|
|
402
|
+
return AsyncDocumentResourceWithStreamingResponse(self._api.document)
|
|
403
|
+
|
|
404
|
+
@cached_property
|
|
405
|
+
def conversation(self) -> AsyncConversationResourceWithStreamingResponse:
|
|
406
|
+
return AsyncConversationResourceWithStreamingResponse(self._api.conversation)
|
|
407
|
+
|
|
408
|
+
@cached_property
|
|
409
|
+
def assistant(self) -> AsyncAssistantResourceWithStreamingResponse:
|
|
410
|
+
return AsyncAssistantResourceWithStreamingResponse(self._api.assistant)
|
|
411
|
+
|
|
412
|
+
@cached_property
|
|
413
|
+
def health(self) -> AsyncHealthResourceWithStreamingResponse:
|
|
414
|
+
return AsyncHealthResourceWithStreamingResponse(self._api.health)
|
|
415
|
+
|
|
416
|
+
@cached_property
|
|
417
|
+
def tag(self) -> AsyncTagResourceWithStreamingResponse:
|
|
418
|
+
return AsyncTagResourceWithStreamingResponse(self._api.tag)
|
|
419
|
+
|
|
420
|
+
@cached_property
|
|
421
|
+
def configs(self) -> AsyncConfigsResourceWithStreamingResponse:
|
|
422
|
+
return AsyncConfigsResourceWithStreamingResponse(self._api.configs)
|