@volter/supercode-orchestrator 0.5.207 → 0.5.208
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/README.md +30 -2
- package/agents.mjs +27 -12
- package/bin/connection-runner.mjs +12 -21
- package/bin/orchestrator.mjs +16 -3
- package/board/agent-declarations.mjs +3 -3
- package/board/args.mjs +2 -2
- package/board/card-state.mjs +29 -0
- package/board/ci.mjs +87 -29
- package/board/cli.mjs +125 -91
- package/board/codex-pane-inputs.mjs +44 -0
- package/board/dispatch.mjs +354 -84
- package/board/engine.mjs +77 -50
- package/board/event-stream.mjs +6 -1
- package/board/files.mjs +3 -1
- package/board/listing.mjs +13 -11
- package/board/machine-fleet.mjs +7 -5
- package/board/notices.mjs +2 -2
- package/board/published.mjs +119 -32
- package/board/readable-id.mjs +34 -0
- package/board/record-view.mjs +10 -1
- package/board/request-mail.mjs +9 -3
- package/board/store.mjs +95 -14
- package/board/tools.mjs +10 -8
- package/board/visibility.mjs +11 -0
- package/board/workflow.mjs +58 -16
- package/board/workspace.mjs +21 -9
- package/board/ztrack.mjs +111 -44
- package/codex-pane-resume.mjs +1 -0
- package/connection.mjs +95 -26
- package/index.d.ts +6 -2
- package/loop.mjs +51 -3
- package/mcp/bridge.mjs +4 -1
- package/mcp/hermes-kanban-tools.json +5 -1
- package/ontology.d.ts +7 -24
- package/orchestration.mjs +6 -3
- package/package.json +5 -4
- package/worker-route.mjs +31 -3
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
// Only declared profile inputs cross machines. A Codex home, environment,
|
|
2
|
+
// configuration, login, memory and rollout are never copied from the board.
|
|
3
|
+
import { existsSync, readFileSync, readdirSync, realpathSync, statSync } from 'node:fs';
|
|
4
|
+
import { join, relative, sep } from 'node:path';
|
|
5
|
+
import { hermesModel } from '../worker-route.mjs';
|
|
6
|
+
import { skillSources } from '../hermes-home.mjs';
|
|
7
|
+
|
|
8
|
+
export function codexPaneInputs(profile, worker, vault) {
|
|
9
|
+
if (worker?.harness !== 'codex' || hermesModel(profile)?.provider !== 'openai-codex' || worker.home === 'user')
|
|
10
|
+
throw new Error('remote headful Codex requires the login-free openai-codex profile route');
|
|
11
|
+
if (Object.hasOwn(worker.env ?? {}, 'CODEX_HOME'))
|
|
12
|
+
throw new Error('remote headful Codex owns its destination home; worker.env.CODEX_HOME cannot override it');
|
|
13
|
+
const forward = vault.get('HERMES_CODEX_BASE_URL') ?? process.env.HERMES_CODEX_BASE_URL;
|
|
14
|
+
if (!forward) throw new Error('remote headful Codex requires HERMES_CODEX_BASE_URL; no pane was launched');
|
|
15
|
+
const files = [];
|
|
16
|
+
let bytes = 0;
|
|
17
|
+
const add = (path, content, mode = 0o600) => {
|
|
18
|
+
bytes += content.length;
|
|
19
|
+
if (bytes > 8 * 1024 * 1024 || files.length >= 4096) throw new Error('the remote Codex profile inputs exceed their transfer bound');
|
|
20
|
+
files.push({ path, base64: content.toString('base64'), mode: mode & 0o777 });
|
|
21
|
+
};
|
|
22
|
+
add('AGENTS.md', existsSync(join(profile.dir, 'AGENTS.md')) ? readFileSync(join(profile.dir, 'AGENTS.md')) : Buffer.alloc(0));
|
|
23
|
+
for (const [name, source] of skillSources(profile.dir)) {
|
|
24
|
+
const root = realpathSync(source);
|
|
25
|
+
const walk = (folder, path, ancestors) => {
|
|
26
|
+
const real = realpathSync(folder), part = relative(root, real);
|
|
27
|
+
if (part === '..' || part.startsWith(`..${sep}`)) throw new Error(`skill ${name} links outside its declared directory; remote Codex inputs were refused`);
|
|
28
|
+
if (ancestors.has(real)) throw new Error(`skill ${name} has a directory cycle`);
|
|
29
|
+
const next = new Set([...ancestors, real]);
|
|
30
|
+
for (const entry of readdirSync(folder).sort()) {
|
|
31
|
+
const from = join(folder, entry), into = `${path}/${entry}`, selected = realpathSync(from), rel = relative(root, selected);
|
|
32
|
+
if (rel === '..' || rel.startsWith(`..${sep}`)) throw new Error(`skill ${name} links outside its declared directory`);
|
|
33
|
+
const info = statSync(from);
|
|
34
|
+
if (info.isDirectory()) walk(from, into, next);
|
|
35
|
+
else if (info.isFile()) {
|
|
36
|
+
if (info.size > 8 * 1024 * 1024 - bytes) throw new Error(`skill ${name} exceeds the remote profile byte bound`);
|
|
37
|
+
add(into, readFileSync(from), info.mode);
|
|
38
|
+
} else throw new Error(`skill ${name} has an unsupported input file`);
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
walk(source, `skills/${name}`, new Set());
|
|
42
|
+
}
|
|
43
|
+
return { forward, files };
|
|
44
|
+
}
|