graphor 0.18.0 → 0.20.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/CHANGELOG.md +63 -0
- package/README.md +113 -354
- package/api-promise.d.mts +1 -0
- package/api-promise.d.mts.map +1 -1
- package/api-promise.d.ts +1 -0
- package/api-promise.d.ts.map +1 -1
- package/api-promise.mjs +1 -0
- package/api-promise.mjs.map +1 -1
- package/client.d.mts +2 -2
- package/client.d.mts.map +1 -1
- package/client.d.ts +2 -2
- package/client.d.ts.map +1 -1
- package/client.js +11 -0
- package/client.js.map +1 -1
- package/client.mjs +11 -0
- package/client.mjs.map +1 -1
- package/core/api-promise.d.mts.map +1 -1
- package/core/api-promise.d.ts.map +1 -1
- package/core/api-promise.mjs.map +1 -1
- package/core/error.mjs.map +1 -1
- package/core/resource.d.mts.map +1 -1
- package/core/resource.d.ts.map +1 -1
- package/core/uploads.d.mts.map +1 -1
- package/core/uploads.d.ts.map +1 -1
- package/core/uploads.mjs.map +1 -1
- package/error.d.mts +1 -0
- package/error.d.mts.map +1 -1
- package/error.d.ts +1 -0
- package/error.d.ts.map +1 -1
- package/error.mjs +1 -0
- package/error.mjs.map +1 -1
- package/index.d.mts.map +1 -1
- package/index.d.ts.map +1 -1
- package/index.mjs.map +1 -1
- package/internal/detect-platform.mjs.map +1 -1
- package/internal/headers.mjs.map +1 -1
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.mjs.map +1 -1
- package/internal/qs/formats.d.mts.map +1 -1
- package/internal/qs/formats.d.ts.map +1 -1
- package/internal/qs/index.d.mts +2 -2
- package/internal/qs/index.d.mts.map +1 -1
- package/internal/qs/index.d.ts +2 -2
- package/internal/qs/index.d.ts.map +1 -1
- package/internal/qs/index.mjs.map +1 -1
- package/internal/qs/stringify.d.mts.map +1 -1
- package/internal/qs/stringify.d.ts.map +1 -1
- package/internal/qs/stringify.mjs.map +1 -1
- package/internal/qs/utils.d.mts.map +1 -1
- package/internal/qs/utils.d.ts.map +1 -1
- package/internal/qs/utils.mjs.map +1 -1
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts.map +1 -1
- package/internal/shims.d.mts +6 -0
- package/internal/shims.d.mts.map +1 -1
- package/internal/shims.d.ts +6 -0
- package/internal/shims.d.ts.map +1 -1
- package/internal/to-file.d.mts.map +1 -1
- package/internal/to-file.d.ts.map +1 -1
- package/internal/to-file.mjs.map +1 -1
- package/internal/types.d.mts +10 -10
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +10 -10
- package/internal/types.d.ts.map +1 -1
- package/internal/uploads.d.mts.map +1 -1
- package/internal/uploads.d.ts.map +1 -1
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/base64.mjs.map +1 -1
- package/internal/utils/env.js +2 -2
- package/internal/utils/env.js.map +1 -1
- package/internal/utils/env.mjs +2 -2
- package/internal/utils/env.mjs.map +1 -1
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js +2 -0
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +2 -0
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/path.mjs.map +1 -1
- package/internal/utils/query.mjs.map +1 -1
- package/internal/utils/values.mjs.map +1 -1
- package/internal/utils.d.mts.map +1 -1
- package/internal/utils.d.ts.map +1 -1
- package/internal/utils.mjs.map +1 -1
- package/package.json +1 -1
- package/resource.d.mts +1 -0
- package/resource.d.mts.map +1 -1
- package/resource.d.ts +1 -0
- package/resource.d.ts.map +1 -1
- package/resource.mjs +1 -0
- package/resource.mjs.map +1 -1
- package/resources/index.d.mts +1 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/sources.d.mts +176 -27
- package/resources/sources.d.mts.map +1 -1
- package/resources/sources.d.ts +176 -27
- package/resources/sources.d.ts.map +1 -1
- package/resources/sources.js +54 -12
- package/resources/sources.js.map +1 -1
- package/resources/sources.mjs +54 -12
- package/resources/sources.mjs.map +1 -1
- package/resources.d.mts.map +1 -1
- package/resources.d.ts.map +1 -1
- package/resources.mjs.map +1 -1
- package/src/client.ts +16 -0
- package/src/internal/types.ts +6 -8
- package/src/internal/utils/env.ts +2 -2
- package/src/internal/utils/log.ts +2 -0
- package/src/resources/index.ts +2 -0
- package/src/resources/sources.ts +205 -26
- package/src/version.ts +1 -1
- package/uploads.d.mts +1 -0
- package/uploads.d.mts.map +1 -1
- package/uploads.d.ts +1 -0
- package/uploads.d.ts.map +1 -1
- package/uploads.mjs +1 -0
- package/uploads.mjs.map +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/src/resources/sources.ts
CHANGED
|
@@ -125,7 +125,7 @@ export class Sources extends APIResource {
|
|
|
125
125
|
* @example
|
|
126
126
|
* ```ts
|
|
127
127
|
* const response = await client.sources.ask({
|
|
128
|
-
* question: '
|
|
128
|
+
* question: "What was the company's revenue in 2025?",
|
|
129
129
|
* });
|
|
130
130
|
* ```
|
|
131
131
|
*/
|
|
@@ -169,8 +169,9 @@ export class Sources extends APIResource {
|
|
|
169
169
|
* @example
|
|
170
170
|
* ```ts
|
|
171
171
|
* const response = await client.sources.extract({
|
|
172
|
-
* output_schema: {
|
|
173
|
-
* user_instruction:
|
|
172
|
+
* output_schema: { properties: 'bar', type: 'bar' },
|
|
173
|
+
* user_instruction:
|
|
174
|
+
* 'Extract all invoice line items including product name, quantity, unit price, and total.',
|
|
174
175
|
* });
|
|
175
176
|
* ```
|
|
176
177
|
*/
|
|
@@ -296,6 +297,52 @@ export class Sources extends APIResource {
|
|
|
296
297
|
return this._client.get('/sources/get-elements', { query, ...options });
|
|
297
298
|
}
|
|
298
299
|
|
|
300
|
+
/**
|
|
301
|
+
* Render a single page of a source file as a base64-encoded PNG screenshot.
|
|
302
|
+
*
|
|
303
|
+
* Use this endpoint to lazily fetch the visual preview of a citation returned by
|
|
304
|
+
* `/ask-sources` without paying the payload cost of inlining base64 in the answer.
|
|
305
|
+
* Supports PDFs, image files (`page_number` must be 1), and Office documents
|
|
306
|
+
* (doc/docx/ppt/pptx/odt — rendered from the converted PDF).
|
|
307
|
+
*
|
|
308
|
+
* **Path parameters:**
|
|
309
|
+
*
|
|
310
|
+
* - **file_id** (str): UUID of the source file.
|
|
311
|
+
* - **page_number** (int): 1-based page number.
|
|
312
|
+
*
|
|
313
|
+
* **Query parameters:**
|
|
314
|
+
*
|
|
315
|
+
* - **max_width** (int, optional, default `900`): Pixel width cap. Clamped to the
|
|
316
|
+
* 300-1600 range.
|
|
317
|
+
*
|
|
318
|
+
* **Returns** a `PublicPageScreenshotResponse` containing:
|
|
319
|
+
*
|
|
320
|
+
* - `file_id`, `file_name`, `page_number` — identifying metadata.
|
|
321
|
+
* - `mime_type` — always `"image/png"`.
|
|
322
|
+
* - `width`, `height` — rendered image dimensions in pixels.
|
|
323
|
+
* - `image_base64` — the base64-encoded PNG bytes.
|
|
324
|
+
*
|
|
325
|
+
* **Error responses:**
|
|
326
|
+
*
|
|
327
|
+
* - `404` — File not found, unsupported file type, or invalid page number.
|
|
328
|
+
* - `500` — Unexpected internal error while rendering.
|
|
329
|
+
*
|
|
330
|
+
* @example
|
|
331
|
+
* ```ts
|
|
332
|
+
* const response = await client.sources.getPageScreenshot(0, {
|
|
333
|
+
* file_id: 'file_id',
|
|
334
|
+
* });
|
|
335
|
+
* ```
|
|
336
|
+
*/
|
|
337
|
+
getPageScreenshot(
|
|
338
|
+
pageNumber: number,
|
|
339
|
+
params: SourceGetPageScreenshotParams,
|
|
340
|
+
options?: RequestOptions,
|
|
341
|
+
): APIPromise<SourceGetPageScreenshotResponse> {
|
|
342
|
+
const { file_id, ...query } = params;
|
|
343
|
+
return this._client.get(path`/sources/${file_id}/pages/${pageNumber}/screenshot`, { query, ...options });
|
|
344
|
+
}
|
|
345
|
+
|
|
299
346
|
/**
|
|
300
347
|
* Upload a local file and schedule ingestion in the background.
|
|
301
348
|
*
|
|
@@ -309,7 +356,7 @@ export class Sources extends APIResource {
|
|
|
309
356
|
* `Content-Length` and have a supported extension (pdf, doc, docx, csv, txt, md,
|
|
310
357
|
* etc.).
|
|
311
358
|
* - **method** (`form`, optional): Partitioning strategy. One of: `fast`,
|
|
312
|
-
* `balanced`, `accurate`, `vlm`, `agentic`. Default when omitted.
|
|
359
|
+
* `balanced`, `accurate`, `vlm`, `agentic`, `auto`. Default when omitted.
|
|
313
360
|
*
|
|
314
361
|
* **Returns** `AsyncIngestResponse` with `build_id`. Use it to check processing
|
|
315
362
|
* status.
|
|
@@ -344,7 +391,7 @@ export class Sources extends APIResource {
|
|
|
344
391
|
* @example
|
|
345
392
|
* ```ts
|
|
346
393
|
* const response = await client.sources.ingestGitHub({
|
|
347
|
-
* url: '
|
|
394
|
+
* url: 'https://github.com/langchain-ai/langchain',
|
|
348
395
|
* });
|
|
349
396
|
* ```
|
|
350
397
|
*/
|
|
@@ -375,8 +422,8 @@ export class Sources extends APIResource {
|
|
|
375
422
|
* also follow and ingest links found on the page. Ignored when the URL resolves
|
|
376
423
|
* to a file.
|
|
377
424
|
* - **method** (str, optional): The partitioning strategy to use. One of: `fast`,
|
|
378
|
-
* `balanced`, `accurate`, `vlm`, `agentic`. When omitted the system
|
|
379
|
-
* applied.
|
|
425
|
+
* `balanced`, `accurate`, `vlm`, `agentic`, `auto`. When omitted the system
|
|
426
|
+
* default is applied.
|
|
380
427
|
*
|
|
381
428
|
* **Returns** a `PublicSourceResponse` with `status: "processing"` immediately.
|
|
382
429
|
* Poll the source status endpoint using the returned `file_id` to track
|
|
@@ -390,7 +437,7 @@ export class Sources extends APIResource {
|
|
|
390
437
|
* @example
|
|
391
438
|
* ```ts
|
|
392
439
|
* const response = await client.sources.ingestURL({
|
|
393
|
-
* url: '
|
|
440
|
+
* url: 'https://example.com/blog/ai-trends-2025',
|
|
394
441
|
* });
|
|
395
442
|
* ```
|
|
396
443
|
*/
|
|
@@ -415,7 +462,7 @@ export class Sources extends APIResource {
|
|
|
415
462
|
* @example
|
|
416
463
|
* ```ts
|
|
417
464
|
* const response = await client.sources.ingestYoutube({
|
|
418
|
-
* url: '
|
|
465
|
+
* url: 'https://www.youtube.com/watch?v=dQw4w9WgXcQ',
|
|
419
466
|
* });
|
|
420
467
|
* ```
|
|
421
468
|
*/
|
|
@@ -437,14 +484,14 @@ export class Sources extends APIResource {
|
|
|
437
484
|
*
|
|
438
485
|
* - **file_id** (str, required): Unique identifier of the source to re-process.
|
|
439
486
|
* - **method** (str, default `"fast"`): Partitioning strategy. One of: `fast`,
|
|
440
|
-
* `balanced`, `accurate`, `vlm`, `agentic`.
|
|
487
|
+
* `balanced`, `accurate`, `vlm`, `agentic`, `auto`.
|
|
441
488
|
*
|
|
442
489
|
* **Returns** `AsyncIngestResponse` with `build_id`.
|
|
443
490
|
*
|
|
444
491
|
* @example
|
|
445
492
|
* ```ts
|
|
446
493
|
* const response = await client.sources.reprocess({
|
|
447
|
-
* file_id: '
|
|
494
|
+
* file_id: 'a1b2c3d4-e5f6-7890-abcd-ef1234567890',
|
|
448
495
|
* });
|
|
449
496
|
* ```
|
|
450
497
|
*/
|
|
@@ -484,7 +531,7 @@ export class Sources extends APIResource {
|
|
|
484
531
|
* @example
|
|
485
532
|
* ```ts
|
|
486
533
|
* const response = await client.sources.retrieveChunks({
|
|
487
|
-
* query: '
|
|
534
|
+
* query: "What was the company's net income in 2025?",
|
|
488
535
|
* });
|
|
489
536
|
* ```
|
|
490
537
|
*/
|
|
@@ -607,10 +654,10 @@ export interface Element {
|
|
|
607
654
|
* - fast → basic
|
|
608
655
|
* - balanced → hi_res
|
|
609
656
|
* - accurate → hi_res_ft
|
|
610
|
-
* - vlm → mai
|
|
611
657
|
* - agentic → graphorlm
|
|
658
|
+
* - auto → auto
|
|
612
659
|
*/
|
|
613
|
-
export type Method = 'fast' | 'balanced' | 'accurate' | '
|
|
660
|
+
export type Method = 'fast' | 'balanced' | 'accurate' | 'agentic' | 'auto';
|
|
614
661
|
|
|
615
662
|
export interface PublicSource {
|
|
616
663
|
/**
|
|
@@ -661,7 +708,7 @@ export interface PublicSource {
|
|
|
661
708
|
|
|
662
709
|
/**
|
|
663
710
|
* Partitioning strategy used during ingestion. V1 API: basic, hi_res, hi_res_ft,
|
|
664
|
-
* mai, graphorlm. V2 API: fast, balanced, accurate,
|
|
711
|
+
* mai, graphorlm, auto. V2 API: fast, balanced, accurate, agentic, auto.
|
|
665
712
|
*/
|
|
666
713
|
method?: string | null;
|
|
667
714
|
}
|
|
@@ -704,10 +751,18 @@ export interface SourceAskResponse {
|
|
|
704
751
|
/**
|
|
705
752
|
* The answer to the question. When output_schema is provided, this will be a short
|
|
706
753
|
* status message and the structured data will be in structured_output (and the raw
|
|
707
|
-
* JSON-text in raw_json).
|
|
754
|
+
* JSON-text in raw_json). Inline citations appear as `[N]` markers; use the
|
|
755
|
+
* `citations` field to resolve each marker to its source.
|
|
708
756
|
*/
|
|
709
757
|
answer: string;
|
|
710
758
|
|
|
759
|
+
/**
|
|
760
|
+
* Structured citations extracted from the `[N]` markers in `answer`. When the
|
|
761
|
+
* request includes `include_citation_images=true`, each entry carries a
|
|
762
|
+
* base64-encoded PNG screenshot of the cited page in `image_base64`.
|
|
763
|
+
*/
|
|
764
|
+
citations?: Array<SourceAskResponse.Citation> | null;
|
|
765
|
+
|
|
711
766
|
/**
|
|
712
767
|
* Conversation identifier used to maintain memory context
|
|
713
768
|
*/
|
|
@@ -737,6 +792,57 @@ export interface SourceAskResponse {
|
|
|
737
792
|
}
|
|
738
793
|
|
|
739
794
|
export namespace SourceAskResponse {
|
|
795
|
+
/**
|
|
796
|
+
* A structured citation extracted from the inline `[N]` markers in the answer.
|
|
797
|
+
*
|
|
798
|
+
* Each citation corresponds to one `[N]` marker in the `answer` text. Use the
|
|
799
|
+
* `index` field to map between the marker and the citation entry.
|
|
800
|
+
*/
|
|
801
|
+
export interface Citation {
|
|
802
|
+
/**
|
|
803
|
+
* Optional element identifier within the page/section (e.g. a specific paragraph
|
|
804
|
+
* or table).
|
|
805
|
+
*/
|
|
806
|
+
element_id?: string | null;
|
|
807
|
+
|
|
808
|
+
/**
|
|
809
|
+
* The unique identifier of the source file the citation refers to.
|
|
810
|
+
*/
|
|
811
|
+
file_id?: string | null;
|
|
812
|
+
|
|
813
|
+
/**
|
|
814
|
+
* Display name of the source file.
|
|
815
|
+
*/
|
|
816
|
+
file_name?: string | null;
|
|
817
|
+
|
|
818
|
+
/**
|
|
819
|
+
* Base64-encoded PNG screenshot of the cited page. Only populated when the request
|
|
820
|
+
* was made with `include_citation_images=true`. May be null if the underlying
|
|
821
|
+
* source is not visualizable (e.g. plain text).
|
|
822
|
+
*/
|
|
823
|
+
image_base64?: string | null;
|
|
824
|
+
|
|
825
|
+
/**
|
|
826
|
+
* The 1-based citation number that appears as `[N]` in the answer text.
|
|
827
|
+
*/
|
|
828
|
+
index?: number | null;
|
|
829
|
+
|
|
830
|
+
/**
|
|
831
|
+
* 1-based page number where the cited content appears.
|
|
832
|
+
*/
|
|
833
|
+
page_number?: number | null;
|
|
834
|
+
|
|
835
|
+
/**
|
|
836
|
+
* Optional section number within the page.
|
|
837
|
+
*/
|
|
838
|
+
section_number?: number | null;
|
|
839
|
+
|
|
840
|
+
/**
|
|
841
|
+
* Short text excerpt around the cited content, useful for quick context.
|
|
842
|
+
*/
|
|
843
|
+
text_preview?: string | null;
|
|
844
|
+
}
|
|
845
|
+
|
|
740
846
|
/**
|
|
741
847
|
* Token usage breakdown for this request.
|
|
742
848
|
*/
|
|
@@ -861,8 +967,8 @@ export interface SourceGetBuildStatusResponse {
|
|
|
861
967
|
* - fast → basic
|
|
862
968
|
* - balanced → hi_res
|
|
863
969
|
* - accurate → hi_res_ft
|
|
864
|
-
* - vlm → mai
|
|
865
970
|
* - agentic → graphorlm
|
|
971
|
+
* - auto → auto
|
|
866
972
|
*/
|
|
867
973
|
method?: Method | null;
|
|
868
974
|
|
|
@@ -931,6 +1037,46 @@ export interface SourceGetElementsResponse {
|
|
|
931
1037
|
total_pages?: number | null;
|
|
932
1038
|
}
|
|
933
1039
|
|
|
1040
|
+
/**
|
|
1041
|
+
* Base64-encoded PNG screenshot of a page from a source file.
|
|
1042
|
+
*/
|
|
1043
|
+
export interface SourceGetPageScreenshotResponse {
|
|
1044
|
+
/**
|
|
1045
|
+
* The unique identifier of the source file.
|
|
1046
|
+
*/
|
|
1047
|
+
file_id: string;
|
|
1048
|
+
|
|
1049
|
+
/**
|
|
1050
|
+
* Base64-encoded PNG image bytes.
|
|
1051
|
+
*/
|
|
1052
|
+
image_base64: string;
|
|
1053
|
+
|
|
1054
|
+
/**
|
|
1055
|
+
* 1-based page number that was rendered.
|
|
1056
|
+
*/
|
|
1057
|
+
page_number: number;
|
|
1058
|
+
|
|
1059
|
+
/**
|
|
1060
|
+
* Display name of the source file.
|
|
1061
|
+
*/
|
|
1062
|
+
file_name?: string | null;
|
|
1063
|
+
|
|
1064
|
+
/**
|
|
1065
|
+
* Pixel height of the rendered image.
|
|
1066
|
+
*/
|
|
1067
|
+
height?: number | null;
|
|
1068
|
+
|
|
1069
|
+
/**
|
|
1070
|
+
* MIME type of the encoded image (always image/png).
|
|
1071
|
+
*/
|
|
1072
|
+
mime_type?: string;
|
|
1073
|
+
|
|
1074
|
+
/**
|
|
1075
|
+
* Pixel width of the rendered image.
|
|
1076
|
+
*/
|
|
1077
|
+
width?: number | null;
|
|
1078
|
+
}
|
|
1079
|
+
|
|
934
1080
|
export interface SourceIngestFileResponse {
|
|
935
1081
|
/**
|
|
936
1082
|
* The ID of the build. This ID can be used to check the status of the request.
|
|
@@ -1109,6 +1255,25 @@ export interface SourceAskParams {
|
|
|
1109
1255
|
*/
|
|
1110
1256
|
file_names?: Array<string> | null;
|
|
1111
1257
|
|
|
1258
|
+
/**
|
|
1259
|
+
* When true, the response's `citations` entries are populated with a
|
|
1260
|
+
* base64-encoded PNG screenshot of each cited page in `image_base64`. Increases
|
|
1261
|
+
* payload size and latency — leave false (the default) when not needed and fetch
|
|
1262
|
+
* screenshots on demand via
|
|
1263
|
+
* `GET /sources/{file_id}/pages/{page_number}/screenshot`.
|
|
1264
|
+
*/
|
|
1265
|
+
include_citation_images?: boolean | null;
|
|
1266
|
+
|
|
1267
|
+
/**
|
|
1268
|
+
* When true, the `answer` field keeps the structured citation markup
|
|
1269
|
+
* `[N](file_id|pX|sY|eZ|fNAME)` emitted by the agent. When false (default), the
|
|
1270
|
+
* markup is stripped to plain `[N]` markers and the structured data is exposed via
|
|
1271
|
+
* `citations` instead. Note: the markup format is an implementation detail and may
|
|
1272
|
+
* change in future versions — prefer the `citations` field for stable parsing. Has
|
|
1273
|
+
* no effect when `output_schema` is set.
|
|
1274
|
+
*/
|
|
1275
|
+
include_citation_markup?: boolean | null;
|
|
1276
|
+
|
|
1112
1277
|
/**
|
|
1113
1278
|
* Optional JSON Schema for requesting structured output. When provided, the answer
|
|
1114
1279
|
* field will contain a short status message and the structured data will be in
|
|
@@ -1122,10 +1287,10 @@ export interface SourceAskParams {
|
|
|
1122
1287
|
reset?: boolean | null;
|
|
1123
1288
|
|
|
1124
1289
|
/**
|
|
1125
|
-
* Controls model and thinking budget: 'fast' (cheapest/fastest), 'balanced',
|
|
1126
|
-
* 'accurate' (most thorough)
|
|
1290
|
+
* Controls model and thinking budget: 'fast' (cheapest/fastest), 'balanced',
|
|
1291
|
+
* 'accurate', or 'max' (most thorough)
|
|
1127
1292
|
*/
|
|
1128
|
-
thinking_level?: 'fast' | 'balanced' | 'accurate' | null;
|
|
1293
|
+
thinking_level?: 'fast' | 'balanced' | 'accurate' | 'max' | null;
|
|
1129
1294
|
}
|
|
1130
1295
|
|
|
1131
1296
|
export interface SourceExtractParams {
|
|
@@ -1151,10 +1316,10 @@ export interface SourceExtractParams {
|
|
|
1151
1316
|
file_names?: Array<string> | null;
|
|
1152
1317
|
|
|
1153
1318
|
/**
|
|
1154
|
-
* Controls model and thinking budget: 'fast' (cheapest/fastest), 'balanced',
|
|
1155
|
-
* 'accurate' (most thorough)
|
|
1319
|
+
* Controls model and thinking budget: 'fast' (cheapest/fastest), 'balanced',
|
|
1320
|
+
* 'accurate', or 'max' (most thorough)
|
|
1156
1321
|
*/
|
|
1157
|
-
thinking_level?: 'fast' | 'balanced' | 'accurate' | null;
|
|
1322
|
+
thinking_level?: 'fast' | 'balanced' | 'accurate' | 'max' | null;
|
|
1158
1323
|
}
|
|
1159
1324
|
|
|
1160
1325
|
export interface SourceGetBuildStatusParams {
|
|
@@ -1209,6 +1374,18 @@ export interface SourceGetElementsParams {
|
|
|
1209
1374
|
type?: string | null;
|
|
1210
1375
|
}
|
|
1211
1376
|
|
|
1377
|
+
export interface SourceGetPageScreenshotParams {
|
|
1378
|
+
/**
|
|
1379
|
+
* Path param
|
|
1380
|
+
*/
|
|
1381
|
+
file_id: string;
|
|
1382
|
+
|
|
1383
|
+
/**
|
|
1384
|
+
* Query param: Pixel width cap for the rendered image (clamped to 300-1600).
|
|
1385
|
+
*/
|
|
1386
|
+
max_width?: number;
|
|
1387
|
+
}
|
|
1388
|
+
|
|
1212
1389
|
export interface SourceIngestFileParams {
|
|
1213
1390
|
file: Uploadable;
|
|
1214
1391
|
|
|
@@ -1220,8 +1397,8 @@ export interface SourceIngestFileParams {
|
|
|
1220
1397
|
* - fast → basic
|
|
1221
1398
|
* - balanced → hi_res
|
|
1222
1399
|
* - accurate → hi_res_ft
|
|
1223
|
-
* - vlm → mai
|
|
1224
1400
|
* - agentic → graphorlm
|
|
1401
|
+
* - auto → auto
|
|
1225
1402
|
*/
|
|
1226
1403
|
method?: Method | null;
|
|
1227
1404
|
}
|
|
@@ -1252,8 +1429,8 @@ export interface SourceIngestURLParams {
|
|
|
1252
1429
|
* - fast → basic
|
|
1253
1430
|
* - balanced → hi_res
|
|
1254
1431
|
* - accurate → hi_res_ft
|
|
1255
|
-
* - vlm → mai
|
|
1256
1432
|
* - agentic → graphorlm
|
|
1433
|
+
* - auto → auto
|
|
1257
1434
|
*/
|
|
1258
1435
|
method?: Method | null;
|
|
1259
1436
|
}
|
|
@@ -1273,7 +1450,7 @@ export interface SourceReprocessParams {
|
|
|
1273
1450
|
file_id: string;
|
|
1274
1451
|
|
|
1275
1452
|
/**
|
|
1276
|
-
* Partitioning strategy. One of: fast, balanced, accurate,
|
|
1453
|
+
* Partitioning strategy. One of: fast, balanced, accurate, agentic, auto.
|
|
1277
1454
|
*/
|
|
1278
1455
|
method?: Method;
|
|
1279
1456
|
}
|
|
@@ -1307,6 +1484,7 @@ export declare namespace Sources {
|
|
|
1307
1484
|
type SourceExtractResponse as SourceExtractResponse,
|
|
1308
1485
|
type SourceGetBuildStatusResponse as SourceGetBuildStatusResponse,
|
|
1309
1486
|
type SourceGetElementsResponse as SourceGetElementsResponse,
|
|
1487
|
+
type SourceGetPageScreenshotResponse as SourceGetPageScreenshotResponse,
|
|
1310
1488
|
type SourceIngestFileResponse as SourceIngestFileResponse,
|
|
1311
1489
|
type SourceIngestGitHubResponse as SourceIngestGitHubResponse,
|
|
1312
1490
|
type SourceIngestURLResponse as SourceIngestURLResponse,
|
|
@@ -1319,6 +1497,7 @@ export declare namespace Sources {
|
|
|
1319
1497
|
type SourceExtractParams as SourceExtractParams,
|
|
1320
1498
|
type SourceGetBuildStatusParams as SourceGetBuildStatusParams,
|
|
1321
1499
|
type SourceGetElementsParams as SourceGetElementsParams,
|
|
1500
|
+
type SourceGetPageScreenshotParams as SourceGetPageScreenshotParams,
|
|
1322
1501
|
type SourceIngestFileParams as SourceIngestFileParams,
|
|
1323
1502
|
type SourceIngestGitHubParams as SourceIngestGitHubParams,
|
|
1324
1503
|
type SourceIngestURLParams as SourceIngestURLParams,
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.20.0'; // x-release-please-version
|
package/uploads.d.mts
CHANGED
package/uploads.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uploads.d.mts","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"uploads.d.mts","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,mCAA+B"}
|
package/uploads.d.ts
CHANGED
package/uploads.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uploads.d.ts","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"uploads.d.ts","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,kCAA+B"}
|
package/uploads.mjs
CHANGED
package/uploads.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uploads.mjs","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"uploads.mjs","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,mCAA+B"}
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.20.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.20.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.20.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|