Amp cannot honor role-specific model config (no per-model override)
Context (shared across all harnesses)
AO stores a per-role model in agentConfig.model (backend/internal/domain/agentconfig.go:27). session_manager.effectiveAgentConfig merges the project base config with the role override and Spawn/Restore forward the resolved value into every adapter as cfg.Config.Model (backend/internal/ports/agent.go). Each adapter must opt in to forwarding that value to its CLI. Today only the Claude (claudecode/claudecode.go:172), Codex (#2869), and Kiro (config-file model key) adapters do.
- Original report: #2769
- Reference fix (the pattern to copy where a mechanism exists): #2869 (Codex)
This issue tracks Amp for completeness of the harness-model-config audit (sibling issues: #2883–#2901).
Situation
The Amp (Sourcegraph) adapter (amp, binary amp) does not forward cfg.Config.Model — and, unlike the other affected harnesses, there is currently no CLI/config surface to forward it to.
GetLaunchCommand(backend/internal/adapters/agent/amp/amp.go:74-75) returns a bare[]string{binary};GetRestoreCommand(:124-125) emits onlyamp --resume <id>. System prompt is injected via a TS plugin (amp/hooks.go). No model handling anywhere. Inherits the emptyagentbase.Base.GetConfigSpec.- Amp abstracts model selection behind a mode system (
low/medium/high/ultra, switched interactively viaCtrl+O → mode). There is no--modelflag, no documented model env var, and no config key for a specific model string. Source: Amp Owner's Manual — https://ampcode.com/manual
Why this is filed as needs-decision (not a bug)
Because Amp exposes no per-model override, agentConfig.model cannot be honored for Amp the way it is for the flag/config harnesses. The options are:
- Document as unsupported: treat
agentConfig.modelas an explicit no-op for Amp and surface that (e.g. a validation warning or docs note) so users aren't surprised. Recommended near-term. - Map to modes (lossy): if AO ever wants some control, map a small vocabulary onto Amp "modes" — but a mode is not a model, so this is a lossy, non-1:1 mapping and probably not worth it.
- Track upstream: revisit if/when the Amp CLI exposes a real model-selection surface.
Ask
Confirm the intended disposition (recommend option 1). If option 1, close with a docs/validation note; if a future model surface appears, this becomes a straightforward Codex-style fix.
References
- Sibling audit issues: #2883–#2901 · Original context: #2769 · Reference pattern: #2869
- Relevant file:
backend/internal/adapters/agent/amp/amp.go
Thanks for contributing to Agent Orchestrator.
This issue is being picked up by the current external contributor on-call pair:
- @illegalcall
- @pulkit7070
If someone is already working on this, please continue as usual. The on-call pair is added for visibility, tracking, and support, not to take over the work. If you need help with review, direction, reproduction, or next steps, please tag @illegalcall and @pulkit7070 here.
For faster context or live questions, you can also join the AO Discord.
Join the session here: https://discord.gg/H6ZDcUXmq
Come by if you want to see what is being built, ask questions, or just hang around with the community.
Im picking up this issue