@signetai/signet-memory-openclaw 0.188.2 → 0.189.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/index.js +43 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -11065,6 +11065,35 @@ function up120(db) {
|
|
|
11065
11065
|
ON source_lifecycle_state(agent_id, source_class, first_searchable_at, first_recall_at);
|
|
11066
11066
|
`);
|
|
11067
11067
|
}
|
|
11068
|
+
function hasColumn23(db, table, column) {
|
|
11069
|
+
return db.prepare(`PRAGMA table_info(${table})`).all().some((row) => row.name === column);
|
|
11070
|
+
}
|
|
11071
|
+
function addColumnIfMissing26(db, column, definition) {
|
|
11072
|
+
if (!hasColumn23(db, "telemetry_events", column)) {
|
|
11073
|
+
db.exec(`ALTER TABLE telemetry_events ADD COLUMN ${column} ${definition}`);
|
|
11074
|
+
}
|
|
11075
|
+
}
|
|
11076
|
+
function up121(db) {
|
|
11077
|
+
addColumnIfMissing26(db, "delivery_attempts", "INTEGER NOT NULL DEFAULT 0");
|
|
11078
|
+
addColumnIfMissing26(db, "last_attempt_at", "TEXT");
|
|
11079
|
+
addColumnIfMissing26(db, "sent_at", "TEXT");
|
|
11080
|
+
addColumnIfMissing26(db, "last_failure_code", "TEXT");
|
|
11081
|
+
db.exec(`
|
|
11082
|
+
CREATE TABLE IF NOT EXISTS telemetry_delivery_state (
|
|
11083
|
+
id INTEGER PRIMARY KEY CHECK (id = 1),
|
|
11084
|
+
window_started_at TEXT NOT NULL,
|
|
11085
|
+
success_count INTEGER NOT NULL DEFAULT 0,
|
|
11086
|
+
failure_count INTEGER NOT NULL DEFAULT 0,
|
|
11087
|
+
consecutive_failures INTEGER NOT NULL DEFAULT 0,
|
|
11088
|
+
last_attempt_at TEXT,
|
|
11089
|
+
last_success_at TEXT,
|
|
11090
|
+
last_failure_code TEXT,
|
|
11091
|
+
dropped_event_count INTEGER NOT NULL DEFAULT 0
|
|
11092
|
+
);
|
|
11093
|
+
INSERT OR IGNORE INTO telemetry_delivery_state (id, window_started_at)
|
|
11094
|
+
VALUES (1, CURRENT_TIMESTAMP);
|
|
11095
|
+
`);
|
|
11096
|
+
}
|
|
11068
11097
|
var MIGRATIONS = [
|
|
11069
11098
|
{
|
|
11070
11099
|
version: 1,
|
|
@@ -12032,6 +12061,20 @@ var MIGRATIONS = [
|
|
|
12032
12061
|
name: "source-lifecycle-telemetry",
|
|
12033
12062
|
up: up120,
|
|
12034
12063
|
artifacts: { tables: ["source_lifecycle_state"] }
|
|
12064
|
+
},
|
|
12065
|
+
{
|
|
12066
|
+
version: 121,
|
|
12067
|
+
name: "telemetry-delivery-health",
|
|
12068
|
+
up: up121,
|
|
12069
|
+
artifacts: {
|
|
12070
|
+
tables: ["telemetry_delivery_state"],
|
|
12071
|
+
columns: [
|
|
12072
|
+
{ table: "telemetry_events", column: "delivery_attempts" },
|
|
12073
|
+
{ table: "telemetry_events", column: "last_attempt_at" },
|
|
12074
|
+
{ table: "telemetry_events", column: "sent_at" },
|
|
12075
|
+
{ table: "telemetry_events", column: "last_failure_code" }
|
|
12076
|
+
]
|
|
12077
|
+
}
|
|
12035
12078
|
}
|
|
12036
12079
|
];
|
|
12037
12080
|
var LATEST_SCHEMA_VERSION = MIGRATIONS[MIGRATIONS.length - 1]?.version ?? 0;
|