@anuma/sdk 6.42.0 → 6.42.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 +10 -14
- package/dist/expo/index.d.mts +2 -0
- package/dist/expo/index.d.ts +2 -0
- package/dist/expo/index.mjs +10 -14
- package/dist/react/index.cjs +10 -14
- package/dist/react/index.d.mts +2 -0
- package/dist/react/index.d.ts +2 -0
- package/dist/react/index.mjs +10 -14
- package/package.json +1 -1
package/dist/expo/index.cjs
CHANGED
|
@@ -20196,6 +20196,8 @@ var queryFields = [
|
|
|
20196
20196
|
"memory_ids",
|
|
20197
20197
|
"topics",
|
|
20198
20198
|
"updated_after",
|
|
20199
|
+
"topics_due",
|
|
20200
|
+
"topics_extracted",
|
|
20199
20201
|
"order",
|
|
20200
20202
|
"cursor",
|
|
20201
20203
|
"limit",
|
|
@@ -21083,11 +21085,6 @@ function sameTopics(stored2, next) {
|
|
|
21083
21085
|
const keys = new Set(stored2.map(key));
|
|
21084
21086
|
return next.every((t) => keys.has(key(t)));
|
|
21085
21087
|
}
|
|
21086
|
-
function extractionDue(memory) {
|
|
21087
|
-
const stamp = memory.topics_extracted_at;
|
|
21088
|
-
if (stamp === void 0 || stamp === null) return "fresh";
|
|
21089
|
-
return memory.updated_at > stamp || (memory.topics_extracted_version ?? 0) < TOPICS_EXTRACTION_VERSION ? "stale" : null;
|
|
21090
|
-
}
|
|
21091
21088
|
function canonicalTopics(row) {
|
|
21092
21089
|
return new Set((parseTopics(row.topics) ?? []).map((topic) => normalizeEntityName(topic.name)));
|
|
21093
21090
|
}
|
|
@@ -21336,17 +21333,16 @@ function createRemoteMemoryStore(options) {
|
|
|
21336
21333
|
};
|
|
21337
21334
|
const topicMaintenance = {
|
|
21338
21335
|
getTopicBacklog: async (backlogOptions = {}) => {
|
|
21339
|
-
const stale = [];
|
|
21340
|
-
const fresh = [];
|
|
21341
|
-
for (const { memory } of await pages(metadata, { order: "created" })) {
|
|
21342
|
-
if (memory.topics_user_managed) continue;
|
|
21343
|
-
const due = extractionDue(memory);
|
|
21344
|
-
if (due === "stale") stale.push(memory.memory_id);
|
|
21345
|
-
else if (due === "fresh") fresh.push(memory.memory_id);
|
|
21346
|
-
}
|
|
21347
21336
|
const limit = backlogOptions.limit !== void 0 && backlogOptions.limit > 0 ? backlogOptions.limit : Infinity;
|
|
21337
|
+
const due = (extracted2, max) => pages(
|
|
21338
|
+
metadata,
|
|
21339
|
+
{ order: "created", topics_due: TOPICS_EXTRACTION_VERSION, topics_extracted: extracted2 },
|
|
21340
|
+
max
|
|
21341
|
+
);
|
|
21342
|
+
const stale = await due(true, limit);
|
|
21343
|
+
const fresh = stale.length < limit ? await due(false, limit - stale.length) : [];
|
|
21348
21344
|
return {
|
|
21349
|
-
pending: [...stale, ...fresh].
|
|
21345
|
+
pending: [...stale, ...fresh].map(({ memory }) => ({ uniqueId: memory.memory_id })),
|
|
21350
21346
|
linkedUnstamped: [],
|
|
21351
21347
|
topicsToRelink: [],
|
|
21352
21348
|
topicsBackfill: []
|
package/dist/expo/index.d.mts
CHANGED
|
@@ -9590,6 +9590,8 @@ interface RemoteMemoryQueryOptions extends RemoteMemoryReadFilters {
|
|
|
9590
9590
|
memory_ids?: string[];
|
|
9591
9591
|
topics?: string[];
|
|
9592
9592
|
updated_after?: number;
|
|
9593
|
+
topics_due?: number;
|
|
9594
|
+
topics_extracted?: boolean;
|
|
9593
9595
|
order?: "created" | "updated" | "archived" | "changed";
|
|
9594
9596
|
cursor?: string;
|
|
9595
9597
|
limit?: number;
|
package/dist/expo/index.d.ts
CHANGED
|
@@ -9590,6 +9590,8 @@ interface RemoteMemoryQueryOptions extends RemoteMemoryReadFilters {
|
|
|
9590
9590
|
memory_ids?: string[];
|
|
9591
9591
|
topics?: string[];
|
|
9592
9592
|
updated_after?: number;
|
|
9593
|
+
topics_due?: number;
|
|
9594
|
+
topics_extracted?: boolean;
|
|
9593
9595
|
order?: "created" | "updated" | "archived" | "changed";
|
|
9594
9596
|
cursor?: string;
|
|
9595
9597
|
limit?: number;
|
package/dist/expo/index.mjs
CHANGED
|
@@ -18563,6 +18563,8 @@ var queryFields = [
|
|
|
18563
18563
|
"memory_ids",
|
|
18564
18564
|
"topics",
|
|
18565
18565
|
"updated_after",
|
|
18566
|
+
"topics_due",
|
|
18567
|
+
"topics_extracted",
|
|
18566
18568
|
"order",
|
|
18567
18569
|
"cursor",
|
|
18568
18570
|
"limit",
|
|
@@ -19448,11 +19450,6 @@ function sameTopics(stored2, next) {
|
|
|
19448
19450
|
const keys = new Set(stored2.map(key));
|
|
19449
19451
|
return next.every((t) => keys.has(key(t)));
|
|
19450
19452
|
}
|
|
19451
|
-
function extractionDue(memory) {
|
|
19452
|
-
const stamp = memory.topics_extracted_at;
|
|
19453
|
-
if (stamp === void 0 || stamp === null) return "fresh";
|
|
19454
|
-
return memory.updated_at > stamp || (memory.topics_extracted_version ?? 0) < TOPICS_EXTRACTION_VERSION ? "stale" : null;
|
|
19455
|
-
}
|
|
19456
19453
|
function canonicalTopics(row) {
|
|
19457
19454
|
return new Set((parseTopics(row.topics) ?? []).map((topic) => normalizeEntityName(topic.name)));
|
|
19458
19455
|
}
|
|
@@ -19701,17 +19698,16 @@ function createRemoteMemoryStore(options) {
|
|
|
19701
19698
|
};
|
|
19702
19699
|
const topicMaintenance = {
|
|
19703
19700
|
getTopicBacklog: async (backlogOptions = {}) => {
|
|
19704
|
-
const stale = [];
|
|
19705
|
-
const fresh = [];
|
|
19706
|
-
for (const { memory } of await pages(metadata, { order: "created" })) {
|
|
19707
|
-
if (memory.topics_user_managed) continue;
|
|
19708
|
-
const due = extractionDue(memory);
|
|
19709
|
-
if (due === "stale") stale.push(memory.memory_id);
|
|
19710
|
-
else if (due === "fresh") fresh.push(memory.memory_id);
|
|
19711
|
-
}
|
|
19712
19701
|
const limit = backlogOptions.limit !== void 0 && backlogOptions.limit > 0 ? backlogOptions.limit : Infinity;
|
|
19702
|
+
const due = (extracted2, max) => pages(
|
|
19703
|
+
metadata,
|
|
19704
|
+
{ order: "created", topics_due: TOPICS_EXTRACTION_VERSION, topics_extracted: extracted2 },
|
|
19705
|
+
max
|
|
19706
|
+
);
|
|
19707
|
+
const stale = await due(true, limit);
|
|
19708
|
+
const fresh = stale.length < limit ? await due(false, limit - stale.length) : [];
|
|
19713
19709
|
return {
|
|
19714
|
-
pending: [...stale, ...fresh].
|
|
19710
|
+
pending: [...stale, ...fresh].map(({ memory }) => ({ uniqueId: memory.memory_id })),
|
|
19715
19711
|
linkedUnstamped: [],
|
|
19716
19712
|
topicsToRelink: [],
|
|
19717
19713
|
topicsBackfill: []
|
package/dist/react/index.cjs
CHANGED
|
@@ -23569,6 +23569,8 @@ var queryFields = [
|
|
|
23569
23569
|
"memory_ids",
|
|
23570
23570
|
"topics",
|
|
23571
23571
|
"updated_after",
|
|
23572
|
+
"topics_due",
|
|
23573
|
+
"topics_extracted",
|
|
23572
23574
|
"order",
|
|
23573
23575
|
"cursor",
|
|
23574
23576
|
"limit",
|
|
@@ -24456,11 +24458,6 @@ function sameTopics(stored2, next) {
|
|
|
24456
24458
|
const keys = new Set(stored2.map(key));
|
|
24457
24459
|
return next.every((t) => keys.has(key(t)));
|
|
24458
24460
|
}
|
|
24459
|
-
function extractionDue(memory) {
|
|
24460
|
-
const stamp = memory.topics_extracted_at;
|
|
24461
|
-
if (stamp === void 0 || stamp === null) return "fresh";
|
|
24462
|
-
return memory.updated_at > stamp || (memory.topics_extracted_version ?? 0) < TOPICS_EXTRACTION_VERSION ? "stale" : null;
|
|
24463
|
-
}
|
|
24464
24461
|
function canonicalTopics(row) {
|
|
24465
24462
|
return new Set((parseTopics(row.topics) ?? []).map((topic) => normalizeEntityName(topic.name)));
|
|
24466
24463
|
}
|
|
@@ -24709,17 +24706,16 @@ function createRemoteMemoryStore(options) {
|
|
|
24709
24706
|
};
|
|
24710
24707
|
const topicMaintenance = {
|
|
24711
24708
|
getTopicBacklog: async (backlogOptions = {}) => {
|
|
24712
|
-
const stale = [];
|
|
24713
|
-
const fresh = [];
|
|
24714
|
-
for (const { memory } of await pages(metadata, { order: "created" })) {
|
|
24715
|
-
if (memory.topics_user_managed) continue;
|
|
24716
|
-
const due = extractionDue(memory);
|
|
24717
|
-
if (due === "stale") stale.push(memory.memory_id);
|
|
24718
|
-
else if (due === "fresh") fresh.push(memory.memory_id);
|
|
24719
|
-
}
|
|
24720
24709
|
const limit = backlogOptions.limit !== void 0 && backlogOptions.limit > 0 ? backlogOptions.limit : Infinity;
|
|
24710
|
+
const due = (extracted2, max) => pages(
|
|
24711
|
+
metadata,
|
|
24712
|
+
{ order: "created", topics_due: TOPICS_EXTRACTION_VERSION, topics_extracted: extracted2 },
|
|
24713
|
+
max
|
|
24714
|
+
);
|
|
24715
|
+
const stale = await due(true, limit);
|
|
24716
|
+
const fresh = stale.length < limit ? await due(false, limit - stale.length) : [];
|
|
24721
24717
|
return {
|
|
24722
|
-
pending: [...stale, ...fresh].
|
|
24718
|
+
pending: [...stale, ...fresh].map(({ memory }) => ({ uniqueId: memory.memory_id })),
|
|
24723
24719
|
linkedUnstamped: [],
|
|
24724
24720
|
topicsToRelink: [],
|
|
24725
24721
|
topicsBackfill: []
|
package/dist/react/index.d.mts
CHANGED
|
@@ -11826,6 +11826,8 @@ interface RemoteMemoryQueryOptions extends RemoteMemoryReadFilters {
|
|
|
11826
11826
|
memory_ids?: string[];
|
|
11827
11827
|
topics?: string[];
|
|
11828
11828
|
updated_after?: number;
|
|
11829
|
+
topics_due?: number;
|
|
11830
|
+
topics_extracted?: boolean;
|
|
11829
11831
|
order?: "created" | "updated" | "archived" | "changed";
|
|
11830
11832
|
cursor?: string;
|
|
11831
11833
|
limit?: number;
|
package/dist/react/index.d.ts
CHANGED
|
@@ -11826,6 +11826,8 @@ interface RemoteMemoryQueryOptions extends RemoteMemoryReadFilters {
|
|
|
11826
11826
|
memory_ids?: string[];
|
|
11827
11827
|
topics?: string[];
|
|
11828
11828
|
updated_after?: number;
|
|
11829
|
+
topics_due?: number;
|
|
11830
|
+
topics_extracted?: boolean;
|
|
11829
11831
|
order?: "created" | "updated" | "archived" | "changed";
|
|
11830
11832
|
cursor?: string;
|
|
11831
11833
|
limit?: number;
|
package/dist/react/index.mjs
CHANGED
|
@@ -21665,6 +21665,8 @@ var queryFields = [
|
|
|
21665
21665
|
"memory_ids",
|
|
21666
21666
|
"topics",
|
|
21667
21667
|
"updated_after",
|
|
21668
|
+
"topics_due",
|
|
21669
|
+
"topics_extracted",
|
|
21668
21670
|
"order",
|
|
21669
21671
|
"cursor",
|
|
21670
21672
|
"limit",
|
|
@@ -22550,11 +22552,6 @@ function sameTopics(stored2, next) {
|
|
|
22550
22552
|
const keys = new Set(stored2.map(key));
|
|
22551
22553
|
return next.every((t) => keys.has(key(t)));
|
|
22552
22554
|
}
|
|
22553
|
-
function extractionDue(memory) {
|
|
22554
|
-
const stamp = memory.topics_extracted_at;
|
|
22555
|
-
if (stamp === void 0 || stamp === null) return "fresh";
|
|
22556
|
-
return memory.updated_at > stamp || (memory.topics_extracted_version ?? 0) < TOPICS_EXTRACTION_VERSION ? "stale" : null;
|
|
22557
|
-
}
|
|
22558
22555
|
function canonicalTopics(row) {
|
|
22559
22556
|
return new Set((parseTopics(row.topics) ?? []).map((topic) => normalizeEntityName(topic.name)));
|
|
22560
22557
|
}
|
|
@@ -22803,17 +22800,16 @@ function createRemoteMemoryStore(options) {
|
|
|
22803
22800
|
};
|
|
22804
22801
|
const topicMaintenance = {
|
|
22805
22802
|
getTopicBacklog: async (backlogOptions = {}) => {
|
|
22806
|
-
const stale = [];
|
|
22807
|
-
const fresh = [];
|
|
22808
|
-
for (const { memory } of await pages(metadata, { order: "created" })) {
|
|
22809
|
-
if (memory.topics_user_managed) continue;
|
|
22810
|
-
const due = extractionDue(memory);
|
|
22811
|
-
if (due === "stale") stale.push(memory.memory_id);
|
|
22812
|
-
else if (due === "fresh") fresh.push(memory.memory_id);
|
|
22813
|
-
}
|
|
22814
22803
|
const limit = backlogOptions.limit !== void 0 && backlogOptions.limit > 0 ? backlogOptions.limit : Infinity;
|
|
22804
|
+
const due = (extracted2, max) => pages(
|
|
22805
|
+
metadata,
|
|
22806
|
+
{ order: "created", topics_due: TOPICS_EXTRACTION_VERSION, topics_extracted: extracted2 },
|
|
22807
|
+
max
|
|
22808
|
+
);
|
|
22809
|
+
const stale = await due(true, limit);
|
|
22810
|
+
const fresh = stale.length < limit ? await due(false, limit - stale.length) : [];
|
|
22815
22811
|
return {
|
|
22816
|
-
pending: [...stale, ...fresh].
|
|
22812
|
+
pending: [...stale, ...fresh].map(({ memory }) => ({ uniqueId: memory.memory_id })),
|
|
22817
22813
|
linkedUnstamped: [],
|
|
22818
22814
|
topicsToRelink: [],
|
|
22819
22815
|
topicsBackfill: []
|