@ours.network/fleet 0.1.1 → 0.2.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/README.md +4 -2
- package/dist/cli.js +4 -0
- package/dist/config.d.ts +1 -0
- package/dist/config.js +2 -1
- package/dist/harness/claude-code.js +2 -1
- package/dist/spawn.d.ts +1 -0
- package/dist/spawn.js +3 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -137,7 +137,7 @@ ours-fleet up|down|restart|force-restart [-c FILE] [Name...]
|
|
|
137
137
|
ours-fleet config [-c FILE] validate + print merged plan
|
|
138
138
|
ours-fleet ls | attach | peek | logs [-f] | status <Name>
|
|
139
139
|
ours-fleet send <Name> "text" | --key <K>
|
|
140
|
-
ours-fleet spawn [--temp] <Name> [--mission --bio-file --persona-file ...]
|
|
140
|
+
ours-fleet spawn [--temp] <Name> [--mission --model --bio-file --persona-file ...]
|
|
141
141
|
ours-fleet rm <Name>
|
|
142
142
|
ours-fleet doctor [--harness H]
|
|
143
143
|
ours-fleet init
|
|
@@ -149,6 +149,7 @@ ours-fleet init
|
|
|
149
149
|
vars: { work_root: /home/me/work } # ${var} substitution anywhere below
|
|
150
150
|
defaults:
|
|
151
151
|
harness: claude-code # for roles that don't set one
|
|
152
|
+
model: claude-fable-5 # default model for roles that don't set one (per-role model / --model wins)
|
|
152
153
|
max_tokens: 500000 # session cap (harness-interpreted)
|
|
153
154
|
roles:
|
|
154
155
|
Name: # [A-Za-z0-9_-]+
|
|
@@ -156,6 +157,7 @@ roles:
|
|
|
156
157
|
identity: "Display Name" # ours identity to bind (default: Name)
|
|
157
158
|
cwd: ${work_root}/repo # where the harness process runs
|
|
158
159
|
coordinator: FleetCoordinator # announce target on boot
|
|
160
|
+
model: claude-fable-5 # launch on a specific model (pass-through id; default: launcher default)
|
|
159
161
|
mission: one line
|
|
160
162
|
persona: | # operating contract (published as persona)
|
|
161
163
|
bio: | # public card (published as bio)
|
|
@@ -187,7 +189,7 @@ for the reference implementation.
|
|
|
187
189
|
ours-fleet is part of [ours.network](https://ours.network) — free, source-available
|
|
188
190
|
software built by a small independent team, running the broker and relay services
|
|
189
191
|
at their own cost. If this is useful to you, please consider chipping in:
|
|
190
|
-
**→ https://
|
|
192
|
+
**→ https://github.com/adapt-toolkit/ours-donate**
|
|
191
193
|
|
|
192
194
|
## License
|
|
193
195
|
|
package/dist/cli.js
CHANGED
|
@@ -48,6 +48,8 @@ cOpt(program.command('config').description('validate + print the merged plan (no
|
|
|
48
48
|
console.log(` source: ${r.sourceFile}`);
|
|
49
49
|
if (r.cwd)
|
|
50
50
|
console.log(` cwd: ${r.cwd}`);
|
|
51
|
+
if (r.model)
|
|
52
|
+
console.log(` model: ${r.model}`);
|
|
51
53
|
if (r.coordinator)
|
|
52
54
|
console.log(` coordinator: ${r.coordinator}`);
|
|
53
55
|
if (r.mission)
|
|
@@ -148,12 +150,14 @@ cOpt(program.command('spawn <name>').description('spawn a new agent (permanent b
|
|
|
148
150
|
.option('--identity <name>', 'ours identity to bind (default: role name)')
|
|
149
151
|
.option('--cwd <dir>', 'working directory')
|
|
150
152
|
.option('--coordinator <name>', 'announce target')
|
|
153
|
+
.option('--model <id>', 'model id to launch on (e.g. claude-fable-5); default: launcher default')
|
|
151
154
|
.option('--bio-file <file>', 'public bio (file)')
|
|
152
155
|
.option('--persona-file <file>', 'persona / operating contract (file)')
|
|
153
156
|
.action(async (name, opts) => {
|
|
154
157
|
const o = {
|
|
155
158
|
name, temp: opts.temp, harness: opts.harness, mission: opts.mission,
|
|
156
159
|
identity: opts.identity, cwd: opts.cwd, coordinator: opts.coordinator,
|
|
160
|
+
model: opts.model,
|
|
157
161
|
bioFile: opts.bioFile, personaFile: opts.personaFile, configPath: opts.configuration,
|
|
158
162
|
};
|
|
159
163
|
try {
|
package/dist/config.d.ts
CHANGED
package/dist/config.js
CHANGED
|
@@ -7,7 +7,7 @@ export class ConfigError extends Error {
|
|
|
7
7
|
const NAME_RE = /^[A-Za-z0-9_-]+$/;
|
|
8
8
|
const ROLE_KEYS = [
|
|
9
9
|
'harness', 'identity', 'cwd', 'coordinator', 'mission', 'persona', 'bio',
|
|
10
|
-
'briefing_file', 'max_tokens', 'autocompact_pct', 'env', 'oversee', 'harness_options',
|
|
10
|
+
'briefing_file', 'model', 'max_tokens', 'autocompact_pct', 'env', 'oversee', 'harness_options',
|
|
11
11
|
];
|
|
12
12
|
function deepSub(v, vars) {
|
|
13
13
|
if (typeof v === 'string')
|
|
@@ -65,6 +65,7 @@ export function loadConfig(configPath) {
|
|
|
65
65
|
sourceFile: file,
|
|
66
66
|
harness: r.harness ?? defaults.harness ?? 'claude-code',
|
|
67
67
|
identity: r.identity ?? name,
|
|
68
|
+
model: r.model ?? defaults.model,
|
|
68
69
|
max_tokens: r.max_tokens ?? defaults.max_tokens,
|
|
69
70
|
});
|
|
70
71
|
}
|
|
@@ -78,7 +78,8 @@ export function makeClaudeCodeAdapter(exec = realExec) {
|
|
|
78
78
|
},
|
|
79
79
|
buildLaunch(role, mode, s, prep) {
|
|
80
80
|
const stateDir = roleStateDir(role);
|
|
81
|
-
const base = ['claude', ...
|
|
81
|
+
const base = ['claude', ...(role.model ? ['--model', role.model] : []),
|
|
82
|
+
...prep.argv, '--remote-control', role.name];
|
|
82
83
|
const argv = mode === 'fresh'
|
|
83
84
|
? [...base, '--session-id', s.sessionId, `Read and follow ${join(stateDir, 'briefing.md')} now.`]
|
|
84
85
|
: [...base, '--resume', s.sessionId,
|
package/dist/spawn.d.ts
CHANGED
package/dist/spawn.js
CHANGED
|
@@ -17,6 +17,8 @@ function roleFromOpts(o) {
|
|
|
17
17
|
r.coordinator = o.coordinator;
|
|
18
18
|
if (o.mission)
|
|
19
19
|
r.mission = o.mission;
|
|
20
|
+
if (o.model?.trim())
|
|
21
|
+
r.model = o.model.trim();
|
|
20
22
|
if (o.bioFile)
|
|
21
23
|
r.bio = readFileSync(o.bioFile, 'utf8').trim();
|
|
22
24
|
if (o.personaFile)
|
|
@@ -57,6 +59,7 @@ export async function spawnTemp(o, binPath, launch = detachedSupervisor) {
|
|
|
57
59
|
name: o.name,
|
|
58
60
|
harness: o.harness ?? cfg.defaults.harness ?? 'claude-code',
|
|
59
61
|
identity: o.identity ?? o.name,
|
|
62
|
+
model: o.model?.trim() || cfg.defaults.model,
|
|
60
63
|
sourceFile: '(temp)',
|
|
61
64
|
};
|
|
62
65
|
const dir = applyRole(role, { temp: true });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ours.network/fleet",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "Harness-agnostic fleet of persistent, identity-bound AI agents. Declarative fleet.yaml, tmux consoles, systemd/launchd supervision, ours.network messaging.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "FSL-1.1-Apache-2.0",
|