retab 0.0.82__tar.gz → 0.0.84__tar.gz

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.
Files changed (68) hide show
  1. {retab-0.0.82 → retab-0.0.84}/PKG-INFO +1 -1
  2. {retab-0.0.82 → retab-0.0.84}/retab/resources/documents/client.py +8 -8
  3. {retab-0.0.82 → retab-0.0.84}/retab/resources/edit/client.py +8 -8
  4. {retab-0.0.82 → retab-0.0.84}/retab/resources/edit/templates/client.py +8 -8
  5. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/edit.py +1 -2
  6. {retab-0.0.82 → retab-0.0.84}/retab/types/edit/templates.py +1 -1
  7. {retab-0.0.82 → retab-0.0.84}/retab.egg-info/PKG-INFO +1 -1
  8. {retab-0.0.82 → retab-0.0.84}/setup.py +1 -1
  9. {retab-0.0.82 → retab-0.0.84}/README.md +0 -0
  10. {retab-0.0.82 → retab-0.0.84}/pyproject.toml +0 -0
  11. {retab-0.0.82 → retab-0.0.84}/retab/__init__.py +0 -0
  12. {retab-0.0.82 → retab-0.0.84}/retab/_resource.py +0 -0
  13. {retab-0.0.82 → retab-0.0.84}/retab/client.py +0 -0
  14. {retab-0.0.82 → retab-0.0.84}/retab/generate_types.py +0 -0
  15. {retab-0.0.82 → retab-0.0.84}/retab/py.typed +0 -0
  16. {retab-0.0.82 → retab-0.0.84}/retab/resources/__init__.py +0 -0
  17. {retab-0.0.82 → retab-0.0.84}/retab/resources/documents/__init__.py +0 -0
  18. {retab-0.0.82 → retab-0.0.84}/retab/resources/edit/__init__.py +0 -0
  19. {retab-0.0.82 → retab-0.0.84}/retab/resources/edit/templates/__init__.py +0 -0
  20. {retab-0.0.82 → retab-0.0.84}/retab/resources/extractions/__init__.py +0 -0
  21. {retab-0.0.82 → retab-0.0.84}/retab/resources/extractions/client.py +0 -0
  22. {retab-0.0.82 → retab-0.0.84}/retab/resources/models.py +0 -0
  23. {retab-0.0.82 → retab-0.0.84}/retab/resources/projects/__init__.py +0 -0
  24. {retab-0.0.82 → retab-0.0.84}/retab/resources/projects/client.py +0 -0
  25. {retab-0.0.82 → retab-0.0.84}/retab/resources/schemas.py +0 -0
  26. {retab-0.0.82 → retab-0.0.84}/retab/resources/workflows/__init__.py +0 -0
  27. {retab-0.0.82 → retab-0.0.84}/retab/resources/workflows/client.py +0 -0
  28. {retab-0.0.82 → retab-0.0.84}/retab/types/__init__.py +0 -0
  29. {retab-0.0.82 → retab-0.0.84}/retab/types/chat.py +0 -0
  30. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/__init__.py +0 -0
  31. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/classify.py +0 -0
  32. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/correct_orientation.py +0 -0
  33. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/create_messages.py +0 -0
  34. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/extract.py +0 -0
  35. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/parse.py +0 -0
  36. {retab-0.0.82 → retab-0.0.84}/retab/types/documents/split.py +0 -0
  37. {retab-0.0.82 → retab-0.0.84}/retab/types/edit/__init__.py +0 -0
  38. {retab-0.0.82 → retab-0.0.84}/retab/types/extractions/__init__.py +0 -0
  39. {retab-0.0.82 → retab-0.0.84}/retab/types/extractions/types.py +0 -0
  40. {retab-0.0.82 → retab-0.0.84}/retab/types/inference_settings.py +0 -0
  41. {retab-0.0.82 → retab-0.0.84}/retab/types/mime.py +0 -0
  42. {retab-0.0.82 → retab-0.0.84}/retab/types/modality.py +0 -0
  43. {retab-0.0.82 → retab-0.0.84}/retab/types/pagination.py +0 -0
  44. {retab-0.0.82 → retab-0.0.84}/retab/types/projects/__init__.py +0 -0
  45. {retab-0.0.82 → retab-0.0.84}/retab/types/projects/metrics.py +0 -0
  46. {retab-0.0.82 → retab-0.0.84}/retab/types/projects/model.py +0 -0
  47. {retab-0.0.82 → retab-0.0.84}/retab/types/projects/predictions.py +0 -0
  48. {retab-0.0.82 → retab-0.0.84}/retab/types/schemas/__init__.py +0 -0
  49. {retab-0.0.82 → retab-0.0.84}/retab/types/schemas/chat.py +0 -0
  50. {retab-0.0.82 → retab-0.0.84}/retab/types/schemas/generate.py +0 -0
  51. {retab-0.0.82 → retab-0.0.84}/retab/types/schemas/layout.py +0 -0
  52. {retab-0.0.82 → retab-0.0.84}/retab/types/schemas/model.py +0 -0
  53. {retab-0.0.82 → retab-0.0.84}/retab/types/schemas/templates.py +0 -0
  54. {retab-0.0.82 → retab-0.0.84}/retab/types/standards.py +0 -0
  55. {retab-0.0.82 → retab-0.0.84}/retab/types/workflows/__init__.py +0 -0
  56. {retab-0.0.82 → retab-0.0.84}/retab/types/workflows/model.py +0 -0
  57. {retab-0.0.82 → retab-0.0.84}/retab/utils/__init__.py +0 -0
  58. {retab-0.0.82 → retab-0.0.84}/retab/utils/display.py +0 -0
  59. {retab-0.0.82 → retab-0.0.84}/retab/utils/hashing.py +0 -0
  60. {retab-0.0.82 → retab-0.0.84}/retab/utils/json_schema.py +0 -0
  61. {retab-0.0.82 → retab-0.0.84}/retab/utils/mime.py +0 -0
  62. {retab-0.0.82 → retab-0.0.84}/retab/utils/stream_context_managers.py +0 -0
  63. {retab-0.0.82 → retab-0.0.84}/retab.egg-info/SOURCES.txt +0 -0
  64. {retab-0.0.82 → retab-0.0.84}/retab.egg-info/dependency_links.txt +0 -0
  65. {retab-0.0.82 → retab-0.0.84}/retab.egg-info/requires.txt +0 -0
  66. {retab-0.0.82 → retab-0.0.84}/retab.egg-info/top_level.txt +0 -0
  67. {retab-0.0.82 → retab-0.0.84}/setup.cfg +0 -0
  68. {retab-0.0.82 → retab-0.0.84}/tests/test_projects.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: retab
3
- Version: 0.0.82
3
+ Version: 0.0.84
4
4
  Summary: Retab official python library
5
5
  Home-page: https://github.com/retab-dev/retab
6
6
  Author: Retab
@@ -119,14 +119,14 @@ class BaseDocumentsMixin:
119
119
 
120
120
  def _prepare_edit(
121
121
  self,
122
- filling_instructions: str,
122
+ instructions: str,
123
123
  document: Path | str | IOBase | MIMEData | PIL.Image.Image | HttpUrl | None = None,
124
124
  model: str = FieldUnset,
125
125
  template_id: str | None = FieldUnset,
126
126
  **extra_body: Any,
127
127
  ) -> PreparedRequest:
128
128
  request_dict: dict[str, Any] = {
129
- "filling_instructions": filling_instructions,
129
+ "instructions": instructions,
130
130
  }
131
131
 
132
132
  if document is not None:
@@ -598,7 +598,7 @@ class Documents(SyncAPIResource, BaseDocumentsMixin):
598
598
 
599
599
  def edit(
600
600
  self,
601
- filling_instructions: str,
601
+ instructions: str,
602
602
  document: Path | str | IOBase | MIMEData | PIL.Image.Image | HttpUrl | None = None,
603
603
  model: str = FieldUnset,
604
604
  template_id: str | None = FieldUnset,
@@ -616,7 +616,7 @@ class Documents(SyncAPIResource, BaseDocumentsMixin):
616
616
  Either `document` OR `template_id` must be provided, but not both.
617
617
 
618
618
  Args:
619
- filling_instructions: Instructions describing how to fill the form fields.
619
+ instructions: Instructions describing how to fill the form fields.
620
620
  document: The document to edit. Can be a file path (Path or str), file-like object, MIMEData, PIL Image, or URL.
621
621
  Mutually exclusive with template_id.
622
622
  model: The LLM model to use for inference. Defaults to "retab-small".
@@ -632,7 +632,7 @@ class Documents(SyncAPIResource, BaseDocumentsMixin):
632
632
  HTTPException: If the request fails.
633
633
  """
634
634
  request = self._prepare_edit(
635
- filling_instructions=filling_instructions,
635
+ instructions=instructions,
636
636
  document=document,
637
637
  model=model,
638
638
  template_id=template_id,
@@ -993,7 +993,7 @@ class AsyncDocuments(AsyncAPIResource, BaseDocumentsMixin):
993
993
 
994
994
  async def edit(
995
995
  self,
996
- filling_instructions: str,
996
+ instructions: str,
997
997
  document: Path | str | IOBase | MIMEData | PIL.Image.Image | HttpUrl | None = None,
998
998
  model: str = FieldUnset,
999
999
  template_id: str | None = FieldUnset,
@@ -1011,7 +1011,7 @@ class AsyncDocuments(AsyncAPIResource, BaseDocumentsMixin):
1011
1011
  Either `document` OR `template_id` must be provided, but not both.
1012
1012
 
1013
1013
  Args:
1014
- filling_instructions: Instructions describing how to fill the form fields.
1014
+ instructions: Instructions describing how to fill the form fields.
1015
1015
  document: The document to edit. Can be a file path (Path or str), file-like object, MIMEData, PIL Image, or URL.
1016
1016
  Mutually exclusive with template_id.
1017
1017
  model: The LLM model to use for inference. Defaults to "gemini-2.5-pro".
@@ -1027,7 +1027,7 @@ class AsyncDocuments(AsyncAPIResource, BaseDocumentsMixin):
1027
1027
  HTTPException: If the request fails.
1028
1028
  """
1029
1029
  request = self._prepare_edit(
1030
- filling_instructions=filling_instructions,
1030
+ instructions=instructions,
1031
1031
  document=document,
1032
1032
  model=model,
1033
1033
  template_id=template_id,
@@ -25,14 +25,14 @@ class BaseEditMixin:
25
25
 
26
26
  def _prepare_fill_document(
27
27
  self,
28
- filling_instructions: str,
28
+ instructions: str,
29
29
  document: Path | str | IOBase | MIMEData | PIL.Image.Image | HttpUrl | None = None,
30
30
  model: str = FieldUnset,
31
31
  template_id: str | None = FieldUnset,
32
32
  **extra_body: Any,
33
33
  ) -> PreparedRequest:
34
34
  request_dict: dict[str, Any] = {
35
- "filling_instructions": filling_instructions,
35
+ "instructions": instructions,
36
36
  }
37
37
 
38
38
  if document is not None:
@@ -65,7 +65,7 @@ class Edit(SyncAPIResource, BaseEditMixin):
65
65
 
66
66
  def fill_document(
67
67
  self,
68
- filling_instructions: str,
68
+ instructions: str,
69
69
  document: Path | str | IOBase | MIMEData | PIL.Image.Image | HttpUrl | None = None,
70
70
  model: str = FieldUnset,
71
71
  template_id: str | None = FieldUnset,
@@ -83,7 +83,7 @@ class Edit(SyncAPIResource, BaseEditMixin):
83
83
  Either `document` OR `template_id` must be provided, but not both.
84
84
 
85
85
  Args:
86
- filling_instructions: Instructions describing how to fill the form fields.
86
+ instructions: Instructions describing how to fill the form fields.
87
87
  document: The document to edit. Can be a file path (Path or str), file-like object,
88
88
  MIMEData, PIL Image, or URL. Mutually exclusive with template_id.
89
89
  model: The LLM model to use for inference. Defaults to "retab-small".
@@ -106,7 +106,7 @@ class Edit(SyncAPIResource, BaseEditMixin):
106
106
  - XLSX/XLS: Native editing for spreadsheets
107
107
  """
108
108
  request = self._prepare_fill_document(
109
- filling_instructions=filling_instructions,
109
+ instructions=instructions,
110
110
  document=document,
111
111
  model=model,
112
112
  template_id=template_id,
@@ -125,7 +125,7 @@ class AsyncEdit(AsyncAPIResource, BaseEditMixin):
125
125
 
126
126
  async def fill_document(
127
127
  self,
128
- filling_instructions: str,
128
+ instructions: str,
129
129
  document: Path | str | IOBase | MIMEData | PIL.Image.Image | HttpUrl | None = None,
130
130
  model: str = FieldUnset,
131
131
  template_id: str | None = FieldUnset,
@@ -143,7 +143,7 @@ class AsyncEdit(AsyncAPIResource, BaseEditMixin):
143
143
  Either `document` OR `template_id` must be provided, but not both.
144
144
 
145
145
  Args:
146
- filling_instructions: Instructions describing how to fill the form fields.
146
+ instructions: Instructions describing how to fill the form fields.
147
147
  document: The document to edit. Can be a file path (Path or str), file-like object,
148
148
  MIMEData, PIL Image, or URL. Mutually exclusive with template_id.
149
149
  model: The LLM model to use for inference. Defaults to "retab-small".
@@ -166,7 +166,7 @@ class AsyncEdit(AsyncAPIResource, BaseEditMixin):
166
166
  - XLSX/XLS: Native editing for spreadsheets
167
167
  """
168
168
  request = self._prepare_fill_document(
169
- filling_instructions=filling_instructions,
169
+ instructions=instructions,
170
170
  document=document,
171
171
  model=model,
172
172
  template_id=template_id,
@@ -161,13 +161,13 @@ class BaseTemplatesMixin:
161
161
  def _prepare_fill(
162
162
  self,
163
163
  template_id: str,
164
- filling_instructions: str,
164
+ instructions: str,
165
165
  model: str = FieldUnset,
166
166
  **extra_body: Any,
167
167
  ) -> PreparedRequest:
168
168
  request_dict: dict[str, Any] = {
169
169
  "template_id": template_id,
170
- "filling_instructions": filling_instructions,
170
+ "instructions": instructions,
171
171
  }
172
172
 
173
173
  if model is not FieldUnset:
@@ -366,7 +366,7 @@ class Templates(SyncAPIResource, BaseTemplatesMixin):
366
366
  def fill(
367
367
  self,
368
368
  template_id: str,
369
- filling_instructions: str,
369
+ instructions: str,
370
370
  model: str = FieldUnset,
371
371
  **extra_body: Any,
372
372
  ) -> EditResponse:
@@ -378,7 +378,7 @@ class Templates(SyncAPIResource, BaseTemplatesMixin):
378
378
 
379
379
  Args:
380
380
  template_id: The template ID to use for filling
381
- filling_instructions: Instructions describing how to fill the form fields
381
+ instructions: Instructions describing how to fill the form fields
382
382
  model: The LLM model to use for inference (default: "retab-small")
383
383
 
384
384
  Returns:
@@ -393,7 +393,7 @@ class Templates(SyncAPIResource, BaseTemplatesMixin):
393
393
  """
394
394
  request = self._prepare_fill(
395
395
  template_id=template_id,
396
- filling_instructions=filling_instructions,
396
+ instructions=instructions,
397
397
  model=model,
398
398
  **extra_body,
399
399
  )
@@ -584,7 +584,7 @@ class AsyncTemplates(AsyncAPIResource, BaseTemplatesMixin):
584
584
  async def fill(
585
585
  self,
586
586
  template_id: str,
587
- filling_instructions: str,
587
+ instructions: str,
588
588
  model: str = FieldUnset,
589
589
  **extra_body: Any,
590
590
  ) -> EditResponse:
@@ -596,7 +596,7 @@ class AsyncTemplates(AsyncAPIResource, BaseTemplatesMixin):
596
596
 
597
597
  Args:
598
598
  template_id: The template ID to use for filling
599
- filling_instructions: Instructions describing how to fill the form fields
599
+ instructions: Instructions describing how to fill the form fields
600
600
  model: The LLM model to use for inference (default: "retab-small")
601
601
 
602
602
  Returns:
@@ -611,7 +611,7 @@ class AsyncTemplates(AsyncAPIResource, BaseTemplatesMixin):
611
611
  """
612
612
  request = self._prepare_fill(
613
613
  template_id=template_id,
614
- filling_instructions=filling_instructions,
614
+ instructions=instructions,
615
615
  model=model,
616
616
  **extra_body,
617
617
  )
@@ -109,7 +109,6 @@ class InferFormSchemaRequest(BaseModel):
109
109
 
110
110
  document: MIMEData = Field(..., description="Input document (PDF or DOCX). DOCX files will be converted to PDF.")
111
111
  model: str = Field(default="retab-small", description="LLM model to use for inference")
112
- instructions: Optional[str] = Field(default=None, description="Optional instructions to guide form field detection (e.g., which fields to focus on, specific areas to look for)")
113
112
 
114
113
 
115
114
  class EditRequest(BaseModel):
@@ -121,7 +120,7 @@ class EditRequest(BaseModel):
121
120
  """
122
121
  document: Optional[MIMEData] = Field(default=None, description="Input document (PDF or DOCX). DOCX files will be converted to PDF. Mutually exclusive with template_id.")
123
122
  model: str = Field(default="retab-small", description="LLM model to use for inference")
124
- filling_instructions: str = Field(..., description="Instructions to fill the form")
123
+ instructions: str = Field(..., description="Instructions to fill the form")
125
124
  template_id: Optional[str] = Field(default=None, description="Template ID to use for filling. When provided, uses the template's pre-defined form fields and empty PDF. Only works for PDF documents. Mutually exclusive with document.")
126
125
 
127
126
  class EditResponse(BaseModel):
@@ -46,5 +46,5 @@ class FillTemplateRequest(BaseModel):
46
46
  Uses pre-defined form fields from the template (PDF only)
47
47
  """
48
48
  model: str = Field(default="retab-small", description="LLM model to use for inference")
49
- filling_instructions: str = Field(..., description="Instructions to fill the form")
49
+ instructions: str = Field(..., description="Instructions to fill the form")
50
50
  template_id: str = Field(..., description="Template ID to use for filling. When provided, uses the template's pre-defined form fields and empty PDF. Only works for PDF documents. Mutually exclusive with document.")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: retab
3
- Version: 0.0.82
3
+ Version: 0.0.84
4
4
  Summary: Retab official python library
5
5
  Home-page: https://github.com/retab-dev/retab
6
6
  Author: Retab
@@ -6,7 +6,7 @@ with open("requirements.txt") as f:
6
6
 
7
7
  setup(
8
8
  name="retab",
9
- version="0.0.82",
9
+ version="0.0.84",
10
10
  author="Retab",
11
11
  author_email="contact@retab.com",
12
12
  description="Retab official python library",
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes