arbi 0.18.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.
- arbi/__init__.py +92 -0
- arbi/_base_client.py +2124 -0
- arbi/_client.py +442 -0
- arbi/_compat.py +219 -0
- arbi/_constants.py +14 -0
- arbi/_exceptions.py +108 -0
- arbi/_files.py +123 -0
- arbi/_models.py +872 -0
- arbi/_qs.py +150 -0
- arbi/_resource.py +43 -0
- arbi/_response.py +830 -0
- arbi/_streaming.py +333 -0
- arbi/_types.py +270 -0
- arbi/_utils/__init__.py +64 -0
- arbi/_utils/_compat.py +45 -0
- arbi/_utils/_datetime_parse.py +136 -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 +58 -0
- arbi/_utils/_transform.py +457 -0
- arbi/_utils/_typing.py +156 -0
- arbi/_utils/_utils.py +421 -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 +312 -0
- arbi/resources/api/configs.py +533 -0
- arbi/resources/api/conversation/__init__.py +33 -0
- arbi/resources/api/conversation/conversation.py +648 -0
- arbi/resources/api/conversation/user.py +270 -0
- arbi/resources/api/document/__init__.py +33 -0
- arbi/resources/api/document/doctag.py +516 -0
- arbi/resources/api/document/document.py +929 -0
- arbi/resources/api/health.py +253 -0
- arbi/resources/api/notifications.py +478 -0
- arbi/resources/api/tag.py +409 -0
- arbi/resources/api/user/__init__.py +61 -0
- arbi/resources/api/user/contacts.py +322 -0
- arbi/resources/api/user/settings.py +283 -0
- arbi/resources/api/user/subscription.py +230 -0
- arbi/resources/api/user/user.py +943 -0
- arbi/resources/api/workspace.py +1198 -0
- arbi/types/__init__.py +8 -0
- arbi/types/api/__init__.py +94 -0
- arbi/types/api/assistant_query_params.py +95 -0
- arbi/types/api/assistant_retrieve_params.py +95 -0
- arbi/types/api/chunker_config_param.py +9 -0
- arbi/types/api/config_create_params.py +227 -0
- arbi/types/api/config_create_response.py +17 -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 +234 -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_message_response.py +105 -0
- arbi/types/api/conversation_retrieve_threads_response.py +124 -0
- arbi/types/api/conversation_share_response.py +11 -0
- arbi/types/api/conversation_update_title_params.py +16 -0
- arbi/types/api/conversation_update_title_response.py +13 -0
- arbi/types/api/doc_response.py +66 -0
- arbi/types/api/document/__init__.py +11 -0
- arbi/types/api/document/doc_tag_response.py +40 -0
- arbi/types/api/document/doctag_create_params.py +35 -0
- arbi/types/api/document/doctag_create_response.py +10 -0
- arbi/types/api/document/doctag_delete_params.py +15 -0
- arbi/types/api/document/doctag_generate_params.py +22 -0
- arbi/types/api/document/doctag_generate_response.py +20 -0
- arbi/types/api/document/doctag_update_params.py +35 -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_params.py +13 -0
- arbi/types/api/document_get_parsed_response.py +26 -0
- arbi/types/api/document_retrieve_params.py +16 -0
- arbi/types/api/document_retrieve_response.py +10 -0
- arbi/types/api/document_update_params.py +42 -0
- arbi/types/api/document_update_response.py +10 -0
- arbi/types/api/document_upload_from_url_params.py +26 -0
- arbi/types/api/document_upload_from_url_response.py +16 -0
- arbi/types/api/document_upload_params.py +26 -0
- arbi/types/api/document_upload_response.py +16 -0
- arbi/types/api/embedder_config.py +30 -0
- arbi/types/api/embedder_config_param.py +29 -0
- arbi/types/api/health_check_models_response.py +21 -0
- arbi/types/api/health_get_models_response.py +19 -0
- arbi/types/api/health_retrieve_status_response.py +49 -0
- arbi/types/api/model_citation_config.py +20 -0
- arbi/types/api/model_citation_config_param.py +20 -0
- arbi/types/api/notification_create_params.py +20 -0
- arbi/types/api/notification_create_response.py +47 -0
- arbi/types/api/notification_delete_params.py +13 -0
- arbi/types/api/notification_get_schemas_response.py +197 -0
- arbi/types/api/notification_list_response.py +47 -0
- arbi/types/api/notification_update_params.py +27 -0
- arbi/types/api/notification_update_response.py +47 -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 +39 -0
- arbi/types/api/retriever_config_param.py +38 -0
- arbi/types/api/tag_create_params.py +49 -0
- arbi/types/api/tag_create_response.py +57 -0
- arbi/types/api/tag_delete_response.py +9 -0
- arbi/types/api/tag_update_params.py +22 -0
- arbi/types/api/tag_update_response.py +57 -0
- arbi/types/api/title_llm_config.py +29 -0
- arbi/types/api/title_llm_config_param.py +28 -0
- arbi/types/api/user/__init__.py +13 -0
- arbi/types/api/user/contact_create_params.py +13 -0
- arbi/types/api/user/contact_create_response.py +30 -0
- arbi/types/api/user/contact_delete_params.py +13 -0
- arbi/types/api/user/contact_list_response.py +30 -0
- arbi/types/api/user/setting_retrieve_response.py +89 -0
- arbi/types/api/user/setting_update_params.py +60 -0
- arbi/types/api/user/subscription_create_params.py +13 -0
- arbi/types/api/user/subscription_create_response.py +11 -0
- arbi/types/api/user/subscription_retrieve_response.py +48 -0
- arbi/types/api/user_change_password_params.py +18 -0
- arbi/types/api/user_change_password_response.py +11 -0
- arbi/types/api/user_check_sso_status_params.py +20 -0
- arbi/types/api/user_check_sso_status_response.py +25 -0
- arbi/types/api/user_list_products_response.py +37 -0
- arbi/types/api/user_list_workspaces_response.py +10 -0
- arbi/types/api/user_login_params.py +18 -0
- arbi/types/api/user_login_response.py +23 -0
- arbi/types/api/user_logout_response.py +9 -0
- arbi/types/api/user_register_params.py +22 -0
- arbi/types/api/user_response.py +26 -0
- arbi/types/api/user_verify_email_params.py +11 -0
- arbi/types/api/user_verify_email_response.py +9 -0
- arbi/types/api/workspace_copy_params.py +21 -0
- arbi/types/api/workspace_copy_response.py +25 -0
- arbi/types/api/workspace_create_protected_params.py +16 -0
- arbi/types/api/workspace_delete_response.py +9 -0
- arbi/types/api/workspace_get_conversations_response.py +30 -0
- arbi/types/api/workspace_get_documents_response.py +10 -0
- arbi/types/api/workspace_get_stats_response.py +17 -0
- arbi/types/api/workspace_get_tags_response.py +60 -0
- arbi/types/api/workspace_get_users_response.py +10 -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 +41 -0
- arbi/types/api/workspace_share_params.py +15 -0
- arbi/types/api/workspace_share_response.py +13 -0
- arbi/types/api/workspace_update_params.py +20 -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.18.0.dist-info/METADATA +410 -0
- arbi-0.18.0.dist-info/RECORD +165 -0
- arbi-0.18.0.dist-info/WHEEL +4 -0
- arbi-0.18.0.dist-info/licenses/LICENSE +201 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Dict, List, Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
|
|
6
|
+
from ...._models import BaseModel
|
|
7
|
+
|
|
8
|
+
__all__ = ["DocTagResponse", "Citations"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class Citations(BaseModel):
|
|
12
|
+
"""Data for a single citation - shared by DocTags and ModelCitationTool."""
|
|
13
|
+
|
|
14
|
+
chunk_ids: List[str]
|
|
15
|
+
|
|
16
|
+
offset_end: int
|
|
17
|
+
|
|
18
|
+
offset_start: int
|
|
19
|
+
|
|
20
|
+
statement: str
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
class DocTagResponse(BaseModel):
|
|
24
|
+
"""Response for doctag operations - the link between a document and a tag."""
|
|
25
|
+
|
|
26
|
+
created_at: datetime
|
|
27
|
+
|
|
28
|
+
created_by_ext_id: str
|
|
29
|
+
|
|
30
|
+
doc_ext_id: str
|
|
31
|
+
|
|
32
|
+
tag_ext_id: str
|
|
33
|
+
|
|
34
|
+
updated_at: datetime
|
|
35
|
+
|
|
36
|
+
citations: Optional[Dict[str, Citations]] = None
|
|
37
|
+
|
|
38
|
+
note: Optional[str] = None
|
|
39
|
+
|
|
40
|
+
updated_by_ext_id: Optional[str] = None
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Dict, Optional
|
|
6
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
7
|
+
|
|
8
|
+
from ...._types import SequenceNotStr
|
|
9
|
+
from ...._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["DoctagCreateParams", "Citations"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DoctagCreateParams(TypedDict, total=False):
|
|
15
|
+
doc_ext_ids: Required[SequenceNotStr[str]]
|
|
16
|
+
|
|
17
|
+
tag_ext_id: Required[str]
|
|
18
|
+
|
|
19
|
+
citations: Optional[Dict[str, Citations]]
|
|
20
|
+
|
|
21
|
+
note: Optional[str]
|
|
22
|
+
|
|
23
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class Citations(TypedDict, total=False):
|
|
27
|
+
"""Data for a single citation - shared by DocTags and ModelCitationTool."""
|
|
28
|
+
|
|
29
|
+
chunk_ids: Required[SequenceNotStr[str]]
|
|
30
|
+
|
|
31
|
+
offset_end: Required[int]
|
|
32
|
+
|
|
33
|
+
offset_start: Required[int]
|
|
34
|
+
|
|
35
|
+
statement: Required[str]
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
from typing_extensions import TypeAlias
|
|
5
|
+
|
|
6
|
+
from .doc_tag_response import DocTagResponse
|
|
7
|
+
|
|
8
|
+
__all__ = ["DoctagCreateResponse"]
|
|
9
|
+
|
|
10
|
+
DoctagCreateResponse: TypeAlias = List[DocTagResponse]
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Required, TypedDict
|
|
6
|
+
|
|
7
|
+
from ...._types import SequenceNotStr
|
|
8
|
+
|
|
9
|
+
__all__ = ["DoctagDeleteParams"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DoctagDeleteParams(TypedDict, total=False):
|
|
13
|
+
doc_ext_ids: Required[SequenceNotStr[str]]
|
|
14
|
+
|
|
15
|
+
tag_ext_id: Required[str]
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Optional
|
|
6
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
7
|
+
|
|
8
|
+
from ...._types import SequenceNotStr
|
|
9
|
+
from ...._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["DoctagGenerateParams"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DoctagGenerateParams(TypedDict, total=False):
|
|
15
|
+
doc_ext_ids: Required[SequenceNotStr[str]]
|
|
16
|
+
|
|
17
|
+
tag_ext_ids: Required[SequenceNotStr[str]]
|
|
18
|
+
|
|
19
|
+
config_ext_id: Optional[str]
|
|
20
|
+
"""Configuration to use for LLM"""
|
|
21
|
+
|
|
22
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
|
|
5
|
+
from ...._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["DoctagGenerateResponse"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class DoctagGenerateResponse(BaseModel):
|
|
11
|
+
"""Response for generate annotations endpoint (202 Accepted).
|
|
12
|
+
|
|
13
|
+
Returns the accepted doc and tag IDs that will be processed.
|
|
14
|
+
"""
|
|
15
|
+
|
|
16
|
+
doc_ext_ids: List[str]
|
|
17
|
+
"""Document IDs that will be processed"""
|
|
18
|
+
|
|
19
|
+
tag_ext_ids: List[str]
|
|
20
|
+
"""Tag IDs that will be processed"""
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Dict, Optional
|
|
6
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
7
|
+
|
|
8
|
+
from ...._types import SequenceNotStr
|
|
9
|
+
from ...._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["DoctagUpdateParams", "Citations"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DoctagUpdateParams(TypedDict, total=False):
|
|
15
|
+
doc_ext_id: Required[str]
|
|
16
|
+
|
|
17
|
+
tag_ext_id: Required[str]
|
|
18
|
+
|
|
19
|
+
citations: Optional[Dict[str, Citations]]
|
|
20
|
+
|
|
21
|
+
note: Optional[str]
|
|
22
|
+
|
|
23
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class Citations(TypedDict, total=False):
|
|
27
|
+
"""Data for a single citation - shared by DocTags and ModelCitationTool."""
|
|
28
|
+
|
|
29
|
+
chunk_ids: Required[SequenceNotStr[str]]
|
|
30
|
+
|
|
31
|
+
offset_end: Required[int]
|
|
32
|
+
|
|
33
|
+
offset_start: Required[int]
|
|
34
|
+
|
|
35
|
+
statement: Required[str]
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from typing_extensions import Literal
|
|
5
|
+
|
|
6
|
+
from pydantic import Field as FieldInfo
|
|
7
|
+
|
|
8
|
+
from ..._models import BaseModel
|
|
9
|
+
|
|
10
|
+
__all__ = ["DocumentDateExtractorLlmConfig"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class DocumentDateExtractorLlmConfig(BaseModel):
|
|
14
|
+
api_type: Optional[Literal["local", "remote"]] = FieldInfo(alias="API_TYPE", default=None)
|
|
15
|
+
"""The inference type (local or remote)."""
|
|
16
|
+
|
|
17
|
+
max_char_context_to_answer: Optional[int] = FieldInfo(alias="MAX_CHAR_CONTEXT_TO_ANSWER", default=None)
|
|
18
|
+
"""Maximum characters in document for context."""
|
|
19
|
+
|
|
20
|
+
max_tokens: Optional[int] = FieldInfo(alias="MAX_TOKENS", default=None)
|
|
21
|
+
"""Maximum number of tokens allowed."""
|
|
22
|
+
|
|
23
|
+
api_model_name: Optional[str] = FieldInfo(alias="MODEL_NAME", default=None)
|
|
24
|
+
"""The name of the non-reasoning model to be used."""
|
|
25
|
+
|
|
26
|
+
system_instruction: Optional[str] = FieldInfo(alias="SYSTEM_INSTRUCTION", default=None)
|
|
27
|
+
|
|
28
|
+
temperature: Optional[float] = FieldInfo(alias="TEMPERATURE", default=None)
|
|
29
|
+
"""Temperature value for randomness."""
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Literal, Annotated, TypedDict
|
|
6
|
+
|
|
7
|
+
from ..._utils import PropertyInfo
|
|
8
|
+
|
|
9
|
+
__all__ = ["DocumentDateExtractorLlmConfigParam"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DocumentDateExtractorLlmConfigParam(TypedDict, total=False):
|
|
13
|
+
api_type: Annotated[Literal["local", "remote"], PropertyInfo(alias="API_TYPE")]
|
|
14
|
+
"""The inference type (local or remote)."""
|
|
15
|
+
|
|
16
|
+
max_char_context_to_answer: Annotated[int, PropertyInfo(alias="MAX_CHAR_CONTEXT_TO_ANSWER")]
|
|
17
|
+
"""Maximum characters in document for context."""
|
|
18
|
+
|
|
19
|
+
max_tokens: Annotated[int, PropertyInfo(alias="MAX_TOKENS")]
|
|
20
|
+
"""Maximum number of tokens allowed."""
|
|
21
|
+
|
|
22
|
+
model_name: Annotated[str, PropertyInfo(alias="MODEL_NAME")]
|
|
23
|
+
"""The name of the non-reasoning model to be used."""
|
|
24
|
+
|
|
25
|
+
system_instruction: Annotated[str, PropertyInfo(alias="SYSTEM_INSTRUCTION")]
|
|
26
|
+
|
|
27
|
+
temperature: Annotated[float, PropertyInfo(alias="TEMPERATURE")]
|
|
28
|
+
"""Temperature value for randomness."""
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Required, TypedDict
|
|
6
|
+
|
|
7
|
+
from ..._types import SequenceNotStr
|
|
8
|
+
|
|
9
|
+
__all__ = ["DocumentDeleteParams"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DocumentDeleteParams(TypedDict, total=False):
|
|
13
|
+
external_ids: Required[SequenceNotStr[str]]
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Dict, List, Optional
|
|
4
|
+
|
|
5
|
+
from ..chunk import Chunk
|
|
6
|
+
from ..._models import BaseModel
|
|
7
|
+
|
|
8
|
+
__all__ = ["DocumentGetParsedResponse", "Metadata"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class Metadata(BaseModel):
|
|
12
|
+
doc_ext_id: Optional[str] = None
|
|
13
|
+
|
|
14
|
+
file_name: Optional[str] = None
|
|
15
|
+
|
|
16
|
+
re_ocred: Optional[bool] = None
|
|
17
|
+
|
|
18
|
+
total_number_of_pages: Optional[int] = None
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class DocumentGetParsedResponse(BaseModel):
|
|
22
|
+
metadata: Metadata
|
|
23
|
+
|
|
24
|
+
chunks: Optional[List[Chunk]] = None
|
|
25
|
+
|
|
26
|
+
footnotes: Optional[Dict[str, str]] = None
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
6
|
+
|
|
7
|
+
from ..._types import SequenceNotStr
|
|
8
|
+
from ..._utils import PropertyInfo
|
|
9
|
+
|
|
10
|
+
__all__ = ["DocumentRetrieveParams"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class DocumentRetrieveParams(TypedDict, total=False):
|
|
14
|
+
external_ids: Required[SequenceNotStr[str]]
|
|
15
|
+
|
|
16
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
from typing_extensions import TypeAlias
|
|
5
|
+
|
|
6
|
+
from .doc_response import DocResponse
|
|
7
|
+
|
|
8
|
+
__all__ = ["DocumentRetrieveResponse"]
|
|
9
|
+
|
|
10
|
+
DocumentRetrieveResponse: TypeAlias = List[DocResponse]
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Union, Iterable, Optional
|
|
6
|
+
from datetime import date
|
|
7
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
8
|
+
|
|
9
|
+
from ..._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["DocumentUpdateParams", "Document", "DocumentDocMetadata"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DocumentUpdateParams(TypedDict, total=False):
|
|
15
|
+
documents: Required[Iterable[Document]]
|
|
16
|
+
|
|
17
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
class DocumentDocMetadata(TypedDict, total=False):
|
|
21
|
+
"""Structured model for document metadata stored in JSONB column."""
|
|
22
|
+
|
|
23
|
+
doc_author: Optional[str]
|
|
24
|
+
|
|
25
|
+
doc_date: Annotated[Union[str, date, None], PropertyInfo(format="iso8601")]
|
|
26
|
+
|
|
27
|
+
doc_nature: Optional[str]
|
|
28
|
+
|
|
29
|
+
doc_subject: Optional[str]
|
|
30
|
+
|
|
31
|
+
title: Optional[str]
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class Document(TypedDict, total=False):
|
|
35
|
+
"""Document update request - identifies doc and fields to update."""
|
|
36
|
+
|
|
37
|
+
external_id: Required[str]
|
|
38
|
+
|
|
39
|
+
doc_metadata: Optional[DocumentDocMetadata]
|
|
40
|
+
"""Structured model for document metadata stored in JSONB column."""
|
|
41
|
+
|
|
42
|
+
shared: Optional[bool]
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
from typing_extensions import TypeAlias
|
|
5
|
+
|
|
6
|
+
from .doc_response import DocResponse
|
|
7
|
+
|
|
8
|
+
__all__ = ["DocumentUpdateResponse"]
|
|
9
|
+
|
|
10
|
+
DocumentUpdateResponse: TypeAlias = List[DocResponse]
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Optional
|
|
6
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
7
|
+
|
|
8
|
+
from ..._types import SequenceNotStr
|
|
9
|
+
from ..._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["DocumentUploadFromURLParams"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DocumentUploadFromURLParams(TypedDict, total=False):
|
|
15
|
+
urls: Required[SequenceNotStr[str]]
|
|
16
|
+
"""URLs to download documents from"""
|
|
17
|
+
|
|
18
|
+
workspace_ext_id: Required[str]
|
|
19
|
+
|
|
20
|
+
config_ext_id: Optional[str]
|
|
21
|
+
"""Configuration to use for processing"""
|
|
22
|
+
|
|
23
|
+
shared: bool
|
|
24
|
+
"""Whether the document should be shared with workspace members"""
|
|
25
|
+
|
|
26
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
|
|
5
|
+
from ..._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["DocumentUploadFromURLResponse"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class DocumentUploadFromURLResponse(BaseModel):
|
|
11
|
+
"""Response for document upload operations.
|
|
12
|
+
|
|
13
|
+
Returns array of document IDs in the same order as uploaded files.
|
|
14
|
+
"""
|
|
15
|
+
|
|
16
|
+
doc_ext_ids: List[str]
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Optional
|
|
6
|
+
from typing_extensions import Required, Annotated, TypedDict
|
|
7
|
+
|
|
8
|
+
from ..._types import FileTypes, SequenceNotStr
|
|
9
|
+
from ..._utils import PropertyInfo
|
|
10
|
+
|
|
11
|
+
__all__ = ["DocumentUploadParams"]
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class DocumentUploadParams(TypedDict, total=False):
|
|
15
|
+
workspace_ext_id: Required[str]
|
|
16
|
+
|
|
17
|
+
files: Required[SequenceNotStr[FileTypes]]
|
|
18
|
+
"""Multiple files to upload"""
|
|
19
|
+
|
|
20
|
+
config_ext_id: Optional[str]
|
|
21
|
+
"""Configuration to use for processing"""
|
|
22
|
+
|
|
23
|
+
shared: bool
|
|
24
|
+
"""Whether the document should be shared with workspace members"""
|
|
25
|
+
|
|
26
|
+
workspace_key: Annotated[str, PropertyInfo(alias="workspace-key")]
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
|
|
5
|
+
from ..._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["DocumentUploadResponse"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class DocumentUploadResponse(BaseModel):
|
|
11
|
+
"""Response for document upload operations.
|
|
12
|
+
|
|
13
|
+
Returns array of document IDs in the same order as uploaded files.
|
|
14
|
+
"""
|
|
15
|
+
|
|
16
|
+
doc_ext_ids: List[str]
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from typing_extensions import Literal
|
|
5
|
+
|
|
6
|
+
from pydantic import Field as FieldInfo
|
|
7
|
+
|
|
8
|
+
from ..._models import BaseModel
|
|
9
|
+
|
|
10
|
+
__all__ = ["EmbedderConfig"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class EmbedderConfig(BaseModel):
|
|
14
|
+
api_type: Optional[Literal["local", "remote"]] = FieldInfo(alias="API_TYPE", default=None)
|
|
15
|
+
"""The inference type (local or remote)."""
|
|
16
|
+
|
|
17
|
+
batch_size: Optional[int] = FieldInfo(alias="BATCH_SIZE", default=None)
|
|
18
|
+
"""Smaller batch size for better parallelization."""
|
|
19
|
+
|
|
20
|
+
embed_prefix: Optional[str] = FieldInfo(alias="EMBED_PREFIX", default=None)
|
|
21
|
+
"""How to embed the sentence for retrieval."""
|
|
22
|
+
|
|
23
|
+
max_concurrent_requests: Optional[int] = FieldInfo(alias="MAX_CONCURRENT_REQUESTS", default=None)
|
|
24
|
+
"""Adjust concurrency level as needed."""
|
|
25
|
+
|
|
26
|
+
api_model_name: Optional[str] = FieldInfo(alias="MODEL_NAME", default=None)
|
|
27
|
+
"""The name of the embedder model."""
|
|
28
|
+
|
|
29
|
+
query_prefix: Optional[str] = FieldInfo(alias="QUERY_PREFIX", default=None)
|
|
30
|
+
"""How to embed the sentence for query."""
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Literal, Annotated, TypedDict
|
|
6
|
+
|
|
7
|
+
from ..._utils import PropertyInfo
|
|
8
|
+
|
|
9
|
+
__all__ = ["EmbedderConfigParam"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class EmbedderConfigParam(TypedDict, total=False):
|
|
13
|
+
api_type: Annotated[Literal["local", "remote"], PropertyInfo(alias="API_TYPE")]
|
|
14
|
+
"""The inference type (local or remote)."""
|
|
15
|
+
|
|
16
|
+
batch_size: Annotated[int, PropertyInfo(alias="BATCH_SIZE")]
|
|
17
|
+
"""Smaller batch size for better parallelization."""
|
|
18
|
+
|
|
19
|
+
embed_prefix: Annotated[str, PropertyInfo(alias="EMBED_PREFIX")]
|
|
20
|
+
"""How to embed the sentence for retrieval."""
|
|
21
|
+
|
|
22
|
+
max_concurrent_requests: Annotated[int, PropertyInfo(alias="MAX_CONCURRENT_REQUESTS")]
|
|
23
|
+
"""Adjust concurrency level as needed."""
|
|
24
|
+
|
|
25
|
+
model_name: Annotated[str, PropertyInfo(alias="MODEL_NAME")]
|
|
26
|
+
"""The name of the embedder model."""
|
|
27
|
+
|
|
28
|
+
query_prefix: Annotated[str, PropertyInfo(alias="QUERY_PREFIX")]
|
|
29
|
+
"""How to embed the sentence for query."""
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List, Optional
|
|
4
|
+
|
|
5
|
+
from ..._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["HealthCheckModelsResponse", "Model"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class Model(BaseModel):
|
|
11
|
+
model: str
|
|
12
|
+
|
|
13
|
+
status: str
|
|
14
|
+
|
|
15
|
+
detail: Optional[str] = None
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class HealthCheckModelsResponse(BaseModel):
|
|
19
|
+
application: str
|
|
20
|
+
|
|
21
|
+
models: List[Model]
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import List
|
|
4
|
+
|
|
5
|
+
from pydantic import Field as FieldInfo
|
|
6
|
+
|
|
7
|
+
from ..._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["HealthGetModelsResponse", "Model"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class Model(BaseModel):
|
|
13
|
+
api_type: str
|
|
14
|
+
|
|
15
|
+
api_model_name: str = FieldInfo(alias="model_name")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class HealthGetModelsResponse(BaseModel):
|
|
19
|
+
models: List[Model]
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Dict, List, Optional
|
|
4
|
+
|
|
5
|
+
from ..._models import BaseModel
|
|
6
|
+
|
|
7
|
+
__all__ = ["HealthRetrieveStatusResponse", "ModelsHealth", "ModelsHealthModel", "Service"]
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class ModelsHealthModel(BaseModel):
|
|
11
|
+
model: str
|
|
12
|
+
|
|
13
|
+
status: str
|
|
14
|
+
|
|
15
|
+
detail: Optional[str] = None
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class ModelsHealth(BaseModel):
|
|
19
|
+
application: str
|
|
20
|
+
|
|
21
|
+
models: List[ModelsHealthModel]
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
class Service(BaseModel):
|
|
25
|
+
name: str
|
|
26
|
+
|
|
27
|
+
status: str
|
|
28
|
+
|
|
29
|
+
detail: Optional[str] = None
|
|
30
|
+
|
|
31
|
+
service_info: Optional[Dict[str, object]] = None
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class HealthRetrieveStatusResponse(BaseModel):
|
|
35
|
+
"""
|
|
36
|
+
Consolidated health response containing all system status and version information
|
|
37
|
+
"""
|
|
38
|
+
|
|
39
|
+
status: str
|
|
40
|
+
|
|
41
|
+
available_models: Optional[List[str]] = None
|
|
42
|
+
|
|
43
|
+
backend_git_hash: Optional[str] = None
|
|
44
|
+
|
|
45
|
+
frontend_docker_version: Optional[str] = None
|
|
46
|
+
|
|
47
|
+
models_health: Optional[ModelsHealth] = None
|
|
48
|
+
|
|
49
|
+
services: Optional[List[Service]] = None
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
|
|
5
|
+
from pydantic import Field as FieldInfo
|
|
6
|
+
|
|
7
|
+
from ..._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["ModelCitationConfig"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class ModelCitationConfig(BaseModel):
|
|
13
|
+
max_numb_citations: Optional[int] = FieldInfo(alias="MAX_NUMB_CITATIONS", default=None)
|
|
14
|
+
"""Maximum number of citations to return per statement."""
|
|
15
|
+
|
|
16
|
+
min_char_size_to_answer: Optional[int] = FieldInfo(alias="MIN_CHAR_SIZE_TO_ANSWER", default=None)
|
|
17
|
+
"""Minimum character length to be considered as a statement for citation."""
|
|
18
|
+
|
|
19
|
+
sim_threashold: Optional[float] = FieldInfo(alias="SIM_THREASHOLD", default=None)
|
|
20
|
+
"""How similar does the statement needs to be to be considered as citation."""
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing_extensions import Annotated, TypedDict
|
|
6
|
+
|
|
7
|
+
from ..._utils import PropertyInfo
|
|
8
|
+
|
|
9
|
+
__all__ = ["ModelCitationConfigParam"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class ModelCitationConfigParam(TypedDict, total=False):
|
|
13
|
+
max_numb_citations: Annotated[int, PropertyInfo(alias="MAX_NUMB_CITATIONS")]
|
|
14
|
+
"""Maximum number of citations to return per statement."""
|
|
15
|
+
|
|
16
|
+
min_char_size_to_answer: Annotated[int, PropertyInfo(alias="MIN_CHAR_SIZE_TO_ANSWER")]
|
|
17
|
+
"""Minimum character length to be considered as a statement for citation."""
|
|
18
|
+
|
|
19
|
+
sim_threashold: Annotated[float, PropertyInfo(alias="SIM_THREASHOLD")]
|
|
20
|
+
"""How similar does the statement needs to be to be considered as citation."""
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import Iterable
|
|
6
|
+
from typing_extensions import Required, TypedDict
|
|
7
|
+
|
|
8
|
+
__all__ = ["NotificationCreateParams", "Message"]
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class NotificationCreateParams(TypedDict, total=False):
|
|
12
|
+
messages: Required[Iterable[Message]]
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class Message(TypedDict, total=False):
|
|
16
|
+
"""Single recipient for bulk message send."""
|
|
17
|
+
|
|
18
|
+
content: Required[str]
|
|
19
|
+
|
|
20
|
+
recipient_ext_id: Required[str]
|