@myagentroam/node 0.9.119 → 0.9.121
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/connector.js +10 -3
- package/dist/database.js +49 -167
- package/dist/migrations/demo.js +9 -0
- package/dist/migrations/types.js +1 -0
- package/dist/migrations/v013.js +327 -0
- package/dist/runner/codex-runner.js +44 -76
- package/dist/runner/mar-agent/managed-run-controller.js +1 -0
- package/dist/runner/opencode-runner.js +27 -38
- package/dist/runner/runner-registry.js +8 -0
- package/dist/service/conversation-template-node-service.js +2 -35
- package/dist/service/goal-mcp-server.js +7 -1
- package/dist/service/hosted-conversation-node-service.js +17 -72
- package/dist/service/workspace-change-service.js +1 -0
- package/package.json +4 -4
- package/dist/migrations/v004.js +0 -91
- package/dist/migrations/v005.js +0 -33
- package/dist/migrations/v006.js +0 -191
- package/dist/migrations/v007.js +0 -52
- package/dist/migrations/v008.js +0 -28
- package/dist/migrations/v009.js +0 -163
- package/dist/migrations/v010.js +0 -96
- package/dist/migrations/v011.js +0 -67
- package/dist/migrations/v012.js +0 -8
package/dist/migrations/v011.js
DELETED
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
export const NODE_SCHEMA_VERSION_V11 = 11;
|
|
2
|
-
/** Adds the fixed localized-display marker for new hosted conversations. */
|
|
3
|
-
export const NODE_SCHEMA_MIGRATION_V11 = String.raw `
|
|
4
|
-
CREATE TABLE hosted_conversations_v11 (
|
|
5
|
-
id TEXT PRIMARY KEY,
|
|
6
|
-
user_storage_key TEXT NOT NULL,
|
|
7
|
-
conversation_storage_key TEXT NOT NULL,
|
|
8
|
-
client_request_id TEXT,
|
|
9
|
-
node_id TEXT NOT NULL,
|
|
10
|
-
session_id TEXT NOT NULL,
|
|
11
|
-
template_id TEXT NOT NULL,
|
|
12
|
-
template_name TEXT NOT NULL,
|
|
13
|
-
active_version_id TEXT NOT NULL REFERENCES conversation_template_versions(id),
|
|
14
|
-
title TEXT NOT NULL,
|
|
15
|
-
status TEXT NOT NULL CHECK (status IN ('ACTIVE')),
|
|
16
|
-
model_id TEXT NOT NULL,
|
|
17
|
-
template_deleted INTEGER NOT NULL DEFAULT 0 CHECK (template_deleted IN (0,1)),
|
|
18
|
-
used_bytes INTEGER NOT NULL DEFAULT 0 CHECK (used_bytes >= 0),
|
|
19
|
-
max_bytes INTEGER NOT NULL CHECK (max_bytes > 0),
|
|
20
|
-
created_at INTEGER NOT NULL CHECK (created_at >= 0),
|
|
21
|
-
updated_at INTEGER NOT NULL CHECK (updated_at >= 0),
|
|
22
|
-
last_activity_at INTEGER NOT NULL CHECK (last_activity_at >= 0),
|
|
23
|
-
pinned_at INTEGER CHECK (pinned_at IS NULL OR pinned_at >= 0),
|
|
24
|
-
title_source TEXT NOT NULL DEFAULT 'CUSTOM'
|
|
25
|
-
CHECK (title_source IN ('DEFAULT','AUTO','CUSTOM')),
|
|
26
|
-
UNIQUE (user_storage_key, conversation_storage_key),
|
|
27
|
-
UNIQUE (user_storage_key, client_request_id)
|
|
28
|
-
) STRICT;
|
|
29
|
-
|
|
30
|
-
INSERT INTO hosted_conversations_v11
|
|
31
|
-
(id,user_storage_key,conversation_storage_key,client_request_id,node_id,session_id,
|
|
32
|
-
template_id,template_name,active_version_id,title,status,model_id,template_deleted,
|
|
33
|
-
used_bytes,max_bytes,created_at,updated_at,last_activity_at,pinned_at,title_source)
|
|
34
|
-
SELECT id,user_storage_key,conversation_storage_key,client_request_id,node_id,session_id,
|
|
35
|
-
template_id,template_name,active_version_id,title,status,model_id,template_deleted,
|
|
36
|
-
used_bytes,max_bytes,created_at,updated_at,last_activity_at,pinned_at,title_source
|
|
37
|
-
FROM hosted_conversations;
|
|
38
|
-
|
|
39
|
-
DROP TABLE hosted_conversations;
|
|
40
|
-
ALTER TABLE hosted_conversations_v11 RENAME TO hosted_conversations;
|
|
41
|
-
|
|
42
|
-
CREATE INDEX hosted_conversations_user_pin_activity
|
|
43
|
-
ON hosted_conversations(
|
|
44
|
-
user_storage_key,
|
|
45
|
-
(pinned_at IS NOT NULL) DESC,
|
|
46
|
-
last_activity_at DESC,
|
|
47
|
-
id DESC
|
|
48
|
-
);
|
|
49
|
-
CREATE INDEX hosted_conversations_template
|
|
50
|
-
ON hosted_conversations(template_id, status, id);
|
|
51
|
-
`;
|
|
52
|
-
export function assertNodeSchemaV11(database) {
|
|
53
|
-
const conversationColumns = database
|
|
54
|
-
.prepare('PRAGMA table_info(hosted_conversations)')
|
|
55
|
-
.all();
|
|
56
|
-
const titleSource = conversationColumns.find((column) => column.name === 'title_source');
|
|
57
|
-
const conversationTable = database
|
|
58
|
-
.prepare("SELECT sql FROM sqlite_master WHERE type='table' AND name='hosted_conversations'")
|
|
59
|
-
.get();
|
|
60
|
-
if (titleSource?.notnull !== 1 ||
|
|
61
|
-
titleSource.dflt_value !== "'CUSTOM'" ||
|
|
62
|
-
typeof conversationTable?.sql !== 'string' ||
|
|
63
|
-
!conversationTable.sql.includes("title_source IN ('DEFAULT','AUTO','CUSTOM')"))
|
|
64
|
-
throw new Error('NODE_DATABASE_SCHEMA_INVALID:hosted_conversations');
|
|
65
|
-
if (database.prepare('PRAGMA foreign_key_check(hosted_conversations)').get() !== undefined)
|
|
66
|
-
throw new Error('NODE_DATABASE_SCHEMA_INVALID:foreign_keys');
|
|
67
|
-
}
|
package/dist/migrations/v012.js
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export const NODE_SCHEMA_VERSION_V12 = 12;
|
|
2
|
-
export const NODE_SCHEMA_MIGRATION_V12 = 'ALTER TABLE workspaces ADD COLUMN preserve_git_config INTEGER NOT NULL DEFAULT 1 CHECK (preserve_git_config IN (0,1));';
|
|
3
|
-
export function assertNodeSchemaV12(database) {
|
|
4
|
-
const columns = database.prepare('PRAGMA table_info(workspaces)').all();
|
|
5
|
-
const column = columns.find((value) => value.name === 'preserve_git_config');
|
|
6
|
-
if (column?.notnull !== 1 || column.dflt_value !== '1')
|
|
7
|
-
throw new Error('NODE_DATABASE_SCHEMA_INVALID:workspaces');
|
|
8
|
-
}
|