@anuma/sdk 2.4.2 → 2.6.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/dist/expo/{chunk-UOUJUZM4.mjs → chunk-TCRDSUC6.mjs} +107 -5
- package/dist/expo/{consolidate-HEMQGOUD.mjs → consolidate-3QQPUWD6.mjs} +15 -9
- package/dist/expo/index.cjs +264 -70
- package/dist/expo/index.d.mts +77 -17
- package/dist/expo/index.d.ts +77 -17
- package/dist/expo/index.mjs +148 -58
- package/dist/{react/recall-G3CS444F.mjs → expo/recall-FQU3NUTL.mjs} +1 -1
- package/dist/react/{chunk-IYDQBFS2.mjs → chunk-ZXS3KOY4.mjs} +111 -6
- package/dist/react/{consolidate-IJH7LD2T.mjs → consolidate-3MXZV3G7.mjs} +15 -9
- package/dist/react/index.cjs +268 -71
- package/dist/react/index.d.mts +85 -20
- package/dist/react/index.d.ts +85 -20
- package/dist/react/index.mjs +148 -58
- package/dist/{expo/recall-HI7VO3VM.mjs → react/recall-PV7L3SN3.mjs} +1 -1
- package/dist/server/{chunk-3MLG7SUH.mjs → chunk-Z6II54I7.mjs} +107 -5
- package/dist/server/{consolidate-TDT4HRHG.mjs → consolidate-CN2GQV4D.mjs} +15 -9
- package/dist/server/index.cjs +264 -70
- package/dist/server/index.d.mts +77 -17
- package/dist/server/index.d.ts +77 -17
- package/dist/server/index.mjs +148 -58
- package/dist/server/{recall-MJHGXMHZ.mjs → recall-CQT24XLH.mjs} +1 -1
- package/package.json +1 -1
package/dist/expo/index.d.mts
CHANGED
|
@@ -4316,6 +4316,12 @@ declare class VaultMemory extends Model {
|
|
|
4316
4316
|
/** Unix ms of the last LLM topic-extraction pass. Null = never extracted
|
|
4317
4317
|
* standalone (linked legacy rows are grandfathered as extracted). */
|
|
4318
4318
|
topicsExtractedAt: number | null;
|
|
4319
|
+
/** A2 supersession: newer memory id that replaced this one, or null if live. */
|
|
4320
|
+
supersededBy: string | null;
|
|
4321
|
+
supersededAt: number | null;
|
|
4322
|
+
/** Extraction-logic version this memory was last stamped under. Null (pre-v38)
|
|
4323
|
+
* reads as 0, so a TOPICS_EXTRACTION_VERSION bump re-extracts stale rows. */
|
|
4324
|
+
topicsExtractedVersion: number | null;
|
|
4319
4325
|
createdAt: Date;
|
|
4320
4326
|
updatedAt: Date;
|
|
4321
4327
|
isDeleted: boolean;
|
|
@@ -4423,6 +4429,16 @@ interface StoredVaultMemory {
|
|
|
4423
4429
|
* Null = never extracted standalone; rows that already carry entity links
|
|
4424
4430
|
* are grandfathered as extracted (see getMemoriesNeedingTopicExtractionOp). */
|
|
4425
4431
|
topicsExtractedAt: number | null;
|
|
4432
|
+
/** Write-time supersession (A2): id of the newer memory that replaced this
|
|
4433
|
+
* one (incompatible-value update, e.g. "Lives in Portland" → "Lives in SF").
|
|
4434
|
+
* Null = live. Superseded rows are excluded from recall/dedup by default but
|
|
4435
|
+
* kept for history + the read-time fallback. */
|
|
4436
|
+
supersededBy: string | null;
|
|
4437
|
+
/** Unix ms when this memory was superseded. Null when live. */
|
|
4438
|
+
supersededAt: number | null;
|
|
4439
|
+
/** Extraction-logic version this memory was last stamped under. Null (pre-v38)
|
|
4440
|
+
* reads as 0, so a TOPICS_EXTRACTION_VERSION bump re-extracts stale rows. */
|
|
4441
|
+
topicsExtractedVersion: number | null;
|
|
4426
4442
|
createdAt: Date;
|
|
4427
4443
|
updatedAt: Date;
|
|
4428
4444
|
isDeleted: boolean;
|
|
@@ -4531,16 +4547,42 @@ declare function getAllVaultMemoriesOp(ctx: VaultMemoryOperationsContext, option
|
|
|
4531
4547
|
* render "forgotten" nodes; ordinary consumers should leave this off.
|
|
4532
4548
|
*/
|
|
4533
4549
|
includeDeleted?: boolean;
|
|
4550
|
+
/**
|
|
4551
|
+
* Include A2-superseded memories (each carries `supersededBy`). Default
|
|
4552
|
+
* `false` — superseded rows are excluded, as they are from recall/dedup.
|
|
4553
|
+
* Used by a "memory history" view to render retired facts.
|
|
4554
|
+
*/
|
|
4555
|
+
includeSuperseded?: boolean;
|
|
4534
4556
|
}): Promise<StoredVaultMemory[]>;
|
|
4535
4557
|
declare function getAllVaultMemoryContentsOp(ctx: VaultMemoryOperationsContext, options?: {
|
|
4536
4558
|
since?: Date;
|
|
4537
4559
|
}): Promise<string[]>;
|
|
4538
4560
|
declare function updateVaultMemoryOp(ctx: VaultMemoryOperationsContext, id: string, opts: UpdateVaultMemoryOptions): Promise<StoredVaultMemory | null>;
|
|
4539
4561
|
declare function deleteVaultMemoryOp(ctx: VaultMemoryOperationsContext, id: string): Promise<boolean>;
|
|
4562
|
+
/**
|
|
4563
|
+
* Mark a memory as superseded by a newer one (A2 write-time supersession).
|
|
4564
|
+
* The row stays in the table (history + read-time fallback) but is excluded
|
|
4565
|
+
* from recall/dedup by default via `superseded_by`. Idempotent-ish: no-op if
|
|
4566
|
+
* the row is missing, not owned, deleted, or already superseded. Does NOT
|
|
4567
|
+
* preserve `updated_at` — superseded rows are hidden from recall, so their
|
|
4568
|
+
* recency is irrelevant.
|
|
4569
|
+
*
|
|
4570
|
+
* @param id - the memory being retired (e.g. "Lives in Portland")
|
|
4571
|
+
* @param supersededById - the newer memory that replaced it (e.g. "Lives in SF")
|
|
4572
|
+
*/
|
|
4573
|
+
declare function supersedeVaultMemoryOp(ctx: VaultMemoryOperationsContext, id: string, supersededById: string): Promise<boolean>;
|
|
4540
4574
|
/**
|
|
4541
4575
|
* Get all non-deleted, unfiled vault memories (folder_id is null).
|
|
4542
4576
|
*/
|
|
4543
4577
|
declare function getUnfiledVaultMemoriesOp(ctx: VaultMemoryOperationsContext): Promise<StoredVaultMemory[]>;
|
|
4578
|
+
/**
|
|
4579
|
+
* The current topic-extraction logic version. Bump this whenever the extraction
|
|
4580
|
+
* prompt or model in `topicExtract.ts` changes: every memory stamped under an
|
|
4581
|
+
* older version (including pre-v37 rows, read as version 0) is then re-extracted
|
|
4582
|
+
* by the next sweep, so topic-quality improvements propagate across the existing
|
|
4583
|
+
* vault. The worker's `limit` drains that re-extraction across sweeps.
|
|
4584
|
+
*/
|
|
4585
|
+
declare const TOPICS_EXTRACTION_VERSION = 1;
|
|
4544
4586
|
/**
|
|
4545
4587
|
* Result of {@link getMemoriesNeedingTopicExtractionOp}: which memories the
|
|
4546
4588
|
* background topic worker should run LLM entity extraction on, and which it
|
|
@@ -4550,8 +4592,10 @@ interface MemoriesNeedingTopicExtraction {
|
|
|
4550
4592
|
/**
|
|
4551
4593
|
* Memories to run LLM topic extraction on (decrypted): never-extracted rows
|
|
4552
4594
|
* with no entity links, plus stamped rows edited since their last pass
|
|
4553
|
-
* (`updated_at` > `topics_extracted_at`)
|
|
4554
|
-
*
|
|
4595
|
+
* (`updated_at` > `topics_extracted_at`) or extracted under an older
|
|
4596
|
+
* `topics_extracted_version` than {@link TOPICS_EXTRACTION_VERSION}. Edited /
|
|
4597
|
+
* stale-version rows come first (they get priority under `limit`), each group
|
|
4598
|
+
* newest-created first.
|
|
4555
4599
|
*/
|
|
4556
4600
|
pending: StoredVaultMemory[];
|
|
4557
4601
|
/**
|
|
@@ -4575,13 +4619,16 @@ declare function getMemoriesNeedingTopicExtractionOp(ctx: VaultMemoryOperationsC
|
|
|
4575
4619
|
limit?: number;
|
|
4576
4620
|
}): Promise<MemoriesNeedingTopicExtraction>;
|
|
4577
4621
|
/**
|
|
4578
|
-
* Stamp `topics_extracted_at` on the given
|
|
4579
|
-
* this after a successful extraction pass
|
|
4580
|
-
* quiet memories aren't re-asked every sweep)
|
|
4581
|
-
* `linkedUnstamped` rows without an LLM call.
|
|
4582
|
-
*
|
|
4583
|
-
*
|
|
4584
|
-
*
|
|
4622
|
+
* Stamp `topics_extracted_at` (and `topics_extracted_version`) on the given
|
|
4623
|
+
* memories — the topic worker calls this after a successful extraction pass
|
|
4624
|
+
* (including zero-entity results, so quiet memories aren't re-asked every sweep)
|
|
4625
|
+
* and to grandfather `linkedUnstamped` rows without an LLM call. `version`
|
|
4626
|
+
* defaults to {@link TOPICS_EXTRACTION_VERSION}: stamping at the current version
|
|
4627
|
+
* (for both fresh extractions and grandfathered legacy rows) means they aren't
|
|
4628
|
+
* re-extracted until a future version bump. Preserves `updated_at` so a stamp
|
|
4629
|
+
* never inflates the recency multiplier — and never masks a concurrent content
|
|
4630
|
+
* edit from the next sweep. Skips deleted, foreign-user, and user-managed rows.
|
|
4631
|
+
* Returns the IDs actually stamped.
|
|
4585
4632
|
*
|
|
4586
4633
|
* ALL eligibility AND `updated_at` are read from the LIVE Model inside the
|
|
4587
4634
|
* serialized writer — never a pre-writer snapshot. Writers are serialized, so
|
|
@@ -4596,7 +4643,7 @@ declare function getMemoriesNeedingTopicExtractionOp(ctx: VaultMemoryOperationsC
|
|
|
4596
4643
|
* (both `pending` and `linkedUnstamped` are capped), so the per-row Model load
|
|
4597
4644
|
* needed to `prepareUpdate` stays bounded and never spikes the RecordCache.
|
|
4598
4645
|
*/
|
|
4599
|
-
declare function stampTopicsExtractedAtOp(ctx: VaultMemoryOperationsContext, memoryIds: readonly string[], extractedAt: number): Promise<string[]>;
|
|
4646
|
+
declare function stampTopicsExtractedAtOp(ctx: VaultMemoryOperationsContext, memoryIds: readonly string[], extractedAt: number, version?: number): Promise<string[]>;
|
|
4600
4647
|
declare function deleteAllVaultMemoriesForUserOp(ctx: VaultMemoryOperationsContext, userId: string): Promise<number>;
|
|
4601
4648
|
declare function updateVaultMemoryEmbeddingOp(ctx: VaultMemoryOperationsContext, id: string, embedding: string, embeddingModel: string): Promise<boolean>;
|
|
4602
4649
|
|
|
@@ -5183,7 +5230,7 @@ interface RecallDiagnostics {
|
|
|
5183
5230
|
/** Soft-degradation signals that fired this call (empty when clean). */
|
|
5184
5231
|
degraded: RecallDegradation[];
|
|
5185
5232
|
}
|
|
5186
|
-
type RetainAction = "create" | "merge" | "update" | "skip" | "suppressed";
|
|
5233
|
+
type RetainAction = "create" | "merge" | "update" | "skip" | "suppressed" | "supersede";
|
|
5187
5234
|
type RetainSource = "manual" | "auto-extracted" | "capsule";
|
|
5188
5235
|
/** Why the consolidator fell back to "create" instead of a real decision. */
|
|
5189
5236
|
type ConsolidationFallbackReason = "llm_error" | "invalid_response";
|
|
@@ -5249,7 +5296,8 @@ interface RetainOptions {
|
|
|
5249
5296
|
interface RetainResult {
|
|
5250
5297
|
action: RetainAction;
|
|
5251
5298
|
memoryId: string;
|
|
5252
|
-
/** When action is 'merge' or 'update', the prior memory's id.
|
|
5299
|
+
/** When action is 'merge' or 'update', the prior memory's id. When action is
|
|
5300
|
+
* 'supersede', the stale memory that was retired (`memoryId` is the new one). */
|
|
5253
5301
|
targetId?: string;
|
|
5254
5302
|
/**
|
|
5255
5303
|
* When action is 'suppressed', the id of the soft-deleted memory that blocked
|
|
@@ -5471,9 +5519,12 @@ declare function extractFacts(messages: AutoExtractMessage[], options: ExtractFa
|
|
|
5471
5519
|
type ExtractOutcome = "extracted" | "no-facts" | "empty-after-retry" | "dropped-after-redaction";
|
|
5472
5520
|
/**
|
|
5473
5521
|
* Stage 2 — for each extracted candidate, call retain() with auto-merge
|
|
5474
|
-
* enabled.
|
|
5475
|
-
*
|
|
5476
|
-
*
|
|
5522
|
+
* enabled. When `consolidateOptions` are wired, retain()'s consolidation pass
|
|
5523
|
+
* is the "resolver": a second LLM call against the top-K existing vault
|
|
5524
|
+
* memories that decides create/update/noop/supersede — including retiring a
|
|
5525
|
+
* stale value on a state change (the supersession the extraction prompt above
|
|
5526
|
+
* promises). Without consolidation, retain() still dedups at the cosine-merge
|
|
5527
|
+
* level, and the read-time supersession heuristic remains the fallback.
|
|
5477
5528
|
*
|
|
5478
5529
|
* Returns the candidates that survived validation along with the retain
|
|
5479
5530
|
* result for each (which captures whether the fact was created, merged,
|
|
@@ -6733,8 +6784,16 @@ declare function useChatStorage(options: UseChatStorageOptions): UseChatStorageR
|
|
|
6733
6784
|
* LLM topic-extraction pass, so the background topic worker re-extracts only
|
|
6734
6785
|
* memories edited since (updated_at > topics_extracted_at) instead of
|
|
6735
6786
|
* re-running the whole vault
|
|
6787
|
+
* - v37: Added superseded_by + superseded_at columns to memory_vault for
|
|
6788
|
+
* write-time supersession — a changed fact retires the stale one (points at
|
|
6789
|
+
* the newer memory) instead of both surviving; superseded rows are excluded
|
|
6790
|
+
* from recall/dedup by default
|
|
6791
|
+
* - v38: Added topics_extracted_version column to memory_vault — the extraction
|
|
6792
|
+
* logic version a memory was last stamped under. Bumping TOPICS_EXTRACTION_VERSION
|
|
6793
|
+
* (new prompt/model) makes the worker re-extract every row whose stored version
|
|
6794
|
+
* is behind, so topic-quality improvements propagate across the existing vault
|
|
6736
6795
|
*/
|
|
6737
|
-
declare const SDK_SCHEMA_VERSION =
|
|
6796
|
+
declare const SDK_SCHEMA_VERSION = 38;
|
|
6738
6797
|
/**
|
|
6739
6798
|
* Combined WatermelonDB schema for all SDK storage modules.
|
|
6740
6799
|
*
|
|
@@ -6814,6 +6873,7 @@ declare const sdkSchema: Readonly<{
|
|
|
6814
6873
|
* - v32 → v33: Added `embedding_model` column to memory_vault (null grandfathered as current-model-compatible)
|
|
6815
6874
|
* - v34 → v35: Added `conversation_memory` table (conversation ↔ recalled memory ids)
|
|
6816
6875
|
* - v35 → v36: Added `topics_extracted_at` column to memory_vault (watermark for the background topic-extraction worker; null + existing links grandfathered as extracted)
|
|
6876
|
+
* - v36 → v37: Added `superseded_by` + `superseded_at` columns to memory_vault (write-time supersession; null = live, excluded from recall/dedup when set)
|
|
6817
6877
|
*/
|
|
6818
6878
|
declare const sdkMigrations: Readonly<{
|
|
6819
6879
|
validated: true;
|
|
@@ -7335,4 +7395,4 @@ declare function refreshNotionAccessToken(params: NotionRefreshTokenParams): Pro
|
|
|
7335
7395
|
*/
|
|
7336
7396
|
declare function createNotionTools(getAccessToken: () => string | null, requestNotionAccess: () => Promise<string>): ToolConfig[];
|
|
7337
7397
|
|
|
7338
|
-
export { type AutoExtractMessage, type AutoExtractor, type Budget, type CachedChunkVectors, type CachedServerTools, Conversation as ChatConversation, Message as ChatMessage, type ChatRole, type ChunkVectorCache, type ChunkingOptions, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateMessageOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type EmbeddedWalletSignerFn, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type FactType, type FileMetadata, type FlushResult, type GetMessagesPageOptions, INFERENCE_ID_HEADER, type LazyStoredConversation, type Logger, LoggerProvider, type LoggerProviderProps, type MemoriesNeedingTopicExtraction, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, type MemoryKind, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MessageRedactionResult, type MessageSkeleton, NOTION_OAUTH_CONFIG, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, PII_PATTERNS, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PromptPreProcessor, type PromptPreProcessorContext, type QuantizedEmbedding, QueueManager, type QueueStatus, RECALL_MAX_LIMIT, RECALL_TOOL_NAME, type RankedMemory, type RecallContext, type RecallDegradation, type RecallDiagnostics, type RecallOptions, type RecallResult, type RecallToolCallbacks, type RecallToolOptions, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, RerankerUnavailableError, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type SearchSource, type SendMessageWithStorageArgs, type SendMessageWithStorageDetachedResult, type SendMessageWithStorageResult, type ServerToolsOptions, type ServerToolsResponse, type SignMessageFn, type StockPriceClassification, type StockPricePreProcessorOptions, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredMessage, type StoredMessageWithSimilarity, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, TOPIC_EXTRACTION_BATCH_SIZE, type TextChunk, type TopicExtractOptions, type TopicExtractionInput, type TopicExtractionRunResult, type TurnCompleteEvent, type TurnSkippedEvent, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, type VaultEmbeddingCache, type VaultFolderOperationsContext, type VaultMemoryOperationsContext, type VaultSaveOperation, type VaultSearchResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, addConversationMemoriesOp, buildNotionAuthUrl, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createNotionTools, createPlatformCursorStore, createRecallTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWeatherPreProcessor, createWebSearchPreProcessor, decryptConversationTitle, deleteAllVaultMemoriesForUserOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoryOp, hasEncryptionKey, isPiiRedactor, isRerankerAvailable, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, preEmbedVaultMemories, quantizeEmbedding, queueManager, recall, reflect, refreshNotionAccessToken, registerNotionClient, requestEncryptionKey, resolvePiiRedactor, resumeStream, retain, sdkMigrations, sdkModelClasses, sdkSchema, searchVaultMemories, setLogger, shouldChunkMessage, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, xhrTransport };
|
|
7398
|
+
export { type AutoExtractMessage, type AutoExtractor, type Budget, type CachedChunkVectors, type CachedServerTools, Conversation as ChatConversation, Message as ChatMessage, type ChatRole, type ChunkVectorCache, type ChunkingOptions, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateMessageOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type EmbeddedWalletSignerFn, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type FactType, type FileMetadata, type FlushResult, type GetMessagesPageOptions, INFERENCE_ID_HEADER, type LazyStoredConversation, type Logger, LoggerProvider, type LoggerProviderProps, type MemoriesNeedingTopicExtraction, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, type MemoryKind, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MessageRedactionResult, type MessageSkeleton, NOTION_OAUTH_CONFIG, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, PII_PATTERNS, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PromptPreProcessor, type PromptPreProcessorContext, type QuantizedEmbedding, QueueManager, type QueueStatus, RECALL_MAX_LIMIT, RECALL_TOOL_NAME, type RankedMemory, type RecallContext, type RecallDegradation, type RecallDiagnostics, type RecallOptions, type RecallResult, type RecallToolCallbacks, type RecallToolOptions, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, RerankerUnavailableError, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type SearchSource, type SendMessageWithStorageArgs, type SendMessageWithStorageDetachedResult, type SendMessageWithStorageResult, type ServerToolsOptions, type ServerToolsResponse, type SignMessageFn, type StockPriceClassification, type StockPricePreProcessorOptions, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredMessage, type StoredMessageWithSimilarity, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, type TextChunk, type TopicExtractOptions, type TopicExtractionInput, type TopicExtractionRunResult, type TurnCompleteEvent, type TurnSkippedEvent, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, type VaultEmbeddingCache, type VaultFolderOperationsContext, type VaultMemoryOperationsContext, type VaultSaveOperation, type VaultSearchResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, addConversationMemoriesOp, buildNotionAuthUrl, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createNotionTools, createPlatformCursorStore, createRecallTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWeatherPreProcessor, createWebSearchPreProcessor, decryptConversationTitle, deleteAllVaultMemoriesForUserOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoryOp, hasEncryptionKey, isPiiRedactor, isRerankerAvailable, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, preEmbedVaultMemories, quantizeEmbedding, queueManager, recall, reflect, refreshNotionAccessToken, registerNotionClient, requestEncryptionKey, resolvePiiRedactor, resumeStream, retain, sdkMigrations, sdkModelClasses, sdkSchema, searchVaultMemories, setLogger, shouldChunkMessage, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, supersedeVaultMemoryOp, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, xhrTransport };
|
package/dist/expo/index.d.ts
CHANGED
|
@@ -4316,6 +4316,12 @@ declare class VaultMemory extends Model {
|
|
|
4316
4316
|
/** Unix ms of the last LLM topic-extraction pass. Null = never extracted
|
|
4317
4317
|
* standalone (linked legacy rows are grandfathered as extracted). */
|
|
4318
4318
|
topicsExtractedAt: number | null;
|
|
4319
|
+
/** A2 supersession: newer memory id that replaced this one, or null if live. */
|
|
4320
|
+
supersededBy: string | null;
|
|
4321
|
+
supersededAt: number | null;
|
|
4322
|
+
/** Extraction-logic version this memory was last stamped under. Null (pre-v38)
|
|
4323
|
+
* reads as 0, so a TOPICS_EXTRACTION_VERSION bump re-extracts stale rows. */
|
|
4324
|
+
topicsExtractedVersion: number | null;
|
|
4319
4325
|
createdAt: Date;
|
|
4320
4326
|
updatedAt: Date;
|
|
4321
4327
|
isDeleted: boolean;
|
|
@@ -4423,6 +4429,16 @@ interface StoredVaultMemory {
|
|
|
4423
4429
|
* Null = never extracted standalone; rows that already carry entity links
|
|
4424
4430
|
* are grandfathered as extracted (see getMemoriesNeedingTopicExtractionOp). */
|
|
4425
4431
|
topicsExtractedAt: number | null;
|
|
4432
|
+
/** Write-time supersession (A2): id of the newer memory that replaced this
|
|
4433
|
+
* one (incompatible-value update, e.g. "Lives in Portland" → "Lives in SF").
|
|
4434
|
+
* Null = live. Superseded rows are excluded from recall/dedup by default but
|
|
4435
|
+
* kept for history + the read-time fallback. */
|
|
4436
|
+
supersededBy: string | null;
|
|
4437
|
+
/** Unix ms when this memory was superseded. Null when live. */
|
|
4438
|
+
supersededAt: number | null;
|
|
4439
|
+
/** Extraction-logic version this memory was last stamped under. Null (pre-v38)
|
|
4440
|
+
* reads as 0, so a TOPICS_EXTRACTION_VERSION bump re-extracts stale rows. */
|
|
4441
|
+
topicsExtractedVersion: number | null;
|
|
4426
4442
|
createdAt: Date;
|
|
4427
4443
|
updatedAt: Date;
|
|
4428
4444
|
isDeleted: boolean;
|
|
@@ -4531,16 +4547,42 @@ declare function getAllVaultMemoriesOp(ctx: VaultMemoryOperationsContext, option
|
|
|
4531
4547
|
* render "forgotten" nodes; ordinary consumers should leave this off.
|
|
4532
4548
|
*/
|
|
4533
4549
|
includeDeleted?: boolean;
|
|
4550
|
+
/**
|
|
4551
|
+
* Include A2-superseded memories (each carries `supersededBy`). Default
|
|
4552
|
+
* `false` — superseded rows are excluded, as they are from recall/dedup.
|
|
4553
|
+
* Used by a "memory history" view to render retired facts.
|
|
4554
|
+
*/
|
|
4555
|
+
includeSuperseded?: boolean;
|
|
4534
4556
|
}): Promise<StoredVaultMemory[]>;
|
|
4535
4557
|
declare function getAllVaultMemoryContentsOp(ctx: VaultMemoryOperationsContext, options?: {
|
|
4536
4558
|
since?: Date;
|
|
4537
4559
|
}): Promise<string[]>;
|
|
4538
4560
|
declare function updateVaultMemoryOp(ctx: VaultMemoryOperationsContext, id: string, opts: UpdateVaultMemoryOptions): Promise<StoredVaultMemory | null>;
|
|
4539
4561
|
declare function deleteVaultMemoryOp(ctx: VaultMemoryOperationsContext, id: string): Promise<boolean>;
|
|
4562
|
+
/**
|
|
4563
|
+
* Mark a memory as superseded by a newer one (A2 write-time supersession).
|
|
4564
|
+
* The row stays in the table (history + read-time fallback) but is excluded
|
|
4565
|
+
* from recall/dedup by default via `superseded_by`. Idempotent-ish: no-op if
|
|
4566
|
+
* the row is missing, not owned, deleted, or already superseded. Does NOT
|
|
4567
|
+
* preserve `updated_at` — superseded rows are hidden from recall, so their
|
|
4568
|
+
* recency is irrelevant.
|
|
4569
|
+
*
|
|
4570
|
+
* @param id - the memory being retired (e.g. "Lives in Portland")
|
|
4571
|
+
* @param supersededById - the newer memory that replaced it (e.g. "Lives in SF")
|
|
4572
|
+
*/
|
|
4573
|
+
declare function supersedeVaultMemoryOp(ctx: VaultMemoryOperationsContext, id: string, supersededById: string): Promise<boolean>;
|
|
4540
4574
|
/**
|
|
4541
4575
|
* Get all non-deleted, unfiled vault memories (folder_id is null).
|
|
4542
4576
|
*/
|
|
4543
4577
|
declare function getUnfiledVaultMemoriesOp(ctx: VaultMemoryOperationsContext): Promise<StoredVaultMemory[]>;
|
|
4578
|
+
/**
|
|
4579
|
+
* The current topic-extraction logic version. Bump this whenever the extraction
|
|
4580
|
+
* prompt or model in `topicExtract.ts` changes: every memory stamped under an
|
|
4581
|
+
* older version (including pre-v37 rows, read as version 0) is then re-extracted
|
|
4582
|
+
* by the next sweep, so topic-quality improvements propagate across the existing
|
|
4583
|
+
* vault. The worker's `limit` drains that re-extraction across sweeps.
|
|
4584
|
+
*/
|
|
4585
|
+
declare const TOPICS_EXTRACTION_VERSION = 1;
|
|
4544
4586
|
/**
|
|
4545
4587
|
* Result of {@link getMemoriesNeedingTopicExtractionOp}: which memories the
|
|
4546
4588
|
* background topic worker should run LLM entity extraction on, and which it
|
|
@@ -4550,8 +4592,10 @@ interface MemoriesNeedingTopicExtraction {
|
|
|
4550
4592
|
/**
|
|
4551
4593
|
* Memories to run LLM topic extraction on (decrypted): never-extracted rows
|
|
4552
4594
|
* with no entity links, plus stamped rows edited since their last pass
|
|
4553
|
-
* (`updated_at` > `topics_extracted_at`)
|
|
4554
|
-
*
|
|
4595
|
+
* (`updated_at` > `topics_extracted_at`) or extracted under an older
|
|
4596
|
+
* `topics_extracted_version` than {@link TOPICS_EXTRACTION_VERSION}. Edited /
|
|
4597
|
+
* stale-version rows come first (they get priority under `limit`), each group
|
|
4598
|
+
* newest-created first.
|
|
4555
4599
|
*/
|
|
4556
4600
|
pending: StoredVaultMemory[];
|
|
4557
4601
|
/**
|
|
@@ -4575,13 +4619,16 @@ declare function getMemoriesNeedingTopicExtractionOp(ctx: VaultMemoryOperationsC
|
|
|
4575
4619
|
limit?: number;
|
|
4576
4620
|
}): Promise<MemoriesNeedingTopicExtraction>;
|
|
4577
4621
|
/**
|
|
4578
|
-
* Stamp `topics_extracted_at` on the given
|
|
4579
|
-
* this after a successful extraction pass
|
|
4580
|
-
* quiet memories aren't re-asked every sweep)
|
|
4581
|
-
* `linkedUnstamped` rows without an LLM call.
|
|
4582
|
-
*
|
|
4583
|
-
*
|
|
4584
|
-
*
|
|
4622
|
+
* Stamp `topics_extracted_at` (and `topics_extracted_version`) on the given
|
|
4623
|
+
* memories — the topic worker calls this after a successful extraction pass
|
|
4624
|
+
* (including zero-entity results, so quiet memories aren't re-asked every sweep)
|
|
4625
|
+
* and to grandfather `linkedUnstamped` rows without an LLM call. `version`
|
|
4626
|
+
* defaults to {@link TOPICS_EXTRACTION_VERSION}: stamping at the current version
|
|
4627
|
+
* (for both fresh extractions and grandfathered legacy rows) means they aren't
|
|
4628
|
+
* re-extracted until a future version bump. Preserves `updated_at` so a stamp
|
|
4629
|
+
* never inflates the recency multiplier — and never masks a concurrent content
|
|
4630
|
+
* edit from the next sweep. Skips deleted, foreign-user, and user-managed rows.
|
|
4631
|
+
* Returns the IDs actually stamped.
|
|
4585
4632
|
*
|
|
4586
4633
|
* ALL eligibility AND `updated_at` are read from the LIVE Model inside the
|
|
4587
4634
|
* serialized writer — never a pre-writer snapshot. Writers are serialized, so
|
|
@@ -4596,7 +4643,7 @@ declare function getMemoriesNeedingTopicExtractionOp(ctx: VaultMemoryOperationsC
|
|
|
4596
4643
|
* (both `pending` and `linkedUnstamped` are capped), so the per-row Model load
|
|
4597
4644
|
* needed to `prepareUpdate` stays bounded and never spikes the RecordCache.
|
|
4598
4645
|
*/
|
|
4599
|
-
declare function stampTopicsExtractedAtOp(ctx: VaultMemoryOperationsContext, memoryIds: readonly string[], extractedAt: number): Promise<string[]>;
|
|
4646
|
+
declare function stampTopicsExtractedAtOp(ctx: VaultMemoryOperationsContext, memoryIds: readonly string[], extractedAt: number, version?: number): Promise<string[]>;
|
|
4600
4647
|
declare function deleteAllVaultMemoriesForUserOp(ctx: VaultMemoryOperationsContext, userId: string): Promise<number>;
|
|
4601
4648
|
declare function updateVaultMemoryEmbeddingOp(ctx: VaultMemoryOperationsContext, id: string, embedding: string, embeddingModel: string): Promise<boolean>;
|
|
4602
4649
|
|
|
@@ -5183,7 +5230,7 @@ interface RecallDiagnostics {
|
|
|
5183
5230
|
/** Soft-degradation signals that fired this call (empty when clean). */
|
|
5184
5231
|
degraded: RecallDegradation[];
|
|
5185
5232
|
}
|
|
5186
|
-
type RetainAction = "create" | "merge" | "update" | "skip" | "suppressed";
|
|
5233
|
+
type RetainAction = "create" | "merge" | "update" | "skip" | "suppressed" | "supersede";
|
|
5187
5234
|
type RetainSource = "manual" | "auto-extracted" | "capsule";
|
|
5188
5235
|
/** Why the consolidator fell back to "create" instead of a real decision. */
|
|
5189
5236
|
type ConsolidationFallbackReason = "llm_error" | "invalid_response";
|
|
@@ -5249,7 +5296,8 @@ interface RetainOptions {
|
|
|
5249
5296
|
interface RetainResult {
|
|
5250
5297
|
action: RetainAction;
|
|
5251
5298
|
memoryId: string;
|
|
5252
|
-
/** When action is 'merge' or 'update', the prior memory's id.
|
|
5299
|
+
/** When action is 'merge' or 'update', the prior memory's id. When action is
|
|
5300
|
+
* 'supersede', the stale memory that was retired (`memoryId` is the new one). */
|
|
5253
5301
|
targetId?: string;
|
|
5254
5302
|
/**
|
|
5255
5303
|
* When action is 'suppressed', the id of the soft-deleted memory that blocked
|
|
@@ -5471,9 +5519,12 @@ declare function extractFacts(messages: AutoExtractMessage[], options: ExtractFa
|
|
|
5471
5519
|
type ExtractOutcome = "extracted" | "no-facts" | "empty-after-retry" | "dropped-after-redaction";
|
|
5472
5520
|
/**
|
|
5473
5521
|
* Stage 2 — for each extracted candidate, call retain() with auto-merge
|
|
5474
|
-
* enabled.
|
|
5475
|
-
*
|
|
5476
|
-
*
|
|
5522
|
+
* enabled. When `consolidateOptions` are wired, retain()'s consolidation pass
|
|
5523
|
+
* is the "resolver": a second LLM call against the top-K existing vault
|
|
5524
|
+
* memories that decides create/update/noop/supersede — including retiring a
|
|
5525
|
+
* stale value on a state change (the supersession the extraction prompt above
|
|
5526
|
+
* promises). Without consolidation, retain() still dedups at the cosine-merge
|
|
5527
|
+
* level, and the read-time supersession heuristic remains the fallback.
|
|
5477
5528
|
*
|
|
5478
5529
|
* Returns the candidates that survived validation along with the retain
|
|
5479
5530
|
* result for each (which captures whether the fact was created, merged,
|
|
@@ -6733,8 +6784,16 @@ declare function useChatStorage(options: UseChatStorageOptions): UseChatStorageR
|
|
|
6733
6784
|
* LLM topic-extraction pass, so the background topic worker re-extracts only
|
|
6734
6785
|
* memories edited since (updated_at > topics_extracted_at) instead of
|
|
6735
6786
|
* re-running the whole vault
|
|
6787
|
+
* - v37: Added superseded_by + superseded_at columns to memory_vault for
|
|
6788
|
+
* write-time supersession — a changed fact retires the stale one (points at
|
|
6789
|
+
* the newer memory) instead of both surviving; superseded rows are excluded
|
|
6790
|
+
* from recall/dedup by default
|
|
6791
|
+
* - v38: Added topics_extracted_version column to memory_vault — the extraction
|
|
6792
|
+
* logic version a memory was last stamped under. Bumping TOPICS_EXTRACTION_VERSION
|
|
6793
|
+
* (new prompt/model) makes the worker re-extract every row whose stored version
|
|
6794
|
+
* is behind, so topic-quality improvements propagate across the existing vault
|
|
6736
6795
|
*/
|
|
6737
|
-
declare const SDK_SCHEMA_VERSION =
|
|
6796
|
+
declare const SDK_SCHEMA_VERSION = 38;
|
|
6738
6797
|
/**
|
|
6739
6798
|
* Combined WatermelonDB schema for all SDK storage modules.
|
|
6740
6799
|
*
|
|
@@ -6814,6 +6873,7 @@ declare const sdkSchema: Readonly<{
|
|
|
6814
6873
|
* - v32 → v33: Added `embedding_model` column to memory_vault (null grandfathered as current-model-compatible)
|
|
6815
6874
|
* - v34 → v35: Added `conversation_memory` table (conversation ↔ recalled memory ids)
|
|
6816
6875
|
* - v35 → v36: Added `topics_extracted_at` column to memory_vault (watermark for the background topic-extraction worker; null + existing links grandfathered as extracted)
|
|
6876
|
+
* - v36 → v37: Added `superseded_by` + `superseded_at` columns to memory_vault (write-time supersession; null = live, excluded from recall/dedup when set)
|
|
6817
6877
|
*/
|
|
6818
6878
|
declare const sdkMigrations: Readonly<{
|
|
6819
6879
|
validated: true;
|
|
@@ -7335,4 +7395,4 @@ declare function refreshNotionAccessToken(params: NotionRefreshTokenParams): Pro
|
|
|
7335
7395
|
*/
|
|
7336
7396
|
declare function createNotionTools(getAccessToken: () => string | null, requestNotionAccess: () => Promise<string>): ToolConfig[];
|
|
7337
7397
|
|
|
7338
|
-
export { type AutoExtractMessage, type AutoExtractor, type Budget, type CachedChunkVectors, type CachedServerTools, Conversation as ChatConversation, Message as ChatMessage, type ChatRole, type ChunkVectorCache, type ChunkingOptions, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateMessageOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type EmbeddedWalletSignerFn, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type FactType, type FileMetadata, type FlushResult, type GetMessagesPageOptions, INFERENCE_ID_HEADER, type LazyStoredConversation, type Logger, LoggerProvider, type LoggerProviderProps, type MemoriesNeedingTopicExtraction, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, type MemoryKind, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MessageRedactionResult, type MessageSkeleton, NOTION_OAUTH_CONFIG, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, PII_PATTERNS, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PromptPreProcessor, type PromptPreProcessorContext, type QuantizedEmbedding, QueueManager, type QueueStatus, RECALL_MAX_LIMIT, RECALL_TOOL_NAME, type RankedMemory, type RecallContext, type RecallDegradation, type RecallDiagnostics, type RecallOptions, type RecallResult, type RecallToolCallbacks, type RecallToolOptions, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, RerankerUnavailableError, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type SearchSource, type SendMessageWithStorageArgs, type SendMessageWithStorageDetachedResult, type SendMessageWithStorageResult, type ServerToolsOptions, type ServerToolsResponse, type SignMessageFn, type StockPriceClassification, type StockPricePreProcessorOptions, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredMessage, type StoredMessageWithSimilarity, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, TOPIC_EXTRACTION_BATCH_SIZE, type TextChunk, type TopicExtractOptions, type TopicExtractionInput, type TopicExtractionRunResult, type TurnCompleteEvent, type TurnSkippedEvent, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, type VaultEmbeddingCache, type VaultFolderOperationsContext, type VaultMemoryOperationsContext, type VaultSaveOperation, type VaultSearchResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, addConversationMemoriesOp, buildNotionAuthUrl, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createNotionTools, createPlatformCursorStore, createRecallTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWeatherPreProcessor, createWebSearchPreProcessor, decryptConversationTitle, deleteAllVaultMemoriesForUserOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoryOp, hasEncryptionKey, isPiiRedactor, isRerankerAvailable, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, preEmbedVaultMemories, quantizeEmbedding, queueManager, recall, reflect, refreshNotionAccessToken, registerNotionClient, requestEncryptionKey, resolvePiiRedactor, resumeStream, retain, sdkMigrations, sdkModelClasses, sdkSchema, searchVaultMemories, setLogger, shouldChunkMessage, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, xhrTransport };
|
|
7398
|
+
export { type AutoExtractMessage, type AutoExtractor, type Budget, type CachedChunkVectors, type CachedServerTools, Conversation as ChatConversation, Message as ChatMessage, type ChatRole, type ChunkVectorCache, type ChunkingOptions, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateMessageOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type EmbeddedWalletSignerFn, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type FactType, type FileMetadata, type FlushResult, type GetMessagesPageOptions, INFERENCE_ID_HEADER, type LazyStoredConversation, type Logger, LoggerProvider, type LoggerProviderProps, type MemoriesNeedingTopicExtraction, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, type MemoryKind, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MessageRedactionResult, type MessageSkeleton, NOTION_OAUTH_CONFIG, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, PII_PATTERNS, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PromptPreProcessor, type PromptPreProcessorContext, type QuantizedEmbedding, QueueManager, type QueueStatus, RECALL_MAX_LIMIT, RECALL_TOOL_NAME, type RankedMemory, type RecallContext, type RecallDegradation, type RecallDiagnostics, type RecallOptions, type RecallResult, type RecallToolCallbacks, type RecallToolOptions, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, RerankerUnavailableError, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type SearchSource, type SendMessageWithStorageArgs, type SendMessageWithStorageDetachedResult, type SendMessageWithStorageResult, type ServerToolsOptions, type ServerToolsResponse, type SignMessageFn, type StockPriceClassification, type StockPricePreProcessorOptions, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredMessage, type StoredMessageWithSimilarity, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, type TextChunk, type TopicExtractOptions, type TopicExtractionInput, type TopicExtractionRunResult, type TurnCompleteEvent, type TurnSkippedEvent, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, type VaultEmbeddingCache, type VaultFolderOperationsContext, type VaultMemoryOperationsContext, type VaultSaveOperation, type VaultSearchResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, addConversationMemoriesOp, buildNotionAuthUrl, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createNotionTools, createPlatformCursorStore, createRecallTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWeatherPreProcessor, createWebSearchPreProcessor, decryptConversationTitle, deleteAllVaultMemoriesForUserOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoryOp, hasEncryptionKey, isPiiRedactor, isRerankerAvailable, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, preEmbedVaultMemories, quantizeEmbedding, queueManager, recall, reflect, refreshNotionAccessToken, registerNotionClient, requestEncryptionKey, resolvePiiRedactor, resumeStream, retain, sdkMigrations, sdkModelClasses, sdkSchema, searchVaultMemories, setLogger, shouldChunkMessage, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, supersedeVaultMemoryOp, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, xhrTransport };
|