-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Labels
enhancementNew feature or requestNew feature or requestphase-5Phase 5: Advanced Features & PolishPhase 5: Advanced Features & Polishphase-5.3Phase 5.3: Polish & Advanced (TUI, debug/replay, dynamic config)Phase 5.3: Polish & Advanced (TUI, debug/replay, dynamic config)symphony-inspiredInspired by OpenAI Symphony spec analysisInspired by OpenAI Symphony spec analysis
Description
Summary
Watch for changes to AGENTS.md/CLAUDE.md/CODEFRAME.md during long-running batch executions and hot-reload configuration without restarting. Inspired by Symphony's dynamic WORKFLOW.md reload pattern.
Motivation
During multi-hour batch runs (cf work batch run --all-ready), operators may need to adjust agent behavior — change the prompt, adjust concurrency, modify gate configuration. Currently this requires killing and restarting the batch. Symphony solves this with filesystem watching and automatic config reload.
This is lower priority because single-task execution is short-lived, but it becomes important for Phase 4 multi-agent scenarios where batch runs may run for hours.
Design
Scope (single session)
- File watcher: Use
watchdogorinotifyto monitor config files for changes - Reload logic in
core/agents_config.py:- On file change: re-parse config
- Validate new config (don't apply if invalid)
- Log reload event with diff summary
- Apply to future task dispatches (don't restart in-flight agents)
- Integration with conductor:
core/conductor.pychecks for config updates between task dispatches- New concurrency/strategy settings apply to remaining tasks
- New prompt/agent settings apply to next agent launch
- Safety:
- Invalid config reload → keep last known good config, log error
- Config reload during agent execution → queued, applied after current task
What reloads dynamically
- Agent prompt / system prompt supplement
- Concurrency limits (
max_parallel) - Gate configuration
- Hook scripts (for future tasks)
- Stall timeout
What requires restart
- Engine selection (react/plan)
- Workspace path
- Tech stack
Acceptance Criteria
- Config file changes detected within 5 seconds during batch execution
- Valid config changes applied to subsequent task dispatches
- Invalid config changes logged as error, previous config retained
- In-flight agent tasks not interrupted by config reload
-
cf work batch statusshows "config reloaded at HH:MM:SS" if reload occurred - Integration test: modify config during batch, verify next task uses new config
Dependencies
- Benefits from [Phase 5] Unified CODEFRAME.md Workflow Config #398 (unified CODEFRAME.md) — single file to watch
- No hard prerequisites
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestphase-5Phase 5: Advanced Features & PolishPhase 5: Advanced Features & Polishphase-5.3Phase 5.3: Polish & Advanced (TUI, debug/replay, dynamic config)Phase 5.3: Polish & Advanced (TUI, debug/replay, dynamic config)symphony-inspiredInspired by OpenAI Symphony spec analysisInspired by OpenAI Symphony spec analysis