@signetai/core 0.182.10 → 0.183.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/index.js
CHANGED
|
@@ -11173,6 +11173,57 @@ function up114(db) {
|
|
|
11173
11173
|
`);
|
|
11174
11174
|
}
|
|
11175
11175
|
|
|
11176
|
+
// src/migrations/115-cross-agent-message-notifications.ts
|
|
11177
|
+
function up115(db) {
|
|
11178
|
+
db.exec(`
|
|
11179
|
+
CREATE TABLE IF NOT EXISTS cross_agent_messages (
|
|
11180
|
+
id TEXT PRIMARY KEY,
|
|
11181
|
+
from_agent_id TEXT NOT NULL,
|
|
11182
|
+
from_session_key TEXT,
|
|
11183
|
+
to_agent_id TEXT,
|
|
11184
|
+
to_session_key TEXT,
|
|
11185
|
+
to_session_agent_id TEXT,
|
|
11186
|
+
broadcast INTEGER NOT NULL DEFAULT 0 CHECK(broadcast IN (0, 1)),
|
|
11187
|
+
message_type TEXT NOT NULL CHECK(message_type IN ('assist_request', 'decision_update', 'info', 'question')),
|
|
11188
|
+
content TEXT NOT NULL,
|
|
11189
|
+
delivery_path TEXT NOT NULL CHECK(delivery_path IN ('local', 'acp')),
|
|
11190
|
+
delivery_status TEXT NOT NULL CHECK(delivery_status IN ('queued', 'delivered', 'failed')),
|
|
11191
|
+
delivery_error TEXT,
|
|
11192
|
+
delivery_receipt_json TEXT,
|
|
11193
|
+
created_at TEXT NOT NULL,
|
|
11194
|
+
expires_at TEXT NOT NULL,
|
|
11195
|
+
CHECK(
|
|
11196
|
+
delivery_path = 'acp'
|
|
11197
|
+
OR (
|
|
11198
|
+
CAST(to_agent_id IS NOT NULL AS INTEGER)
|
|
11199
|
+
+ CAST(to_session_key IS NOT NULL AS INTEGER)
|
|
11200
|
+
+ broadcast = 1
|
|
11201
|
+
)
|
|
11202
|
+
)
|
|
11203
|
+
);
|
|
11204
|
+
|
|
11205
|
+
CREATE TABLE IF NOT EXISTS cross_agent_message_receipts (
|
|
11206
|
+
message_id TEXT NOT NULL REFERENCES cross_agent_messages(id) ON DELETE CASCADE,
|
|
11207
|
+
agent_id TEXT NOT NULL,
|
|
11208
|
+
acknowledged_at TEXT NOT NULL,
|
|
11209
|
+
PRIMARY KEY (message_id, agent_id)
|
|
11210
|
+
);
|
|
11211
|
+
|
|
11212
|
+
CREATE INDEX IF NOT EXISTS idx_cross_agent_messages_agent
|
|
11213
|
+
ON cross_agent_messages(to_agent_id, expires_at, created_at, id);
|
|
11214
|
+
CREATE INDEX IF NOT EXISTS idx_cross_agent_messages_session
|
|
11215
|
+
ON cross_agent_messages(to_session_key, expires_at, created_at, id);
|
|
11216
|
+
CREATE INDEX IF NOT EXISTS idx_cross_agent_messages_session_agent
|
|
11217
|
+
ON cross_agent_messages(to_session_agent_id, expires_at, created_at, id);
|
|
11218
|
+
CREATE INDEX IF NOT EXISTS idx_cross_agent_messages_broadcast
|
|
11219
|
+
ON cross_agent_messages(broadcast, expires_at, created_at, id);
|
|
11220
|
+
CREATE INDEX IF NOT EXISTS idx_cross_agent_messages_sender
|
|
11221
|
+
ON cross_agent_messages(from_agent_id, expires_at, created_at, id);
|
|
11222
|
+
CREATE INDEX IF NOT EXISTS idx_cross_agent_receipts_agent
|
|
11223
|
+
ON cross_agent_message_receipts(agent_id, acknowledged_at, message_id);
|
|
11224
|
+
`);
|
|
11225
|
+
}
|
|
11226
|
+
|
|
11176
11227
|
// src/migrations/index.ts
|
|
11177
11228
|
var MIGRATIONS = [
|
|
11178
11229
|
{
|
|
@@ -12091,6 +12142,14 @@ var MIGRATIONS = [
|
|
|
12091
12142
|
version: 114,
|
|
12092
12143
|
name: "memory-traversal-hydration-index",
|
|
12093
12144
|
up: up114
|
|
12145
|
+
},
|
|
12146
|
+
{
|
|
12147
|
+
version: 115,
|
|
12148
|
+
name: "cross-agent-message-notifications",
|
|
12149
|
+
up: up115,
|
|
12150
|
+
artifacts: {
|
|
12151
|
+
tables: ["cross_agent_messages", "cross_agent_message_receipts"]
|
|
12152
|
+
}
|
|
12094
12153
|
}
|
|
12095
12154
|
];
|
|
12096
12155
|
function checksum(m) {
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { MigrationDb } from "./index";
|
|
2
|
+
/**
|
|
3
|
+
* Migration 115: durable cross-agent inbox and acknowledgements (#944).
|
|
4
|
+
*
|
|
5
|
+
* Messages remain available across daemon restarts until acknowledgement or
|
|
6
|
+
* the bounded retention window expires. Receipts are agent-scoped so one
|
|
7
|
+
* recipient cannot dismiss a broadcast for every other agent.
|
|
8
|
+
*/
|
|
9
|
+
export declare function up(db: MigrationDb): void;
|
|
10
|
+
//# sourceMappingURL=115-cross-agent-message-notifications.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"115-cross-agent-message-notifications.d.ts","sourceRoot":"","sources":["../../src/migrations/115-cross-agent-message-notifications.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAE3C;;;;;;GAMG;AACH,wBAAgB,EAAE,CAAC,EAAE,EAAE,WAAW,GAAG,IAAI,CAgDxC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/migrations/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/migrations/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAwHH,MAAM,WAAW,WAAW;IAC3B,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG;QACrB,GAAG,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,GAAG,IAAI,CAAC;QAC9B,GAAG,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;QAC7D,GAAG,CAA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