feat(agents): add agent override configuration support

- Add AgentName, AgentOverrideConfig, AgentOverrides types
- Implement createBuiltinAgents with disabled_agents and overrides support
- Support oh-my-opencode.json config for:
  - disabled_agents: disable specific built-in agents
  - agents: override model, temperature, tools, permission per agent
- Tools and permission objects are shallow-merged with base config
- Export types for external consumers
- Update README with agent override documentation
This commit is contained in:
YeonGyu-Kim
2025-12-05 02:32:33 +09:00
parent 6220fcddcf
commit 22acb0def1
5 changed files with 114 additions and 6 deletions
+12
View File
@@ -0,0 +1,12 @@
import type { AgentConfig } from "@opencode-ai/sdk"
export type AgentName =
| "oracle"
| "librarian"
| "explore"
| "frontend-ui-ux-engineer"
| "document-writer"
export type AgentOverrideConfig = Partial<AgentConfig>
export type AgentOverrides = Partial<Record<AgentName, AgentOverrideConfig>>