@anuma/sdk 6.26.0 → 6.26.2

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.
@@ -4240,6 +4240,18 @@ interface ProcessedFileResult {
4240
4240
  imageDataUrls?: string[];
4241
4241
  /** Optional metadata about the extraction */
4242
4242
  metadata?: {
4243
+ /**
4244
+ * True when the processor itself dropped part of the file (e.g. spreadsheet rows past the
4245
+ * per-sheet cap). Surfaces as a `"truncated"` {@link FileProcessingStatus}.
4246
+ */
4247
+ truncated?: boolean;
4248
+ /**
4249
+ * The exact sentence in `extractedText` that describes `imageDataUrls` (e.g. "pages 2-3
4250
+ * rendered as images and included in this message"). A consumer that drops some or all of
4251
+ * those images (the cross-file image budget, a zip archive) replaces this sentence so the
4252
+ * model is never told an image was included when it was not.
4253
+ */
4254
+ imageNote?: string;
4243
4255
  pageCount?: number;
4244
4256
  sheetCount?: number;
4245
4257
  sheetNames?: string[];
@@ -4271,7 +4283,8 @@ interface PreprocessingOptions {
4271
4283
  /**
4272
4284
  * Processors to use.
4273
4285
  * - undefined (default): Use all built-in processors
4274
- * - null or []: Disable preprocessing
4286
+ * - null or []: Disable preprocessing (every non-image file is reported `skipped` /
4287
+ * `unsupported_type` in `fileStatuses`)
4275
4288
  * - FileProcessor[]: Use specific processors
4276
4289
  */
4277
4290
  processors?: FileProcessor[] | null;
@@ -4281,11 +4294,50 @@ interface PreprocessingOptions {
4281
4294
  maxFileSizeBytes?: number;
4282
4295
  /** Timeout per file in milliseconds (default: 30000). Prevents hangs from slow CDN workers or large files. */
4283
4296
  timeoutMs?: number;
4297
+ /**
4298
+ * Max characters of extracted text kept per file (default: 100,000). Longer text is cut and
4299
+ * ends with a `[truncated: …]` marker naming how much was kept.
4300
+ */
4301
+ maxExtractedCharsPerFile?: number;
4302
+ /**
4303
+ * Max characters of `extractedContent` across all files of one preprocessing run
4304
+ * (default: 200,000), counting each file's header, separator and truncation marker, not just
4305
+ * its text. Files are cut in order; files that find the budget already spent get no section of
4306
+ * their own — one combined `[truncated: …]` line names them, and their status is `truncated`.
4307
+ */
4308
+ maxExtractedCharsTotal?: number;
4284
4309
  /** Callback for progress updates */
4285
4310
  onProgress?: (current: number, total: number, fileName: string) => void;
4286
4311
  /** Callback for errors (non-fatal) */
4287
4312
  onError?: (fileName: string, error: Error) => void;
4288
4313
  }
4314
+ /**
4315
+ * Why a file was not (fully) read. Paired with {@link FileProcessingStatus}.
4316
+ *
4317
+ * - `too_large`: over `maxFileSizeBytes`
4318
+ * - `unsupported_type`: no processor handles the file's type
4319
+ * - `no_data`: the file has no URL/data to read
4320
+ * - `empty`: the file was read but contained no extractable content
4321
+ * - `timeout`: processing exceeded `timeoutMs`
4322
+ * - `error`: the processor threw (corrupt, password-protected, …)
4323
+ */
4324
+ type FileProcessingReason = "too_large" | "unsupported_type" | "no_data" | "empty" | "timeout" | "error";
4325
+ /**
4326
+ * What happened to one attached file during preprocessing — so the app can tell the user
4327
+ * precisely which attachment the model could not read, and why.
4328
+ *
4329
+ * - `extracted`: its full text reached the model
4330
+ * - `truncated`: part of it reached the model (a size/row/image budget cut the rest)
4331
+ * - `rendered_as_images`: some or all pages were sent as images (scanned PDF)
4332
+ * - `skipped`: not processed (see `reason`)
4333
+ * - `failed`: processing was attempted and failed (see `reason`)
4334
+ */
4335
+ interface FileProcessingStatus {
4336
+ fileId: string;
4337
+ fileName: string;
4338
+ status: "extracted" | "truncated" | "rendered_as_images" | "skipped" | "failed";
4339
+ reason?: FileProcessingReason;
4340
+ }
4289
4341
  /**
4290
4342
  * Result from preprocessing files
4291
4343
  */
@@ -4302,6 +4354,11 @@ interface PreprocessingResult {
4302
4354
  originalFiles?: FileMetadata[];
4303
4355
  /** IDs of files that were successfully preprocessed (used to remove from message) */
4304
4356
  preprocessedFileIds: string[];
4357
+ /**
4358
+ * One entry per input file, in input order. Image files (`image/*`) with no processor are
4359
+ * left out: callers send those directly as `image_url` parts, so they are not "skipped".
4360
+ */
4361
+ fileStatuses: FileProcessingStatus[];
4305
4362
  /** Processing metadata */
4306
4363
  metadata: {
4307
4364
  processedCount: number;
@@ -5358,6 +5415,8 @@ interface BaseUseChatStorageOptions {
5358
5415
  * a custom one matching `PromptPreProcessor`.
5359
5416
  */
5360
5417
  preProcessors?: PromptPreProcessor[];
5418
+ /** Output pacing forwarded to useChat. Set false when the UI batches streamed updates. */
5419
+ smoothing?: StreamSmoothingConfig | boolean;
5361
5420
  /**
5362
5421
  * Enable best-effort, client-side PII obfuscation (NOT a compliance
5363
5422
  * guarantee). Outbound message text is scanned for personally identifiable
@@ -11373,6 +11432,231 @@ interface MemoryVaultToolOptions {
11373
11432
  */
11374
11433
  declare function createMemoryVaultTool(vaultCtx: VaultMemoryOperationsContext, options?: MemoryVaultToolOptions, embeddingOptions?: EmbeddingOptions, cache?: VaultEmbeddingCache): ToolConfig;
11375
11434
 
11435
+ /**
11436
+ * Processor for Excel files (.xlsx) that converts each sheet to CSV.
11437
+ *
11438
+ * CSV rather than JSON: JSON repeated every header on every row, several times the characters
11439
+ * for the same data, and ran into the text caps long before the data did.
11440
+ *
11441
+ * Uses a dynamic import for exceljs so the heavy dependency tree is only
11442
+ * loaded when actually processing an Excel file.
11443
+ */
11444
+ declare class ExcelProcessor implements FileProcessor {
11445
+ readonly name = "excel";
11446
+ readonly supportedMimeTypes: string[];
11447
+ readonly supportedExtensions: string[];
11448
+ private readonly maxRowsPerSheet;
11449
+ constructor(options?: {
11450
+ maxRowsPerSheet?: number;
11451
+ });
11452
+ private loadExcelJS;
11453
+ process(file: FileWithData): Promise<ProcessedFileResult | null>;
11454
+ private resolveCellValue;
11455
+ }
11456
+
11457
+ /**
11458
+ * Processor for PDF files that extracts text content page by page.
11459
+ *
11460
+ * Pages without a usable text layer (scanned pages, including scans inside an otherwise-digital
11461
+ * document) are rendered as images, up to {@link MAX_IMAGE_PAGES}, so a vision model can read
11462
+ * them. A note at the top of the text states exactly which pages arrived as images and which
11463
+ * were left out.
11464
+ */
11465
+ declare class PdfProcessor implements FileProcessor {
11466
+ readonly name = "pdf";
11467
+ readonly supportedMimeTypes: string[];
11468
+ readonly supportedExtensions: string[];
11469
+ process(file: FileWithData): Promise<ProcessedFileResult | null>;
11470
+ }
11471
+
11472
+ /**
11473
+ * Processor for plain-text files (.md, .txt, .csv, .json, .yaml, etc.) that
11474
+ * decodes the file's data URL as UTF-8 and inlines the contents into the user
11475
+ * message.
11476
+ *
11477
+ * Unlike PDF/Word/Excel, no transformation is needed — the raw text IS the
11478
+ * extractable content. Without this processor, text files attached in the UI
11479
+ * would be visible as attachments but their contents would never reach the
11480
+ * model (only `image/*` files are inlined directly by callers).
11481
+ */
11482
+ declare class TextProcessor implements FileProcessor {
11483
+ readonly name = "text";
11484
+ readonly supportedMimeTypes: ("application/json" | "text/plain" | "text/markdown" | "text/x-markdown" | "text/csv" | "text/tab-separated-values" | "text/html" | "text/xml" | "text/yaml" | "text/x-yaml" | "application/ld+json" | "application/xml" | "application/yaml" | "application/x-yaml")[];
11485
+ readonly supportedExtensions: (".txt" | ".md" | ".markdown" | ".csv" | ".tsv" | ".json" | ".jsonl" | ".ndjson" | ".log" | ".yaml" | ".yml" | ".xml" | ".html" | ".htm" | ".ini" | ".toml" | ".cfg" | ".conf")[];
11486
+ process(file: FileWithData): Promise<ProcessedFileResult | null>;
11487
+ /**
11488
+ * Pick a format hint so the orchestrator can wrap the content appropriately
11489
+ * (e.g. JSON files get fenced as ```json so the model parses them as data
11490
+ * rather than prose).
11491
+ */
11492
+ private resolveFormat;
11493
+ }
11494
+
11495
+ /**
11496
+ * Processor for Word documents (.docx) that converts to markdown
11497
+ */
11498
+ declare class WordProcessor implements FileProcessor {
11499
+ readonly name = "word";
11500
+ readonly supportedMimeTypes: string[];
11501
+ readonly supportedExtensions: string[];
11502
+ process(file: FileWithData): Promise<ProcessedFileResult | null>;
11503
+ /**
11504
+ * Count words in text
11505
+ */
11506
+ private countWords;
11507
+ }
11508
+
11509
+ /**
11510
+ * Minimal file shape needed to look up or test for a processor.
11511
+ * Wider than `FileMetadata` so callers with `File`, `Blob`-like objects, or
11512
+ * just a `{ name, type }` pair from a drag-drop event can use the API.
11513
+ */
11514
+ interface FileTypeQuery {
11515
+ name: string;
11516
+ type: string;
11517
+ }
11518
+ /**
11519
+ * Registry for managing and finding file processors
11520
+ */
11521
+ declare class ProcessorRegistry {
11522
+ private processors;
11523
+ /**
11524
+ * Register a processor
11525
+ */
11526
+ register(processor: FileProcessor): void;
11527
+ /**
11528
+ * Find a processor that can handle the given file
11529
+ * @param file - File metadata to match
11530
+ * @returns The matching processor, or null if none found
11531
+ */
11532
+ findProcessor(file: FileTypeQuery): FileProcessor | null;
11533
+ /**
11534
+ * Test whether any registered processor can handle the given file.
11535
+ * Convenience wrapper around `findProcessor` for upload-time validation
11536
+ * where you only care about the boolean answer.
11537
+ */
11538
+ isSupported(file: FileTypeQuery): boolean;
11539
+ /**
11540
+ * Get the union of all MIME types handled by registered processors.
11541
+ * Useful for building an `<input type="file" accept="...">` allowlist.
11542
+ * Result is deduplicated and sorted for stable output.
11543
+ */
11544
+ getSupportedMimeTypes(): string[];
11545
+ /**
11546
+ * Get the union of all file extensions handled by registered processors.
11547
+ * Includes the leading dot (e.g. `.md`, `.pdf`) so values can be passed
11548
+ * directly to an `<input accept>` attribute.
11549
+ * Result is deduplicated and sorted for stable output.
11550
+ */
11551
+ getSupportedExtensions(): string[];
11552
+ /**
11553
+ * Get all registered processors
11554
+ */
11555
+ getAll(): FileProcessor[];
11556
+ /**
11557
+ * Extract file extension from filename
11558
+ */
11559
+ private getFileExtension;
11560
+ }
11561
+
11562
+ /**
11563
+ * Options for configuring ZipProcessor behavior
11564
+ */
11565
+ interface ZipProcessorOptions {
11566
+ /** Maximum size (in bytes) for processing individual files (default: 10MB) */
11567
+ maxFileSize?: number;
11568
+ /** Whether to include hidden files and directories (default: false) */
11569
+ includeHidden?: boolean;
11570
+ }
11571
+ /**
11572
+ * Processor for ZIP archive files that extracts contents and delegates
11573
+ * to other processors for supported file types
11574
+ */
11575
+ declare class ZipProcessor implements FileProcessor {
11576
+ readonly name = "zip";
11577
+ readonly supportedMimeTypes: string[];
11578
+ readonly supportedExtensions: string[];
11579
+ /** Maximum size (in bytes) for processing individual files */
11580
+ private readonly maxFileSize;
11581
+ /** Whether to include hidden files and directories */
11582
+ private readonly includeHidden;
11583
+ /** Registry of processors for nested files */
11584
+ private registry;
11585
+ constructor(options?: ZipProcessorOptions);
11586
+ /**
11587
+ * Set the processor registry for handling nested files
11588
+ * This must be called before processing if you want nested file support
11589
+ */
11590
+ setRegistry(registry: ProcessorRegistry): void;
11591
+ process(file: FileWithData): Promise<ProcessedFileResult | null>;
11592
+ /**
11593
+ * Check if a path represents a hidden file or directory
11594
+ */
11595
+ private isHidden;
11596
+ /**
11597
+ * Format the output with file listing and processed contents
11598
+ */
11599
+ private formatOutput;
11600
+ /**
11601
+ * Get file extension from filename
11602
+ */
11603
+ private getFileExtension;
11604
+ /**
11605
+ * Guess MIME type from file extension
11606
+ */
11607
+ private guessMimeType;
11608
+ }
11609
+
11610
+ /**
11611
+ * One line per file the model did NOT get, saying why — e.g.
11612
+ * `[order.pdf could not be read: the file is larger than 10 MB]`.
11613
+ *
11614
+ * Put these in the same `<attached_files>` part as the extracted contents so the model can tell
11615
+ * the user exactly which attachment it could not read instead of guessing ("an unreadable image
11616
+ * placeholder"). Returns null when every file was read.
11617
+ */
11618
+ declare function formatFileProcessingNotes(statuses: FileProcessingStatus[], options?: {
11619
+ maxFileSizeBytes?: number;
11620
+ }): string | null;
11621
+
11622
+ /**
11623
+ * Test whether the SDK can extract text from the given file.
11624
+ *
11625
+ * Use this for upload-time validation in drag-drop handlers, file-picker
11626
+ * onChange, or paste handlers — block at the boundary with a clear message
11627
+ * instead of silently accepting a file the model will never see.
11628
+ *
11629
+ * Note: this covers files handled by the SDK's text extractors (PDF, Word,
11630
+ * Excel, Zip, plain text/markdown/JSON, etc.). Image files (`image/*`) are
11631
+ * sent directly as `image_url` content parts and are NOT handled by
11632
+ * processors — combine with an image check in your validation:
11633
+ *
11634
+ * ```ts
11635
+ * const ok = file.type.startsWith("image/") || isSupportedFile(file);
11636
+ * ```
11637
+ */
11638
+ declare function isSupportedFile(file: FileTypeQuery): boolean;
11639
+ /**
11640
+ * Get the union of all MIME types and extensions handled by the SDK's
11641
+ * default processors. Useful for building an `<input type="file" accept>`
11642
+ * allowlist.
11643
+ *
11644
+ * Note: does NOT include image MIME types — add `"image/*"` yourself if you
11645
+ * want the file picker to also accept images. See `isSupportedFile` docs.
11646
+ */
11647
+ declare function getSupportedFileTypes(): {
11648
+ mimeTypes: string[];
11649
+ extensions: string[];
11650
+ };
11651
+ /**
11652
+ * Preprocess files by extracting text content
11653
+ *
11654
+ * @param files - Files to process
11655
+ * @param options - Preprocessing options
11656
+ * @returns Result with extracted content and metadata
11657
+ */
11658
+ declare function preprocessFiles(files: FileMetadata[] | undefined, options?: PreprocessingOptions): Promise<PreprocessingResult>;
11659
+
11376
11660
  /**
11377
11661
  * Preview which tools `useChatStorage` will include for a given prompt,
11378
11662
  * without making the actual chat request.
@@ -11553,6 +11837,14 @@ interface SendMessageWithStorageArgs extends BaseSendMessageWithStorageArgs {
11553
11837
  * the conversation-shared redactor, matching the hook-level behavior.
11554
11838
  */
11555
11839
  piiRedaction?: boolean | PiiRedactor;
11840
+ /**
11841
+ * Called once, after the turn's attachments are preprocessed and before the request is sent,
11842
+ * with one {@link FileProcessingStatus} per attached file (images sent as `image_url` are left
11843
+ * out). Use it to tell the user which attachments the model could not read, or only partly
11844
+ * read, and why. Not called when no files are attached. Errors thrown by the callback are
11845
+ * logged and ignored.
11846
+ */
11847
+ onFileProcessingResult?: (statuses: FileProcessingStatus[]) => void;
11556
11848
  }
11557
11849
  /**
11558
11850
  * Result from sendMessage with storage (React version)
@@ -13954,210 +14246,6 @@ interface UseVoiceResult {
13954
14246
  */
13955
14247
  declare function useVoice(options?: UseVoiceOptions): UseVoiceResult;
13956
14248
 
13957
- /**
13958
- * Processor for Excel files (.xlsx) that converts to JSON structure.
13959
- *
13960
- * Uses a dynamic import for exceljs so the heavy dependency tree is only
13961
- * loaded when actually processing an Excel file.
13962
- */
13963
- declare class ExcelProcessor implements FileProcessor {
13964
- readonly name = "excel";
13965
- readonly supportedMimeTypes: string[];
13966
- readonly supportedExtensions: string[];
13967
- private loadExcelJS;
13968
- process(file: FileWithData): Promise<ProcessedFileResult | null>;
13969
- private resolveCellValue;
13970
- }
13971
-
13972
- /**
13973
- * Processor for PDF files that extracts text content.
13974
- * Falls back to rendering pages as images when text extraction yields no
13975
- * content (e.g. scanned/image-based PDFs), enabling vision models to read
13976
- * the document.
13977
- */
13978
- declare class PdfProcessor implements FileProcessor {
13979
- readonly name = "pdf";
13980
- readonly supportedMimeTypes: string[];
13981
- readonly supportedExtensions: string[];
13982
- process(file: FileWithData): Promise<ProcessedFileResult | null>;
13983
- }
13984
-
13985
- /**
13986
- * Processor for plain-text files (.md, .txt, .csv, .json, .yaml, etc.) that
13987
- * decodes the file's data URL as UTF-8 and inlines the contents into the user
13988
- * message.
13989
- *
13990
- * Unlike PDF/Word/Excel, no transformation is needed — the raw text IS the
13991
- * extractable content. Without this processor, text files attached in the UI
13992
- * would be visible as attachments but their contents would never reach the
13993
- * model (only `image/*` files are inlined directly by callers).
13994
- */
13995
- declare class TextProcessor implements FileProcessor {
13996
- readonly name = "text";
13997
- readonly supportedMimeTypes: ("application/json" | "text/plain" | "text/markdown" | "text/x-markdown" | "text/csv" | "text/tab-separated-values" | "text/html" | "text/xml" | "text/yaml" | "text/x-yaml" | "application/ld+json" | "application/xml" | "application/yaml" | "application/x-yaml")[];
13998
- readonly supportedExtensions: (".txt" | ".md" | ".markdown" | ".csv" | ".tsv" | ".json" | ".jsonl" | ".ndjson" | ".log" | ".yaml" | ".yml" | ".xml" | ".html" | ".htm" | ".ini" | ".toml" | ".cfg" | ".conf")[];
13999
- process(file: FileWithData): Promise<ProcessedFileResult | null>;
14000
- /**
14001
- * Pick a format hint so the orchestrator can wrap the content appropriately
14002
- * (e.g. JSON files get fenced as ```json so the model parses them as data
14003
- * rather than prose).
14004
- */
14005
- private resolveFormat;
14006
- }
14007
-
14008
- /**
14009
- * Processor for Word documents (.docx) that converts to markdown
14010
- */
14011
- declare class WordProcessor implements FileProcessor {
14012
- readonly name = "word";
14013
- readonly supportedMimeTypes: string[];
14014
- readonly supportedExtensions: string[];
14015
- process(file: FileWithData): Promise<ProcessedFileResult | null>;
14016
- /**
14017
- * Count words in text
14018
- */
14019
- private countWords;
14020
- }
14021
-
14022
- /**
14023
- * Minimal file shape needed to look up or test for a processor.
14024
- * Wider than `FileMetadata` so callers with `File`, `Blob`-like objects, or
14025
- * just a `{ name, type }` pair from a drag-drop event can use the API.
14026
- */
14027
- interface FileTypeQuery {
14028
- name: string;
14029
- type: string;
14030
- }
14031
- /**
14032
- * Registry for managing and finding file processors
14033
- */
14034
- declare class ProcessorRegistry {
14035
- private processors;
14036
- /**
14037
- * Register a processor
14038
- */
14039
- register(processor: FileProcessor): void;
14040
- /**
14041
- * Find a processor that can handle the given file
14042
- * @param file - File metadata to match
14043
- * @returns The matching processor, or null if none found
14044
- */
14045
- findProcessor(file: FileTypeQuery): FileProcessor | null;
14046
- /**
14047
- * Test whether any registered processor can handle the given file.
14048
- * Convenience wrapper around `findProcessor` for upload-time validation
14049
- * where you only care about the boolean answer.
14050
- */
14051
- isSupported(file: FileTypeQuery): boolean;
14052
- /**
14053
- * Get the union of all MIME types handled by registered processors.
14054
- * Useful for building an `<input type="file" accept="...">` allowlist.
14055
- * Result is deduplicated and sorted for stable output.
14056
- */
14057
- getSupportedMimeTypes(): string[];
14058
- /**
14059
- * Get the union of all file extensions handled by registered processors.
14060
- * Includes the leading dot (e.g. `.md`, `.pdf`) so values can be passed
14061
- * directly to an `<input accept>` attribute.
14062
- * Result is deduplicated and sorted for stable output.
14063
- */
14064
- getSupportedExtensions(): string[];
14065
- /**
14066
- * Get all registered processors
14067
- */
14068
- getAll(): FileProcessor[];
14069
- /**
14070
- * Extract file extension from filename
14071
- */
14072
- private getFileExtension;
14073
- }
14074
-
14075
- /**
14076
- * Options for configuring ZipProcessor behavior
14077
- */
14078
- interface ZipProcessorOptions {
14079
- /** Maximum size (in bytes) for processing individual files (default: 10MB) */
14080
- maxFileSize?: number;
14081
- /** Whether to include hidden files and directories (default: false) */
14082
- includeHidden?: boolean;
14083
- }
14084
- /**
14085
- * Processor for ZIP archive files that extracts contents and delegates
14086
- * to other processors for supported file types
14087
- */
14088
- declare class ZipProcessor implements FileProcessor {
14089
- readonly name = "zip";
14090
- readonly supportedMimeTypes: string[];
14091
- readonly supportedExtensions: string[];
14092
- /** Maximum size (in bytes) for processing individual files */
14093
- private readonly maxFileSize;
14094
- /** Whether to include hidden files and directories */
14095
- private readonly includeHidden;
14096
- /** Registry of processors for nested files */
14097
- private registry;
14098
- constructor(options?: ZipProcessorOptions);
14099
- /**
14100
- * Set the processor registry for handling nested files
14101
- * This must be called before processing if you want nested file support
14102
- */
14103
- setRegistry(registry: ProcessorRegistry): void;
14104
- process(file: FileWithData): Promise<ProcessedFileResult | null>;
14105
- /**
14106
- * Check if a path represents a hidden file or directory
14107
- */
14108
- private isHidden;
14109
- /**
14110
- * Format the output with file listing and processed contents
14111
- */
14112
- private formatOutput;
14113
- /**
14114
- * Get file extension from filename
14115
- */
14116
- private getFileExtension;
14117
- /**
14118
- * Guess MIME type from file extension
14119
- */
14120
- private guessMimeType;
14121
- }
14122
-
14123
- /**
14124
- * Test whether the SDK can extract text from the given file.
14125
- *
14126
- * Use this for upload-time validation in drag-drop handlers, file-picker
14127
- * onChange, or paste handlers — block at the boundary with a clear message
14128
- * instead of silently accepting a file the model will never see.
14129
- *
14130
- * Note: this covers files handled by the SDK's text extractors (PDF, Word,
14131
- * Excel, Zip, plain text/markdown/JSON, etc.). Image files (`image/*`) are
14132
- * sent directly as `image_url` content parts and are NOT handled by
14133
- * processors — combine with an image check in your validation:
14134
- *
14135
- * ```ts
14136
- * const ok = file.type.startsWith("image/") || isSupportedFile(file);
14137
- * ```
14138
- */
14139
- declare function isSupportedFile(file: FileTypeQuery): boolean;
14140
- /**
14141
- * Get the union of all MIME types and extensions handled by the SDK's
14142
- * default processors. Useful for building an `<input type="file" accept>`
14143
- * allowlist.
14144
- *
14145
- * Note: does NOT include image MIME types — add `"image/*"` yourself if you
14146
- * want the file picker to also accept images. See `isSupportedFile` docs.
14147
- */
14148
- declare function getSupportedFileTypes(): {
14149
- mimeTypes: string[];
14150
- extensions: string[];
14151
- };
14152
- /**
14153
- * Preprocess files by extracting text content
14154
- *
14155
- * @param files - Files to process
14156
- * @param options - Preprocessing options
14157
- * @returns Result with extracted content and metadata
14158
- */
14159
- declare function preprocessFiles(files: FileMetadata[] | undefined, options?: PreprocessingOptions): Promise<PreprocessingResult>;
14160
-
14161
14249
  /**
14162
14250
  * @inline
14163
14251
  */
@@ -14500,6 +14588,45 @@ declare function useWalletBinding(options?: UseWalletBindingOptions): UseWalletB
14500
14588
  */
14501
14589
  declare const TOOL_RESULT_ORIGIN = "tool_result";
14502
14590
 
14591
+ /**
14592
+ * True when a text part is the attachment-contents part built by {@link buildAttachedFilesText}.
14593
+ *
14594
+ * Matches the whole generated shape — opening tag plus the fixed header line, and the closing
14595
+ * tag — not just the tag, so user text that merely starts with `<attached_files>` is still
14596
+ * treated as the user's prompt.
14597
+ */
14598
+ declare function isAttachedFilesText(text: string | undefined | null): boolean;
14599
+ /**
14600
+ * Wrap a turn's extracted file contents (the `[Extracted content from <name>]`
14601
+ * blocks `preprocessFiles` emits) in the tagged part that rides on that turn's
14602
+ * user message.
14603
+ */
14604
+ declare function buildAttachedFilesText(fileContext: string): string;
14605
+ /**
14606
+ * Put the current turn's extracted attachment contents on the last user
14607
+ * message, as a text part inserted right after that message's LAST text part:
14608
+ * after everything the user wrote, and before any parts that follow it
14609
+ * (typically images). With interleaved parts such as `[text, image, text,
14610
+ * image]` it lands between the second text and the second image.
14611
+ *
14612
+ * Why not a system message: a detached system message at the front of the
14613
+ * request ("the user has attached files to this conversation") is separated
14614
+ * from the words that refer to it by the whole system prompt, tool catalog and
14615
+ * history. In a long, multi-file conversation fast models stopped connecting
14616
+ * the two and told users the attachment was unreadable even though its text
14617
+ * was in the request. Keeping the contents on the turn that attached them is
14618
+ * how native file attachments work on every provider, and survives the auto
14619
+ * router switching models between turns.
14620
+ *
14621
+ * The part goes AFTER the user's own text because the portal's query
14622
+ * classifier routes on the first text part of the last user message — it must
14623
+ * keep reading the user's prompt, not the document.
14624
+ *
14625
+ * Returns a new array; the input is not mutated. When there is no user
14626
+ * message the messages are returned unchanged.
14627
+ */
14628
+ declare function attachFileContextToLastUserMessage(messages: LlmapiMessage[], fileContext: string): LlmapiMessage[];
14629
+
14503
14630
  /**
14504
14631
  * Dropbox API utilities
14505
14632
  *
@@ -16452,4 +16579,4 @@ declare function renderAnumaTree(node: AnumaNode): React.ReactElement | null;
16452
16579
  */
16453
16580
  declare function renderAnumaJsx(jsx: string): React.ReactElement | null;
16454
16581
 
16455
- export { Anuma, type AnumaChild, AnumaJsxError, type AnumaNode, AnumaShadowIsolationProvider, type AnumaShadowIsolationProviderProps, type AnumaTheme, AnumaThemeProvider, type AnumaThemeProviderProps, AppFile as AppFileModel, type AppFileOperationsContext, type AttrValue, type AutoExtractMessage, type AutoExtractor, DEFAULT_CONVERSATIONS_FOLDER as BACKUP_DRIVE_CONVERSATIONS_FOLDER, DEFAULT_ROOT_FOLDER as BACKUP_DRIVE_ROOT_FOLDER, DEFAULT_BACKUP_FOLDER as BACKUP_ICLOUD_FOLDER, BUILT_IN_TOOL_SETS, type BackupAuthContextValue, BackupAuthProvider, type BackupAuthProviderProps, type BackupOperationOptions, BlobUrlManager, type Budget, CHUNKS_DISCARDED_ORIGIN, type CachedChunkVectors, type CachedServerTools, ChartCard, type ChartCardProps, type ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Conversation as ChatConversation, Message as ChatMessage, type ChatRole, type ChatStorageAdapter, type ChatStorageObservable, type ChunkSearchResult, type ChunkVectorCache, type ChunkingOptions, type CircleProps, type ClientToolsFilterFn, type ConsolidationAction, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type ConversationQueryOptions, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateDecaySweeperOptions, type CreateEntityOptions, type CreateMediaOptions, type CreateMessageOptions, type CreateModelPreferenceOptions, type CreateProjectOptions, type CreateSavedToolOptions, type CreateServerToolsFilterOptions, type CreateUserPreferenceOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_BACKUP_FOLDER$1 as DEFAULT_BACKUP_FOLDER, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_DECAY_POLICY, DEFAULT_CONVERSATIONS_FOLDER as DEFAULT_DRIVE_CONVERSATIONS_FOLDER, DEFAULT_ROOT_FOLDER as DEFAULT_DRIVE_ROOT_FOLDER, DEFAULT_BACKUP_FOLDER$1 as DEFAULT_DROPBOX_FOLDER, DEFAULT_EXCLUDED_SERVER_TOOLS, DEFAULT_BACKUP_FOLDER as DEFAULT_ICLOUD_BACKUP_FOLDER, DEFAULT_MAX_CLASSIFIER_CALLS_PER_SWEEP, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_PERSONALITY_SETTINGS, DEFAULT_PROFILE_FACETS, DEFAULT_PROFILE_FACT_TYPE_WEIGHTS, DEFAULT_PROFILE_PROOF_ALPHA, DEFAULT_PROFILE_TREND_MULTIPLIERS, DEFAULT_SERVER_TOOLS_MATCH_OPTIONS, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type DecayCandidateRaw, type DecayClassifier, type DecayInput, type DecayPolicy, type DecaySweepResult, type DecaySweeper, type DecayVerdict, type DeckProps, type DisplayToolMigrations, type DropboxAuthContextValue, DropboxAuthProvider, type DropboxAuthProviderProps, type DropboxExportResult, type DropboxImportResult, type DurableAutoExtractorOptions, ENTITY_FANOUT, ENTITY_KINDS, type EmbeddedWalletSignerFn, EncryptionKeyMissingError, type EncryptionKeyVersion, type EntityInput, type EntityKind, Entity as EntityModel, type EntityOperationsContext, ExcelProcessor, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type ExtractionFunnel, type ExtractionTimings, FILE_PLACEHOLDER_PREFIX, FILE_PLACEHOLDER_REGEX, type FactType, type FileMetadata, type FileProcessor, type FileTypeQuery, type FileWithData, type FlushResult, type GetConversationsPageOptions, type GetMessagesPageOptions, type GoogleDriveAuthContextValue, GoogleDriveAuthProvider, type GoogleDriveAuthProviderProps, type GoogleDriveExportResult, type GoogleDriveImportResult, type GraphTraversalOptions, type GroupProps, HARD_DELETE_WINDOW_MS, type ICloudAuthContextValue, ICloudAuthProvider, type ICloudAuthProviderProps, type ICloudExportResult, type ICloudImportResult, INFERENCE_ID_HEADER, INTERNAL_FLOW_MARKER, type IconProps, type ImageProps, type InjectionClassifierOptions, type InjectionReason, type InteractionType, type KnownTag, type LazyStoredConversation, type LineProps, type LlmDecayClassifierOptions, type LlmNeighborRefinerOptions, type Logger, LoggerProvider, type LoggerProviderProps, MAX_HOPS, MEDIUM_TTL_MS, type ManualFactType, type MediaDimensions, type MediaFilterOptions, type MediaMetadata, type MediaOperationsContext, type MediaRole, type MediaType, type MemoriesNeedingTopicExtraction, type MemoryContextItem, type MemoryContextLane, type MemoryContextOptions, type MemoryContextResult, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, MemoryEntity as MemoryEntityModel, type MemoryExtractedEvent, type MemoryKind, type MemoryQuarantinedEvent, type MemoryToVerify, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MemoryVerification, type MessageChunk, type MessageFeedback, type MessageOrigin, type MessageSkeleton, type ModelLoadProgress, NEVER_TTL_MS, NODE_BUDGET, type NeighborRefiner, type NowSource, type OCRFile, type ObservationTrend, type ObservationTrendInput, type OperationExecutor, PAST_EVENT_GRACE_MS, PROFILE_DOC_VERSION, type ParsedServerToolsResponse, type PdfExportOptions, type PdfExportProgress, type PdfExportStage, type PdfFile, PdfProcessor, type PendingInteraction, type PersonalitySettings, type PersonalitySliders, type PersonalityStyle, type PhoneCallPollingOptions, type PhotoIngestResult, type PhotoMediaRef, type PlatformStorage, type PortalLlmAuth, type PortalLlmFailure, type PortalLlmFailureReason, type PreprocessingOptions, type PreprocessingResult, type ProcessedFileResult, ProcessorRegistry, type ProfileConfigFingerprint, type ProfileDoc, type ProfileFacet, type ProfileFacetKey, type ProfileSalienceInput, type ProfileSection, type ProfileUpdate, type ProgressCallback, Project, type ProjectOperationsContext, type PromptPreProcessor, type PromptPreProcessorContext, type ProviderAuthState, type ProviderBackupState, ProviderStreamError, type PublishedPhotoMemory, type QuantizedEmbedding, type QuarantinedMemoryInfo, type QueueEncryptionContext, QueueManager, type QueueStatus, type QueuedOperation, type QueuedOperationType, R2_DEFAULT_TTL_MS, RECALL_MAX_LIMIT, RECALL_TOOL_NAME, type RankableVaultMemory, type RankedMemory, type RankedProfileCandidate, type RecallContext, type RecallDegradation, type RecallDiagnostics, type RecallEmptyReason, type RecallOptions, type RecallResult, type RecallToolCallbacks, type RecallToolOptions, type RecencyOptions, type RectProps, type ReflectOptions, type ReflectResult, type RequestEncryptionKeyOptions, RerankerUnavailableError, type ResumeStreamOptions, type ResumeStreamResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, SERVER_TOOL_DEPENDENCY_SETS, SHORT_TTL_MS, SLIDER_CONFIG, SLIDES_FILE_PATH, SLIDE_CANVAS_HEIGHT, SLIDE_CANVAS_WIDTH, STREAM_RESUMABLE_HEADER, SavedTool as SavedToolModel, type SavedToolOperationsContext, type SavedToolParameter, type ScoreBreakdown, type ScoreProfileSalienceOptions, type ScreenProps, type ScreenResult, type ScreenedCandidate, type SearchMessagesOptions, type SearchSource, type SelectServerToolsForPromptOptions, type SendMessageWithStorageArgs, type SendMessageWithStorageResult, type ServerTool, type ServerToolsFilter, type ServerToolsFilterFn, type ServerToolsFilterFunction, type ServerToolsOptions, type ServerToolsResponse, type SignMessageFn, type SignMessageOptions, type SlideProps, type StepFinishEvent, type StockPriceClassification, type StockPricePreProcessorOptions, type StorageOperationsContext, type StoredAppFile, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredEntity, type StoredFileWithContext, type StoredMedia, Media as StoredMediaModel, type StoredMessage, type StoredMessageWithSimilarity, type StoredModelPreference, ModelPreference as StoredModelPreferenceModel, type StoredProject, type StoredSavedTool, type StoredTopic, type StoredUserPreference, UserPreference as StoredUserPreferenceModel, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, type SynthesizeProfileOptions, THEME_ATTRS, TOOL_RESULT_ORIGIN, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, TREND_RECENT_WINDOW_DAYS, TREND_STALE_WINDOW_DAYS, type TextChunk, TextProcessor, type TextProps, type ThemeAttr, type ToolCallArgumentsDeltaEvent, type ToolMatchOptions, type ToolMatchResult, type ToolSet, type TopicExtractOptions, type TopicExtractionInput, type TopicExtractionRunResult, type TopicSkipReason, type TopicSource, type TranscriptionResult, type TurnCompleteEvent, type TurnSkippedEvent, type UIInteractionContextValue, UIInteractionProvider, type UIInteractionProviderProps, type UncheckedReason, type UnverifiableReason, type UpdateMediaOptions, type UpdateModelPreferenceOptions, type UpdateProjectOptions, type UpdateSavedToolOptions, type UpdateUserPreferenceOptions, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseBackupOptions, type UseBackupResult, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseDropboxBackupOptions, type UseDropboxBackupResult, type UseEncryptionResult, type UseExportPdfResult, type UseFilesOptions, type UseFilesResult, type UseGoogleDriveBackupOptions, type UseGoogleDriveBackupResult, type UseICloudBackupOptions, type UseICloudBackupResult, type UseModelsResult, type UseOCRResult, type UsePdfResult, type UsePhoneCallsOptions, type UsePhoneCallsResult, type UseProjectsOptions, type UseProjectsResult, type UseSettingsOptions, type UseSettingsResult, type UseSubscriptionOptions, type UseSubscriptionResult, type UseToolsOptions, type UseToolsResult, type UseVoiceOptions, type UseVoiceResult, type UseWalletBindingOptions, type UseWalletBindingResult, VAULT_SIZE_HOP_CAP, type VaultCandidateKey, type VaultEmbeddingCache, type VaultEmbeddingExpectation, type VaultFolderOperationsContext, type VaultMemoryOperationsContext, type VaultMemoryVisibility, type VaultMemoryWriter, type VaultSaveOperation, type VaultSearchResult, type VaultWriteAction, type VaultWriteInput, type VaultWriteOutcome, type VerificationSources, type VerifyMemoriesForPublishOptions, type VoiceRecording, WalletPoller, WatermelonChatStorageAdapter, type WatermelonChatStorageAdapterOptions, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, type WhisperModel, WordProcessor, ZipProcessor, type ZipProcessorOptions, addConversationMemoriesOp, appFileToStored, archiveVaultMemoryOp, assembleMemoryContext, backfillMemoryEntityUserIdsOp, backfillMemoryTopicsOp, capHopsForDensity, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyDecay, classifyInjectionCandidates, classifyObservationTrend, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearAllKeyPairs, clearCalendarToken, clearConversationMemoriesOp, clearDriveToken, clearToken as clearDropboxToken, clearEncryptionKey, clearGithubToken, clearGoogleDriveToken, clearICloudAuth, clearKeyPair, clearLazyTitleCache, clearMemoryTopicsOverrideOp, clearNotionToken, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createDecaySweeper, createDurableAutoExtractor, createGitHubTools, createLlmDecayClassifier, createLlmNeighborRefiner, createMediaBatchOp, createMediaOp, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createMessageSourceResolver, createPlatformCursorStore, createProjectOp, createRecallTool, createSavedToolOp, createServerToolsFilter, createStockPricePreProcessor, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWeatherPreProcessor, createWebSearchPreProcessor, decodeChunkVector, decryptConversationTitle, decryptData, decryptDataBatch, decryptDataBytes, decryptDataBytesFromBytes, decryptDataWithKey, defaultServerToolsFilter, deleteAllAppFilesOp, deleteAllVaultMemoriesForUserOp, deleteAppFileOp, deleteEncryptedFile, deleteMediaByConversationOp, deleteMediaByMessageOp, deleteMediaOp, deleteMessageOp, deleteProjectOp, deleteSavedToolOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, eagerEmbedContent, embedAllMessages, embedMessage, encodeChunkVector, encryptData, encryptDataBatch, encryptDataBytes, encryptDataWithKey, ensureDefaultFoldersOp, expandToolSetsAdditive, exportElementToPdf, exportMarkdownToPdf, exportPublicKey, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, extractFileIds, fileExists, findById, findMatchingTools, findParentOfId, generateConversationId, generateEmbedding, generateEmbeddings, generateMediaId, generateProjectId, getAIGeneratedMediaOp, getAllSavedToolsOp, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getAndClearCalendarPendingMessage, getAndClearCalendarReturnUrl, getAndClearDrivePendingMessage, getAndClearDriveReturnUrl, getAndClearGithubPendingMessage, getAndClearGithubReturnUrl, getAndClearNotionPendingMessage, getAndClearNotionReturnUrl, getAppFileMapOp, getAppFileOp, getAppFilesOp, getAudioOp, getCachedServerTools, getCalendarAccessToken, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsByProjectOp, getConversationsLazyOp, getConversationsPageOp, getDecayCandidatesRawOp, getDocumentsOp, getDriveAccessToken, getEncryptionKey, getEntitiesByMemoryIdsOp, getGithubAccessToken, getGoogleDriveStoredToken, getId, getImagesOp, getLogger, getMediaByConversationOp, getMediaByIdOp, getMediaByIdsOp, getMediaByMessageOp, getMediaByModelOp, getMediaByRoleOp, getMediaBySourceUrlOp, getMediaByTypeOp, getMediaCountOp, getMediaCountsByTypeOp, getMediaOp, getMediaTypeFromMime, getMemoriesByEntityNamesOp, getMemoriesNeedingTopicExtractionOp, getNotionAccessToken, getNotionMCPUrl, getNumberAttr, getProjectConversationCountOp, getProjectConversationsOp, getProjectOp, getProjectsOp, getRecentMediaOp, getSavedToolByIdOp, getServerTools, getStringAttr, getSupportedFileTypes, getToolsChecksum, getUnfiledVaultMemoriesOp, getUserUploadedMediaOp, getValidCalendarToken, getValidDriveToken, getValidGithubToken, getValidNotionToken, getVaultCandidateKeysOp, getVaultEmbeddingsByIdsOp, getVaultFolderMemoryCountOp, getVaultMemoriesByIdsOp, getVaultMemoryOp, getVaultRankingProjectionsOp, getVideosOp, handleCalendarCallback, handleDriveCallback, handleGithubCallback, handleNotionCallback, hardDeleteDecayedOp, hardDeleteMediaOp, hasCalendarCredentials, hasDriveCredentials, hasDropboxCredentials, hasEncryptionKey, hasGithubCredentials, hasGoogleDriveCredentials, hasICloudCredentials, hasKeyPair, hasNotionCredentials, ingestPublishedPhotoMemoriesOp, injectionSignatureCatalog, insertAfterId, insertChild, isAnumaTag, isCalendarCallback, isDegradedTopicSkip, isDriveCallback, isEncrypted, isGithubCallback, isHtmlTag, isNotionCallback, isOPFSSupported, isR2UrlExpired, isRerankerAvailable, isSupportedFile, isSupportedMediaType, linkMemoryEntitiesOp, maskScopedEmbeddingCache, mediaToStored, migrateCalendarToken, migrateDisplayResult, migrateDriveToken, migrateGithubToken, migrateNotionClientRegistration, migrateNotionToken, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, parseJsx, parseMedia, preEmbedVaultMemories, preprocessFiles, previewToolSelection, projectToStored, putAppFileOp, quantizeEmbedding, queueManager, rankProfileCandidates, readEncryptedFile, recall, reflect, refreshCalendarToken, refreshDriveToken, refreshEncryptionKeyIfMatches, refreshGithubToken, refreshNotionToken, relinkMemoryTopicsOp, relinkMisclassifiedVideosOp, removeById, renderAnumaJsx, renderAnumaTree, renderElementToCanvas, replaceById, replaceMemoryEntitiesGuardedOp, requestEncryptionKey, requestKeyPair, resolveFilePlaceholders, resolveThemeColor, restoreVaultMemoryOp, resumeStream, retain, revokeCalendarToken, revokeDriveToken, revokeGithubToken, revokeNotionAccess, savedToolToStored, scoreProfileSalience, screenCandidatesForInjection, sdkMigrations, sdkModelClasses, sdkSchema, searchChunksOp, searchMediaOp, searchMessagesOp, searchVaultMemories, seedEncryptionKeys, selectServerToolsForPrompt, serializeJsx, setLogger, setMemoryEntitiesOp, setMemoryVisibilityOp, settingsStorageSchema, shouldChunkMessage, shouldRecallMemory, shouldRefreshTools, stampTopicsExtractedAtOp, startGithubAuth, startNotionAuth, storeCalendarPendingMessage, storeCalendarReturnUrl, storeCalendarToken, storeDrivePendingMessage, storeDriveReturnUrl, storeDriveToken, storeGithubPendingMessage, storeGithubReturnUrl, storeGithubToken, storeNotionPendingMessage, storeNotionReturnUrl, streamCancelPath, streamReplayPath, summarizeObservationTrends, supersedeVaultMemoryOp, synthesizeProfile, traverseGraphLane, ttlForType, updateAttrs, updateConversationProjectOp, updateMediaMessageIdBatchOp, updateMediaOp, updateMessageFeedbackOp, updateProjectNameOp, updateProjectOp, updateSavedToolOp, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, useAnumaTheme, useBackup, useBackupAuth, useChat, useChatStorage, useCredits, useDatabaseManager, useDropboxAuth, useDropboxBackup, useEncryption, useExportPdf, useFiles, useGoogleDriveAuth, useGoogleDriveBackup, useICloudAuth, useICloudBackup, useModels, useOCR, usePdf, usePhoneCalls, useProjects, useSettings, useSubscription, useTools, useUIInteraction, useVoice, useWalletBinding, userPreferencesStorageSchema, verifyMemoriesForPublish, walk, webPlatformStorage, withInternalFlowMarker, writeEncryptedFile };
16582
+ export { Anuma, type AnumaChild, AnumaJsxError, type AnumaNode, AnumaShadowIsolationProvider, type AnumaShadowIsolationProviderProps, type AnumaTheme, AnumaThemeProvider, type AnumaThemeProviderProps, AppFile as AppFileModel, type AppFileOperationsContext, type AttrValue, type AutoExtractMessage, type AutoExtractor, DEFAULT_CONVERSATIONS_FOLDER as BACKUP_DRIVE_CONVERSATIONS_FOLDER, DEFAULT_ROOT_FOLDER as BACKUP_DRIVE_ROOT_FOLDER, DEFAULT_BACKUP_FOLDER as BACKUP_ICLOUD_FOLDER, BUILT_IN_TOOL_SETS, type BackupAuthContextValue, BackupAuthProvider, type BackupAuthProviderProps, type BackupOperationOptions, BlobUrlManager, type Budget, CHUNKS_DISCARDED_ORIGIN, type CachedChunkVectors, type CachedServerTools, ChartCard, type ChartCardProps, type ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Conversation as ChatConversation, Message as ChatMessage, type ChatRole, type ChatStorageAdapter, type ChatStorageObservable, type ChunkSearchResult, type ChunkVectorCache, type ChunkingOptions, type CircleProps, type ClientToolsFilterFn, type ConsolidationAction, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type ConversationQueryOptions, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateDecaySweeperOptions, type CreateEntityOptions, type CreateMediaOptions, type CreateMessageOptions, type CreateModelPreferenceOptions, type CreateProjectOptions, type CreateSavedToolOptions, type CreateServerToolsFilterOptions, type CreateUserPreferenceOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_BACKUP_FOLDER$1 as DEFAULT_BACKUP_FOLDER, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_DECAY_POLICY, DEFAULT_CONVERSATIONS_FOLDER as DEFAULT_DRIVE_CONVERSATIONS_FOLDER, DEFAULT_ROOT_FOLDER as DEFAULT_DRIVE_ROOT_FOLDER, DEFAULT_BACKUP_FOLDER$1 as DEFAULT_DROPBOX_FOLDER, DEFAULT_EXCLUDED_SERVER_TOOLS, DEFAULT_BACKUP_FOLDER as DEFAULT_ICLOUD_BACKUP_FOLDER, DEFAULT_MAX_CLASSIFIER_CALLS_PER_SWEEP, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_PERSONALITY_SETTINGS, DEFAULT_PROFILE_FACETS, DEFAULT_PROFILE_FACT_TYPE_WEIGHTS, DEFAULT_PROFILE_PROOF_ALPHA, DEFAULT_PROFILE_TREND_MULTIPLIERS, DEFAULT_SERVER_TOOLS_MATCH_OPTIONS, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type DecayCandidateRaw, type DecayClassifier, type DecayInput, type DecayPolicy, type DecaySweepResult, type DecaySweeper, type DecayVerdict, type DeckProps, type DisplayToolMigrations, type DropboxAuthContextValue, DropboxAuthProvider, type DropboxAuthProviderProps, type DropboxExportResult, type DropboxImportResult, type DurableAutoExtractorOptions, ENTITY_FANOUT, ENTITY_KINDS, type EmbeddedWalletSignerFn, EncryptionKeyMissingError, type EncryptionKeyVersion, type EntityInput, type EntityKind, Entity as EntityModel, type EntityOperationsContext, ExcelProcessor, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type ExtractionFunnel, type ExtractionTimings, FILE_PLACEHOLDER_PREFIX, FILE_PLACEHOLDER_REGEX, type FactType, type FileMetadata, type FileProcessingReason, type FileProcessingStatus, type FileProcessor, type FileTypeQuery, type FileWithData, type FlushResult, type GetConversationsPageOptions, type GetMessagesPageOptions, type GoogleDriveAuthContextValue, GoogleDriveAuthProvider, type GoogleDriveAuthProviderProps, type GoogleDriveExportResult, type GoogleDriveImportResult, type GraphTraversalOptions, type GroupProps, HARD_DELETE_WINDOW_MS, type ICloudAuthContextValue, ICloudAuthProvider, type ICloudAuthProviderProps, type ICloudExportResult, type ICloudImportResult, INFERENCE_ID_HEADER, INTERNAL_FLOW_MARKER, type IconProps, type ImageProps, type InjectionClassifierOptions, type InjectionReason, type InteractionType, type KnownTag, type LazyStoredConversation, type LineProps, type LlmDecayClassifierOptions, type LlmNeighborRefinerOptions, type Logger, LoggerProvider, type LoggerProviderProps, MAX_HOPS, MEDIUM_TTL_MS, type ManualFactType, type MediaDimensions, type MediaFilterOptions, type MediaMetadata, type MediaOperationsContext, type MediaRole, type MediaType, type MemoriesNeedingTopicExtraction, type MemoryContextItem, type MemoryContextLane, type MemoryContextOptions, type MemoryContextResult, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, MemoryEntity as MemoryEntityModel, type MemoryExtractedEvent, type MemoryKind, type MemoryQuarantinedEvent, type MemoryToVerify, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MemoryVerification, type MessageChunk, type MessageFeedback, type MessageOrigin, type MessageSkeleton, type ModelLoadProgress, NEVER_TTL_MS, NODE_BUDGET, type NeighborRefiner, type NowSource, type OCRFile, type ObservationTrend, type ObservationTrendInput, type OperationExecutor, PAST_EVENT_GRACE_MS, PROFILE_DOC_VERSION, type ParsedServerToolsResponse, type PdfExportOptions, type PdfExportProgress, type PdfExportStage, type PdfFile, PdfProcessor, type PendingInteraction, type PersonalitySettings, type PersonalitySliders, type PersonalityStyle, type PhoneCallPollingOptions, type PhotoIngestResult, type PhotoMediaRef, type PlatformStorage, type PortalLlmAuth, type PortalLlmFailure, type PortalLlmFailureReason, type PreprocessingOptions, type PreprocessingResult, type ProcessedFileResult, ProcessorRegistry, type ProfileConfigFingerprint, type ProfileDoc, type ProfileFacet, type ProfileFacetKey, type ProfileSalienceInput, type ProfileSection, type ProfileUpdate, type ProgressCallback, Project, type ProjectOperationsContext, type PromptPreProcessor, type PromptPreProcessorContext, type ProviderAuthState, type ProviderBackupState, ProviderStreamError, type PublishedPhotoMemory, type QuantizedEmbedding, type QuarantinedMemoryInfo, type QueueEncryptionContext, QueueManager, type QueueStatus, type QueuedOperation, type QueuedOperationType, R2_DEFAULT_TTL_MS, RECALL_MAX_LIMIT, RECALL_TOOL_NAME, type RankableVaultMemory, type RankedMemory, type RankedProfileCandidate, type RecallContext, type RecallDegradation, type RecallDiagnostics, type RecallEmptyReason, type RecallOptions, type RecallResult, type RecallToolCallbacks, type RecallToolOptions, type RecencyOptions, type RectProps, type ReflectOptions, type ReflectResult, type RequestEncryptionKeyOptions, RerankerUnavailableError, type ResumeStreamOptions, type ResumeStreamResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, SERVER_TOOL_DEPENDENCY_SETS, SHORT_TTL_MS, SLIDER_CONFIG, SLIDES_FILE_PATH, SLIDE_CANVAS_HEIGHT, SLIDE_CANVAS_WIDTH, STREAM_RESUMABLE_HEADER, SavedTool as SavedToolModel, type SavedToolOperationsContext, type SavedToolParameter, type ScoreBreakdown, type ScoreProfileSalienceOptions, type ScreenProps, type ScreenResult, type ScreenedCandidate, type SearchMessagesOptions, type SearchSource, type SelectServerToolsForPromptOptions, type SendMessageWithStorageArgs, type SendMessageWithStorageResult, type ServerTool, type ServerToolsFilter, type ServerToolsFilterFn, type ServerToolsFilterFunction, type ServerToolsOptions, type ServerToolsResponse, type SignMessageFn, type SignMessageOptions, type SlideProps, type StepFinishEvent, type StockPriceClassification, type StockPricePreProcessorOptions, type StorageOperationsContext, type StoredAppFile, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredEntity, type StoredFileWithContext, type StoredMedia, Media as StoredMediaModel, type StoredMessage, type StoredMessageWithSimilarity, type StoredModelPreference, ModelPreference as StoredModelPreferenceModel, type StoredProject, type StoredSavedTool, type StoredTopic, type StoredUserPreference, UserPreference as StoredUserPreferenceModel, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, type StreamSmoothingConfig, type SynthesizeProfileOptions, THEME_ATTRS, TOOL_RESULT_ORIGIN, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, TREND_RECENT_WINDOW_DAYS, TREND_STALE_WINDOW_DAYS, type TextChunk, TextProcessor, type TextProps, type ThemeAttr, type ToolCallArgumentsDeltaEvent, type ToolMatchOptions, type ToolMatchResult, type ToolSet, type TopicExtractOptions, type TopicExtractionInput, type TopicExtractionRunResult, type TopicSkipReason, type TopicSource, type TranscriptionResult, type TurnCompleteEvent, type TurnSkippedEvent, type UIInteractionContextValue, UIInteractionProvider, type UIInteractionProviderProps, type UncheckedReason, type UnverifiableReason, type UpdateMediaOptions, type UpdateModelPreferenceOptions, type UpdateProjectOptions, type UpdateSavedToolOptions, type UpdateUserPreferenceOptions, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseBackupOptions, type UseBackupResult, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseDropboxBackupOptions, type UseDropboxBackupResult, type UseEncryptionResult, type UseExportPdfResult, type UseFilesOptions, type UseFilesResult, type UseGoogleDriveBackupOptions, type UseGoogleDriveBackupResult, type UseICloudBackupOptions, type UseICloudBackupResult, type UseModelsResult, type UseOCRResult, type UsePdfResult, type UsePhoneCallsOptions, type UsePhoneCallsResult, type UseProjectsOptions, type UseProjectsResult, type UseSettingsOptions, type UseSettingsResult, type UseSubscriptionOptions, type UseSubscriptionResult, type UseToolsOptions, type UseToolsResult, type UseVoiceOptions, type UseVoiceResult, type UseWalletBindingOptions, type UseWalletBindingResult, VAULT_SIZE_HOP_CAP, type VaultCandidateKey, type VaultEmbeddingCache, type VaultEmbeddingExpectation, type VaultFolderOperationsContext, type VaultMemoryOperationsContext, type VaultMemoryVisibility, type VaultMemoryWriter, type VaultSaveOperation, type VaultSearchResult, type VaultWriteAction, type VaultWriteInput, type VaultWriteOutcome, type VerificationSources, type VerifyMemoriesForPublishOptions, type VoiceRecording, WalletPoller, WatermelonChatStorageAdapter, type WatermelonChatStorageAdapterOptions, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, type WhisperModel, WordProcessor, ZipProcessor, type ZipProcessorOptions, addConversationMemoriesOp, appFileToStored, archiveVaultMemoryOp, assembleMemoryContext, attachFileContextToLastUserMessage, backfillMemoryEntityUserIdsOp, backfillMemoryTopicsOp, buildAttachedFilesText, capHopsForDensity, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyDecay, classifyInjectionCandidates, classifyObservationTrend, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearAllKeyPairs, clearCalendarToken, clearConversationMemoriesOp, clearDriveToken, clearToken as clearDropboxToken, clearEncryptionKey, clearGithubToken, clearGoogleDriveToken, clearICloudAuth, clearKeyPair, clearLazyTitleCache, clearMemoryTopicsOverrideOp, clearNotionToken, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createDecaySweeper, createDurableAutoExtractor, createGitHubTools, createLlmDecayClassifier, createLlmNeighborRefiner, createMediaBatchOp, createMediaOp, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createMessageSourceResolver, createPlatformCursorStore, createProjectOp, createRecallTool, createSavedToolOp, createServerToolsFilter, createStockPricePreProcessor, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWeatherPreProcessor, createWebSearchPreProcessor, decodeChunkVector, decryptConversationTitle, decryptData, decryptDataBatch, decryptDataBytes, decryptDataBytesFromBytes, decryptDataWithKey, defaultServerToolsFilter, deleteAllAppFilesOp, deleteAllVaultMemoriesForUserOp, deleteAppFileOp, deleteEncryptedFile, deleteMediaByConversationOp, deleteMediaByMessageOp, deleteMediaOp, deleteMessageOp, deleteProjectOp, deleteSavedToolOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, eagerEmbedContent, embedAllMessages, embedMessage, encodeChunkVector, encryptData, encryptDataBatch, encryptDataBytes, encryptDataWithKey, ensureDefaultFoldersOp, expandToolSetsAdditive, exportElementToPdf, exportMarkdownToPdf, exportPublicKey, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, extractFileIds, fileExists, findById, findMatchingTools, findParentOfId, formatFileProcessingNotes, generateConversationId, generateEmbedding, generateEmbeddings, generateMediaId, generateProjectId, getAIGeneratedMediaOp, getAllSavedToolsOp, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getAndClearCalendarPendingMessage, getAndClearCalendarReturnUrl, getAndClearDrivePendingMessage, getAndClearDriveReturnUrl, getAndClearGithubPendingMessage, getAndClearGithubReturnUrl, getAndClearNotionPendingMessage, getAndClearNotionReturnUrl, getAppFileMapOp, getAppFileOp, getAppFilesOp, getAudioOp, getCachedServerTools, getCalendarAccessToken, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsByProjectOp, getConversationsLazyOp, getConversationsPageOp, getDecayCandidatesRawOp, getDocumentsOp, getDriveAccessToken, getEncryptionKey, getEntitiesByMemoryIdsOp, getGithubAccessToken, getGoogleDriveStoredToken, getId, getImagesOp, getLogger, getMediaByConversationOp, getMediaByIdOp, getMediaByIdsOp, getMediaByMessageOp, getMediaByModelOp, getMediaByRoleOp, getMediaBySourceUrlOp, getMediaByTypeOp, getMediaCountOp, getMediaCountsByTypeOp, getMediaOp, getMediaTypeFromMime, getMemoriesByEntityNamesOp, getMemoriesNeedingTopicExtractionOp, getNotionAccessToken, getNotionMCPUrl, getNumberAttr, getProjectConversationCountOp, getProjectConversationsOp, getProjectOp, getProjectsOp, getRecentMediaOp, getSavedToolByIdOp, getServerTools, getStringAttr, getSupportedFileTypes, getToolsChecksum, getUnfiledVaultMemoriesOp, getUserUploadedMediaOp, getValidCalendarToken, getValidDriveToken, getValidGithubToken, getValidNotionToken, getVaultCandidateKeysOp, getVaultEmbeddingsByIdsOp, getVaultFolderMemoryCountOp, getVaultMemoriesByIdsOp, getVaultMemoryOp, getVaultRankingProjectionsOp, getVideosOp, handleCalendarCallback, handleDriveCallback, handleGithubCallback, handleNotionCallback, hardDeleteDecayedOp, hardDeleteMediaOp, hasCalendarCredentials, hasDriveCredentials, hasDropboxCredentials, hasEncryptionKey, hasGithubCredentials, hasGoogleDriveCredentials, hasICloudCredentials, hasKeyPair, hasNotionCredentials, ingestPublishedPhotoMemoriesOp, injectionSignatureCatalog, insertAfterId, insertChild, isAnumaTag, isAttachedFilesText, isCalendarCallback, isDegradedTopicSkip, isDriveCallback, isEncrypted, isGithubCallback, isHtmlTag, isNotionCallback, isOPFSSupported, isR2UrlExpired, isRerankerAvailable, isSupportedFile, isSupportedMediaType, linkMemoryEntitiesOp, maskScopedEmbeddingCache, mediaToStored, migrateCalendarToken, migrateDisplayResult, migrateDriveToken, migrateGithubToken, migrateNotionClientRegistration, migrateNotionToken, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, parseJsx, parseMedia, preEmbedVaultMemories, preprocessFiles, previewToolSelection, projectToStored, putAppFileOp, quantizeEmbedding, queueManager, rankProfileCandidates, readEncryptedFile, recall, reflect, refreshCalendarToken, refreshDriveToken, refreshEncryptionKeyIfMatches, refreshGithubToken, refreshNotionToken, relinkMemoryTopicsOp, relinkMisclassifiedVideosOp, removeById, renderAnumaJsx, renderAnumaTree, renderElementToCanvas, replaceById, replaceMemoryEntitiesGuardedOp, requestEncryptionKey, requestKeyPair, resolveFilePlaceholders, resolveThemeColor, restoreVaultMemoryOp, resumeStream, retain, revokeCalendarToken, revokeDriveToken, revokeGithubToken, revokeNotionAccess, savedToolToStored, scoreProfileSalience, screenCandidatesForInjection, sdkMigrations, sdkModelClasses, sdkSchema, searchChunksOp, searchMediaOp, searchMessagesOp, searchVaultMemories, seedEncryptionKeys, selectServerToolsForPrompt, serializeJsx, setLogger, setMemoryEntitiesOp, setMemoryVisibilityOp, settingsStorageSchema, shouldChunkMessage, shouldRecallMemory, shouldRefreshTools, stampTopicsExtractedAtOp, startGithubAuth, startNotionAuth, storeCalendarPendingMessage, storeCalendarReturnUrl, storeCalendarToken, storeDrivePendingMessage, storeDriveReturnUrl, storeDriveToken, storeGithubPendingMessage, storeGithubReturnUrl, storeGithubToken, storeNotionPendingMessage, storeNotionReturnUrl, streamCancelPath, streamReplayPath, summarizeObservationTrends, supersedeVaultMemoryOp, synthesizeProfile, traverseGraphLane, ttlForType, updateAttrs, updateConversationProjectOp, updateMediaMessageIdBatchOp, updateMediaOp, updateMessageFeedbackOp, updateProjectNameOp, updateProjectOp, updateSavedToolOp, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, useAnumaTheme, useBackup, useBackupAuth, useChat, useChatStorage, useCredits, useDatabaseManager, useDropboxAuth, useDropboxBackup, useEncryption, useExportPdf, useFiles, useGoogleDriveAuth, useGoogleDriveBackup, useICloudAuth, useICloudBackup, useModels, useOCR, usePdf, usePhoneCalls, useProjects, useSettings, useSubscription, useTools, useUIInteraction, useVoice, useWalletBinding, userPreferencesStorageSchema, verifyMemoriesForPublish, walk, webPlatformStorage, withInternalFlowMarker, writeEncryptedFile };