retab 0.0.44__py3-none-any.whl → 0.0.46__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.
- retab/generate_types.py +1 -1
- retab/resources/deployments/client.py +9 -9
- retab/resources/projects/client.py +21 -21
- retab/resources/projects/documents.py +43 -43
- retab/resources/projects/iterations.py +54 -54
- retab/types/ai_models.py +1 -1
- retab/types/projects/documents.py +2 -0
- retab/utils/benchmarking.py +1 -1
- {retab-0.0.44.dist-info → retab-0.0.46.dist-info}/METADATA +1 -1
- {retab-0.0.44.dist-info → retab-0.0.46.dist-info}/RECORD +12 -12
- {retab-0.0.44.dist-info → retab-0.0.46.dist-info}/WHEEL +0 -0
- {retab-0.0.44.dist-info → retab-0.0.46.dist-info}/top_level.txt +0 -0
retab/generate_types.py
CHANGED
@@ -49,7 +49,7 @@ def type_to_zod(field_type: Any, put_names: bool = True, ts: bool = False) -> st
|
|
49
49
|
excluded_fields = set()
|
50
50
|
typename = "z.object({\n"
|
51
51
|
ts_typename = "{\n"
|
52
|
-
props = [(n, f.annotation, f.default) for n, f in origin.model_fields.items()] if issubclass(origin, BaseModel) else \
|
52
|
+
props = [(n, f.annotation, f.default) for n, f in origin.model_fields.items() if not f.exclude] if issubclass(origin, BaseModel) else \
|
53
53
|
[(n, f, PydanticUndefined) for n, f in origin.__annotations__.items()]
|
54
54
|
|
55
55
|
for field_name, field, default in props:
|
@@ -12,7 +12,7 @@ from ...types.standards import PreparedRequest
|
|
12
12
|
|
13
13
|
|
14
14
|
class DeploymentsMixin:
|
15
|
-
def
|
15
|
+
def prepare_extract(
|
16
16
|
self,
|
17
17
|
project_id: str,
|
18
18
|
iteration_id: str,
|
@@ -22,7 +22,7 @@ class DeploymentsMixin:
|
|
22
22
|
seed: int | None = None,
|
23
23
|
store: bool = True,
|
24
24
|
) -> PreparedRequest:
|
25
|
-
"""Prepare a request to
|
25
|
+
"""Prepare a request to extract documents from a deployment.
|
26
26
|
|
27
27
|
Args:
|
28
28
|
project_id: ID of the project
|
@@ -73,7 +73,7 @@ class DeploymentsMixin:
|
|
73
73
|
)
|
74
74
|
files = files_list
|
75
75
|
|
76
|
-
url = f"/v1/deployments/{project_id}/{iteration_id}
|
76
|
+
url = f"/v1/deployments/extract/{project_id}/{iteration_id}"
|
77
77
|
|
78
78
|
return PreparedRequest(method="POST", url=url, form_data=form_data, files=files)
|
79
79
|
|
@@ -84,7 +84,7 @@ class Deployments(SyncAPIResource, DeploymentsMixin):
|
|
84
84
|
def __init__(self, client: Any) -> None:
|
85
85
|
super().__init__(client=client)
|
86
86
|
|
87
|
-
def
|
87
|
+
def extract(
|
88
88
|
self,
|
89
89
|
project_id: str,
|
90
90
|
iteration_id: str,
|
@@ -94,7 +94,7 @@ class Deployments(SyncAPIResource, DeploymentsMixin):
|
|
94
94
|
seed: int | None = None,
|
95
95
|
store: bool = True,
|
96
96
|
) -> RetabParsedChatCompletion:
|
97
|
-
"""
|
97
|
+
"""Extract documents from a deployment.
|
98
98
|
|
99
99
|
Args:
|
100
100
|
project_id: ID of the project
|
@@ -108,7 +108,7 @@ class Deployments(SyncAPIResource, DeploymentsMixin):
|
|
108
108
|
Returns:
|
109
109
|
RetabParsedChatCompletion: The processing result
|
110
110
|
"""
|
111
|
-
request = self.
|
111
|
+
request = self.prepare_extract(project_id=project_id, iteration_id=iteration_id, document=document, documents=documents, temperature=temperature, seed=seed, store=store)
|
112
112
|
response = self._client._prepared_request(request)
|
113
113
|
return RetabParsedChatCompletion.model_validate(response)
|
114
114
|
|
@@ -119,7 +119,7 @@ class AsyncDeployments(AsyncAPIResource, DeploymentsMixin):
|
|
119
119
|
def __init__(self, client: Any) -> None:
|
120
120
|
super().__init__(client=client)
|
121
121
|
|
122
|
-
async def
|
122
|
+
async def extract(
|
123
123
|
self,
|
124
124
|
project_id: str,
|
125
125
|
iteration_id: str,
|
@@ -129,7 +129,7 @@ class AsyncDeployments(AsyncAPIResource, DeploymentsMixin):
|
|
129
129
|
seed: int | None = None,
|
130
130
|
store: bool = True,
|
131
131
|
) -> RetabParsedChatCompletion:
|
132
|
-
"""
|
132
|
+
"""Extract documents from a deployment.
|
133
133
|
|
134
134
|
Args:
|
135
135
|
project_id: ID of the project
|
@@ -143,6 +143,6 @@ class AsyncDeployments(AsyncAPIResource, DeploymentsMixin):
|
|
143
143
|
Returns:
|
144
144
|
RetabParsedChatCompletion: The processing result
|
145
145
|
"""
|
146
|
-
request = self.
|
146
|
+
request = self.prepare_extract(project_id=project_id, iteration_id=iteration_id, document=document, documents=documents, temperature=temperature, seed=seed, store=store)
|
147
147
|
response = await self._client._prepared_request(request)
|
148
148
|
return RetabParsedChatCompletion.model_validate(response)
|
@@ -26,12 +26,12 @@ class ProjectsMixin:
|
|
26
26
|
eval_data = BaseProject(**eval_dict)
|
27
27
|
return PreparedRequest(method="POST", url="/v1/projects", data=eval_data.model_dump(exclude_unset=True, mode="json"))
|
28
28
|
|
29
|
-
def prepare_get(self,
|
30
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
29
|
+
def prepare_get(self, project_id: str) -> PreparedRequest:
|
30
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}")
|
31
31
|
|
32
32
|
def prepare_update(
|
33
33
|
self,
|
34
|
-
|
34
|
+
project_id: str,
|
35
35
|
name: str = FieldUnset,
|
36
36
|
json_schema: dict[str, Any] = FieldUnset,
|
37
37
|
default_inference_settings: InferenceSettings = FieldUnset,
|
@@ -52,7 +52,7 @@ class ProjectsMixin:
|
|
52
52
|
|
53
53
|
data = PatchProjectRequest(**update_dict).model_dump(exclude_unset=True, mode="json")
|
54
54
|
|
55
|
-
return PreparedRequest(method="PATCH", url=f"/v1/projects/{
|
55
|
+
return PreparedRequest(method="PATCH", url=f"/v1/projects/{project_id}", data=data)
|
56
56
|
|
57
57
|
def prepare_list(self) -> PreparedRequest:
|
58
58
|
"""
|
@@ -105,25 +105,25 @@ class Projects(SyncAPIResource, ProjectsMixin):
|
|
105
105
|
response = self._client._prepared_request(request)
|
106
106
|
return Project(**response)
|
107
107
|
|
108
|
-
def get(self,
|
108
|
+
def get(self, project_id: str) -> Project:
|
109
109
|
"""
|
110
110
|
Get an evaluation by ID.
|
111
111
|
|
112
112
|
Args:
|
113
|
-
|
113
|
+
project_id: The ID of the evaluation to retrieve
|
114
114
|
|
115
115
|
Returns:
|
116
116
|
Project: The evaluation
|
117
117
|
Raises:
|
118
118
|
HTTPException if the request fails
|
119
119
|
"""
|
120
|
-
request = self.prepare_get(
|
120
|
+
request = self.prepare_get(project_id)
|
121
121
|
response = self._client._prepared_request(request)
|
122
122
|
return Project(**response)
|
123
123
|
|
124
124
|
def update(
|
125
125
|
self,
|
126
|
-
|
126
|
+
project_id: str,
|
127
127
|
name: str = FieldUnset,
|
128
128
|
json_schema: dict[str, Any] = FieldUnset,
|
129
129
|
default_inference_settings: InferenceSettings = FieldUnset,
|
@@ -132,7 +132,7 @@ class Projects(SyncAPIResource, ProjectsMixin):
|
|
132
132
|
Update an evaluation with partial updates.
|
133
133
|
|
134
134
|
Args:
|
135
|
-
|
135
|
+
project_id: The ID of the evaluation to update
|
136
136
|
name: Optional new name for the evaluation
|
137
137
|
json_schema: Optional new JSON schema
|
138
138
|
documents: Optional list of documents to update
|
@@ -145,7 +145,7 @@ class Projects(SyncAPIResource, ProjectsMixin):
|
|
145
145
|
HTTPException if the request fails
|
146
146
|
"""
|
147
147
|
request = self.prepare_update(
|
148
|
-
|
148
|
+
project_id=project_id,
|
149
149
|
name=name,
|
150
150
|
json_schema=json_schema,
|
151
151
|
default_inference_settings=default_inference_settings,
|
@@ -167,19 +167,19 @@ class Projects(SyncAPIResource, ProjectsMixin):
|
|
167
167
|
response = self._client._prepared_request(request)
|
168
168
|
return [Project(**item) for item in response.get("data", [])]
|
169
169
|
|
170
|
-
def delete(self,
|
170
|
+
def delete(self, project_id: str) -> DeleteResponse:
|
171
171
|
"""
|
172
172
|
Delete an evaluation.
|
173
173
|
|
174
174
|
Args:
|
175
|
-
|
175
|
+
project_id: The ID of the evaluation to delete
|
176
176
|
|
177
177
|
Returns:
|
178
178
|
DeleteResponse: The response containing success status and ID
|
179
179
|
Raises:
|
180
180
|
HTTPException if the request fails
|
181
181
|
"""
|
182
|
-
request = self.prepare_delete(
|
182
|
+
request = self.prepare_delete(project_id)
|
183
183
|
return self._client._prepared_request(request)
|
184
184
|
|
185
185
|
|
@@ -208,25 +208,25 @@ class AsyncProjects(AsyncAPIResource, ProjectsMixin):
|
|
208
208
|
response = await self._client._prepared_request(request)
|
209
209
|
return Project(**response)
|
210
210
|
|
211
|
-
async def get(self,
|
211
|
+
async def get(self, project_id: str) -> Project:
|
212
212
|
"""
|
213
213
|
Get an evaluation by ID.
|
214
214
|
|
215
215
|
Args:
|
216
|
-
|
216
|
+
project_id: The ID of the evaluation to retrieve
|
217
217
|
|
218
218
|
Returns:
|
219
219
|
Project: The evaluation
|
220
220
|
Raises:
|
221
221
|
HTTPException if the request fails
|
222
222
|
"""
|
223
|
-
request = self.prepare_get(
|
223
|
+
request = self.prepare_get(project_id)
|
224
224
|
response = await self._client._prepared_request(request)
|
225
225
|
return Project(**response)
|
226
226
|
|
227
227
|
async def update(
|
228
228
|
self,
|
229
|
-
|
229
|
+
project_id: str,
|
230
230
|
name: str = FieldUnset,
|
231
231
|
json_schema: dict[str, Any] = FieldUnset,
|
232
232
|
default_inference_settings: InferenceSettings = FieldUnset,
|
@@ -248,7 +248,7 @@ class AsyncProjects(AsyncAPIResource, ProjectsMixin):
|
|
248
248
|
HTTPException if the request fails
|
249
249
|
"""
|
250
250
|
request = self.prepare_update(
|
251
|
-
|
251
|
+
project_id=project_id,
|
252
252
|
name=name,
|
253
253
|
json_schema=json_schema,
|
254
254
|
default_inference_settings=default_inference_settings,
|
@@ -269,17 +269,17 @@ class AsyncProjects(AsyncAPIResource, ProjectsMixin):
|
|
269
269
|
response = await self._client._prepared_request(request)
|
270
270
|
return [Project(**item) for item in response.get("data", [])]
|
271
271
|
|
272
|
-
async def delete(self,
|
272
|
+
async def delete(self, project_id: str) -> DeleteResponse:
|
273
273
|
"""
|
274
274
|
Delete an evaluation.
|
275
275
|
|
276
276
|
Args:
|
277
|
-
|
277
|
+
project_id: The ID of the evaluation to delete
|
278
278
|
|
279
279
|
Returns:
|
280
280
|
DeleteResponse: The response containing success status and ID
|
281
281
|
Raises:
|
282
282
|
HTTPException if the request fails
|
283
283
|
"""
|
284
|
-
request = self.prepare_delete(
|
284
|
+
request = self.prepare_delete(project_id)
|
285
285
|
return await self._client._prepared_request(request)
|
@@ -15,26 +15,26 @@ from ...types.documents.extractions import RetabParsedChatCompletion
|
|
15
15
|
|
16
16
|
|
17
17
|
class DocumentsMixin:
|
18
|
-
def prepare_get(self,
|
19
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
18
|
+
def prepare_get(self, project_id: str, document_id: str) -> PreparedRequest:
|
19
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}/documents/{document_id}")
|
20
20
|
|
21
|
-
def prepare_create(self,
|
21
|
+
def prepare_create(self, project_id: str, document: MIMEData, annotation: dict[str, Any], annotation_metadata: dict[str, Any] | None = None) -> PreparedRequest:
|
22
22
|
# Serialize the MIMEData
|
23
23
|
document_item = DocumentItem(mime_data=document, annotation=annotation, annotation_metadata=PredictionMetadata(**annotation_metadata) if annotation_metadata else None)
|
24
|
-
return PreparedRequest(method="POST", url=f"/v1/projects/{
|
24
|
+
return PreparedRequest(method="POST", url=f"/v1/projects/{project_id}/documents", data=document_item.model_dump(mode="json"))
|
25
25
|
|
26
|
-
def prepare_list(self,
|
27
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
26
|
+
def prepare_list(self, project_id: str) -> PreparedRequest:
|
27
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}/documents")
|
28
28
|
|
29
|
-
def prepare_update(self,
|
29
|
+
def prepare_update(self, project_id: str, document_id: str, annotation: dict[str, Any]) -> PreparedRequest:
|
30
30
|
update_request = PatchProjectDocumentRequest(annotation=annotation)
|
31
|
-
return PreparedRequest(method="PATCH", url=f"/v1/projects/{
|
31
|
+
return PreparedRequest(method="PATCH", url=f"/v1/projects/{project_id}/documents/{document_id}", data=update_request.model_dump(mode="json", exclude_unset=True))
|
32
32
|
|
33
|
-
def prepare_delete(self,
|
34
|
-
return PreparedRequest(method="DELETE", url=f"/v1/projects/{
|
33
|
+
def prepare_delete(self, project_id: str, document_id: str) -> PreparedRequest:
|
34
|
+
return PreparedRequest(method="DELETE", url=f"/v1/projects/{project_id}/documents/{document_id}")
|
35
35
|
|
36
|
-
def prepare_llm_annotate(self,
|
37
|
-
return PreparedRequest(method="POST", url=f"/v1/projects/{
|
36
|
+
def prepare_llm_annotate(self, project_id: str, document_id: str) -> PreparedRequest:
|
37
|
+
return PreparedRequest(method="POST", url=f"/v1/projects/{project_id}/documents/{document_id}/llm-annotate", data={"stream": False})
|
38
38
|
|
39
39
|
|
40
40
|
class Documents(SyncAPIResource, DocumentsMixin):
|
@@ -42,7 +42,7 @@ class Documents(SyncAPIResource, DocumentsMixin):
|
|
42
42
|
|
43
43
|
def create(
|
44
44
|
self,
|
45
|
-
|
45
|
+
project_id: str,
|
46
46
|
document: Union[Path, str, IOBase, MIMEData, PIL.Image.Image, HttpUrl],
|
47
47
|
annotation: Dict[str, Any],
|
48
48
|
annotation_metadata: Dict[str, Any] | None = None,
|
@@ -51,7 +51,7 @@ class Documents(SyncAPIResource, DocumentsMixin):
|
|
51
51
|
Create a document for an evaluation.
|
52
52
|
|
53
53
|
Args:
|
54
|
-
|
54
|
+
project_id: The ID of the evaluation
|
55
55
|
document: The document to process. Can be:
|
56
56
|
- A file path (Path or str)
|
57
57
|
- A file-like object (IOBase)
|
@@ -69,32 +69,32 @@ class Documents(SyncAPIResource, DocumentsMixin):
|
|
69
69
|
mime_document: MIMEData = prepare_mime_document(document)
|
70
70
|
|
71
71
|
# Let prepare_create handle the serialization
|
72
|
-
request = self.prepare_create(
|
72
|
+
request = self.prepare_create(project_id, mime_document, annotation, annotation_metadata)
|
73
73
|
response = self._client._prepared_request(request)
|
74
74
|
return ProjectDocument(**response)
|
75
75
|
|
76
|
-
def list(self,
|
76
|
+
def list(self, project_id: str) -> List[ProjectDocument]:
|
77
77
|
"""
|
78
78
|
List documents for an evaluation.
|
79
79
|
|
80
80
|
Args:
|
81
|
-
|
81
|
+
project_id: The ID of the evaluation
|
82
82
|
|
83
83
|
Returns:
|
84
84
|
List[ProjectDocument]: List of documents
|
85
85
|
Raises:
|
86
86
|
HTTPException if the request fails
|
87
87
|
"""
|
88
|
-
request = self.prepare_list(
|
88
|
+
request = self.prepare_list(project_id)
|
89
89
|
response = self._client._prepared_request(request)
|
90
90
|
return [ProjectDocument(**item) for item in response.get("data", [])]
|
91
91
|
|
92
|
-
def get(self,
|
92
|
+
def get(self, project_id: str, document_id: str) -> ProjectDocument:
|
93
93
|
"""
|
94
94
|
Get a document by ID.
|
95
95
|
|
96
96
|
Args:
|
97
|
-
|
97
|
+
project_id: The ID of the evaluation
|
98
98
|
document_id: The ID of the document
|
99
99
|
|
100
100
|
Returns:
|
@@ -102,16 +102,16 @@ class Documents(SyncAPIResource, DocumentsMixin):
|
|
102
102
|
Raises:
|
103
103
|
HTTPException if the request fails
|
104
104
|
"""
|
105
|
-
request = self.prepare_get(
|
105
|
+
request = self.prepare_get(project_id, document_id)
|
106
106
|
response = self._client._prepared_request(request)
|
107
107
|
return ProjectDocument(**response)
|
108
108
|
|
109
|
-
def update(self,
|
109
|
+
def update(self, project_id: str, document_id: str, annotation: dict[str, Any]) -> ProjectDocument:
|
110
110
|
"""
|
111
111
|
Update a document.
|
112
112
|
|
113
113
|
Args:
|
114
|
-
|
114
|
+
project_id: The ID of the evaluation
|
115
115
|
document_id: The ID of the document
|
116
116
|
annotation: The ground truth for the document
|
117
117
|
Returns:
|
@@ -119,16 +119,16 @@ class Documents(SyncAPIResource, DocumentsMixin):
|
|
119
119
|
Raises:
|
120
120
|
HTTPException if the request fails
|
121
121
|
"""
|
122
|
-
request = self.prepare_update(
|
122
|
+
request = self.prepare_update(project_id, document_id, annotation=annotation)
|
123
123
|
response = self._client._prepared_request(request)
|
124
124
|
return ProjectDocument(**response)
|
125
125
|
|
126
|
-
def delete(self,
|
126
|
+
def delete(self, project_id: str, document_id: str) -> DeleteResponse:
|
127
127
|
"""
|
128
128
|
Delete a document.
|
129
129
|
|
130
130
|
Args:
|
131
|
-
|
131
|
+
project_id: The ID of the evaluation
|
132
132
|
document_id: The ID of the document
|
133
133
|
|
134
134
|
Returns:
|
@@ -136,14 +136,14 @@ class Documents(SyncAPIResource, DocumentsMixin):
|
|
136
136
|
Raises:
|
137
137
|
HTTPException if the request fails
|
138
138
|
"""
|
139
|
-
request = self.prepare_delete(
|
139
|
+
request = self.prepare_delete(project_id, document_id)
|
140
140
|
return self._client._prepared_request(request)
|
141
141
|
|
142
|
-
def llm_annotate(self,
|
142
|
+
def llm_annotate(self, project_id: str, document_id: str) -> RetabParsedChatCompletion:
|
143
143
|
"""
|
144
144
|
Annotate a document with an LLM. This method updates the document (within the evaluation) with the latest extraction.
|
145
145
|
"""
|
146
|
-
request = self.prepare_llm_annotate(
|
146
|
+
request = self.prepare_llm_annotate(project_id, document_id)
|
147
147
|
response = self._client._prepared_request(request)
|
148
148
|
return RetabParsedChatCompletion(**response)
|
149
149
|
|
@@ -153,7 +153,7 @@ class AsyncDocuments(AsyncAPIResource, DocumentsMixin):
|
|
153
153
|
|
154
154
|
async def create(
|
155
155
|
self,
|
156
|
-
|
156
|
+
project_id: str,
|
157
157
|
document: Union[Path, str, IOBase, MIMEData, PIL.Image.Image, HttpUrl],
|
158
158
|
annotation: Dict[str, Any],
|
159
159
|
annotation_metadata: Dict[str, Any] | None = None,
|
@@ -162,7 +162,7 @@ class AsyncDocuments(AsyncAPIResource, DocumentsMixin):
|
|
162
162
|
Create a document for an evaluation.
|
163
163
|
|
164
164
|
Args:
|
165
|
-
|
165
|
+
project_id: The ID of the evaluation
|
166
166
|
document: The document to process. Can be:
|
167
167
|
- A file path (Path or str)
|
168
168
|
- A file-like object (IOBase)
|
@@ -180,32 +180,32 @@ class AsyncDocuments(AsyncAPIResource, DocumentsMixin):
|
|
180
180
|
mime_document: MIMEData = prepare_mime_document(document)
|
181
181
|
|
182
182
|
# Let prepare_create handle the serialization
|
183
|
-
request = self.prepare_create(
|
183
|
+
request = self.prepare_create(project_id, mime_document, annotation, annotation_metadata)
|
184
184
|
response = await self._client._prepared_request(request)
|
185
185
|
return ProjectDocument(**response)
|
186
186
|
|
187
|
-
async def list(self,
|
187
|
+
async def list(self, project_id: str) -> List[ProjectDocument]:
|
188
188
|
"""
|
189
189
|
List documents for an evaluation.
|
190
190
|
|
191
191
|
Args:
|
192
|
-
|
192
|
+
project_id: The ID of the evaluation
|
193
193
|
|
194
194
|
Returns:
|
195
195
|
List[ProjectDocument]: List of documents
|
196
196
|
Raises:
|
197
197
|
HTTPException if the request fails
|
198
198
|
"""
|
199
|
-
request = self.prepare_list(
|
199
|
+
request = self.prepare_list(project_id)
|
200
200
|
response = await self._client._prepared_request(request)
|
201
201
|
return [ProjectDocument(**item) for item in response.get("data", [])]
|
202
202
|
|
203
|
-
async def update(self,
|
203
|
+
async def update(self, project_id: str, document_id: str, annotation: dict[str, Any]) -> ProjectDocument:
|
204
204
|
"""
|
205
205
|
Update a document.
|
206
206
|
|
207
207
|
Args:
|
208
|
-
|
208
|
+
project_id: The ID of the evaluation
|
209
209
|
document_id: The ID of the document
|
210
210
|
annotation: The ground truth for the document
|
211
211
|
|
@@ -214,16 +214,16 @@ class AsyncDocuments(AsyncAPIResource, DocumentsMixin):
|
|
214
214
|
Raises:
|
215
215
|
HTTPException if the request fails
|
216
216
|
"""
|
217
|
-
request = self.prepare_update(
|
217
|
+
request = self.prepare_update(project_id, document_id, annotation)
|
218
218
|
response = await self._client._prepared_request(request)
|
219
219
|
return ProjectDocument(**response)
|
220
220
|
|
221
|
-
async def delete(self,
|
221
|
+
async def delete(self, project_id: str, document_id: str) -> DeleteResponse:
|
222
222
|
"""
|
223
223
|
Delete a document.
|
224
224
|
|
225
225
|
Args:
|
226
|
-
|
226
|
+
project_id: The ID of the evaluation
|
227
227
|
document_id: The ID of the document
|
228
228
|
|
229
229
|
Returns:
|
@@ -231,14 +231,14 @@ class AsyncDocuments(AsyncAPIResource, DocumentsMixin):
|
|
231
231
|
Raises:
|
232
232
|
HTTPException if the request fails
|
233
233
|
"""
|
234
|
-
request = self.prepare_delete(
|
234
|
+
request = self.prepare_delete(project_id, document_id)
|
235
235
|
return await self._client._prepared_request(request)
|
236
236
|
|
237
|
-
async def llm_annotate(self,
|
237
|
+
async def llm_annotate(self, project_id: str, document_id: str) -> RetabParsedChatCompletion:
|
238
238
|
"""
|
239
239
|
Annotate a document with an LLM.
|
240
240
|
This method updates the document (within the evaluation) with the latest extraction.
|
241
241
|
"""
|
242
|
-
request = self.prepare_llm_annotate(
|
242
|
+
request = self.prepare_llm_annotate(project_id, document_id)
|
243
243
|
response = await self._client._prepared_request(request)
|
244
244
|
return RetabParsedChatCompletion(**response)
|
@@ -13,18 +13,18 @@ from ...types.documents.extractions import RetabParsedChatCompletion
|
|
13
13
|
|
14
14
|
|
15
15
|
class IterationsMixin:
|
16
|
-
def prepare_get(self,
|
17
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
16
|
+
def prepare_get(self, project_id: str, iteration_id: str) -> PreparedRequest:
|
17
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}/iterations/{iteration_id}")
|
18
18
|
|
19
|
-
def prepare_list(self,
|
19
|
+
def prepare_list(self, project_id: str, model: Optional[str] = None) -> PreparedRequest:
|
20
20
|
params = {}
|
21
21
|
if model:
|
22
22
|
params["model"] = model
|
23
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
23
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}/iterations", params=params)
|
24
24
|
|
25
25
|
def prepare_create(
|
26
26
|
self,
|
27
|
-
|
27
|
+
project_id: str,
|
28
28
|
model: str = FieldUnset,
|
29
29
|
json_schema: Optional[Dict[str, Any]] = None,
|
30
30
|
temperature: float = FieldUnset,
|
@@ -54,11 +54,11 @@ class IterationsMixin:
|
|
54
54
|
|
55
55
|
request = CreateIterationRequest(inference_settings=inference_settings, json_schema=json_schema)
|
56
56
|
|
57
|
-
return PreparedRequest(method="POST", url=f"/v1/projects/{
|
57
|
+
return PreparedRequest(method="POST", url=f"/v1/projects/{project_id}/iterations", data=request.model_dump(exclude_unset=True, exclude_defaults=True, mode="json"))
|
58
58
|
|
59
59
|
def prepare_update(
|
60
60
|
self,
|
61
|
-
|
61
|
+
project_id: str,
|
62
62
|
iteration_id: str,
|
63
63
|
json_schema: Dict[str, Any] = FieldUnset,
|
64
64
|
model: str = FieldUnset,
|
@@ -94,18 +94,18 @@ class IterationsMixin:
|
|
94
94
|
iteration_data = PatchIterationRequest(**iteration_dict)
|
95
95
|
|
96
96
|
return PreparedRequest(
|
97
|
-
method="PATCH", url=f"/v1/projects/{
|
97
|
+
method="PATCH", url=f"/v1/projects/{project_id}/iterations/{iteration_id}", data=iteration_data.model_dump(exclude_unset=True, exclude_defaults=True, mode="json")
|
98
98
|
)
|
99
99
|
|
100
|
-
def prepare_delete(self,
|
101
|
-
return PreparedRequest(method="DELETE", url=f"/v1/projects/{
|
100
|
+
def prepare_delete(self, project_id: str, iteration_id: str) -> PreparedRequest:
|
101
|
+
return PreparedRequest(method="DELETE", url=f"/v1/projects/{project_id}/iterations/{iteration_id}")
|
102
102
|
|
103
|
-
def prepare_compute_distances(self,
|
104
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
103
|
+
def prepare_compute_distances(self, project_id: str, iteration_id: str, document_id: str) -> PreparedRequest:
|
104
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}/iterations/{iteration_id}/documents/{document_id}/distances")
|
105
105
|
|
106
106
|
def prepare_process(
|
107
107
|
self,
|
108
|
-
|
108
|
+
project_id: str,
|
109
109
|
iteration_id: str,
|
110
110
|
document_ids: Optional[List[str]] = None,
|
111
111
|
only_outdated: bool = True,
|
@@ -114,13 +114,13 @@ class IterationsMixin:
|
|
114
114
|
document_ids=document_ids,
|
115
115
|
only_outdated=only_outdated,
|
116
116
|
)
|
117
|
-
return PreparedRequest(method="POST", url=f"/v1/projects/{
|
117
|
+
return PreparedRequest(method="POST", url=f"/v1/projects/{project_id}/iterations/{iteration_id}/process", data=request.model_dump(exclude_none=True, mode="json"))
|
118
118
|
|
119
|
-
def prepare_process_document(self,
|
120
|
-
return PreparedRequest(method="POST", url=f"/v1/projects/{
|
119
|
+
def prepare_process_document(self, project_id: str, iteration_id: str, document_id: str) -> PreparedRequest:
|
120
|
+
return PreparedRequest(method="POST", url=f"/v1/projects/{project_id}/iterations/{iteration_id}/documents/{document_id}/process", data={"stream": False})
|
121
121
|
|
122
|
-
def prepare_status(self,
|
123
|
-
return PreparedRequest(method="GET", url=f"/v1/projects/{
|
122
|
+
def prepare_status(self, project_id: str, iteration_id: str) -> PreparedRequest:
|
123
|
+
return PreparedRequest(method="GET", url=f"/v1/projects/{project_id}/iterations/{iteration_id}/status")
|
124
124
|
|
125
125
|
|
126
126
|
class Iterations(SyncAPIResource, IterationsMixin):
|
@@ -129,17 +129,17 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
129
129
|
def __init__(self, *args, **kwargs):
|
130
130
|
super().__init__(*args, **kwargs)
|
131
131
|
|
132
|
-
def get(self,
|
133
|
-
request = self.prepare_get(
|
132
|
+
def get(self, project_id: str, iteration_id: str) -> Iteration:
|
133
|
+
request = self.prepare_get(project_id, iteration_id)
|
134
134
|
response = self._client._prepared_request(request)
|
135
135
|
return Iteration(**response)
|
136
136
|
|
137
|
-
def list(self,
|
137
|
+
def list(self, project_id: str, model: Optional[str] = None) -> List[Iteration]:
|
138
138
|
"""
|
139
139
|
List iterations for an evaluation.
|
140
140
|
|
141
141
|
Args:
|
142
|
-
|
142
|
+
project_id: The ID of the evaluation
|
143
143
|
model: Optional model to filter by
|
144
144
|
|
145
145
|
Returns:
|
@@ -147,13 +147,13 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
147
147
|
Raises:
|
148
148
|
HTTPException if the request fails
|
149
149
|
"""
|
150
|
-
request = self.prepare_list(
|
150
|
+
request = self.prepare_list(project_id, model)
|
151
151
|
response = self._client._prepared_request(request)
|
152
152
|
return [Iteration(**item) for item in response.get("data", [])]
|
153
153
|
|
154
154
|
def create(
|
155
155
|
self,
|
156
|
-
|
156
|
+
project_id: str,
|
157
157
|
model: str = FieldUnset,
|
158
158
|
temperature: float = FieldUnset,
|
159
159
|
modality: Modality = FieldUnset,
|
@@ -167,7 +167,7 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
167
167
|
Create a new iteration for an evaluation.
|
168
168
|
|
169
169
|
Args:
|
170
|
-
|
170
|
+
project_id: The ID of the evaluation
|
171
171
|
json_schema: The JSON schema for the iteration (if not set, we use the one of the eval)
|
172
172
|
model: The model to use for the iteration
|
173
173
|
temperature: The temperature to use for the model
|
@@ -187,7 +187,7 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
187
187
|
HTTPException if the request fails
|
188
188
|
"""
|
189
189
|
request = self.prepare_create(
|
190
|
-
|
190
|
+
project_id=project_id,
|
191
191
|
json_schema=json_schema,
|
192
192
|
model=model,
|
193
193
|
temperature=temperature,
|
@@ -200,7 +200,7 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
200
200
|
response = self._client._prepared_request(request)
|
201
201
|
return Iteration(**response)
|
202
202
|
|
203
|
-
def delete(self,
|
203
|
+
def delete(self, project_id: str, iteration_id: str) -> DeleteResponse:
|
204
204
|
"""
|
205
205
|
Delete an iteration.
|
206
206
|
|
@@ -212,10 +212,10 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
212
212
|
Raises:
|
213
213
|
HTTPException if the request fails
|
214
214
|
"""
|
215
|
-
request = self.prepare_delete(
|
215
|
+
request = self.prepare_delete(project_id, iteration_id)
|
216
216
|
return self._client._prepared_request(request)
|
217
217
|
|
218
|
-
def compute_distances(self,
|
218
|
+
def compute_distances(self, project_id: str, iteration_id: str, document_id: str) -> DistancesResult:
|
219
219
|
"""
|
220
220
|
Get distances for a document in an iteration.
|
221
221
|
|
@@ -228,13 +228,13 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
228
228
|
Raises:
|
229
229
|
HTTPException if the request fails
|
230
230
|
"""
|
231
|
-
request = self.prepare_compute_distances(
|
231
|
+
request = self.prepare_compute_distances(project_id, iteration_id, document_id)
|
232
232
|
response = self._client._prepared_request(request)
|
233
233
|
return DistancesResult(**response)
|
234
234
|
|
235
235
|
def process(
|
236
236
|
self,
|
237
|
-
|
237
|
+
project_id: str,
|
238
238
|
iteration_id: str,
|
239
239
|
document_ids: Optional[List[str]] = None,
|
240
240
|
only_outdated: bool = True,
|
@@ -252,11 +252,11 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
252
252
|
Raises:
|
253
253
|
HTTPException if the request fails
|
254
254
|
"""
|
255
|
-
request = self.prepare_process(
|
255
|
+
request = self.prepare_process(project_id, iteration_id, document_ids, only_outdated)
|
256
256
|
response = self._client._prepared_request(request)
|
257
257
|
return Iteration(**response)
|
258
258
|
|
259
|
-
def process_document(self,
|
259
|
+
def process_document(self, project_id: str, iteration_id: str, document_id: str) -> RetabParsedChatCompletion:
|
260
260
|
"""
|
261
261
|
Process a single document within an iteration.
|
262
262
|
This method updates the iteration document with the latest extraction.
|
@@ -270,11 +270,11 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
270
270
|
Raises:
|
271
271
|
HTTPException if the request fails
|
272
272
|
"""
|
273
|
-
request = self.prepare_process_document(
|
273
|
+
request = self.prepare_process_document(project_id, iteration_id, document_id)
|
274
274
|
response = self._client._prepared_request(request)
|
275
275
|
return RetabParsedChatCompletion(**response)
|
276
276
|
|
277
|
-
def status(self,
|
277
|
+
def status(self, project_id: str, iteration_id: str) -> IterationDocumentStatusResponse:
|
278
278
|
"""
|
279
279
|
Get the status of documents in an iteration.
|
280
280
|
|
@@ -286,7 +286,7 @@ class Iterations(SyncAPIResource, IterationsMixin):
|
|
286
286
|
Raises:
|
287
287
|
HTTPException if the request fails
|
288
288
|
"""
|
289
|
-
request = self.prepare_status(
|
289
|
+
request = self.prepare_status(project_id, iteration_id)
|
290
290
|
response = self._client._prepared_request(request)
|
291
291
|
return IterationDocumentStatusResponse(**response)
|
292
292
|
|
@@ -297,7 +297,7 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
297
297
|
def __init__(self, *args, **kwargs):
|
298
298
|
super().__init__(*args, **kwargs)
|
299
299
|
|
300
|
-
async def get(self,
|
300
|
+
async def get(self, project_id: str, iteration_id: str) -> Iteration:
|
301
301
|
"""
|
302
302
|
Get an iteration by ID.
|
303
303
|
|
@@ -309,16 +309,16 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
309
309
|
Raises:
|
310
310
|
HTTPException if the request fails
|
311
311
|
"""
|
312
|
-
request = self.prepare_get(
|
312
|
+
request = self.prepare_get(project_id, iteration_id)
|
313
313
|
response = await self._client._prepared_request(request)
|
314
314
|
return Iteration(**response)
|
315
315
|
|
316
|
-
async def list(self,
|
316
|
+
async def list(self, project_id: str, model: Optional[str] = None) -> List[Iteration]:
|
317
317
|
"""
|
318
318
|
List iterations for an evaluation.
|
319
319
|
|
320
320
|
Args:
|
321
|
-
|
321
|
+
project_id: The ID of the evaluation
|
322
322
|
model: Optional model to filter by
|
323
323
|
|
324
324
|
Returns:
|
@@ -326,13 +326,13 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
326
326
|
Raises:
|
327
327
|
HTTPException if the request fails
|
328
328
|
"""
|
329
|
-
request = self.prepare_list(
|
329
|
+
request = self.prepare_list(project_id, model)
|
330
330
|
response = await self._client._prepared_request(request)
|
331
331
|
return [Iteration(**item) for item in response.get("data", [])]
|
332
332
|
|
333
333
|
async def create(
|
334
334
|
self,
|
335
|
-
|
335
|
+
project_id: str,
|
336
336
|
model: str,
|
337
337
|
temperature: float = 0.0,
|
338
338
|
modality: Modality = "native",
|
@@ -346,7 +346,7 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
346
346
|
Create a new iteration for an evaluation.
|
347
347
|
|
348
348
|
Args:
|
349
|
-
|
349
|
+
project_id: The ID of the evaluation
|
350
350
|
json_schema: The JSON schema for the iteration
|
351
351
|
model: The model to use for the iteration
|
352
352
|
temperature: The temperature to use for the model
|
@@ -366,7 +366,7 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
366
366
|
HTTPException if the request fails
|
367
367
|
"""
|
368
368
|
request = self.prepare_create(
|
369
|
-
|
369
|
+
project_id=project_id,
|
370
370
|
json_schema=json_schema,
|
371
371
|
model=model,
|
372
372
|
temperature=temperature,
|
@@ -379,7 +379,7 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
379
379
|
response = await self._client._prepared_request(request)
|
380
380
|
return Iteration(**response)
|
381
381
|
|
382
|
-
async def delete(self,
|
382
|
+
async def delete(self, project_id: str, iteration_id: str) -> DeleteResponse:
|
383
383
|
"""
|
384
384
|
Delete an iteration.
|
385
385
|
|
@@ -391,10 +391,10 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
391
391
|
Raises:
|
392
392
|
HTTPException if the request fails
|
393
393
|
"""
|
394
|
-
request = self.prepare_delete(
|
394
|
+
request = self.prepare_delete(project_id, iteration_id)
|
395
395
|
return await self._client._prepared_request(request)
|
396
396
|
|
397
|
-
async def compute_distances(self,
|
397
|
+
async def compute_distances(self, project_id: str, iteration_id: str, document_id: str) -> DistancesResult:
|
398
398
|
"""
|
399
399
|
Get distances for a document in an iteration.
|
400
400
|
|
@@ -407,13 +407,13 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
407
407
|
Raises:
|
408
408
|
HTTPException if the request fails
|
409
409
|
"""
|
410
|
-
request = self.prepare_compute_distances(
|
410
|
+
request = self.prepare_compute_distances(project_id, iteration_id, document_id)
|
411
411
|
response = await self._client._prepared_request(request)
|
412
412
|
return DistancesResult(**response)
|
413
413
|
|
414
414
|
async def process(
|
415
415
|
self,
|
416
|
-
|
416
|
+
project_id: str,
|
417
417
|
iteration_id: str,
|
418
418
|
document_ids: Optional[List[str]] = None,
|
419
419
|
only_outdated: bool = True,
|
@@ -431,11 +431,11 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
431
431
|
Raises:
|
432
432
|
HTTPException if the request fails
|
433
433
|
"""
|
434
|
-
request = self.prepare_process(
|
434
|
+
request = self.prepare_process(project_id, iteration_id, document_ids, only_outdated)
|
435
435
|
response = await self._client._prepared_request(request)
|
436
436
|
return Iteration(**response)
|
437
437
|
|
438
|
-
async def process_document(self,
|
438
|
+
async def process_document(self, project_id: str, iteration_id: str, document_id: str) -> RetabParsedChatCompletion:
|
439
439
|
"""
|
440
440
|
Process a single document within an iteration.
|
441
441
|
This method updates the iteration document with the latest extraction.
|
@@ -449,11 +449,11 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
449
449
|
Raises:
|
450
450
|
HTTPException if the request fails
|
451
451
|
"""
|
452
|
-
request = self.prepare_process_document(
|
452
|
+
request = self.prepare_process_document(project_id, iteration_id, document_id)
|
453
453
|
response = await self._client._prepared_request(request)
|
454
454
|
return RetabParsedChatCompletion(**response)
|
455
455
|
|
456
|
-
async def status(self,
|
456
|
+
async def status(self, project_id: str, iteration_id: str) -> IterationDocumentStatusResponse:
|
457
457
|
"""
|
458
458
|
Get the status of documents in an iteration.
|
459
459
|
|
@@ -465,6 +465,6 @@ class AsyncIterations(AsyncAPIResource, IterationsMixin):
|
|
465
465
|
Raises:
|
466
466
|
HTTPException if the request fails
|
467
467
|
"""
|
468
|
-
request = self.prepare_status(
|
468
|
+
request = self.prepare_status(project_id, iteration_id)
|
469
469
|
response = await self._client._prepared_request(request)
|
470
470
|
return IterationDocumentStatusResponse(**response)
|
retab/types/ai_models.py
CHANGED
@@ -74,7 +74,7 @@ class FinetunedModel(BaseModel):
|
|
74
74
|
schema_id: str
|
75
75
|
schema_data_id: str
|
76
76
|
finetuning_props: InferenceSettings
|
77
|
-
|
77
|
+
project_id: str | None = None
|
78
78
|
created_at: datetime.datetime = Field(default_factory=lambda: datetime.datetime.now(datetime.timezone.utc))
|
79
79
|
|
80
80
|
|
@@ -19,6 +19,7 @@ class DocumentItem(AnnotatedDocument):
|
|
19
19
|
|
20
20
|
class ProjectDocument(DocumentItem):
|
21
21
|
id: str = Field(description="The ID of the document. Equal to mime_data.id but robust to the case where mime_data is a BaseMIMEData")
|
22
|
+
ocr_file_id: Optional[str] = Field(default=None, description="The ID of the OCR file")
|
22
23
|
|
23
24
|
|
24
25
|
class CreateProjectDocumentRequest(DocumentItem):
|
@@ -28,3 +29,4 @@ class CreateProjectDocumentRequest(DocumentItem):
|
|
28
29
|
class PatchProjectDocumentRequest(BaseModel):
|
29
30
|
annotation: Optional[dict[str, Any]] = Field(default=None, description="The ground truth of the document")
|
30
31
|
annotation_metadata: Optional[PredictionMetadata] = Field(default=None, description="The metadata of the annotation when the annotation is a prediction")
|
32
|
+
ocr_file_id: Optional[str] = Field(default=None, description="The ID of the OCR file")
|
retab/utils/benchmarking.py
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
retab/__init__.py,sha256=IfXoXvlvx4t1q5Ge6_pCOQnGOymVPxT7Dm1vQJ0OqoA,153
|
2
2
|
retab/_resource.py,sha256=JfAU4UTa05ugWfbrpO7fsVr_pFewht99NkoIfK6kBQM,577
|
3
3
|
retab/client.py,sha256=iONTgYnm2qc17BfrKht8kbLAooKD7_ie3Wmfny5xE9I,27915
|
4
|
-
retab/generate_types.py,sha256=
|
4
|
+
retab/generate_types.py,sha256=JNVTPKLig0lzy7ik6jBlvWkA9txWNUUBhxRJRHmd3OQ,7798
|
5
5
|
retab/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
6
6
|
retab/resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
7
7
|
retab/resources/evals.py,sha256=vOMyCJ0dVy6YZUv4NtkujZBZCByvr0PmSpV6UGnorHw,29927
|
@@ -20,7 +20,7 @@ retab/resources/consensus/completions_stream.py,sha256=DlU9od01F1Fmh9WjTLhq4Ksnt
|
|
20
20
|
retab/resources/consensus/responses.py,sha256=hf1_gXBG8iwrBGyuXx16qCh6ULDXn9a0Uty1C-WiG7s,9966
|
21
21
|
retab/resources/consensus/responses_stream.py,sha256=OopJ9aoO7HctfhLnXzJx8-dkk-4jK_juOw6jUAkzwVM,11671
|
22
22
|
retab/resources/deployments/__init__.py,sha256=sGTfJ8ozhkTtEzHC_LziiffYFElm6XjtYIZ0jEDFLg4,97
|
23
|
-
retab/resources/deployments/client.py,sha256=
|
23
|
+
retab/resources/deployments/client.py,sha256=y2zc1gRnzvLVoR_ZDOBPy_Fdq1iOYafA12ThAaqfDrA,6169
|
24
24
|
retab/resources/deployments/automations/__init__.py,sha256=Iej-_yIxc8xAuhYmR0e2VI7j_EXVsNk1_L98OJSD82E,121
|
25
25
|
retab/resources/deployments/automations/client.py,sha256=3w54F0JfC2GYDosLux8LVEjDd_RXqQ29-SyNXGa28U8,10500
|
26
26
|
retab/resources/deployments/automations/endpoints.py,sha256=zJ556BNighciPff1laA_bBPZNxT4mWmGi-kDMXa5_tw,10893
|
@@ -47,15 +47,15 @@ retab/resources/processors/automations/mailboxes.py,sha256=OwThPbkjixPnmIIsOmKRq
|
|
47
47
|
retab/resources/processors/automations/outlook.py,sha256=UrzyVRMfzkSwbMo4EsAxYkqOs3J8IBN2yrXrv40lo3w,14616
|
48
48
|
retab/resources/processors/automations/tests.py,sha256=nbO6qIkQnpr629ZkCchbfCJOm7KyjDOaLsxXxB3i0cg,6219
|
49
49
|
retab/resources/projects/__init__.py,sha256=tPR3_3tr7bsoYd618qmGjnYN2R23PmF5oCFd7Z5_HGY,85
|
50
|
-
retab/resources/projects/client.py,sha256=
|
51
|
-
retab/resources/projects/documents.py,sha256=
|
52
|
-
retab/resources/projects/iterations.py,sha256=
|
50
|
+
retab/resources/projects/client.py,sha256=1yyYfJhY4ztkgljm6mxGjg4Xx7dD90x-YCphcrjskeI,9646
|
51
|
+
retab/resources/projects/documents.py,sha256=1lHgK3g_die4_IVX4HJBfo7tZ2oI8b9aa3Gt-Ly0IRE,9657
|
52
|
+
retab/resources/projects/iterations.py,sha256=dSv-YN5FT0d4skQwbl0cn6jCRn1keM3mon__lsel02o,18528
|
53
53
|
retab/resources/secrets/__init__.py,sha256=SwofMyk96k0YSyj1d_GRxhpVx4wb4TA97TISsTjB0Kc,105
|
54
54
|
retab/resources/secrets/client.py,sha256=nXt1cgvkWqhA99WTnC1PWbWJq-EbwvoDuCQOa0GJOOU,599
|
55
55
|
retab/resources/secrets/external_api_keys.py,sha256=3TuJxjk65EPUT2XC3wBcYWaVwqzc6QGv9BoHufzxTLU,3759
|
56
56
|
retab/resources/secrets/webhook.py,sha256=2mFDNblQYBGOwgqOG5gfRJkusQX7Hjy28XZ7O7ffkl8,1805
|
57
57
|
retab/types/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
58
|
-
retab/types/ai_models.py,sha256=
|
58
|
+
retab/types/ai_models.py,sha256=mLUp_ZjVIgW2pbeMlPiWGaDsaJiB9YHaPD0z5hoo10Q,4979
|
59
59
|
retab/types/browser_canvas.py,sha256=U3yLqJcSwfturcIsNFSblRtFtnG3p-UL1YYoM9KZfdE,70
|
60
60
|
retab/types/chat.py,sha256=l32vhLtNcdmHFjG4iVC617j38x6a2oH7CNPwlvqdF8g,424
|
61
61
|
retab/types/completions.py,sha256=ZQU29bm-FhdOzky4_Dp2N--fedR82C3QfCRZCJCQ-P8,5381
|
@@ -99,7 +99,7 @@ retab/types/jobs/finetune.py,sha256=6O9NUy-ap_aqZ73tYx-NRRdFgKOIvk8WcItGhEUvrSQ,
|
|
99
99
|
retab/types/jobs/prompt_optimization.py,sha256=P7JI0zKFExCN4ws8kpFrCHBFbrJ4m4-zGJnNVXWa-ic,1306
|
100
100
|
retab/types/jobs/webcrawl.py,sha256=C3_7mW2mmOXs6ypktDIHdjMnify90pFo70wmhrs_TP8,183
|
101
101
|
retab/types/projects/__init__.py,sha256=63kk9c9PZX9cknPSYeK2gG5_ys98PqjEnj5OyYtsujY,964
|
102
|
-
retab/types/projects/documents.py,sha256=
|
102
|
+
retab/types/projects/documents.py,sha256=peASfHxDmvNE373lfrxrdS6F5_TW2rrm2QXEf6pjmd8,1441
|
103
103
|
retab/types/projects/iterations.py,sha256=YfiqaTvCxmPIJORHzCgtafshUBRZN9LAo1y2cOPSBco,3306
|
104
104
|
retab/types/projects/model.py,sha256=xfDb1rcMWx-xSAwfCg2z2l0xKSsKOvBB_skBDsNxWc8,2820
|
105
105
|
retab/types/schemas/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -113,7 +113,7 @@ retab/types/secrets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSu
|
|
113
113
|
retab/types/secrets/external_api_keys.py,sha256=-yaaOfNLxKpll3oD-0htQlW8S03lyWs9Mmk9HOdyQ3g,437
|
114
114
|
retab/utils/__init__.py,sha256=cta2g2pCC9nDHbM4-s5PwLNqwF31T8oP5wy5UvGrJc8,151
|
115
115
|
retab/utils/ai_models.py,sha256=wooYSZAxLiL2i9lSku2266tyown0rhPnjOzoyBgkUH4,8421
|
116
|
-
retab/utils/benchmarking.py,sha256=
|
116
|
+
retab/utils/benchmarking.py,sha256=jM9rebliYH_ByPUOkQLR8LeRDcxc0SsVYajqwMmyWl4,17846
|
117
117
|
retab/utils/chat.py,sha256=ZHt6oEX2lZl8O0tIj-rHnqgmDbHxMYEWPkx0fArvojo,14352
|
118
118
|
retab/utils/display.py,sha256=ZFPbiBnwEWGR-suS8e9Xilz9OqyYRDwsKYWfbFSJPJM,18868
|
119
119
|
retab/utils/hashing.py,sha256=_BMVUvftOcJav68QL0rLkH2dbhW9RRJPzeGC2akR0fc,757
|
@@ -128,7 +128,7 @@ retab/utils/_model_cards/openai.yaml,sha256=PcmjqAioomqWOw25H4BluVfJ1WO_zapg_nPx
|
|
128
128
|
retab/utils/_model_cards/xai.yaml,sha256=OdVV33_WODc4UBZhDezcUq_5mHQK5zeOT49EjJUJ764,612
|
129
129
|
retab/utils/usage/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
130
130
|
retab/utils/usage/usage.py,sha256=Dxi4EyTBMsu4mgUg7hwh4gTQlE70Xn3gxMZb0EEbti4,12791
|
131
|
-
retab-0.0.
|
132
|
-
retab-0.0.
|
133
|
-
retab-0.0.
|
134
|
-
retab-0.0.
|
131
|
+
retab-0.0.46.dist-info/METADATA,sha256=wisxUVLeri-e0M0icR5E3c_12hUSqo_NKfyQD1Vz-ak,4481
|
132
|
+
retab-0.0.46.dist-info/WHEEL,sha256=HiCZjzuy6Dw0hdX5R3LCFPDmFS4BWl8H-8W39XfmgX4,91
|
133
|
+
retab-0.0.46.dist-info/top_level.txt,sha256=waQR0EGdhLIQtztoE3AXg7ik5ONQ9q_bsKVpyFuJdq0,6
|
134
|
+
retab-0.0.46.dist-info/RECORD,,
|
File without changes
|
File without changes
|