Implement hierarchical agent tree architecture
Core types with provability design: - Task, Budget, Complexity with documented invariants - VerificationCriteria with programmatic/LLM hybrid support - SubtaskPlan with topological sort for execution order Agent hierarchy: - Agent trait with pre/post-conditions documented - OrchestratorAgent for Root/Node agents - LeafAgent for specialized workers Leaf agents: - ComplexityEstimator: estimates task difficulty (0-1 score) - ModelSelector: U-curve optimization for cost/capability - TaskExecutor: refactored from original agent loop - Verifier: hybrid programmatic + LLM verification Orchestrators: - RootAgent: top-level, estimates complexity, splits tasks - NodeAgent: intermediate, handles delegated subtasks Budget system: - Budget allocation strategies (proportional, equal, priority) - OpenRouter pricing integration for cost estimation API updated to use hierarchical RootAgent
This commit is contained in:
@@ -36,6 +36,7 @@ walkdir = "2"
|
||||
urlencoding = "2"
|
||||
anyhow = "1"
|
||||
async-stream = "0.3"
|
||||
regex = "1"
|
||||
|
||||
[dev-dependencies]
|
||||
tokio-test = "0.4"
|
||||
|
||||
Reference in New Issue
Block a user