diff --git a/README.md b/README.md index c9143b6..5980f2d 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,7 @@ agent me # show the current credential's identity agent run start --config # start a run from a saved config agent run start --config-file f.json # ...or from an inline config agent run start --template welcome-to-ellipsis # ...or from a maintained template +agent run start --config --config-override "limits:\n run: 5" # override config fields for this run agent run start --config --watch # start and immediately stream it agent run list --limit 20 # list recent runs (filter by --source, --days, …) agent run get # inspect one run (prints a dashboard link) diff --git a/src/commands/run.tsx b/src/commands/run.tsx index 7657037..98a748a 100644 --- a/src/commands/run.tsx +++ b/src/commands/run.tsx @@ -44,9 +44,8 @@ export function registerRun(program: Command): void { 'start from a maintained run template (e.g. welcome-to-ellipsis)', ) .option( - '-b, --budget ', - "per-run budget override in USD (sets the config's limits.run for this run)", - parseFloat, + '-o, --config-override ', + 'partial agent config (YAML) merged onto the chosen config for this run, e.g. "limits:\\n run: 5"', ) .option( '-m, --metadata ', @@ -62,7 +61,7 @@ export function registerRun(program: Command): void { config?: string configFile?: string template?: string - budget?: number + configOverride?: string metadata: Record source: string watch?: boolean @@ -85,11 +84,9 @@ export function registerRun(program: Command): void { if (opts.config) req.config_id = opts.config if (opts.configFile) req.config = readJsonFile(opts.configFile) if (opts.template) req.template_id = opts.template - // A budget is expressed as a config override of limits.run (the server - // merges it onto the chosen config and re-validates). - if (opts.budget !== undefined) { - req.config_override_yaml = `limits:\n run: ${opts.budget}` - } + // Merged onto the chosen config and re-validated server-side; set + // limits.run here to override this run's budget. + if (opts.configOverride) req.config_override_yaml = opts.configOverride const api = new ApiClient() const run = await api.startAgentRun(req)