chunkr-ai 0.1.0a1__py3-none-any.whl → 0.1.0a3__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.
Files changed (46) hide show
  1. chunkr_ai/_client.py +18 -9
  2. chunkr_ai/_files.py +1 -1
  3. chunkr_ai/_version.py +1 -1
  4. chunkr_ai/pagination.py +61 -1
  5. chunkr_ai/resources/__init__.py +27 -13
  6. chunkr_ai/resources/files.py +712 -0
  7. chunkr_ai/resources/tasks/__init__.py +33 -0
  8. chunkr_ai/resources/tasks/parse.py +612 -0
  9. chunkr_ai/resources/tasks/tasks.py +596 -0
  10. chunkr_ai/types/__init__.py +7 -19
  11. chunkr_ai/types/delete.py +10 -0
  12. chunkr_ai/types/file.py +30 -0
  13. chunkr_ai/types/file_create_params.py +17 -0
  14. chunkr_ai/types/file_list_params.py +28 -0
  15. chunkr_ai/types/file_url.py +15 -0
  16. chunkr_ai/types/file_url_params.py +15 -0
  17. chunkr_ai/types/files_page_response.py +20 -0
  18. chunkr_ai/types/task.py +866 -27
  19. chunkr_ai/types/tasks/__init__.py +6 -0
  20. chunkr_ai/types/tasks/parse_create_params.py +844 -0
  21. chunkr_ai/types/tasks/parse_update_params.py +838 -0
  22. {chunkr_ai-0.1.0a1.dist-info → chunkr_ai-0.1.0a3.dist-info}/METADATA +39 -21
  23. chunkr_ai-0.1.0a3.dist-info/RECORD +52 -0
  24. chunkr_ai/resources/task.py +0 -1166
  25. chunkr_ai/types/auto_generation_config.py +0 -39
  26. chunkr_ai/types/auto_generation_config_param.py +0 -39
  27. chunkr_ai/types/bounding_box.py +0 -19
  28. chunkr_ai/types/chunk_processing.py +0 -40
  29. chunkr_ai/types/chunk_processing_param.py +0 -42
  30. chunkr_ai/types/ignore_generation_config.py +0 -39
  31. chunkr_ai/types/ignore_generation_config_param.py +0 -39
  32. chunkr_ai/types/llm_generation_config.py +0 -39
  33. chunkr_ai/types/llm_generation_config_param.py +0 -39
  34. chunkr_ai/types/llm_processing.py +0 -36
  35. chunkr_ai/types/llm_processing_param.py +0 -36
  36. chunkr_ai/types/picture_generation_config.py +0 -39
  37. chunkr_ai/types/picture_generation_config_param.py +0 -39
  38. chunkr_ai/types/segment_processing.py +0 -280
  39. chunkr_ai/types/segment_processing_param.py +0 -281
  40. chunkr_ai/types/table_generation_config.py +0 -39
  41. chunkr_ai/types/table_generation_config_param.py +0 -39
  42. chunkr_ai/types/task_parse_params.py +0 -90
  43. chunkr_ai/types/task_update_params.py +0 -90
  44. chunkr_ai-0.1.0a1.dist-info/RECORD +0 -58
  45. {chunkr_ai-0.1.0a1.dist-info → chunkr_ai-0.1.0a3.dist-info}/WHEEL +0 -0
  46. {chunkr_ai-0.1.0a1.dist-info → chunkr_ai-0.1.0a3.dist-info}/licenses/LICENSE +0 -0
@@ -1,280 +0,0 @@
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
- from .llm_generation_config import LlmGenerationConfig
9
- from .auto_generation_config import AutoGenerationConfig
10
- from .table_generation_config import TableGenerationConfig
11
- from .ignore_generation_config import IgnoreGenerationConfig
12
- from .picture_generation_config import PictureGenerationConfig
13
-
14
- __all__ = ["SegmentProcessing"]
15
-
16
-
17
- class SegmentProcessing(BaseModel):
18
- caption: Optional[AutoGenerationConfig] = FieldInfo(alias="Caption", default=None)
19
- """Controls the processing and generation for the segment.
20
-
21
- - `crop_image` controls whether to crop the file's images to the segment's
22
- bounding box. The cropped image will be stored in the segment's `image` field.
23
- Use `All` to always crop, or `Auto` to only crop when needed for
24
- post-processing.
25
- - `format` specifies the output format: `Html` or `Markdown`
26
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
27
- - `Auto`: Process content automatically
28
- - `LLM`: Use large language models for processing
29
- - `Ignore`: Exclude segments from final output
30
- - `description` enables LLM-generated descriptions for segments
31
-
32
- **Deprecated fields (for backwards compatibility):**
33
-
34
- - `llm` - **DEPRECATED**: Use `description` instead
35
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
36
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
37
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
38
- """
39
-
40
- footnote: Optional[AutoGenerationConfig] = FieldInfo(alias="Footnote", default=None)
41
- """Controls the processing and generation for the segment.
42
-
43
- - `crop_image` controls whether to crop the file's images to the segment's
44
- bounding box. The cropped image will be stored in the segment's `image` field.
45
- Use `All` to always crop, or `Auto` to only crop when needed for
46
- post-processing.
47
- - `format` specifies the output format: `Html` or `Markdown`
48
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
49
- - `Auto`: Process content automatically
50
- - `LLM`: Use large language models for processing
51
- - `Ignore`: Exclude segments from final output
52
- - `description` enables LLM-generated descriptions for segments
53
-
54
- **Deprecated fields (for backwards compatibility):**
55
-
56
- - `llm` - **DEPRECATED**: Use `description` instead
57
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
58
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
59
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
60
- """
61
-
62
- formula: Optional[LlmGenerationConfig] = FieldInfo(alias="Formula", default=None)
63
- """Controls the processing and generation for the segment.
64
-
65
- - `crop_image` controls whether to crop the file's images to the segment's
66
- bounding box. The cropped image will be stored in the segment's `image` field.
67
- Use `All` to always crop, or `Auto` to only crop when needed for
68
- post-processing.
69
- - `format` specifies the output format: `Html` or `Markdown`
70
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
71
- - `Auto`: Process content automatically
72
- - `LLM`: Use large language models for processing
73
- - `Ignore`: Exclude segments from final output
74
- - `description` enables LLM-generated descriptions for segments
75
-
76
- **Deprecated fields (for backwards compatibility):**
77
-
78
- - `llm` - **DEPRECATED**: Use `description` instead
79
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
80
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
81
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
82
- """
83
-
84
- list_item: Optional[AutoGenerationConfig] = FieldInfo(alias="ListItem", default=None)
85
- """Controls the processing and generation for the segment.
86
-
87
- - `crop_image` controls whether to crop the file's images to the segment's
88
- bounding box. The cropped image will be stored in the segment's `image` field.
89
- Use `All` to always crop, or `Auto` to only crop when needed for
90
- post-processing.
91
- - `format` specifies the output format: `Html` or `Markdown`
92
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
93
- - `Auto`: Process content automatically
94
- - `LLM`: Use large language models for processing
95
- - `Ignore`: Exclude segments from final output
96
- - `description` enables LLM-generated descriptions for segments
97
-
98
- **Deprecated fields (for backwards compatibility):**
99
-
100
- - `llm` - **DEPRECATED**: Use `description` instead
101
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
102
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
103
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
104
- """
105
-
106
- page: Optional[LlmGenerationConfig] = FieldInfo(alias="Page", default=None)
107
- """Controls the processing and generation for the segment.
108
-
109
- - `crop_image` controls whether to crop the file's images to the segment's
110
- bounding box. The cropped image will be stored in the segment's `image` field.
111
- Use `All` to always crop, or `Auto` to only crop when needed for
112
- post-processing.
113
- - `format` specifies the output format: `Html` or `Markdown`
114
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
115
- - `Auto`: Process content automatically
116
- - `LLM`: Use large language models for processing
117
- - `Ignore`: Exclude segments from final output
118
- - `description` enables LLM-generated descriptions for segments
119
-
120
- **Deprecated fields (for backwards compatibility):**
121
-
122
- - `llm` - **DEPRECATED**: Use `description` instead
123
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
124
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
125
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
126
- """
127
-
128
- page_footer: Optional[IgnoreGenerationConfig] = FieldInfo(alias="PageFooter", default=None)
129
- """Controls the processing and generation for the segment.
130
-
131
- - `crop_image` controls whether to crop the file's images to the segment's
132
- bounding box. The cropped image will be stored in the segment's `image` field.
133
- Use `All` to always crop, or `Auto` to only crop when needed for
134
- post-processing.
135
- - `format` specifies the output format: `Html` or `Markdown`
136
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
137
- - `Auto`: Process content automatically
138
- - `LLM`: Use large language models for processing
139
- - `Ignore`: Exclude segments from final output
140
- - `description` enables LLM-generated descriptions for segments
141
-
142
- **Deprecated fields (for backwards compatibility):**
143
-
144
- - `llm` - **DEPRECATED**: Use `description` instead
145
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
146
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
147
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
148
- """
149
-
150
- page_header: Optional[IgnoreGenerationConfig] = FieldInfo(alias="PageHeader", default=None)
151
- """Controls the processing and generation for the segment.
152
-
153
- - `crop_image` controls whether to crop the file's images to the segment's
154
- bounding box. The cropped image will be stored in the segment's `image` field.
155
- Use `All` to always crop, or `Auto` to only crop when needed for
156
- post-processing.
157
- - `format` specifies the output format: `Html` or `Markdown`
158
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
159
- - `Auto`: Process content automatically
160
- - `LLM`: Use large language models for processing
161
- - `Ignore`: Exclude segments from final output
162
- - `description` enables LLM-generated descriptions for segments
163
-
164
- **Deprecated fields (for backwards compatibility):**
165
-
166
- - `llm` - **DEPRECATED**: Use `description` instead
167
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
168
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
169
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
170
- """
171
-
172
- picture: Optional[PictureGenerationConfig] = FieldInfo(alias="Picture", default=None)
173
- """Controls the processing and generation for the segment.
174
-
175
- - `crop_image` controls whether to crop the file's images to the segment's
176
- bounding box. The cropped image will be stored in the segment's `image` field.
177
- Use `All` to always crop, or `Auto` to only crop when needed for
178
- post-processing.
179
- - `format` specifies the output format: `Html` or `Markdown`
180
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
181
- - `Auto`: Process content automatically
182
- - `LLM`: Use large language models for processing
183
- - `Ignore`: Exclude segments from final output
184
- - `description` enables LLM-generated descriptions for segments
185
-
186
- **Deprecated fields (for backwards compatibility):**
187
-
188
- - `llm` - **DEPRECATED**: Use `description` instead
189
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
190
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
191
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
192
- """
193
-
194
- section_header: Optional[AutoGenerationConfig] = FieldInfo(alias="SectionHeader", default=None)
195
- """Controls the processing and generation for the segment.
196
-
197
- - `crop_image` controls whether to crop the file's images to the segment's
198
- bounding box. The cropped image will be stored in the segment's `image` field.
199
- Use `All` to always crop, or `Auto` to only crop when needed for
200
- post-processing.
201
- - `format` specifies the output format: `Html` or `Markdown`
202
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
203
- - `Auto`: Process content automatically
204
- - `LLM`: Use large language models for processing
205
- - `Ignore`: Exclude segments from final output
206
- - `description` enables LLM-generated descriptions for segments
207
-
208
- **Deprecated fields (for backwards compatibility):**
209
-
210
- - `llm` - **DEPRECATED**: Use `description` instead
211
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
212
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
213
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
214
- """
215
-
216
- table: Optional[TableGenerationConfig] = FieldInfo(alias="Table", default=None)
217
- """Controls the processing and generation for the segment.
218
-
219
- - `crop_image` controls whether to crop the file's images to the segment's
220
- bounding box. The cropped image will be stored in the segment's `image` field.
221
- Use `All` to always crop, or `Auto` to only crop when needed for
222
- post-processing.
223
- - `format` specifies the output format: `Html` or `Markdown`
224
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
225
- - `Auto`: Process content automatically
226
- - `LLM`: Use large language models for processing
227
- - `Ignore`: Exclude segments from final output
228
- - `description` enables LLM-generated descriptions for segments
229
-
230
- **Deprecated fields (for backwards compatibility):**
231
-
232
- - `llm` - **DEPRECATED**: Use `description` instead
233
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
234
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
235
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
236
- """
237
-
238
- text: Optional[AutoGenerationConfig] = FieldInfo(alias="Text", default=None)
239
- """Controls the processing and generation for the segment.
240
-
241
- - `crop_image` controls whether to crop the file's images to the segment's
242
- bounding box. The cropped image will be stored in the segment's `image` field.
243
- Use `All` to always crop, or `Auto` to only crop when needed for
244
- post-processing.
245
- - `format` specifies the output format: `Html` or `Markdown`
246
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
247
- - `Auto`: Process content automatically
248
- - `LLM`: Use large language models for processing
249
- - `Ignore`: Exclude segments from final output
250
- - `description` enables LLM-generated descriptions for segments
251
-
252
- **Deprecated fields (for backwards compatibility):**
253
-
254
- - `llm` - **DEPRECATED**: Use `description` instead
255
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
256
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
257
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
258
- """
259
-
260
- title: Optional[AutoGenerationConfig] = FieldInfo(alias="Title", default=None)
261
- """Controls the processing and generation for the segment.
262
-
263
- - `crop_image` controls whether to crop the file's images to the segment's
264
- bounding box. The cropped image will be stored in the segment's `image` field.
265
- Use `All` to always crop, or `Auto` to only crop when needed for
266
- post-processing.
267
- - `format` specifies the output format: `Html` or `Markdown`
268
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
269
- - `Auto`: Process content automatically
270
- - `LLM`: Use large language models for processing
271
- - `Ignore`: Exclude segments from final output
272
- - `description` enables LLM-generated descriptions for segments
273
-
274
- **Deprecated fields (for backwards compatibility):**
275
-
276
- - `llm` - **DEPRECATED**: Use `description` instead
277
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
278
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
279
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
280
- """
@@ -1,281 +0,0 @@
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 Annotated, TypedDict
7
-
8
- from .._utils import PropertyInfo
9
- from .llm_generation_config_param import LlmGenerationConfigParam
10
- from .auto_generation_config_param import AutoGenerationConfigParam
11
- from .table_generation_config_param import TableGenerationConfigParam
12
- from .ignore_generation_config_param import IgnoreGenerationConfigParam
13
- from .picture_generation_config_param import PictureGenerationConfigParam
14
-
15
- __all__ = ["SegmentProcessingParam"]
16
-
17
-
18
- class SegmentProcessingParam(TypedDict, total=False):
19
- caption: Annotated[Optional[AutoGenerationConfigParam], PropertyInfo(alias="Caption")]
20
- """Controls the processing and generation for the segment.
21
-
22
- - `crop_image` controls whether to crop the file's images to the segment's
23
- bounding box. The cropped image will be stored in the segment's `image` field.
24
- Use `All` to always crop, or `Auto` to only crop when needed for
25
- post-processing.
26
- - `format` specifies the output format: `Html` or `Markdown`
27
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
28
- - `Auto`: Process content automatically
29
- - `LLM`: Use large language models for processing
30
- - `Ignore`: Exclude segments from final output
31
- - `description` enables LLM-generated descriptions for segments
32
-
33
- **Deprecated fields (for backwards compatibility):**
34
-
35
- - `llm` - **DEPRECATED**: Use `description` instead
36
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
37
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
38
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
39
- """
40
-
41
- footnote: Annotated[Optional[AutoGenerationConfigParam], PropertyInfo(alias="Footnote")]
42
- """Controls the processing and generation for the segment.
43
-
44
- - `crop_image` controls whether to crop the file's images to the segment's
45
- bounding box. The cropped image will be stored in the segment's `image` field.
46
- Use `All` to always crop, or `Auto` to only crop when needed for
47
- post-processing.
48
- - `format` specifies the output format: `Html` or `Markdown`
49
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
50
- - `Auto`: Process content automatically
51
- - `LLM`: Use large language models for processing
52
- - `Ignore`: Exclude segments from final output
53
- - `description` enables LLM-generated descriptions for segments
54
-
55
- **Deprecated fields (for backwards compatibility):**
56
-
57
- - `llm` - **DEPRECATED**: Use `description` instead
58
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
59
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
60
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
61
- """
62
-
63
- formula: Annotated[Optional[LlmGenerationConfigParam], PropertyInfo(alias="Formula")]
64
- """Controls the processing and generation for the segment.
65
-
66
- - `crop_image` controls whether to crop the file's images to the segment's
67
- bounding box. The cropped image will be stored in the segment's `image` field.
68
- Use `All` to always crop, or `Auto` to only crop when needed for
69
- post-processing.
70
- - `format` specifies the output format: `Html` or `Markdown`
71
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
72
- - `Auto`: Process content automatically
73
- - `LLM`: Use large language models for processing
74
- - `Ignore`: Exclude segments from final output
75
- - `description` enables LLM-generated descriptions for segments
76
-
77
- **Deprecated fields (for backwards compatibility):**
78
-
79
- - `llm` - **DEPRECATED**: Use `description` instead
80
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
81
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
82
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
83
- """
84
-
85
- list_item: Annotated[Optional[AutoGenerationConfigParam], PropertyInfo(alias="ListItem")]
86
- """Controls the processing and generation for the segment.
87
-
88
- - `crop_image` controls whether to crop the file's images to the segment's
89
- bounding box. The cropped image will be stored in the segment's `image` field.
90
- Use `All` to always crop, or `Auto` to only crop when needed for
91
- post-processing.
92
- - `format` specifies the output format: `Html` or `Markdown`
93
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
94
- - `Auto`: Process content automatically
95
- - `LLM`: Use large language models for processing
96
- - `Ignore`: Exclude segments from final output
97
- - `description` enables LLM-generated descriptions for segments
98
-
99
- **Deprecated fields (for backwards compatibility):**
100
-
101
- - `llm` - **DEPRECATED**: Use `description` instead
102
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
103
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
104
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
105
- """
106
-
107
- page: Annotated[Optional[LlmGenerationConfigParam], PropertyInfo(alias="Page")]
108
- """Controls the processing and generation for the segment.
109
-
110
- - `crop_image` controls whether to crop the file's images to the segment's
111
- bounding box. The cropped image will be stored in the segment's `image` field.
112
- Use `All` to always crop, or `Auto` to only crop when needed for
113
- post-processing.
114
- - `format` specifies the output format: `Html` or `Markdown`
115
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
116
- - `Auto`: Process content automatically
117
- - `LLM`: Use large language models for processing
118
- - `Ignore`: Exclude segments from final output
119
- - `description` enables LLM-generated descriptions for segments
120
-
121
- **Deprecated fields (for backwards compatibility):**
122
-
123
- - `llm` - **DEPRECATED**: Use `description` instead
124
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
125
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
126
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
127
- """
128
-
129
- page_footer: Annotated[Optional[IgnoreGenerationConfigParam], PropertyInfo(alias="PageFooter")]
130
- """Controls the processing and generation for the segment.
131
-
132
- - `crop_image` controls whether to crop the file's images to the segment's
133
- bounding box. The cropped image will be stored in the segment's `image` field.
134
- Use `All` to always crop, or `Auto` to only crop when needed for
135
- post-processing.
136
- - `format` specifies the output format: `Html` or `Markdown`
137
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
138
- - `Auto`: Process content automatically
139
- - `LLM`: Use large language models for processing
140
- - `Ignore`: Exclude segments from final output
141
- - `description` enables LLM-generated descriptions for segments
142
-
143
- **Deprecated fields (for backwards compatibility):**
144
-
145
- - `llm` - **DEPRECATED**: Use `description` instead
146
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
147
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
148
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
149
- """
150
-
151
- page_header: Annotated[Optional[IgnoreGenerationConfigParam], PropertyInfo(alias="PageHeader")]
152
- """Controls the processing and generation for the segment.
153
-
154
- - `crop_image` controls whether to crop the file's images to the segment's
155
- bounding box. The cropped image will be stored in the segment's `image` field.
156
- Use `All` to always crop, or `Auto` to only crop when needed for
157
- post-processing.
158
- - `format` specifies the output format: `Html` or `Markdown`
159
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
160
- - `Auto`: Process content automatically
161
- - `LLM`: Use large language models for processing
162
- - `Ignore`: Exclude segments from final output
163
- - `description` enables LLM-generated descriptions for segments
164
-
165
- **Deprecated fields (for backwards compatibility):**
166
-
167
- - `llm` - **DEPRECATED**: Use `description` instead
168
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
169
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
170
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
171
- """
172
-
173
- picture: Annotated[Optional[PictureGenerationConfigParam], PropertyInfo(alias="Picture")]
174
- """Controls the processing and generation for the segment.
175
-
176
- - `crop_image` controls whether to crop the file's images to the segment's
177
- bounding box. The cropped image will be stored in the segment's `image` field.
178
- Use `All` to always crop, or `Auto` to only crop when needed for
179
- post-processing.
180
- - `format` specifies the output format: `Html` or `Markdown`
181
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
182
- - `Auto`: Process content automatically
183
- - `LLM`: Use large language models for processing
184
- - `Ignore`: Exclude segments from final output
185
- - `description` enables LLM-generated descriptions for segments
186
-
187
- **Deprecated fields (for backwards compatibility):**
188
-
189
- - `llm` - **DEPRECATED**: Use `description` instead
190
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
191
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
192
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
193
- """
194
-
195
- section_header: Annotated[Optional[AutoGenerationConfigParam], PropertyInfo(alias="SectionHeader")]
196
- """Controls the processing and generation for the segment.
197
-
198
- - `crop_image` controls whether to crop the file's images to the segment's
199
- bounding box. The cropped image will be stored in the segment's `image` field.
200
- Use `All` to always crop, or `Auto` to only crop when needed for
201
- post-processing.
202
- - `format` specifies the output format: `Html` or `Markdown`
203
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
204
- - `Auto`: Process content automatically
205
- - `LLM`: Use large language models for processing
206
- - `Ignore`: Exclude segments from final output
207
- - `description` enables LLM-generated descriptions for segments
208
-
209
- **Deprecated fields (for backwards compatibility):**
210
-
211
- - `llm` - **DEPRECATED**: Use `description` instead
212
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
213
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
214
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
215
- """
216
-
217
- table: Annotated[Optional[TableGenerationConfigParam], PropertyInfo(alias="Table")]
218
- """Controls the processing and generation for the segment.
219
-
220
- - `crop_image` controls whether to crop the file's images to the segment's
221
- bounding box. The cropped image will be stored in the segment's `image` field.
222
- Use `All` to always crop, or `Auto` to only crop when needed for
223
- post-processing.
224
- - `format` specifies the output format: `Html` or `Markdown`
225
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
226
- - `Auto`: Process content automatically
227
- - `LLM`: Use large language models for processing
228
- - `Ignore`: Exclude segments from final output
229
- - `description` enables LLM-generated descriptions for segments
230
-
231
- **Deprecated fields (for backwards compatibility):**
232
-
233
- - `llm` - **DEPRECATED**: Use `description` instead
234
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
235
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
236
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
237
- """
238
-
239
- text: Annotated[Optional[AutoGenerationConfigParam], PropertyInfo(alias="Text")]
240
- """Controls the processing and generation for the segment.
241
-
242
- - `crop_image` controls whether to crop the file's images to the segment's
243
- bounding box. The cropped image will be stored in the segment's `image` field.
244
- Use `All` to always crop, or `Auto` to only crop when needed for
245
- post-processing.
246
- - `format` specifies the output format: `Html` or `Markdown`
247
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
248
- - `Auto`: Process content automatically
249
- - `LLM`: Use large language models for processing
250
- - `Ignore`: Exclude segments from final output
251
- - `description` enables LLM-generated descriptions for segments
252
-
253
- **Deprecated fields (for backwards compatibility):**
254
-
255
- - `llm` - **DEPRECATED**: Use `description` instead
256
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
257
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
258
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
259
- """
260
-
261
- title: Annotated[Optional[AutoGenerationConfigParam], PropertyInfo(alias="Title")]
262
- """Controls the processing and generation for the segment.
263
-
264
- - `crop_image` controls whether to crop the file's images to the segment's
265
- bounding box. The cropped image will be stored in the segment's `image` field.
266
- Use `All` to always crop, or `Auto` to only crop when needed for
267
- post-processing.
268
- - `format` specifies the output format: `Html` or `Markdown`
269
- - `strategy` determines how the content is generated: `Auto`, `LLM`, or `Ignore`
270
- - `Auto`: Process content automatically
271
- - `LLM`: Use large language models for processing
272
- - `Ignore`: Exclude segments from final output
273
- - `description` enables LLM-generated descriptions for segments
274
-
275
- **Deprecated fields (for backwards compatibility):**
276
-
277
- - `llm` - **DEPRECATED**: Use `description` instead
278
- - `embed_sources` - **DEPRECATED**: Embed field is auto-populated
279
- - `html` - **DEPRECATED**: Use `format: Html` and `strategy` instead
280
- - `markdown` - **DEPRECATED**: Use `format: Markdown` and `strategy` instead
281
- """
@@ -1,39 +0,0 @@
1
- # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- from typing import List, Optional
4
- from typing_extensions import Literal
5
-
6
- from .._models import BaseModel
7
-
8
- __all__ = ["TableGenerationConfig"]
9
-
10
-
11
- class TableGenerationConfig(BaseModel):
12
- crop_image: Optional[Literal["All", "Auto"]] = None
13
- """Controls the cropping strategy for an item (e.g. segment, chunk, etc.)
14
-
15
- - `All` crops all images in the item
16
- - `Auto` crops images only if required for post-processing
17
- """
18
-
19
- description: Optional[bool] = None
20
- """Generate LLM descriptions for this segment"""
21
-
22
- embed_sources: Optional[List[Literal["Content", "HTML", "Markdown", "LLM"]]] = None
23
- """**DEPRECATED**: `embed` field is auto populated"""
24
-
25
- extended_context: Optional[bool] = None
26
- """Use the full page image as context for LLM generation"""
27
-
28
- format: Optional[Literal["Html", "Markdown"]] = None
29
-
30
- html: Optional[Literal["LLM", "Auto", "Ignore"]] = None
31
- """**DEPRECATED**: Use `format: html` and `strategy` instead."""
32
-
33
- llm: Optional[str] = None
34
- """**DEPRECATED**: use description instead"""
35
-
36
- markdown: Optional[Literal["LLM", "Auto", "Ignore"]] = None
37
- """**DEPRECATED**: Use `format: markdown` and `strategy` instead."""
38
-
39
- strategy: Optional[Literal["LLM", "Auto", "Ignore"]] = None
@@ -1,39 +0,0 @@
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 List, Optional
6
- from typing_extensions import Literal, TypedDict
7
-
8
- __all__ = ["TableGenerationConfigParam"]
9
-
10
-
11
- class TableGenerationConfigParam(TypedDict, total=False):
12
- crop_image: Literal["All", "Auto"]
13
- """Controls the cropping strategy for an item (e.g. segment, chunk, etc.)
14
-
15
- - `All` crops all images in the item
16
- - `Auto` crops images only if required for post-processing
17
- """
18
-
19
- description: bool
20
- """Generate LLM descriptions for this segment"""
21
-
22
- embed_sources: List[Literal["Content", "HTML", "Markdown", "LLM"]]
23
- """**DEPRECATED**: `embed` field is auto populated"""
24
-
25
- extended_context: bool
26
- """Use the full page image as context for LLM generation"""
27
-
28
- format: Literal["Html", "Markdown"]
29
-
30
- html: Optional[Literal["LLM", "Auto", "Ignore"]]
31
- """**DEPRECATED**: Use `format: html` and `strategy` instead."""
32
-
33
- llm: Optional[str]
34
- """**DEPRECATED**: use description instead"""
35
-
36
- markdown: Optional[Literal["LLM", "Auto", "Ignore"]]
37
- """**DEPRECATED**: Use `format: markdown` and `strategy` instead."""
38
-
39
- strategy: Literal["LLM", "Auto", "Ignore"]