@anuma/sdk 10.4.3 → 10.5.1
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/index.cjs +204 -14
- package/dist/expo/index.d.mts +20 -2
- package/dist/expo/index.d.ts +20 -2
- package/dist/expo/index.mjs +201 -14
- package/dist/index.cjs +69 -4
- package/dist/index.d.mts +20 -2
- package/dist/index.d.ts +20 -2
- package/dist/index.mjs +67 -4
- package/dist/react/{chunk-6ANL34M3.mjs → chunk-6QCUNXU6.mjs} +1 -0
- package/dist/react/{consolidate-JL4P6FXW.mjs → consolidate-RASCVKD2.mjs} +1 -1
- package/dist/react/index.cjs +259 -53
- package/dist/react/index.d.mts +20 -2
- package/dist/react/index.d.ts +20 -2
- package/dist/react/index.mjs +259 -55
- package/dist/server/{chunk-BIMEZT3O.mjs → chunk-JEY3L7WD.mjs} +1 -0
- package/dist/server/{consolidate-JZJYY3SZ.mjs → consolidate-5DFDLGSS.mjs} +1 -1
- package/dist/server/index.cjs +130 -6
- package/dist/server/index.mjs +132 -8
- package/package.json +1 -1
package/dist/expo/index.cjs
CHANGED
|
@@ -1597,6 +1597,7 @@ __export(index_exports, {
|
|
|
1597
1597
|
isEncrypted: () => isEncrypted,
|
|
1598
1598
|
isPiiRedactor: () => isPiiRedactor,
|
|
1599
1599
|
isRerankerAvailable: () => isRerankerAvailable,
|
|
1600
|
+
loadSettings: () => loadSettings,
|
|
1600
1601
|
localChatBackend: () => localChatBackend,
|
|
1601
1602
|
maskScopedEmbeddingCache: () => maskScopedEmbeddingCache,
|
|
1602
1603
|
maxVaultAttachmentBytes: () => maxVaultAttachmentBytes,
|
|
@@ -1625,6 +1626,7 @@ __export(index_exports, {
|
|
|
1625
1626
|
restoreVaultMemoryOp: () => restoreVaultMemoryOp,
|
|
1626
1627
|
resumeStream: () => resumeStream,
|
|
1627
1628
|
retain: () => retain,
|
|
1629
|
+
saveSetting: () => saveSetting,
|
|
1628
1630
|
scoreProfileSalience: () => scoreProfileSalience,
|
|
1629
1631
|
screenCandidatesForInjection: () => screenCandidatesForInjection,
|
|
1630
1632
|
sdkMigrations: () => sdkMigrations,
|
|
@@ -12727,7 +12729,7 @@ var ChatStoreError = class extends Error {
|
|
|
12727
12729
|
};
|
|
12728
12730
|
|
|
12729
12731
|
// src/lib/chatStore/remote.ts
|
|
12730
|
-
var kinds = /* @__PURE__ */ new Set(["conversation", "message", "summary", "project", "memory_links"]);
|
|
12732
|
+
var kinds = /* @__PURE__ */ new Set(["conversation", "message", "summary", "project", "memory_links", "setting"]);
|
|
12731
12733
|
var cipherPattern = /^enc:v\d+:(?:[0-9a-f]{2}){28,}$/i;
|
|
12732
12734
|
var maxPayload = 2 * 1024 * 1024;
|
|
12733
12735
|
var storedDims2 = 1536;
|
|
@@ -12783,9 +12785,12 @@ function validRecord(value) {
|
|
|
12783
12785
|
(key3) => ![...metadata, "data"].includes(key3)
|
|
12784
12786
|
))
|
|
12785
12787
|
return false;
|
|
12786
|
-
const root = value.kind
|
|
12788
|
+
const root = rootKind(value.kind);
|
|
12787
12789
|
return root ? value.conversationId === "" : id(value.conversationId);
|
|
12788
12790
|
}
|
|
12791
|
+
function rootKind(kind) {
|
|
12792
|
+
return kind === "conversation" || kind === "project" || kind === "setting";
|
|
12793
|
+
}
|
|
12789
12794
|
function embeddings(write) {
|
|
12790
12795
|
if (write.embeddings === void 0) return true;
|
|
12791
12796
|
return Array.isArray(write.embeddings) && !write.record.isDeleted && (write.record.kind === "message" || write.record.kind === "summary") && write.embeddings.length <= maxChunksPerRecord && (write.embeddingModel === void 0 || typeof write.embeddingModel === "string" && write.embeddingModel.length <= 256) && Array.from({ length: write.embeddings.length }, (_, i) => i).every(
|
|
@@ -12993,7 +12998,7 @@ async function createRemoteChatStore(options) {
|
|
|
12993
12998
|
async list(query) {
|
|
12994
12999
|
const limit = query.limit ?? 20;
|
|
12995
13000
|
const parent = query.conversationId ?? "";
|
|
12996
|
-
if (!kinds.has(query.kind) || !integer(limit, 1) || query.includeDeleted !== void 0 && typeof query.includeDeleted !== "boolean" || limit > 200 || (query.cursor?.length ?? 0) > 2048 || (query.kind
|
|
13001
|
+
if (!kinds.has(query.kind) || !integer(limit, 1) || query.includeDeleted !== void 0 && typeof query.includeDeleted !== "boolean" || limit > 200 || (query.cursor?.length ?? 0) > 2048 || (rootKind(query.kind) ? parent !== "" : !id(parent)))
|
|
12997
13002
|
invalid();
|
|
12998
13003
|
const params = new URLSearchParams({
|
|
12999
13004
|
account_id: String(accountId),
|
|
@@ -13136,10 +13141,12 @@ async function createRemoteChatStore(options) {
|
|
|
13136
13141
|
},
|
|
13137
13142
|
async changes(cursor, options2) {
|
|
13138
13143
|
const limit = options2?.limit ?? 100;
|
|
13139
|
-
|
|
13144
|
+
const kindsFilter = options2?.kinds;
|
|
13145
|
+
if (!integer(limit, 1) || limit > 200 || cursor !== void 0 && (!text5(cursor) || cursor.length > 2048) || kindsFilter !== void 0 && (!Array.isArray(kindsFilter) || kindsFilter.length === 0 || new Set(kindsFilter).size !== kindsFilter.length || kindsFilter.some((k) => !kinds.has(k))))
|
|
13140
13146
|
invalid();
|
|
13141
13147
|
const params = new URLSearchParams({ account_id: String(accountId), limit: String(limit) });
|
|
13142
13148
|
if (cursor) params.set("cursor", cursor);
|
|
13149
|
+
if (kindsFilter) params.set("kinds", kindsFilter.join(","));
|
|
13143
13150
|
const value = await request(`/changes?${params}`, {}, options2?.signal);
|
|
13144
13151
|
if (!object(value) || !Array.isArray(value.items) || value.items.length > limit || value.next_cursor !== void 0 && !text5(value.next_cursor) || value.changes_cursor !== void 0 && !text5(value.changes_cursor))
|
|
13145
13152
|
invalid();
|
|
@@ -13550,6 +13557,62 @@ async function migrateChatsToRemote(options) {
|
|
|
13550
13557
|
return passes(false);
|
|
13551
13558
|
}
|
|
13552
13559
|
|
|
13560
|
+
// src/lib/chatStore/settings.ts
|
|
13561
|
+
var maxSaveAttempts = 3;
|
|
13562
|
+
function toSetting(snapshot) {
|
|
13563
|
+
if (snapshot.record.isDeleted) return null;
|
|
13564
|
+
return {
|
|
13565
|
+
section: snapshot.record.id,
|
|
13566
|
+
data: snapshot.record.data,
|
|
13567
|
+
version: snapshot.version,
|
|
13568
|
+
createdAt: snapshot.record.createdAt,
|
|
13569
|
+
updatedAt: snapshot.record.updatedAt
|
|
13570
|
+
};
|
|
13571
|
+
}
|
|
13572
|
+
async function loadSettings(store, signal) {
|
|
13573
|
+
const out = /* @__PURE__ */ new Map();
|
|
13574
|
+
let cursor;
|
|
13575
|
+
do {
|
|
13576
|
+
const page = await store.list({ kind: "setting", limit: 100, cursor, signal });
|
|
13577
|
+
for (const item of page.items) {
|
|
13578
|
+
const setting = toSetting(item);
|
|
13579
|
+
if (setting) out.set(setting.section, setting);
|
|
13580
|
+
}
|
|
13581
|
+
cursor = page.nextCursor;
|
|
13582
|
+
} while (cursor);
|
|
13583
|
+
return out;
|
|
13584
|
+
}
|
|
13585
|
+
async function saveSetting(store, section, data, signal) {
|
|
13586
|
+
for (let attempt = 1; ; attempt++) {
|
|
13587
|
+
const current = await store.get("setting", section, signal);
|
|
13588
|
+
const now = Date.now();
|
|
13589
|
+
try {
|
|
13590
|
+
const [saved] = await store.putMany(
|
|
13591
|
+
[
|
|
13592
|
+
{
|
|
13593
|
+
record: {
|
|
13594
|
+
kind: "setting",
|
|
13595
|
+
id: section,
|
|
13596
|
+
conversationId: "",
|
|
13597
|
+
sortKey: 0,
|
|
13598
|
+
createdAt: current?.record.createdAt ?? now,
|
|
13599
|
+
updatedAt: Math.max(now, (current?.record.updatedAt ?? 0) + 1),
|
|
13600
|
+
isDeleted: false,
|
|
13601
|
+
data
|
|
13602
|
+
},
|
|
13603
|
+
expectedVersion: current?.version ?? 0
|
|
13604
|
+
}
|
|
13605
|
+
],
|
|
13606
|
+
signal
|
|
13607
|
+
);
|
|
13608
|
+
return toSetting(saved);
|
|
13609
|
+
} catch (error) {
|
|
13610
|
+
if (!(error instanceof ChatStoreError) || error.code !== "version_conflict" || attempt >= maxSaveAttempts)
|
|
13611
|
+
throw error;
|
|
13612
|
+
}
|
|
13613
|
+
}
|
|
13614
|
+
}
|
|
13615
|
+
|
|
13553
13616
|
// src/lib/chatStore/vaultAttachments.ts
|
|
13554
13617
|
var frameVersion = 1;
|
|
13555
13618
|
var ivBytes = 12;
|
|
@@ -19224,6 +19287,7 @@ init_logger();
|
|
|
19224
19287
|
init_redactor();
|
|
19225
19288
|
|
|
19226
19289
|
// src/lib/memory/entitySalience.ts
|
|
19290
|
+
init_patterns();
|
|
19227
19291
|
var GENERIC_ENTITY_NAMES = /* @__PURE__ */ new Set([
|
|
19228
19292
|
"today",
|
|
19229
19293
|
"tomorrow",
|
|
@@ -19369,6 +19433,125 @@ var WEAK_MODIFIERS = /* @__PURE__ */ new Set([
|
|
|
19369
19433
|
"and",
|
|
19370
19434
|
"or"
|
|
19371
19435
|
]);
|
|
19436
|
+
var MAX_ENTITY_NAME_LENGTH = 120;
|
|
19437
|
+
var MAX_ENTITY_NAME_TOKENS = 11;
|
|
19438
|
+
var PREFIXED_HEX = /^0x[0-9a-f]{16,}$/i;
|
|
19439
|
+
var BARE_HEX = /^[0-9a-f]{32,}$/i;
|
|
19440
|
+
var BASE58_STRING = /^[1-9A-HJ-NP-Za-km-z]{32,88}$/;
|
|
19441
|
+
var UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
19442
|
+
var TRUNCATED_ID = /^[0-9a-z]{3,}(?:…|\.{2,3})[0-9a-z]{3,}$/i;
|
|
19443
|
+
var KEY_SEGMENT_MIN_LENGTH = 16;
|
|
19444
|
+
var LONG_DIGIT_RUN = /^\d{6,}$/;
|
|
19445
|
+
var CURRENCY_MARKED = /[$€£¥₹₿]\d|\d[$€£¥₹₿]/;
|
|
19446
|
+
var NUMERIC_TOKEN = /^[~≈+\-−]?(?:us\$|[$€£¥₹₿])?\d(?:[\d,.]*\d)?(?:k|mm|m|bn|b|t|x|%|[$€£¥₹₿])?$/i;
|
|
19447
|
+
var PLAIN_YEAR = /^(?:1\d{3}|20\d{2})$/;
|
|
19448
|
+
var SUFFIXED_NAME = /^\d*[1-9][kmb]$/i;
|
|
19449
|
+
var BARE_INTEGER = /^\d+$/;
|
|
19450
|
+
var TICKER = /^\$?[A-Z]{2,6}$/;
|
|
19451
|
+
var DETACHED_CURRENCY_SYMBOL = /(^|\s)([$€£¥₹₿])\s+(?=\d)|(\d)\s+([$€£¥₹₿])(?=\s|$)/gu;
|
|
19452
|
+
var LEADING_PUNCTUATION = /^[^\p{L}\p{N}$€£¥₹₿~≈+\-−]+/u;
|
|
19453
|
+
var TRAILING_KEPT_CHARACTER = /[\p{L}\p{N}$€£¥₹₿%]/u;
|
|
19454
|
+
var LEADING_CURRENCY_CODES = /* @__PURE__ */ new Set(["usd", "eur", "gbp", "jpy", "cad", "aud", "chf", "cny"]);
|
|
19455
|
+
var QUANTITY_UNIT_WORDS = /* @__PURE__ */ new Set([
|
|
19456
|
+
"usd",
|
|
19457
|
+
"usdc",
|
|
19458
|
+
"usdt",
|
|
19459
|
+
"eur",
|
|
19460
|
+
"gbp",
|
|
19461
|
+
"sol",
|
|
19462
|
+
"eth",
|
|
19463
|
+
"btc",
|
|
19464
|
+
"dollar",
|
|
19465
|
+
"dollars",
|
|
19466
|
+
"euro",
|
|
19467
|
+
"euros",
|
|
19468
|
+
"buck",
|
|
19469
|
+
"bucks",
|
|
19470
|
+
"k",
|
|
19471
|
+
"thousand",
|
|
19472
|
+
"million",
|
|
19473
|
+
"billion",
|
|
19474
|
+
"trillion",
|
|
19475
|
+
"share",
|
|
19476
|
+
"shares",
|
|
19477
|
+
"token",
|
|
19478
|
+
"tokens",
|
|
19479
|
+
"coin",
|
|
19480
|
+
"coins",
|
|
19481
|
+
"unit",
|
|
19482
|
+
"units",
|
|
19483
|
+
"position",
|
|
19484
|
+
"balance",
|
|
19485
|
+
"stake",
|
|
19486
|
+
"holdings"
|
|
19487
|
+
]);
|
|
19488
|
+
var AMOUNT_WORDS = /* @__PURE__ */ new Set([...QUANTITY_UNIT_WORDS, "percent", "of"]);
|
|
19489
|
+
var NAME_PII_CATEGORIES = /* @__PURE__ */ new Set(["EMAIL", "PHONE", "SSN", "CREDIT_CARD"]);
|
|
19490
|
+
var NAME_PII_PATTERNS = PII_PATTERNS.filter(
|
|
19491
|
+
(pattern) => NAME_PII_CATEGORIES.has(pattern.category) && pattern.context === void 0
|
|
19492
|
+
);
|
|
19493
|
+
var KEPT_PLACEHOLDER_CATEGORIES = /* @__PURE__ */ new Set(["PERSON", "LOCATION", "ORG"]);
|
|
19494
|
+
var PLACEHOLDER_TOKEN = /\b([A-Za-z]+(?:_[A-Za-z]+)*)_\d+\b/g;
|
|
19495
|
+
function trimPunctuation(token) {
|
|
19496
|
+
const chars = Array.from(token.replace(LEADING_PUNCTUATION, ""));
|
|
19497
|
+
let end = chars.length;
|
|
19498
|
+
while (end > 0 && !TRAILING_KEPT_CHARACTER.test(chars[end - 1])) end--;
|
|
19499
|
+
return chars.slice(0, end).join("");
|
|
19500
|
+
}
|
|
19501
|
+
function hasLetterAndDigit(text16) {
|
|
19502
|
+
return /\p{L}/u.test(text16) && /\p{N}/u.test(text16);
|
|
19503
|
+
}
|
|
19504
|
+
function isIdentifierToken(token) {
|
|
19505
|
+
if (PREFIXED_HEX.test(token) || BARE_HEX.test(token) || BASE58_STRING.test(token)) return true;
|
|
19506
|
+
if (UUID.test(token) || LONG_DIGIT_RUN.test(token)) return true;
|
|
19507
|
+
if (TRUNCATED_ID.test(token) && hasLetterAndDigit(token)) return true;
|
|
19508
|
+
return token.split(/[-_.]/).some((segment) => segment.length >= KEY_SEGMENT_MIN_LENGTH && hasLetterAndDigit(segment));
|
|
19509
|
+
}
|
|
19510
|
+
function containsStructuredPii(name) {
|
|
19511
|
+
return NAME_PII_PATTERNS.some(
|
|
19512
|
+
(pattern) => (name.match(pattern.regex) ?? []).some((match) => pattern.validate?.(match) ?? true)
|
|
19513
|
+
);
|
|
19514
|
+
}
|
|
19515
|
+
function isAmountUnitToken(token) {
|
|
19516
|
+
return NUMERIC_TOKEN.test(token) || TICKER.test(token) || AMOUNT_WORDS.has(token.toLowerCase());
|
|
19517
|
+
}
|
|
19518
|
+
function isAmountWordOrNumber(token) {
|
|
19519
|
+
return NUMERIC_TOKEN.test(token) || AMOUNT_WORDS.has(token.toLowerCase());
|
|
19520
|
+
}
|
|
19521
|
+
function isAmount(tokens) {
|
|
19522
|
+
const start = LEADING_CURRENCY_CODES.has(tokens[0]?.toLowerCase() ?? "") ? 1 : 0;
|
|
19523
|
+
const first = tokens[start];
|
|
19524
|
+
if (first === void 0 || !NUMERIC_TOKEN.test(first)) return false;
|
|
19525
|
+
const units = tokens.slice(start + 1);
|
|
19526
|
+
if (start === 0 && units.length === 0)
|
|
19527
|
+
return !PLAIN_YEAR.test(first) && !SUFFIXED_NAME.test(first);
|
|
19528
|
+
if (!units.every(isAmountUnitToken)) return false;
|
|
19529
|
+
return start === 1 || !BARE_INTEGER.test(first) || units.some(isAmountWordOrNumber);
|
|
19530
|
+
}
|
|
19531
|
+
function hasQuantityPhrase(tokens) {
|
|
19532
|
+
return tokens.some(
|
|
19533
|
+
(token, i) => NUMERIC_TOKEN.test(token) && QUANTITY_UNIT_WORDS.has(tokens[i + 1]?.toLowerCase() ?? "")
|
|
19534
|
+
);
|
|
19535
|
+
}
|
|
19536
|
+
function isIdentifierOrAmountEntityName(name) {
|
|
19537
|
+
const trimmed = name.trim();
|
|
19538
|
+
if (trimmed.length > MAX_ENTITY_NAME_LENGTH) return true;
|
|
19539
|
+
if (containsStructuredPii(trimmed)) return true;
|
|
19540
|
+
const tokens = trimmed.replace(DETACHED_CURRENCY_SYMBOL, "$1$2$3$4").split(/\s+/).map(trimPunctuation).filter((token) => token.length > 0);
|
|
19541
|
+
if (tokens.length === 0) return false;
|
|
19542
|
+
if (tokens.length > MAX_ENTITY_NAME_TOKENS) return true;
|
|
19543
|
+
if (tokens.some(isIdentifierToken)) return true;
|
|
19544
|
+
if (tokens.some((token) => CURRENCY_MARKED.test(token))) return true;
|
|
19545
|
+
return isAmount(tokens) || hasQuantityPhrase(tokens);
|
|
19546
|
+
}
|
|
19547
|
+
function restoreEntityName(name, redactor) {
|
|
19548
|
+
for (const [token, category] of name.matchAll(PLACEHOLDER_TOKEN)) {
|
|
19549
|
+
if (KEPT_PLACEHOLDER_CATEGORIES.has(category.toUpperCase())) continue;
|
|
19550
|
+
if (redactor.restoreForStorage(token).text !== token) return null;
|
|
19551
|
+
}
|
|
19552
|
+
const restored = redactor.restoreForStorage(name);
|
|
19553
|
+
return restored.unresolved || isIdentifierOrAmountEntityName(restored.text) ? null : restored.text;
|
|
19554
|
+
}
|
|
19372
19555
|
|
|
19373
19556
|
// src/lib/memory/injectionClassifier.ts
|
|
19374
19557
|
init_logger();
|
|
@@ -22181,8 +22364,8 @@ function restoreCandidates(candidates, redactor, ownNames) {
|
|
|
22181
22364
|
...c,
|
|
22182
22365
|
content: content.text,
|
|
22183
22366
|
entities: c.entities.flatMap((e) => {
|
|
22184
|
-
const
|
|
22185
|
-
return
|
|
22367
|
+
const name = restoreEntityName(e.name, redactor);
|
|
22368
|
+
return name === null ? [] : [{ ...e, name }];
|
|
22186
22369
|
})
|
|
22187
22370
|
},
|
|
22188
22371
|
unresolved: content.unresolved
|
|
@@ -22450,18 +22633,21 @@ function validateCandidates(parsed, validIds, userIds, fallbackSourceId, ownName
|
|
|
22450
22633
|
}
|
|
22451
22634
|
return out;
|
|
22452
22635
|
}
|
|
22636
|
+
function isAcceptedEntityName(name) {
|
|
22637
|
+
return name.length > 0 && !isGenericEntityName(name) && !isIdentifierOrAmountEntityName(name);
|
|
22638
|
+
}
|
|
22453
22639
|
function parseEntities(raw) {
|
|
22454
22640
|
const out = [];
|
|
22455
22641
|
for (const e of raw) {
|
|
22456
22642
|
if (typeof e === "string") {
|
|
22457
22643
|
const name2 = e.trim();
|
|
22458
|
-
if (
|
|
22644
|
+
if (isAcceptedEntityName(name2)) out.push({ name: name2 });
|
|
22459
22645
|
continue;
|
|
22460
22646
|
}
|
|
22461
22647
|
if (typeof e !== "object" || e === null) continue;
|
|
22462
22648
|
const obj = e;
|
|
22463
22649
|
const name = typeof obj.name === "string" ? obj.name.trim() : "";
|
|
22464
|
-
if (
|
|
22650
|
+
if (!isAcceptedEntityName(name)) continue;
|
|
22465
22651
|
const kind = typeof obj.kind === "string" && ENTITY_KINDS.includes(obj.kind) ? obj.kind : void 0;
|
|
22466
22652
|
const weight = typeof obj.salience === "string" && Object.keys(TOPIC_SALIENCE_WEIGHTS).includes(obj.salience) ? TOPIC_SALIENCE_WEIGHTS[obj.salience] : void 0;
|
|
22467
22653
|
out.push({
|
|
@@ -24625,6 +24811,7 @@ Each memory is a short statement about the user. For each memory, list the NAMED
|
|
|
24625
24811
|
Include only NAMED entities, skip generic/common nouns. A topic must identify a specific thing the user could recognize by name; if it would be equally true of thousands of unrelated memories, leave it out:
|
|
24626
24812
|
- SKIP bare generic nouns even when the memory capitalizes them or a calendar entry is titled that way \u2014 "Home", "Work", "Meeting", "Lunch", "Birthday", "Appointment", "Trip", "Today", "Friday", "March" are NOT topics.
|
|
24627
24813
|
- KEEP the specific thing instead, when the memory names one: "Blue Bottle on Valencia" over "cafe", "Chicago Marathon" over "event", "Hollowpoint Labs" over "work".
|
|
24814
|
+
- SKIP identifiers and numbers \u2014 addresses, hashes, keys, account or order numbers, balances, prices, amounts and position sizes are NOT topics. Use the general subject instead: "Solana" or "trading" rather than "3.5 SOL" or an address.
|
|
24628
24815
|
- Prefer 0 entities over a weak one. A memory whose only candidate is a generic noun has NO entities.
|
|
24629
24816
|
${ENTITY_KIND_GUIDELINES}
|
|
24630
24817
|
|
|
@@ -24730,8 +24917,8 @@ List each memory's named entities.`,
|
|
|
24730
24917
|
}
|
|
24731
24918
|
function restoreEntities(entities, redactor) {
|
|
24732
24919
|
return entities.flatMap((e) => {
|
|
24733
|
-
const
|
|
24734
|
-
return
|
|
24920
|
+
const name = restoreEntityName(e.name, redactor);
|
|
24921
|
+
return name === null ? [] : [{ ...e, name }];
|
|
24735
24922
|
});
|
|
24736
24923
|
}
|
|
24737
24924
|
function parseTopicResponse(parsed, validIds) {
|
|
@@ -29915,6 +30102,7 @@ function useCredits(options = {}) {
|
|
|
29915
30102
|
const baseUrlRef = (0, import_react2.useRef)(baseUrl);
|
|
29916
30103
|
const onErrorRef = (0, import_react2.useRef)(onError);
|
|
29917
30104
|
const abortControllerRef = (0, import_react2.useRef)(null);
|
|
30105
|
+
const hasFetchedRef = (0, import_react2.useRef)(false);
|
|
29918
30106
|
(0, import_react2.useEffect)(() => {
|
|
29919
30107
|
getTokenRef.current = getToken;
|
|
29920
30108
|
baseUrlRef.current = baseUrl;
|
|
@@ -29922,6 +30110,7 @@ function useCredits(options = {}) {
|
|
|
29922
30110
|
});
|
|
29923
30111
|
(0, import_react2.useEffect)(() => {
|
|
29924
30112
|
return () => {
|
|
30113
|
+
hasFetchedRef.current = false;
|
|
29925
30114
|
if (abortControllerRef.current) {
|
|
29926
30115
|
abortControllerRef.current.abort();
|
|
29927
30116
|
abortControllerRef.current = null;
|
|
@@ -29969,14 +30158,14 @@ function useCredits(options = {}) {
|
|
|
29969
30158
|
headers,
|
|
29970
30159
|
signal
|
|
29971
30160
|
});
|
|
30161
|
+
if (signal.aborted) return;
|
|
29972
30162
|
if (response.error) {
|
|
29973
30163
|
const errorMsg = response.error.error ?? "Failed to fetch credit balance";
|
|
29974
|
-
throw new Error(errorMsg);
|
|
30164
|
+
throw Object.assign(new Error(errorMsg), { cause: response.error });
|
|
29975
30165
|
}
|
|
29976
|
-
if (signal.aborted) return;
|
|
29977
30166
|
setBalance(response.data ?? null);
|
|
29978
30167
|
} catch (err) {
|
|
29979
|
-
if (err instanceof Error && err.name === "AbortError") return;
|
|
30168
|
+
if (signal.aborted || err instanceof Error && err.name === "AbortError") return;
|
|
29980
30169
|
handleError(err);
|
|
29981
30170
|
} finally {
|
|
29982
30171
|
stopLoading();
|
|
@@ -30038,7 +30227,6 @@ function useCredits(options = {}) {
|
|
|
30038
30227
|
},
|
|
30039
30228
|
[getHeaders, handleError, startLoading, stopLoading]
|
|
30040
30229
|
);
|
|
30041
|
-
const hasFetchedRef = (0, import_react2.useRef)(false);
|
|
30042
30230
|
(0, import_react2.useEffect)(() => {
|
|
30043
30231
|
if (autoFetch && !hasFetchedRef.current) {
|
|
30044
30232
|
hasFetchedRef.current = true;
|
|
@@ -34561,6 +34749,7 @@ function useChatStorage(options) {
|
|
|
34561
34749
|
isEncrypted,
|
|
34562
34750
|
isPiiRedactor,
|
|
34563
34751
|
isRerankerAvailable,
|
|
34752
|
+
loadSettings,
|
|
34564
34753
|
localChatBackend,
|
|
34565
34754
|
maskScopedEmbeddingCache,
|
|
34566
34755
|
maxVaultAttachmentBytes,
|
|
@@ -34589,6 +34778,7 @@ function useChatStorage(options) {
|
|
|
34589
34778
|
restoreVaultMemoryOp,
|
|
34590
34779
|
resumeStream,
|
|
34591
34780
|
retain,
|
|
34781
|
+
saveSetting,
|
|
34592
34782
|
scoreProfileSalience,
|
|
34593
34783
|
screenCandidatesForInjection,
|
|
34594
34784
|
sdkMigrations,
|
package/dist/expo/index.d.mts
CHANGED
|
@@ -8264,7 +8264,7 @@ interface BaseUseChatStorageResult {
|
|
|
8264
8264
|
}
|
|
8265
8265
|
declare function generateConversationId(): string;
|
|
8266
8266
|
|
|
8267
|
-
type ChatRecordKind = "conversation" | "message" | "summary" | "project" | "memory_links";
|
|
8267
|
+
type ChatRecordKind = "conversation" | "message" | "summary" | "project" | "memory_links" | "setting";
|
|
8268
8268
|
type ChatJson = null | boolean | number | string | ChatJson[] | {
|
|
8269
8269
|
[key: string]: ChatJson;
|
|
8270
8270
|
};
|
|
@@ -8390,8 +8390,10 @@ interface ChatStore {
|
|
|
8390
8390
|
importRecords(records: readonly ChatImport[], signal?: AbortSignal): Promise<number>;
|
|
8391
8391
|
verify(revisions: readonly ChatRevision[], signal?: AbortSignal): Promise<ChatRef[]>;
|
|
8392
8392
|
activate(signal?: AbortSignal): Promise<boolean>;
|
|
8393
|
+
/** Without `kinds`, vault returns every kind except `setting`. */
|
|
8393
8394
|
changes(cursor?: string, options?: {
|
|
8394
8395
|
limit?: number;
|
|
8396
|
+
kinds?: readonly ChatRecordKind[];
|
|
8395
8397
|
signal?: AbortSignal;
|
|
8396
8398
|
}): Promise<ChatChanges>;
|
|
8397
8399
|
search(embedding: readonly number[], options?: ChatSearchOptions): Promise<ChatSearchHit[]>;
|
|
@@ -8462,6 +8464,22 @@ declare function migrateChatsToRemote(options: ChatMigrationOptions): Promise<Ch
|
|
|
8462
8464
|
/** Connect to owner-scoped server storage using the account's canonical device-held cipher. */
|
|
8463
8465
|
declare function createRemoteChatStore(options: RemoteChatStoreOptions): Promise<ChatStore>;
|
|
8464
8466
|
|
|
8467
|
+
interface Setting {
|
|
8468
|
+
section: string;
|
|
8469
|
+
data: {
|
|
8470
|
+
[key: string]: ChatJson;
|
|
8471
|
+
};
|
|
8472
|
+
version: number;
|
|
8473
|
+
createdAt: number;
|
|
8474
|
+
updatedAt: number;
|
|
8475
|
+
}
|
|
8476
|
+
/** Every stored settings section, keyed by section name. */
|
|
8477
|
+
declare function loadSettings(store: ChatStore, signal?: AbortSignal): Promise<Map<string, Setting>>;
|
|
8478
|
+
/** Replaces one section with `data`; the last save of a section wins across devices. */
|
|
8479
|
+
declare function saveSetting(store: ChatStore, section: string, data: {
|
|
8480
|
+
[key: string]: ChatJson;
|
|
8481
|
+
}, signal?: AbortSignal): Promise<Setting>;
|
|
8482
|
+
|
|
8465
8483
|
/**
|
|
8466
8484
|
* AES-GCM keys derived from one wallet signature over `SIGN_MESSAGE`.
|
|
8467
8485
|
* @public
|
|
@@ -12299,4 +12317,4 @@ interface UseChatStorageResult extends BaseUseChatStorageResult {
|
|
|
12299
12317
|
*/
|
|
12300
12318
|
declare function useChatStorage(options: UseChatStorageOptions): UseChatStorageResult;
|
|
12301
12319
|
|
|
12302
|
-
export { type AutoExtractMessage, type AutoExtractor, type Budget, CHUNKS_DISCARDED_ORIGIN, type CachedChunkVectors, type CachedServerTools, type ChatAccount, type ChatAccountState, type ChatAttachment, type ChatAttachments, type ChatBackend, type ChatBackendFactory, type ChatBackendSigner, type ChatCacheStorage, type ChatChanges, type ChatChunkSearchOptions, Conversation as ChatConversation, type ChatImport, type ChatJson, type ChatListOptions, Message as ChatMessage, type ChatMigrationOptions, type ChatMigrationProgress, type ChatMigrationResult, type ChatMigrationSkip, type ChatOutboxLocks, type ChatOutboxStorage, type ChatPage, type ChatPresignedUrl, type ChatRecord, type ChatRecordKind, type ChatRef, type ChatRevision, type ChatRole, type ChatSearchHit, type ChatSearchOptions, type ChatSnapshot, type ChatStore, ChatStoreError, type ChatWrite, type ChunkSearchStats, type ChunkVectorCache, type ChunkingOptions, type ConsolidationAction, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateDecaySweeperOptions, type CreateMessageOptions, type CreateSelectPaymentWalletToolOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CreateWalletPaymentToolOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_DECAY_POLICY, DEFAULT_MAX_CLASSIFIER_CALLS_PER_SWEEP, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_PROFILE_FACETS, DEFAULT_PROFILE_FACT_TYPE_WEIGHTS, DEFAULT_PROFILE_PROOF_ALPHA, DEFAULT_PROFILE_TREND_MULTIPLIERS, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type DecayCandidateRaw, type DecayClassifier, type DecayInput, type DecayPolicy, type DecaySweepResult, type DecaySweeper, type DecayVerdict, type DurableAutoExtractorOptions, ENTITY_FANOUT, type EmbeddedWalletSignerFn, type EmbeddingRepairOptions, type EmbeddingRepairResult, EncryptionKeyMissingError, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type ExtractionFunnel, type ExtractionMessageSource, type ExtractionSourceMessage, type ExtractionSourceStatus, type ExtractionTimings, type FactType, type FileMetadata, type FileProcessingReason, type FileProcessingStatus, type FlushResult, type GetConversationsPageOptions, type GetMessagesPageOptions, type GraphTraversalOptions, HARD_DELETE_WINDOW_MS, INFERENCE_ID_HEADER, type InjectionClassifierOptions, type InjectionReason, type LazyStoredConversation, type LlmDecayClassifierOptions, type LlmNeighborRefinerOptions, type LocalMemoryStoreOptions, type LocalMessageAttachment, type Logger, LoggerProvider, type LoggerProviderProps, MAX_HOPS, MEDIUM_TTL_MS, MEMORY_KINDS, MEMORY_LEVELS, type ManualFactType, type MemoriesNeedingTopicExtraction, type MemoryContextItem, type MemoryContextLane, type MemoryContextOptions, type MemoryContextResult, type MemoryCounts, type MemoryCreate, type MemoryDecay, type MemoryDecaySweeperOptions, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, MemoryKeyError, type MemoryKeyRing, type MemoryKind, type MemoryLevel, MemoryLevelError, type MemoryListOptions, type MemoryMaintenance, type MemoryMigrationOptions, type MemoryMigrationProgress, type MemoryMigrationResult, type MemoryMigrationSkip, type MemoryQuarantinedEvent, type MemoryRecallOptions, type MemoryRetainOptions, type MemoryStore, type MemorySubscribeOptions, type MemoryToVerify, type MemoryTopic, type MemoryTopicBacklog, type MemoryTopicMaintenance, type MemoryUpdate, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MemoryVerification, type MessageAttachmentMigrationOptions, type MessageAttachmentMigrationResult, type MessageRedactionResult, type MessageSkeleton, NEVER_TTL_MS, NODE_BUDGET, NOTION_OAUTH_CONFIG, type NeighborRefiner, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionMcpCaller, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, type NowSource, type ObservationTrend, type ObservationTrendInput, PAST_EVENT_GRACE_MS, PII_PATTERNS, PROFILE_DOC_VERSION, type PaymentWallet, type PhotoIngestResult, type PhotoMediaRef, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PortalLlmFailure, type PortalLlmFailureReason, type ProfileConfigFingerprint, type ProfileDoc, type ProfileFacet, type ProfileFacetKey, type ProfileSalienceInput, type ProfileSection, type PromptPreProcessor, type PromptPreProcessorContext, type PublishedPhotoMemory, type QuantizedEmbedding, type QuarantinedMemoryInfo, QueueManager, type QueueStatus, 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 RecallTelemetryCallbacks, type RecallToolCallbacks, type RecallToolOptions, type RecallTruncation, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, type RemoteChatStoreOptions, type RemoteMemoryCandidateOptions, type RemoteMemoryDecodeFailure, RemoteMemoryError, type RemoteMemoryListOptions, type RemoteMemoryMetadataPage, type RemoteMemoryMetadataRecord, type RemoteMemoryPage, RemoteMemoryPartialCreateError, type RemoteMemoryPersistence, type RemoteMemoryPersistenceOptions, type RemoteMemoryPipeline, type RemoteMemoryPipelineOptions, type RemoteMemoryQueryOptions, type RemoteMemoryQueryPage, type RemoteMemoryReadFilters, type RemoteMemoryRecord, type RemoteMemoryRow, type RemoteMemoryStoreOptions, type RemoteMemoryTopic, type RemoteMemoryWorkKind, type RemoteMemoryWorkLease, type RemoteMemoryWorkPersistence, type RemoteTopicPersistence, type RequestEncryptionKeyOptions, RerankerUnavailableError, type ReservationReceipt, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, SELECT_PAYMENT_WALLET_TOOL_NAME, SHORT_TTL_MS, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type ScoreProfileSalienceOptions, type ScreenResult, type ScreenedCandidate, type SearchSource, type SelectPaymentWalletResult, 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 StoredTopic, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, type StreamSmoothingConfig, type SynthesizeProfileOptions, TOOL_RESULT_ORIGIN, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, TOPIC_SALIENCE_WEIGHTS, TREND_RECENT_WINDOW_DAYS, TREND_STALE_WINDOW_DAYS, type TextChunk, type TopicExtractOptions, type TopicExtractionBatchDiagnostics, type TopicExtractionInput, type TopicExtractionRunResult, type TopicSalience, type TopicSkipReason, type TurnCompleteEvent, type TurnSkippedEvent, type UncheckedReason, type UnverifiableReason, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, VAULT_SIZE_HOP_CAP, type VaultAttachmentCache, type VaultAttachmentJournal, type VaultAttachmentOwner, type VaultAttachmentRef, type VaultAttachmentUploadOptions, type VaultAttachments, type VaultAttachmentsOptions, type VaultChatActivity, type VaultChatBackend, type VaultChatBackendOptions, type VaultChatEvent, type VaultEmbeddingCache, type VaultEmbeddingExpectation, type VaultFolderOperationsContext, type VaultMemoryKind, type VaultMemoryOperationsContext, type VaultMemoryProjection, type VaultMemoryVisibility, type VaultMemoryWriter, type VaultSaveOperation, type VaultSearchResult, type VaultWriteAction, type VaultWriteInput, type VaultWriteOutcome, type VerificationSources, type VerifyMemoriesForPublishOptions, WALLET_PAYMENT_TOOL_NAME, type WalletPaymentOutcome, type WalletPaymentPassenger, type WalletPaymentRequest, type WalletPaymentResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, type WriteFailureReason, addConversationMemoriesOp, archiveVaultMemoryOp, assembleMemoryContext, attachFileContextToLastUserMessage, backfillMemoryTopicsOp, buildAttachedFilesText, buildNotionAuthUrl, capHopsForDensity, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyDecay, classifyInjectionCandidates, classifyObservationTrend, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearModelsCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createDecaySweeper, createDurableAutoExtractor, createLlmDecayClassifier, createLlmNeighborRefiner, createLocalMemoryStore, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createMessageSourceResolver, createNotionProxyTools, createNotionTools, createPlatformCursorStore, createRecallTool, createRemoteChatStore, createRemoteMemoryPersistence, createRemoteMemoryPipeline, createRemoteMemoryStore, createSelectPaymentWalletTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultAttachments, createVaultChatBackend, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWalletPaymentTool, createWeatherPreProcessor, createWebSearchPreProcessor, decodeChunkVector, decryptConversationTitle, decryptMessageEmbeddingFields, deleteAllVaultMemoriesForUserOp, deleteMessageOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, deriveKeyFromSignatureBytes, deriveMemoryKeyRing, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, encodeChunkVector, encryptToolCallEventsOp, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, extractReservationReceipts, formatFileProcessingNotes, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getConversationsPageOp, getDecayCandidatesRawOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoriesByIdsOp, getVaultMemoryOp, getVaultRankingProjectionsOp, hardDeleteDecayedOp, hasEncryptionKey, ingestPublishedPhotoMemoriesOp, injectionSignatureCatalog, isAttachedFilesText, isDegradedTopicSkip, isEncrypted, isPiiRedactor, isRerankerAvailable, localChatBackend, maskScopedEmbeddingCache, maxVaultAttachmentBytes, memoryCipher, migrateChatsToRemote, migrateMemoriesToRemote, migrateMessageAttachments, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, parseMedia, preEmbedVaultMemories, primaryTopic, quantizeEmbedding, queueManager, rankProfileCandidates, recall, reencryptMemoryField, reflect, refreshEncryptionKeyIfMatches, refreshNotionAccessToken, registerNotionClient, relinkMemoryTopicsOp, requestEncryptionKey, resolvePiiRedactor, restoreVaultMemoryOp, resumeStream, retain, scoreProfileSalience, screenCandidatesForInjection, sdkMigrations, sdkModelClasses, sdkSchema, sealLegacyMessageEmbeddingsOp, searchVaultMemories, seedEncryptionKeys, setLogger, setMemoryVisibilityOp, shouldChunkMessage, shouldRecallMemory, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, stripLegacyChunkTextOp, summarizeObservationTrends, supersedeVaultMemoryOp, synthesizeProfile, topicWeight, traverseGraphLane, ttlForType, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, vaultAttachmentRefs, vaultChatBackend, verifyMemoriesForPublish, xhrTransport };
|
|
12320
|
+
export { type AutoExtractMessage, type AutoExtractor, type Budget, CHUNKS_DISCARDED_ORIGIN, type CachedChunkVectors, type CachedServerTools, type ChatAccount, type ChatAccountState, type ChatAttachment, type ChatAttachments, type ChatBackend, type ChatBackendFactory, type ChatBackendSigner, type ChatCacheStorage, type ChatChanges, type ChatChunkSearchOptions, Conversation as ChatConversation, type ChatImport, type ChatJson, type ChatListOptions, Message as ChatMessage, type ChatMigrationOptions, type ChatMigrationProgress, type ChatMigrationResult, type ChatMigrationSkip, type ChatOutboxLocks, type ChatOutboxStorage, type ChatPage, type ChatPresignedUrl, type ChatRecord, type ChatRecordKind, type ChatRef, type ChatRevision, type ChatRole, type ChatSearchHit, type ChatSearchOptions, type ChatSnapshot, type ChatStore, ChatStoreError, type ChatWrite, type ChunkSearchStats, type ChunkVectorCache, type ChunkingOptions, type ConsolidationAction, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateDecaySweeperOptions, type CreateMessageOptions, type CreateSelectPaymentWalletToolOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CreateWalletPaymentToolOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_DECAY_POLICY, DEFAULT_MAX_CLASSIFIER_CALLS_PER_SWEEP, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_PROFILE_FACETS, DEFAULT_PROFILE_FACT_TYPE_WEIGHTS, DEFAULT_PROFILE_PROOF_ALPHA, DEFAULT_PROFILE_TREND_MULTIPLIERS, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type DecayCandidateRaw, type DecayClassifier, type DecayInput, type DecayPolicy, type DecaySweepResult, type DecaySweeper, type DecayVerdict, type DurableAutoExtractorOptions, ENTITY_FANOUT, type EmbeddedWalletSignerFn, type EmbeddingRepairOptions, type EmbeddingRepairResult, EncryptionKeyMissingError, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type ExtractionFunnel, type ExtractionMessageSource, type ExtractionSourceMessage, type ExtractionSourceStatus, type ExtractionTimings, type FactType, type FileMetadata, type FileProcessingReason, type FileProcessingStatus, type FlushResult, type GetConversationsPageOptions, type GetMessagesPageOptions, type GraphTraversalOptions, HARD_DELETE_WINDOW_MS, INFERENCE_ID_HEADER, type InjectionClassifierOptions, type InjectionReason, type LazyStoredConversation, type LlmDecayClassifierOptions, type LlmNeighborRefinerOptions, type LocalMemoryStoreOptions, type LocalMessageAttachment, type Logger, LoggerProvider, type LoggerProviderProps, MAX_HOPS, MEDIUM_TTL_MS, MEMORY_KINDS, MEMORY_LEVELS, type ManualFactType, type MemoriesNeedingTopicExtraction, type MemoryContextItem, type MemoryContextLane, type MemoryContextOptions, type MemoryContextResult, type MemoryCounts, type MemoryCreate, type MemoryDecay, type MemoryDecaySweeperOptions, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, MemoryKeyError, type MemoryKeyRing, type MemoryKind, type MemoryLevel, MemoryLevelError, type MemoryListOptions, type MemoryMaintenance, type MemoryMigrationOptions, type MemoryMigrationProgress, type MemoryMigrationResult, type MemoryMigrationSkip, type MemoryQuarantinedEvent, type MemoryRecallOptions, type MemoryRetainOptions, type MemoryStore, type MemorySubscribeOptions, type MemoryToVerify, type MemoryTopic, type MemoryTopicBacklog, type MemoryTopicMaintenance, type MemoryUpdate, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MemoryVerification, type MessageAttachmentMigrationOptions, type MessageAttachmentMigrationResult, type MessageRedactionResult, type MessageSkeleton, NEVER_TTL_MS, NODE_BUDGET, NOTION_OAUTH_CONFIG, type NeighborRefiner, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionMcpCaller, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, type NowSource, type ObservationTrend, type ObservationTrendInput, PAST_EVENT_GRACE_MS, PII_PATTERNS, PROFILE_DOC_VERSION, type PaymentWallet, type PhotoIngestResult, type PhotoMediaRef, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PortalLlmFailure, type PortalLlmFailureReason, type ProfileConfigFingerprint, type ProfileDoc, type ProfileFacet, type ProfileFacetKey, type ProfileSalienceInput, type ProfileSection, type PromptPreProcessor, type PromptPreProcessorContext, type PublishedPhotoMemory, type QuantizedEmbedding, type QuarantinedMemoryInfo, QueueManager, type QueueStatus, 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 RecallTelemetryCallbacks, type RecallToolCallbacks, type RecallToolOptions, type RecallTruncation, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, type RemoteChatStoreOptions, type RemoteMemoryCandidateOptions, type RemoteMemoryDecodeFailure, RemoteMemoryError, type RemoteMemoryListOptions, type RemoteMemoryMetadataPage, type RemoteMemoryMetadataRecord, type RemoteMemoryPage, RemoteMemoryPartialCreateError, type RemoteMemoryPersistence, type RemoteMemoryPersistenceOptions, type RemoteMemoryPipeline, type RemoteMemoryPipelineOptions, type RemoteMemoryQueryOptions, type RemoteMemoryQueryPage, type RemoteMemoryReadFilters, type RemoteMemoryRecord, type RemoteMemoryRow, type RemoteMemoryStoreOptions, type RemoteMemoryTopic, type RemoteMemoryWorkKind, type RemoteMemoryWorkLease, type RemoteMemoryWorkPersistence, type RemoteTopicPersistence, type RequestEncryptionKeyOptions, RerankerUnavailableError, type ReservationReceipt, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, SELECT_PAYMENT_WALLET_TOOL_NAME, SHORT_TTL_MS, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type ScoreProfileSalienceOptions, type ScreenResult, type ScreenedCandidate, type SearchSource, type SelectPaymentWalletResult, type SendMessageWithStorageArgs, type SendMessageWithStorageDetachedResult, type SendMessageWithStorageResult, type ServerToolsOptions, type ServerToolsResponse, type Setting, type SignMessageFn, type StockPriceClassification, type StockPricePreProcessorOptions, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredMessage, type StoredMessageWithSimilarity, type StoredTopic, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, type StreamSmoothingConfig, type SynthesizeProfileOptions, TOOL_RESULT_ORIGIN, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, TOPIC_SALIENCE_WEIGHTS, TREND_RECENT_WINDOW_DAYS, TREND_STALE_WINDOW_DAYS, type TextChunk, type TopicExtractOptions, type TopicExtractionBatchDiagnostics, type TopicExtractionInput, type TopicExtractionRunResult, type TopicSalience, type TopicSkipReason, type TurnCompleteEvent, type TurnSkippedEvent, type UncheckedReason, type UnverifiableReason, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, VAULT_SIZE_HOP_CAP, type VaultAttachmentCache, type VaultAttachmentJournal, type VaultAttachmentOwner, type VaultAttachmentRef, type VaultAttachmentUploadOptions, type VaultAttachments, type VaultAttachmentsOptions, type VaultChatActivity, type VaultChatBackend, type VaultChatBackendOptions, type VaultChatEvent, type VaultEmbeddingCache, type VaultEmbeddingExpectation, type VaultFolderOperationsContext, type VaultMemoryKind, type VaultMemoryOperationsContext, type VaultMemoryProjection, type VaultMemoryVisibility, type VaultMemoryWriter, type VaultSaveOperation, type VaultSearchResult, type VaultWriteAction, type VaultWriteInput, type VaultWriteOutcome, type VerificationSources, type VerifyMemoriesForPublishOptions, WALLET_PAYMENT_TOOL_NAME, type WalletPaymentOutcome, type WalletPaymentPassenger, type WalletPaymentRequest, type WalletPaymentResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, type WriteFailureReason, addConversationMemoriesOp, archiveVaultMemoryOp, assembleMemoryContext, attachFileContextToLastUserMessage, backfillMemoryTopicsOp, buildAttachedFilesText, buildNotionAuthUrl, capHopsForDensity, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyDecay, classifyInjectionCandidates, classifyObservationTrend, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearModelsCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createDecaySweeper, createDurableAutoExtractor, createLlmDecayClassifier, createLlmNeighborRefiner, createLocalMemoryStore, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createMessageSourceResolver, createNotionProxyTools, createNotionTools, createPlatformCursorStore, createRecallTool, createRemoteChatStore, createRemoteMemoryPersistence, createRemoteMemoryPipeline, createRemoteMemoryStore, createSelectPaymentWalletTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultAttachments, createVaultChatBackend, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWalletPaymentTool, createWeatherPreProcessor, createWebSearchPreProcessor, decodeChunkVector, decryptConversationTitle, decryptMessageEmbeddingFields, deleteAllVaultMemoriesForUserOp, deleteMessageOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, deriveKeyFromSignatureBytes, deriveMemoryKeyRing, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, encodeChunkVector, encryptToolCallEventsOp, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, extractReservationReceipts, formatFileProcessingNotes, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getConversationsPageOp, getDecayCandidatesRawOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoriesByIdsOp, getVaultMemoryOp, getVaultRankingProjectionsOp, hardDeleteDecayedOp, hasEncryptionKey, ingestPublishedPhotoMemoriesOp, injectionSignatureCatalog, isAttachedFilesText, isDegradedTopicSkip, isEncrypted, isPiiRedactor, isRerankerAvailable, loadSettings, localChatBackend, maskScopedEmbeddingCache, maxVaultAttachmentBytes, memoryCipher, migrateChatsToRemote, migrateMemoriesToRemote, migrateMessageAttachments, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, parseMedia, preEmbedVaultMemories, primaryTopic, quantizeEmbedding, queueManager, rankProfileCandidates, recall, reencryptMemoryField, reflect, refreshEncryptionKeyIfMatches, refreshNotionAccessToken, registerNotionClient, relinkMemoryTopicsOp, requestEncryptionKey, resolvePiiRedactor, restoreVaultMemoryOp, resumeStream, retain, saveSetting, scoreProfileSalience, screenCandidatesForInjection, sdkMigrations, sdkModelClasses, sdkSchema, sealLegacyMessageEmbeddingsOp, searchVaultMemories, seedEncryptionKeys, setLogger, setMemoryVisibilityOp, shouldChunkMessage, shouldRecallMemory, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, stripLegacyChunkTextOp, summarizeObservationTrends, supersedeVaultMemoryOp, synthesizeProfile, topicWeight, traverseGraphLane, ttlForType, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, vaultAttachmentRefs, vaultChatBackend, verifyMemoriesForPublish, xhrTransport };
|
package/dist/expo/index.d.ts
CHANGED
|
@@ -8264,7 +8264,7 @@ interface BaseUseChatStorageResult {
|
|
|
8264
8264
|
}
|
|
8265
8265
|
declare function generateConversationId(): string;
|
|
8266
8266
|
|
|
8267
|
-
type ChatRecordKind = "conversation" | "message" | "summary" | "project" | "memory_links";
|
|
8267
|
+
type ChatRecordKind = "conversation" | "message" | "summary" | "project" | "memory_links" | "setting";
|
|
8268
8268
|
type ChatJson = null | boolean | number | string | ChatJson[] | {
|
|
8269
8269
|
[key: string]: ChatJson;
|
|
8270
8270
|
};
|
|
@@ -8390,8 +8390,10 @@ interface ChatStore {
|
|
|
8390
8390
|
importRecords(records: readonly ChatImport[], signal?: AbortSignal): Promise<number>;
|
|
8391
8391
|
verify(revisions: readonly ChatRevision[], signal?: AbortSignal): Promise<ChatRef[]>;
|
|
8392
8392
|
activate(signal?: AbortSignal): Promise<boolean>;
|
|
8393
|
+
/** Without `kinds`, vault returns every kind except `setting`. */
|
|
8393
8394
|
changes(cursor?: string, options?: {
|
|
8394
8395
|
limit?: number;
|
|
8396
|
+
kinds?: readonly ChatRecordKind[];
|
|
8395
8397
|
signal?: AbortSignal;
|
|
8396
8398
|
}): Promise<ChatChanges>;
|
|
8397
8399
|
search(embedding: readonly number[], options?: ChatSearchOptions): Promise<ChatSearchHit[]>;
|
|
@@ -8462,6 +8464,22 @@ declare function migrateChatsToRemote(options: ChatMigrationOptions): Promise<Ch
|
|
|
8462
8464
|
/** Connect to owner-scoped server storage using the account's canonical device-held cipher. */
|
|
8463
8465
|
declare function createRemoteChatStore(options: RemoteChatStoreOptions): Promise<ChatStore>;
|
|
8464
8466
|
|
|
8467
|
+
interface Setting {
|
|
8468
|
+
section: string;
|
|
8469
|
+
data: {
|
|
8470
|
+
[key: string]: ChatJson;
|
|
8471
|
+
};
|
|
8472
|
+
version: number;
|
|
8473
|
+
createdAt: number;
|
|
8474
|
+
updatedAt: number;
|
|
8475
|
+
}
|
|
8476
|
+
/** Every stored settings section, keyed by section name. */
|
|
8477
|
+
declare function loadSettings(store: ChatStore, signal?: AbortSignal): Promise<Map<string, Setting>>;
|
|
8478
|
+
/** Replaces one section with `data`; the last save of a section wins across devices. */
|
|
8479
|
+
declare function saveSetting(store: ChatStore, section: string, data: {
|
|
8480
|
+
[key: string]: ChatJson;
|
|
8481
|
+
}, signal?: AbortSignal): Promise<Setting>;
|
|
8482
|
+
|
|
8465
8483
|
/**
|
|
8466
8484
|
* AES-GCM keys derived from one wallet signature over `SIGN_MESSAGE`.
|
|
8467
8485
|
* @public
|
|
@@ -12299,4 +12317,4 @@ interface UseChatStorageResult extends BaseUseChatStorageResult {
|
|
|
12299
12317
|
*/
|
|
12300
12318
|
declare function useChatStorage(options: UseChatStorageOptions): UseChatStorageResult;
|
|
12301
12319
|
|
|
12302
|
-
export { type AutoExtractMessage, type AutoExtractor, type Budget, CHUNKS_DISCARDED_ORIGIN, type CachedChunkVectors, type CachedServerTools, type ChatAccount, type ChatAccountState, type ChatAttachment, type ChatAttachments, type ChatBackend, type ChatBackendFactory, type ChatBackendSigner, type ChatCacheStorage, type ChatChanges, type ChatChunkSearchOptions, Conversation as ChatConversation, type ChatImport, type ChatJson, type ChatListOptions, Message as ChatMessage, type ChatMigrationOptions, type ChatMigrationProgress, type ChatMigrationResult, type ChatMigrationSkip, type ChatOutboxLocks, type ChatOutboxStorage, type ChatPage, type ChatPresignedUrl, type ChatRecord, type ChatRecordKind, type ChatRef, type ChatRevision, type ChatRole, type ChatSearchHit, type ChatSearchOptions, type ChatSnapshot, type ChatStore, ChatStoreError, type ChatWrite, type ChunkSearchStats, type ChunkVectorCache, type ChunkingOptions, type ConsolidationAction, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateDecaySweeperOptions, type CreateMessageOptions, type CreateSelectPaymentWalletToolOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CreateWalletPaymentToolOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_DECAY_POLICY, DEFAULT_MAX_CLASSIFIER_CALLS_PER_SWEEP, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_PROFILE_FACETS, DEFAULT_PROFILE_FACT_TYPE_WEIGHTS, DEFAULT_PROFILE_PROOF_ALPHA, DEFAULT_PROFILE_TREND_MULTIPLIERS, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type DecayCandidateRaw, type DecayClassifier, type DecayInput, type DecayPolicy, type DecaySweepResult, type DecaySweeper, type DecayVerdict, type DurableAutoExtractorOptions, ENTITY_FANOUT, type EmbeddedWalletSignerFn, type EmbeddingRepairOptions, type EmbeddingRepairResult, EncryptionKeyMissingError, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type ExtractionFunnel, type ExtractionMessageSource, type ExtractionSourceMessage, type ExtractionSourceStatus, type ExtractionTimings, type FactType, type FileMetadata, type FileProcessingReason, type FileProcessingStatus, type FlushResult, type GetConversationsPageOptions, type GetMessagesPageOptions, type GraphTraversalOptions, HARD_DELETE_WINDOW_MS, INFERENCE_ID_HEADER, type InjectionClassifierOptions, type InjectionReason, type LazyStoredConversation, type LlmDecayClassifierOptions, type LlmNeighborRefinerOptions, type LocalMemoryStoreOptions, type LocalMessageAttachment, type Logger, LoggerProvider, type LoggerProviderProps, MAX_HOPS, MEDIUM_TTL_MS, MEMORY_KINDS, MEMORY_LEVELS, type ManualFactType, type MemoriesNeedingTopicExtraction, type MemoryContextItem, type MemoryContextLane, type MemoryContextOptions, type MemoryContextResult, type MemoryCounts, type MemoryCreate, type MemoryDecay, type MemoryDecaySweeperOptions, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, MemoryKeyError, type MemoryKeyRing, type MemoryKind, type MemoryLevel, MemoryLevelError, type MemoryListOptions, type MemoryMaintenance, type MemoryMigrationOptions, type MemoryMigrationProgress, type MemoryMigrationResult, type MemoryMigrationSkip, type MemoryQuarantinedEvent, type MemoryRecallOptions, type MemoryRetainOptions, type MemoryStore, type MemorySubscribeOptions, type MemoryToVerify, type MemoryTopic, type MemoryTopicBacklog, type MemoryTopicMaintenance, type MemoryUpdate, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MemoryVerification, type MessageAttachmentMigrationOptions, type MessageAttachmentMigrationResult, type MessageRedactionResult, type MessageSkeleton, NEVER_TTL_MS, NODE_BUDGET, NOTION_OAUTH_CONFIG, type NeighborRefiner, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionMcpCaller, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, type NowSource, type ObservationTrend, type ObservationTrendInput, PAST_EVENT_GRACE_MS, PII_PATTERNS, PROFILE_DOC_VERSION, type PaymentWallet, type PhotoIngestResult, type PhotoMediaRef, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PortalLlmFailure, type PortalLlmFailureReason, type ProfileConfigFingerprint, type ProfileDoc, type ProfileFacet, type ProfileFacetKey, type ProfileSalienceInput, type ProfileSection, type PromptPreProcessor, type PromptPreProcessorContext, type PublishedPhotoMemory, type QuantizedEmbedding, type QuarantinedMemoryInfo, QueueManager, type QueueStatus, 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 RecallTelemetryCallbacks, type RecallToolCallbacks, type RecallToolOptions, type RecallTruncation, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, type RemoteChatStoreOptions, type RemoteMemoryCandidateOptions, type RemoteMemoryDecodeFailure, RemoteMemoryError, type RemoteMemoryListOptions, type RemoteMemoryMetadataPage, type RemoteMemoryMetadataRecord, type RemoteMemoryPage, RemoteMemoryPartialCreateError, type RemoteMemoryPersistence, type RemoteMemoryPersistenceOptions, type RemoteMemoryPipeline, type RemoteMemoryPipelineOptions, type RemoteMemoryQueryOptions, type RemoteMemoryQueryPage, type RemoteMemoryReadFilters, type RemoteMemoryRecord, type RemoteMemoryRow, type RemoteMemoryStoreOptions, type RemoteMemoryTopic, type RemoteMemoryWorkKind, type RemoteMemoryWorkLease, type RemoteMemoryWorkPersistence, type RemoteTopicPersistence, type RequestEncryptionKeyOptions, RerankerUnavailableError, type ReservationReceipt, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, SELECT_PAYMENT_WALLET_TOOL_NAME, SHORT_TTL_MS, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type ScoreProfileSalienceOptions, type ScreenResult, type ScreenedCandidate, type SearchSource, type SelectPaymentWalletResult, 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 StoredTopic, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, type StreamSmoothingConfig, type SynthesizeProfileOptions, TOOL_RESULT_ORIGIN, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, TOPIC_SALIENCE_WEIGHTS, TREND_RECENT_WINDOW_DAYS, TREND_STALE_WINDOW_DAYS, type TextChunk, type TopicExtractOptions, type TopicExtractionBatchDiagnostics, type TopicExtractionInput, type TopicExtractionRunResult, type TopicSalience, type TopicSkipReason, type TurnCompleteEvent, type TurnSkippedEvent, type UncheckedReason, type UnverifiableReason, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, VAULT_SIZE_HOP_CAP, type VaultAttachmentCache, type VaultAttachmentJournal, type VaultAttachmentOwner, type VaultAttachmentRef, type VaultAttachmentUploadOptions, type VaultAttachments, type VaultAttachmentsOptions, type VaultChatActivity, type VaultChatBackend, type VaultChatBackendOptions, type VaultChatEvent, type VaultEmbeddingCache, type VaultEmbeddingExpectation, type VaultFolderOperationsContext, type VaultMemoryKind, type VaultMemoryOperationsContext, type VaultMemoryProjection, type VaultMemoryVisibility, type VaultMemoryWriter, type VaultSaveOperation, type VaultSearchResult, type VaultWriteAction, type VaultWriteInput, type VaultWriteOutcome, type VerificationSources, type VerifyMemoriesForPublishOptions, WALLET_PAYMENT_TOOL_NAME, type WalletPaymentOutcome, type WalletPaymentPassenger, type WalletPaymentRequest, type WalletPaymentResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, type WriteFailureReason, addConversationMemoriesOp, archiveVaultMemoryOp, assembleMemoryContext, attachFileContextToLastUserMessage, backfillMemoryTopicsOp, buildAttachedFilesText, buildNotionAuthUrl, capHopsForDensity, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyDecay, classifyInjectionCandidates, classifyObservationTrend, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearModelsCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createDecaySweeper, createDurableAutoExtractor, createLlmDecayClassifier, createLlmNeighborRefiner, createLocalMemoryStore, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createMessageSourceResolver, createNotionProxyTools, createNotionTools, createPlatformCursorStore, createRecallTool, createRemoteChatStore, createRemoteMemoryPersistence, createRemoteMemoryPipeline, createRemoteMemoryStore, createSelectPaymentWalletTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultAttachments, createVaultChatBackend, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWalletPaymentTool, createWeatherPreProcessor, createWebSearchPreProcessor, decodeChunkVector, decryptConversationTitle, decryptMessageEmbeddingFields, deleteAllVaultMemoriesForUserOp, deleteMessageOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, deriveKeyFromSignatureBytes, deriveMemoryKeyRing, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, encodeChunkVector, encryptToolCallEventsOp, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, extractReservationReceipts, formatFileProcessingNotes, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getConversationsPageOp, getDecayCandidatesRawOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoriesByIdsOp, getVaultMemoryOp, getVaultRankingProjectionsOp, hardDeleteDecayedOp, hasEncryptionKey, ingestPublishedPhotoMemoriesOp, injectionSignatureCatalog, isAttachedFilesText, isDegradedTopicSkip, isEncrypted, isPiiRedactor, isRerankerAvailable, localChatBackend, maskScopedEmbeddingCache, maxVaultAttachmentBytes, memoryCipher, migrateChatsToRemote, migrateMemoriesToRemote, migrateMessageAttachments, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, parseMedia, preEmbedVaultMemories, primaryTopic, quantizeEmbedding, queueManager, rankProfileCandidates, recall, reencryptMemoryField, reflect, refreshEncryptionKeyIfMatches, refreshNotionAccessToken, registerNotionClient, relinkMemoryTopicsOp, requestEncryptionKey, resolvePiiRedactor, restoreVaultMemoryOp, resumeStream, retain, scoreProfileSalience, screenCandidatesForInjection, sdkMigrations, sdkModelClasses, sdkSchema, sealLegacyMessageEmbeddingsOp, searchVaultMemories, seedEncryptionKeys, setLogger, setMemoryVisibilityOp, shouldChunkMessage, shouldRecallMemory, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, stripLegacyChunkTextOp, summarizeObservationTrends, supersedeVaultMemoryOp, synthesizeProfile, topicWeight, traverseGraphLane, ttlForType, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, vaultAttachmentRefs, vaultChatBackend, verifyMemoriesForPublish, xhrTransport };
|
|
12320
|
+
export { type AutoExtractMessage, type AutoExtractor, type Budget, CHUNKS_DISCARDED_ORIGIN, type CachedChunkVectors, type CachedServerTools, type ChatAccount, type ChatAccountState, type ChatAttachment, type ChatAttachments, type ChatBackend, type ChatBackendFactory, type ChatBackendSigner, type ChatCacheStorage, type ChatChanges, type ChatChunkSearchOptions, Conversation as ChatConversation, type ChatImport, type ChatJson, type ChatListOptions, Message as ChatMessage, type ChatMigrationOptions, type ChatMigrationProgress, type ChatMigrationResult, type ChatMigrationSkip, type ChatOutboxLocks, type ChatOutboxStorage, type ChatPage, type ChatPresignedUrl, type ChatRecord, type ChatRecordKind, type ChatRef, type ChatRevision, type ChatRole, type ChatSearchHit, type ChatSearchOptions, type ChatSnapshot, type ChatStore, ChatStoreError, type ChatWrite, type ChunkSearchStats, type ChunkVectorCache, type ChunkingOptions, type ConsolidationAction, type ConsolidationFallbackReason, type ConversationMemoryInput, ConversationMemory as ConversationMemoryModel, type ConversationMemoryOperationsContext, type CreateAutoExtractorOptions, type CreateConversationOptions, type CreateDecaySweeperOptions, type CreateMessageOptions, type CreateSelectPaymentWalletToolOptions, type CreateVaultFolderOptions, type CreateVaultMemoryOptions, type CreateWalletPaymentToolOptions, type CryptoPriceClassification, type CryptoPricePreProcessorOptions, DEFAULT_CACHE_EXPIRATION_MS, DEFAULT_CHUNK_CACHE_SIZE, DEFAULT_CHUNK_OVERLAP, DEFAULT_CHUNK_SIZE, DEFAULT_DECAY_POLICY, DEFAULT_MAX_CLASSIFIER_CALLS_PER_SWEEP, DEFAULT_MIN_CHUNK_SIZE, DEFAULT_PROFILE_FACETS, DEFAULT_PROFILE_FACT_TYPE_WEIGHTS, DEFAULT_PROFILE_PROOF_ALPHA, DEFAULT_PROFILE_TREND_MULTIPLIERS, DEFAULT_VAULT_CACHE_SIZE, DatabaseManager, type DatabaseManagerLogger, type DatabaseManagerOptions, type DecayCandidateRaw, type DecayClassifier, type DecayInput, type DecayPolicy, type DecaySweepResult, type DecaySweeper, type DecayVerdict, type DurableAutoExtractorOptions, ENTITY_FANOUT, type EmbeddedWalletSignerFn, type EmbeddingRepairOptions, type EmbeddingRepairResult, EncryptionKeyMissingError, type ExtractFactsOptions, type ExtractOutcome, type ExtractedCandidate, type ExtractedEntity, type ExtractionCursorStore, type ExtractionFunnel, type ExtractionMessageSource, type ExtractionSourceMessage, type ExtractionSourceStatus, type ExtractionTimings, type FactType, type FileMetadata, type FileProcessingReason, type FileProcessingStatus, type FlushResult, type GetConversationsPageOptions, type GetMessagesPageOptions, type GraphTraversalOptions, HARD_DELETE_WINDOW_MS, INFERENCE_ID_HEADER, type InjectionClassifierOptions, type InjectionReason, type LazyStoredConversation, type LlmDecayClassifierOptions, type LlmNeighborRefinerOptions, type LocalMemoryStoreOptions, type LocalMessageAttachment, type Logger, LoggerProvider, type LoggerProviderProps, MAX_HOPS, MEDIUM_TTL_MS, MEMORY_KINDS, MEMORY_LEVELS, type ManualFactType, type MemoriesNeedingTopicExtraction, type MemoryContextItem, type MemoryContextLane, type MemoryContextOptions, type MemoryContextResult, type MemoryCounts, type MemoryCreate, type MemoryDecay, type MemoryDecaySweeperOptions, type EmbeddingOptions as MemoryEngineEmbeddingOptions, type MemoryEngineResult, type MemoryEngineSearchOptions, type MemoryExtractedEvent, MemoryKeyError, type MemoryKeyRing, type MemoryKind, type MemoryLevel, MemoryLevelError, type MemoryListOptions, type MemoryMaintenance, type MemoryMigrationOptions, type MemoryMigrationProgress, type MemoryMigrationResult, type MemoryMigrationSkip, type MemoryQuarantinedEvent, type MemoryRecallOptions, type MemoryRetainOptions, type MemoryStore, type MemorySubscribeOptions, type MemoryToVerify, type MemoryTopic, type MemoryTopicBacklog, type MemoryTopicMaintenance, type MemoryUpdate, type MemoryVaultSearchOptions, type MemoryVaultToolOptions, type MemoryVerification, type MessageAttachmentMigrationOptions, type MessageAttachmentMigrationResult, type MessageRedactionResult, type MessageSkeleton, NEVER_TTL_MS, NODE_BUDGET, NOTION_OAUTH_CONFIG, type NeighborRefiner, type NotionAuthUrlParams, type NotionClientRegistration, type NotionExchangeCodeParams, type NotionMcpCaller, type NotionOAuthEndpoints, type NotionPKCEChallenge, type NotionRefreshTokenParams, type NotionTokenResponse, type NowSource, type ObservationTrend, type ObservationTrendInput, PAST_EVENT_GRACE_MS, PII_PATTERNS, PROFILE_DOC_VERSION, type PaymentWallet, type PhotoIngestResult, type PhotoMediaRef, type PiiCategory, type PiiMatch, type PiiPattern, PiiRedactor, type PiiRedactorOptions, type PlatformStorage, type PortalLlmAuth, type PortalLlmFailure, type PortalLlmFailureReason, type ProfileConfigFingerprint, type ProfileDoc, type ProfileFacet, type ProfileFacetKey, type ProfileSalienceInput, type ProfileSection, type PromptPreProcessor, type PromptPreProcessorContext, type PublishedPhotoMemory, type QuantizedEmbedding, type QuarantinedMemoryInfo, QueueManager, type QueueStatus, 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 RecallTelemetryCallbacks, type RecallToolCallbacks, type RecallToolOptions, type RecallTruncation, type RecencyOptions, type RedactionResult, type ReflectOptions, type ReflectResult, type RemoteChatStoreOptions, type RemoteMemoryCandidateOptions, type RemoteMemoryDecodeFailure, RemoteMemoryError, type RemoteMemoryListOptions, type RemoteMemoryMetadataPage, type RemoteMemoryMetadataRecord, type RemoteMemoryPage, RemoteMemoryPartialCreateError, type RemoteMemoryPersistence, type RemoteMemoryPersistenceOptions, type RemoteMemoryPipeline, type RemoteMemoryPipelineOptions, type RemoteMemoryQueryOptions, type RemoteMemoryQueryPage, type RemoteMemoryReadFilters, type RemoteMemoryRecord, type RemoteMemoryRow, type RemoteMemoryStoreOptions, type RemoteMemoryTopic, type RemoteMemoryWorkKind, type RemoteMemoryWorkLease, type RemoteMemoryWorkPersistence, type RemoteTopicPersistence, type RequestEncryptionKeyOptions, RerankerUnavailableError, type ReservationReceipt, type ResumeStreamOptions, type ResumeStreamResult, type ResumeStreamWithStorageResult, type RetainAction, type RetainContext, type RetainOptions, type RetainResult, type RetainSource, SDK_SCHEMA_VERSION, SELECT_PAYMENT_WALLET_TOOL_NAME, SHORT_TTL_MS, STREAM_RESUMABLE_HEADER, type ScoreBreakdown, type ScoreProfileSalienceOptions, type ScreenResult, type ScreenedCandidate, type SearchSource, type SelectPaymentWalletResult, type SendMessageWithStorageArgs, type SendMessageWithStorageDetachedResult, type SendMessageWithStorageResult, type ServerToolsOptions, type ServerToolsResponse, type Setting, type SignMessageFn, type StockPriceClassification, type StockPricePreProcessorOptions, type ChatCompletionUsage as StoredChatCompletionUsage, type StoredConversation, type StoredConversationMemory, type StoredMessage, type StoredMessageWithSimilarity, type StoredTopic, type StoredVaultFolder, VaultFolder as StoredVaultFolderModel, type StoredVaultMemory, VaultMemory as StoredVaultMemoryModel, StreamExpiredError, type StreamMetaEvent, type StreamResumeHandle, type StreamSmoothingConfig, type SynthesizeProfileOptions, TOOL_RESULT_ORIGIN, TOPICS_EXTRACTION_VERSION, TOPIC_EXTRACTION_BATCH_SIZE, TOPIC_SALIENCE_WEIGHTS, TREND_RECENT_WINDOW_DAYS, TREND_STALE_WINDOW_DAYS, type TextChunk, type TopicExtractOptions, type TopicExtractionBatchDiagnostics, type TopicExtractionInput, type TopicExtractionRunResult, type TopicSalience, type TopicSkipReason, type TurnCompleteEvent, type TurnSkippedEvent, type UncheckedReason, type UnverifiableReason, type UpdateVaultFolderOptions, type UpdateVaultMemoryOptions, type UseChatStorageOptions, type UseChatStorageResult, type UseCreditsOptions, type UseCreditsResult, type UseModelsOptions, type UseModelsResult, VAULT_SIZE_HOP_CAP, type VaultAttachmentCache, type VaultAttachmentJournal, type VaultAttachmentOwner, type VaultAttachmentRef, type VaultAttachmentUploadOptions, type VaultAttachments, type VaultAttachmentsOptions, type VaultChatActivity, type VaultChatBackend, type VaultChatBackendOptions, type VaultChatEvent, type VaultEmbeddingCache, type VaultEmbeddingExpectation, type VaultFolderOperationsContext, type VaultMemoryKind, type VaultMemoryOperationsContext, type VaultMemoryProjection, type VaultMemoryVisibility, type VaultMemoryWriter, type VaultSaveOperation, type VaultSearchResult, type VaultWriteAction, type VaultWriteInput, type VaultWriteOutcome, type VerificationSources, type VerifyMemoriesForPublishOptions, WALLET_PAYMENT_TOOL_NAME, type WalletPaymentOutcome, type WalletPaymentPassenger, type WalletPaymentRequest, type WalletPaymentResult, WalletPoller, type WeatherClassification, type WeatherPreProcessorOptions, type WebSearchClassification, type WebSearchPreProcessorOptions, type WriteFailureReason, addConversationMemoriesOp, archiveVaultMemoryOp, assembleMemoryContext, attachFileContextToLastUserMessage, backfillMemoryTopicsOp, buildAttachedFilesText, buildNotionAuthUrl, capHopsForDensity, chatStorageMigrations, chatStorageSchema, chunkAndEmbedAllMessages, chunkAndEmbedMessage, chunkText, classifyCryptoPrice, classifyCryptoPriceBatch, classifyDecay, classifyInjectionCandidates, classifyObservationTrend, classifyStockPrice, classifyStockPriceBatch, classifyWeather, classifyWeatherBatch, classifyWebSearch, classifyWebSearchBatch, clearAllEncryptionKeys, clearAllEncryptionState, clearConversationMemoriesOp, clearEncryptionKey, clearLazyTitleCache, clearModelsCache, clearServerToolsCache, consoleLogger, conversationMemoryToStored, cosineInt8, createAutoExtractor, createChunkVectorCache, createCryptoPricePreProcessor, createDecaySweeper, createDurableAutoExtractor, createLlmDecayClassifier, createLlmNeighborRefiner, createLocalMemoryStore, createMemoryEngineTool, createMemoryVaultSearchTool, createMemoryVaultTool, createMessageSourceResolver, createNotionProxyTools, createNotionTools, createPlatformCursorStore, createRecallTool, createRemoteChatStore, createRemoteMemoryPersistence, createRemoteMemoryPipeline, createRemoteMemoryStore, createSelectPaymentWalletTool, createStockPricePreProcessor, createStreamingDeAnonymizer, createVaultAttachments, createVaultChatBackend, createVaultEmbeddingCache, createVaultFolderOp, createVaultMemoriesBatchOp, createVaultMemoryOp, createWalletPaymentTool, createWeatherPreProcessor, createWebSearchPreProcessor, decodeChunkVector, decryptConversationTitle, decryptMessageEmbeddingFields, deleteAllVaultMemoriesForUserOp, deleteMessageOp, deleteVaultFolderOp, deleteVaultMemoryOp, dequantizeEmbedding, deriveKeyFromSignatureBytes, deriveMemoryKeyRing, discoverNotionOAuthEndpoints, eagerEmbedContent, embedAllMessages, embedMessage, encodeChunkVector, encryptToolCallEventsOp, ensureDefaultFoldersOp, exchangeNotionCode, extractAndLinkEntitiesForMemoriesOp, extractAndRetain, extractEntitiesForMemories, extractFacts, extractReservationReceipts, formatFileProcessingNotes, generateConversationId, generateEmbedding, generateEmbeddings, generateNotionPKCE, getAllVaultFoldersOp, getAllVaultMemoriesOp, getAllVaultMemoryContentsOp, getCachedServerTools, getConversationMemoriesOp, getConversationsByProjectLazyOp, getConversationsLazyOp, getConversationsPageOp, getDecayCandidatesRawOp, getLogger, getMemoriesNeedingTopicExtractionOp, getServerTools, getUnfiledVaultMemoriesOp, getVaultFolderMemoryCountOp, getVaultMemoriesByIdsOp, getVaultMemoryOp, getVaultRankingProjectionsOp, hardDeleteDecayedOp, hasEncryptionKey, ingestPublishedPhotoMemoriesOp, injectionSignatureCatalog, isAttachedFilesText, isDegradedTopicSkip, isEncrypted, isPiiRedactor, isRerankerAvailable, loadSettings, localChatBackend, maskScopedEmbeddingCache, maxVaultAttachmentBytes, memoryCipher, migrateChatsToRemote, migrateMemoriesToRemote, migrateMessageAttachments, moveMemoriesToFolderOp, noopLogger, onKeyAvailable, parseMedia, preEmbedVaultMemories, primaryTopic, quantizeEmbedding, queueManager, rankProfileCandidates, recall, reencryptMemoryField, reflect, refreshEncryptionKeyIfMatches, refreshNotionAccessToken, registerNotionClient, relinkMemoryTopicsOp, requestEncryptionKey, resolvePiiRedactor, restoreVaultMemoryOp, resumeStream, retain, saveSetting, scoreProfileSalience, screenCandidatesForInjection, sdkMigrations, sdkModelClasses, sdkSchema, sealLegacyMessageEmbeddingsOp, searchVaultMemories, seedEncryptionKeys, setLogger, setMemoryVisibilityOp, shouldChunkMessage, shouldRecallMemory, stampTopicsExtractedAtOp, streamCancelPath, streamReplayPath, stripLegacyChunkTextOp, summarizeObservationTrends, supersedeVaultMemoryOp, synthesizeProfile, topicWeight, traverseGraphLane, ttlForType, updateVaultFolderContextOp, updateVaultFolderOp, updateVaultMemoryEmbeddingOp, updateVaultMemoryOp, upsertMessageOp, useChat, useChatStorage, useCredits, useEncryption, useModels, vaultAttachmentRefs, vaultChatBackend, verifyMemoriesForPublish, xhrTransport };
|