@docling/docling-client 2.141.0 → 2.145.0
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.
- package/PYTHON_CLIENT_PARITY.md +47 -5
- package/dist/index.cjs +3 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -1
- package/dist/index.d.ts +12 -1
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
package/PYTHON_CLIENT_PARITY.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Python client parity
|
|
2
2
|
|
|
3
|
-
This document compares `@docling/docling-client` with Docling Python 2.
|
|
4
|
-
at commit `
|
|
3
|
+
This document compares `@docling/docling-client` with Docling Python 2.145.0
|
|
4
|
+
at commit `45d334e`, specifically:
|
|
5
5
|
|
|
6
6
|
- `DoclingServiceClient`
|
|
7
7
|
- `AsyncDoclingServiceClient`
|
|
@@ -159,6 +159,48 @@ High-level limits match Python:
|
|
|
159
159
|
TypeScript restricts limit values to safe integers, which is stricter than
|
|
160
160
|
Python's unbounded integer type.
|
|
161
161
|
|
|
162
|
+
## Service client changes (v2.145.0)
|
|
163
|
+
|
|
164
|
+
Python v2.145.0 at commit `45d334e` includes two service-facing changes since
|
|
165
|
+
v2.142.0. Everything else in the v2.143.0–v2.145.0 range (OCR, VLM, ASR,
|
|
166
|
+
backend fixes, mixed-format ZIP inputs) is server-side or core-library
|
|
167
|
+
behavior with no service-client or service-datamodel surface.
|
|
168
|
+
|
|
169
|
+
- `ZipArchiveResult` gained an optional `filename` (v2.143.0), a suggested
|
|
170
|
+
download name for the archive:
|
|
171
|
+
|
|
172
|
+
```
|
|
173
|
+
https://github.com/docling-project/docling/blob/v2.145.0/docling/datamodel/service/responses.py#L122
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
The TypeScript `ZipArchiveResult` interface exposes `filename?: string | null`.
|
|
177
|
+
Raw ZIP downloads already surfaced the `Content-Disposition` name through
|
|
178
|
+
`RawServiceResult.filename`.
|
|
179
|
+
|
|
180
|
+
- The service client no longer sends the default page range in request options
|
|
181
|
+
(v2.145.0). Python's `_resolve_options()` only writes `page_range` back when
|
|
182
|
+
the effective range differs from the merged options:
|
|
183
|
+
|
|
184
|
+
```
|
|
185
|
+
https://github.com/docling-project/docling/blob/v2.145.0/docling/service_client/client.py#L454
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
TypeScript `applyPageLimits()` mirrors this: with no `page_range`, `pageRange`,
|
|
189
|
+
or `maxNumPages`, no `page_range` is sent, and an unset range is never
|
|
190
|
+
materialized as the all-pages default.
|
|
191
|
+
|
|
192
|
+
| Python (v2.145.0) | TypeScript | Wire key |
|
|
193
|
+
| ------------------------------- | --------------------------- | ------------ |
|
|
194
|
+
| `ZipArchiveResult.filename` | `ZipArchiveResult.filename` | `filename` |
|
|
195
|
+
| `_resolve_options()` page range | `applyPageLimits()` | `page_range` |
|
|
196
|
+
|
|
197
|
+
## Version bump (v2.142.0)
|
|
198
|
+
|
|
199
|
+
Python v2.142.0 at commit `6aaf87e` is a version-only bump over v2.141.0.
|
|
200
|
+
No new fields, types, or operations were added to the service client or
|
|
201
|
+
service datamodel APIs. All TypeScript types, interfaces, methods, and
|
|
202
|
+
validation logic added in previous releases remain in full parity.
|
|
203
|
+
|
|
162
204
|
## Internal scheduler refactoring (v2.141.0)
|
|
163
205
|
|
|
164
206
|
`AsyncDoclingServiceClient.submit_and_retrieve_each()` was refactored in
|
|
@@ -166,7 +208,7 @@ Python v2.141.0 to use an internal `_run_bounded()` helper from
|
|
|
166
208
|
`docling/service_client/_scheduler.py` for bounded concurrency fan-out:
|
|
167
209
|
|
|
168
210
|
```
|
|
169
|
-
https://github.com/docling-project/docling/blob/v2.
|
|
211
|
+
https://github.com/docling-project/docling/blob/v2.142.0/docling/service_client/_scheduler.py#L31
|
|
170
212
|
```
|
|
171
213
|
|
|
172
214
|
The TypeScript scheduler already implements equivalent bounded-concurrency
|
|
@@ -178,7 +220,7 @@ changes are needed; this is a pure internal refactoring on the Python side.
|
|
|
178
220
|
`ConfidenceScores` gained a recursive `pages` field in Python v2.139.0:
|
|
179
221
|
|
|
180
222
|
```
|
|
181
|
-
https://github.com/docling-project/docling/blob/v2.
|
|
223
|
+
https://github.com/docling-project/docling/blob/v2.142.0/docling/datamodel/service/responses.py#L45
|
|
182
224
|
```
|
|
183
225
|
|
|
184
226
|
When present, it maps 1-based page numbers to per-page `ConfidenceScores`
|
|
@@ -196,7 +238,7 @@ objects. The TypeScript `ConfidenceScores` interface includes the
|
|
|
196
238
|
`content` to `document` in Python v2.133.0:
|
|
197
239
|
|
|
198
240
|
```
|
|
199
|
-
https://github.com/docling-project/docling/blob/v2.
|
|
241
|
+
https://github.com/docling-project/docling/blob/v2.142.0/docling/datamodel/service/responses.py#L84
|
|
200
242
|
```
|
|
201
243
|
|
|
202
244
|
Pydantic continues to serialize the field as `content` on the wire via
|
package/dist/index.cjs
CHANGED
|
@@ -1192,6 +1192,9 @@ function applyPageLimits(options, pageRange, maxNumPages) {
|
|
|
1192
1192
|
}
|
|
1193
1193
|
if (effectiveRange !== void 0) {
|
|
1194
1194
|
validatePageRange(effectiveRange);
|
|
1195
|
+
if (options.page_range === void 0 && effectiveRange[0] === 1 && effectiveRange[1] === Number.MAX_SAFE_INTEGER) {
|
|
1196
|
+
return clone(options);
|
|
1197
|
+
}
|
|
1195
1198
|
return { ...clone(options), page_range: [...effectiveRange] };
|
|
1196
1199
|
}
|
|
1197
1200
|
return clone(options);
|