forked from froooze/DEXBot2
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnullclaw_bridge.js
More file actions
49 lines (43 loc) · 1.03 KB
/
nullclaw_bridge.js
File metadata and controls
49 lines (43 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
const {
createClawBridge,
describeClawBridge,
runClawCommand
} = require('./claw_bridge');
function createNullClawBridge(options = {}) {
return createClawBridge({
...options,
runtime: {
...(options.runtime || {}),
name: options.runtime?.name || 'nullclaw-bridge'
}
});
}
function describeNullClawBridge(options = {}) {
const manifest = describeClawBridge({
...options,
runtimeName: 'nullclaw',
scriptPath: 'node scripts/nullclaw_bridge.js'
});
return {
...manifest,
compatibility: {
...manifest.compatibility,
name: 'NullClaw',
trustModel: 'NullClaw sends intents and reads context; AI-Bot handles signing through DEXBot2'
}
};
}
function runNullClawCommand(command, options = {}) {
if (command === 'manifest') {
return describeNullClawBridge(options);
}
return runClawCommand(command, {
...options,
runtimeName: options.runtimeName || 'nullclaw'
});
}
module.exports = {
createNullClawBridge,
describeNullClawBridge,
runNullClawCommand
};