Initial commit: coding harness feedback analysis
Harnesses under analysis: - opencode (Go-based coding agent) - pi (minimal terminal coding harness by Mario Zechner) - hermes (Nous Research agent) - forgecode (AI pair programmer with sub-agents) Each harness folder contains: - repo/: Source code from respective repositories - feedback/localllm/: Community feedback for local/smaller models - feedback/frontier/: Community feedback for frontier models Research focus: Tool handling, skills systems, prompt engineering, context management, and best practices for smaller/local models.
This commit is contained in:
@@ -0,0 +1,75 @@
|
|||||||
|
# AGENTS.md
|
||||||
|
|
||||||
|
## Research Project: Coding Agent Harness Analysis
|
||||||
|
|
||||||
|
### Objective
|
||||||
|
Collect data and feedback on four coding agent harnesses to determine what works best for different model sizes, particularly smaller/local models.
|
||||||
|
|
||||||
|
### Harnesses Under Analysis
|
||||||
|
1. **opencode** - Go-based coding agent
|
||||||
|
2. **pi** (pi-mono) - Mario Zechner's minimal terminal coding agent
|
||||||
|
3. **hermes** - Nous Research's agent that grows with you
|
||||||
|
4. **forgecode** - AI pair programmer with sub-agents
|
||||||
|
|
||||||
|
### Data Collection Strategy
|
||||||
|
|
||||||
|
#### Performance Benchmarks
|
||||||
|
- Run terminal-bench and similar benchmarks across all harnesses
|
||||||
|
- Track relative performance metrics
|
||||||
|
- Document success rates, speed, and quality of outputs
|
||||||
|
|
||||||
|
#### Community Feedback Collection
|
||||||
|
Feedback organized by harness and model tier:
|
||||||
|
- `opencode/feedback/localllm/` - Community feedback for local models
|
||||||
|
- `opencode/feedback/frontier/` - Community feedback for frontier models
|
||||||
|
- `pi/feedback/localllm/` - Community feedback for local models
|
||||||
|
- `pi/feedback/frontier/` - Community feedback for frontier models
|
||||||
|
- `hermes/feedback/localllm/` - Community feedback for local models
|
||||||
|
- `hermes/feedback/frontier/` - Community feedback for frontier models
|
||||||
|
- `forgecode/feedback/localllm/` - Community feedback for local models
|
||||||
|
- `forgecode/feedback/frontier/` - Community feedback for frontier models
|
||||||
|
|
||||||
|
### Folder Structure
|
||||||
|
```
|
||||||
|
opencode/
|
||||||
|
repo/ - opencode-ai/opencode source
|
||||||
|
feedback/
|
||||||
|
localllm/ - Local model feedback
|
||||||
|
frontier/ - Frontier model feedback
|
||||||
|
|
||||||
|
pi/
|
||||||
|
repo/ - badlogic/pi-mono source
|
||||||
|
feedback/
|
||||||
|
localllm/ - Local model feedback
|
||||||
|
frontier/ - Frontier model feedback
|
||||||
|
|
||||||
|
hermes/
|
||||||
|
repo/ - NousResearch/hermes-agent source
|
||||||
|
feedback/
|
||||||
|
localllm/ - Local model feedback
|
||||||
|
frontier/ - Frontier model feedback
|
||||||
|
|
||||||
|
forgecode/
|
||||||
|
repo/ - antinomyhq/forgecode source
|
||||||
|
feedback/
|
||||||
|
localllm/ - Local model feedback
|
||||||
|
frontier/ - Frontier model feedback
|
||||||
|
```
|
||||||
|
|
||||||
|
### Research Focus Areas
|
||||||
|
- Tool handling and capabilities
|
||||||
|
- Skills system effectiveness
|
||||||
|
- Prompt engineering strategies
|
||||||
|
- Context management
|
||||||
|
- Error recovery and resilience
|
||||||
|
|
||||||
|
### Future Work
|
||||||
|
Eventually extract best practices and implement improvements specifically optimized for smaller/local models.
|
||||||
|
|
||||||
|
### Reference Materials
|
||||||
|
Files from `../entropy/Research/md/` contain prompt research and strategies:
|
||||||
|
- `Research.md` - General research methodology
|
||||||
|
- `Research-prompt.md` - Prompt engineering research and strategies
|
||||||
|
- `Research-orchestration.md` - Orchestration patterns and strategies
|
||||||
|
|
||||||
|
These files contain prompt research and strategies to reference during analysis.
|
||||||
@@ -0,0 +1,737 @@
|
|||||||
|
# Agent Orchestration and System Design
|
||||||
|
|
||||||
|
A practical, research-backed field guide for designing agent systems: workflows, multi-agent pipelines, memory, evaluation, and infrastructure.
|
||||||
|
|
||||||
|
Use it for:
|
||||||
|
- choosing between single-agent, workflow, and multi-agent designs
|
||||||
|
- orchestration patterns (sequential, parallel, evaluator-optimizer)
|
||||||
|
- agent memory and context management
|
||||||
|
- error recovery and production reliability
|
||||||
|
- evaluation and harness design
|
||||||
|
- tooling and automation loops
|
||||||
|
|
||||||
|
Prompt-level decisions (system prompt writing, CoT strategy, instruction following) live in `Research-prompt.md`.
|
||||||
|
|
||||||
|
## Fast Takeaways
|
||||||
|
|
||||||
|
1. Start with the simplest scaffold that can pass evals. Default to single-agent or workflow. Add agents only when evals show clear gains.
|
||||||
|
2. Separate generator and evaluator roles. Self-evaluation is too lenient; an external evaluator is much stronger.
|
||||||
|
3. Use different models or prompts only when they contribute distinct evidence or skills. Homogeneous agent swarms do not scale.
|
||||||
|
4. Model your agent loop as an explicit state machine. Named states with typed transitions beat open-ended ReAct loops beyond 5–6 steps.
|
||||||
|
5. Error states are first-class citizens. After two consecutive failures on the same action, return to planning — not more retries.
|
||||||
|
6. Memory is a system: working buffer + episodic store + semantic rules. A raw vector store is not a memory architecture.
|
||||||
|
7. Context window management: observation masking outperforms LLM summarization on cost and quality. Keep the reasoning chain; replace old tool outputs.
|
||||||
|
8. Grade outcomes, artifacts, and grounded evidence — not exact tool-call traces.
|
||||||
|
9. HITL approval is only useful if presented as a plain-language summary, not raw JSON.
|
||||||
|
10. Instrument with OpenTelemetry from day one. Correlate traces across agent boundaries with parent-child span IDs.
|
||||||
|
|
||||||
|
## What To Copy Into Systems
|
||||||
|
|
||||||
|
### Orchestration
|
||||||
|
- Keep the default path single-agent or workflow-based.
|
||||||
|
- Add planners, reviewers, or specialist agents only when evals show clear gains.
|
||||||
|
- Prefer bounded loops: one plan phase, one act phase, one verifier, one retry budget.
|
||||||
|
- Use different models or prompts only when they contribute distinct evidence or skills.
|
||||||
|
- Treat multi-agent diversity as a tool, not a religion.
|
||||||
|
|
||||||
|
### System Design
|
||||||
|
- One agent, one responsibility. Separate generator from evaluator from synthesizer.
|
||||||
|
- Small specialists for mechanical subproblems (grep, read, classify, run) are a real design pattern.
|
||||||
|
- Reserve expensive frontier models for hard reasoning and synthesis.
|
||||||
|
- Route by capability and role, not by "use more agents for quality."
|
||||||
|
- A compound system is not a complex system. Match complexity to business value.
|
||||||
|
|
||||||
|
### Tooling and Action Surface
|
||||||
|
- Favor tools that return verifiable feedback: tests, compiler errors, search results, fetched pages, graders.
|
||||||
|
- Apply poka-yoke to every tool: use absolute filepaths, validate inputs before calling external services, return structured error objects not raw exceptions.
|
||||||
|
- Keep traces and artifacts.
|
||||||
|
- If the task is stale/exact/source-sensitive, lookup beats memory.
|
||||||
|
|
||||||
|
### Automation and Safety
|
||||||
|
- Fix a metric before running an autonomous loop.
|
||||||
|
- Keep the mutable surface small.
|
||||||
|
- Auto-commit only after checks pass.
|
||||||
|
- Separate "experiment failed" from "checks failed" from "metric regressed."
|
||||||
|
- Prefer narrow optimization targets over grand autonomous platform behavior.
|
||||||
|
|
||||||
|
### Evaluation
|
||||||
|
- Build evals from real failures and real manual checks.
|
||||||
|
- Balance both sides of decision boundaries: "should do X" and "should not do X."
|
||||||
|
- Isolate trials — no shared repo state, hidden cache, or leaked history.
|
||||||
|
- Use deterministic graders where possible.
|
||||||
|
- Use LLM graders with clear rubrics and human calibration when needed.
|
||||||
|
- Read transcripts constantly. If metrics and transcripts disagree, suspect the harness or grader.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: System Design
|
||||||
|
|
||||||
|
### 1. The Shift from Models to Compound AI Systems (BAIR, 2024)
|
||||||
|
Source: https://bair.berkeley.edu/blog/2024/02/18/compound-ai-systems/
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Strong AI systems increasingly come from multiple interacting components, not just bigger base models. System design can improve quality faster than scaling alone.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Current-data access, control, trust, and cost are often easier to solve at the system level.
|
||||||
|
- Optimizing a compound system is a distinct engineering problem from optimizing a model.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Build around tools, retrievers, graders, and routers when they solve a real product problem.
|
||||||
|
- Do not mistake "compound system" for "maximally complex system."
|
||||||
|
|
||||||
|
### 2. Building Effective AI Agents (Anthropic, 2026)
|
||||||
|
Source: https://resources.anthropic.com/building-effective-ai-agents
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- High-quality practical guidance from a team operating real agent systems at scale.
|
||||||
|
|
||||||
|
The most useful framing:
|
||||||
|
- Choose between single-agent, workflow, and multi-agent designs intentionally.
|
||||||
|
- Use a small set of reusable patterns:
|
||||||
|
- **Prompt chaining** — sequential, each output feeds the next
|
||||||
|
- **Routing** — classify input, dispatch to specialist
|
||||||
|
- **Parallelization** — sectioning for independent subtasks; voting for confidence
|
||||||
|
- **Orchestrator-workers** — dynamic delegation for unpredictable subtasks
|
||||||
|
- **Evaluator-optimizer** — generate-then-critique loop for refineable outputs
|
||||||
|
- Match system complexity to business value.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Default to simple workflows first.
|
||||||
|
- Reach for evaluator-optimizer when correctness matters and the task benefits from revision.
|
||||||
|
- Reach for multi-agent only after single-agent/workflow baselines are exhausted.
|
||||||
|
- The most successful teams use "simple, composable patterns rather than complex frameworks."
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Using agent frameworks without understanding what they do under the hood — they often create abstraction layers that obscure prompts and responses.
|
||||||
|
- Adding agents before measuring whether simpler approaches fail.
|
||||||
|
|
||||||
|
### 3. Harness Design for Long-Running Application Development (Anthropic, 2026)
|
||||||
|
Source: https://www.anthropic.com/engineering/harness-design-long-running-apps
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Strong, current practical guidance on long-running coding harnesses from a team actively tuning them against real app-building tasks.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Separate generator and evaluator roles. Self-evaluation is too lenient; a tuned external evaluator is much more useful.
|
||||||
|
- Make "done" explicit before coding. Use a per-sprint contract negotiated between builder and evaluator.
|
||||||
|
- Keep planner output high-level and product-facing. Over-specifying low-level details too early cascades bad assumptions.
|
||||||
|
- Use evaluators that touch the environment directly. Playwright-driven QA against real UI/API behavior is much stronger than static inspection.
|
||||||
|
- Use hard thresholds for acceptance, not vague approval. If a criterion misses, fail the chunk and return actionable feedback.
|
||||||
|
- Preserve handoff artifacts and structured files between agents. File-based communication reduces drift across long runs.
|
||||||
|
- Context resets vs. compaction is a model-specific engineering choice. Resets help when the model shows context anxiety; stronger models may make resets unnecessary.
|
||||||
|
- Every harness component encodes an assumption about model weakness. Re-run ablations and remove scaffold that is no longer load-bearing after model upgrades.
|
||||||
|
- Evaluators are worth the cost near the model's capability boundary. When the model can already do the task reliably solo, evaluator passes can become mostly overhead.
|
||||||
|
- Read logs and calibrate the evaluator from real disagreements. Prompt tuning should come from concrete misses, not abstract "better QA" wishes.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Keep coder and reviewer/verifier separate when acceptance quality matters.
|
||||||
|
- Add an explicit contract or acceptance plan before implementation when the spec is high-level.
|
||||||
|
- Prefer grounded evaluator tools over reviewer vibes.
|
||||||
|
- Keep handoff state compact and structured enough to survive resets when resets are needed.
|
||||||
|
- Revisit harness complexity whenever the base model changes; stale scaffold is real technical debt.
|
||||||
|
|
||||||
|
### 4. Understanding Agent Scaling via Diversity (2026)
|
||||||
|
Source: arXiv:2602.03794
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- More homogeneous agents do not scale indefinitely; diversity matters more than count.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Two meaningfully different agents can outperform a swarm of same-ish agents.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Diversity should come from role, model, tool access, or evidence channel.
|
||||||
|
- Do not duplicate the same model/prompt ten times and call it orchestration.
|
||||||
|
|
||||||
|
### 5. SOLVE-Med / MATA / Small-Model Orchestration (2025–2026)
|
||||||
|
Sources:
|
||||||
|
- SOLVE-Med: arXiv:2511.03542
|
||||||
|
- MATA: arXiv:2602.09642
|
||||||
|
|
||||||
|
Why they matter:
|
||||||
|
- Small specialized models, when orchestrated well, can outperform or match much larger standalone systems.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Cheap specialists for mechanical subproblems are a real design pattern, not a hack.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Route grep/read/run/simple classification to cheaper lanes.
|
||||||
|
- Reserve expensive models for hard reasoning or integration steps.
|
||||||
|
|
||||||
|
### 6. Difficulty-Aware Agentic Orchestration (DAAO, 2025)
|
||||||
|
Source: arXiv:2509.11079
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Not all subtasks need the same model size. A variational autoencoder estimating query difficulty + a cost/performance-aware router gives near-frontier quality at significantly lower cost.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Difficulty-based routing is a high-leverage optimization most systems skip.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Classify task difficulty before dispatching to a model. Easy classification → cheap model. Hard synthesis → frontier model.
|
||||||
|
- This is the principled version of the "route to cheap specialists" heuristic.
|
||||||
|
|
||||||
|
### 7. Multi-Agent Orchestration for Deterministic Decision Support (2025)
|
||||||
|
Source: arXiv:2511.15755
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- 348 controlled trials: multi-agent orchestration achieved 100% actionable recommendation rate vs. 1.7% for single-agent, with 80x specificity and 140x correctness improvement at similar latency.
|
||||||
|
- The reframing: multi-agent orchestration is a production-readiness requirement, not a performance optimization. Consistent, deterministic quality is what enables SLA commitments.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Single agents produce high-variance outputs. Multi-agent systems with clear role separation produce stable ones.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- When variance is unacceptable (financial decisions, infrastructure changes, compliance tasks), multi-agent is not optional — it's the architecture that enables quality guarantees.
|
||||||
|
|
||||||
|
### 8. Emergent Coordination in Multi-Agent Systems (2025)
|
||||||
|
Source: arXiv:2510.05174
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Coordination is better when agents share objectives and understand complementary roles.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Role awareness is useful; vague social-role prompts are not enough.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- When using multiple agents, explicitly describe what each one contributes and how outputs combine.
|
||||||
|
- Name the shared objective in the orchestrator prompt; name each agent's responsibility in its own prompt.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Memory
|
||||||
|
|
||||||
|
### 9. A-MEM: Agentic Memory for LLM Agents (NeurIPS 2025)
|
||||||
|
Source: https://arxiv.org/abs/2502.12110
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- A Zettelkasten-style memory network — structured notes with attributes, keywords, and tags — doubled complex reasoning performance vs. flat vector store baselines at lower token cost.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Every memory node gets a structured note with contextual description, keywords, and tags at write time.
|
||||||
|
- An autonomous link-generation mechanism identifies connections via cosine similarity + LLM analysis.
|
||||||
|
- When a new memory is added, existing related memories are also updated — the memory network evolves.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- At minimum, build two layers: a short-term in-context working buffer and a persistent episodic store with structured metadata per entry.
|
||||||
|
- Enrich every stored memory with metadata at write time (task context, success/failure outcome, timestamps, tags) — retrieval quality depends entirely on index richness.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Flat vector stores with no structural metadata — retrieval becomes a bag-of-embeddings lottery.
|
||||||
|
- Unbounded episodic stores without consolidation or eviction policies.
|
||||||
|
|
||||||
|
### 10. Episodic Memory is the Missing Piece for Long-Term LLM Agents (2025)
|
||||||
|
Source: https://arxiv.org/abs/2502.06975
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Of the four memory tiers (working, episodic, semantic, procedural), episodic memory is the most underinvested and the key enabler for genuine long-term agent improvement.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Time-stamped traces of specific past task runs enable single-shot learning from concrete prior instances. Without episodic memory, agents keep relearning the same lessons.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Implement an episodic-to-semantic consolidation job: after task completion, abstract successful patterns from the episode trace into reusable rules in semantic memory.
|
||||||
|
- For multi-agent systems: distinguish per-agent private episodic memory from shared semantic memory. Sharing raw episodes risks leakage; sharing distilled rules is safer.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Context Management
|
||||||
|
|
||||||
|
### 11. Cutting Through the Noise: Efficient Context Management (JetBrains Research, Dec 2025)
|
||||||
|
Source: https://blog.jetbrains.com/research/2025/12/efficient-context-management/
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Both common strategies (observation masking and LLM summarization) cut costs >50% vs. unmanaged context. But observation masking matched or outperformed summarization in 4 of 5 configurations, at lower complexity.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- **Observation masking**: replaces older tool outputs/file contents with a placeholder, keeps the reasoning chain intact. Fast, cheap, no extra LLM calls.
|
||||||
|
- **LLM summarization**: compresses old turns. Slower, more expensive, and paradoxically caused agents to run ~15% longer trajectories (summaries gave false confidence to keep going).
|
||||||
|
- With Qwen3-Coder 480B, masking achieved 2.6% *higher* solve rates while being 52% cheaper.
|
||||||
|
- A 2026 industry report attributed ~65% of enterprise AI failures to "context drift" — accumulated noise causing agents to lose track of their goal.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Default to **observation masking** as the primary compaction strategy. Keep the reasoning chain; replace tool outputs after a rolling window.
|
||||||
|
- Add LLM summarization as a fallback only when a single tool response is too large to fit once.
|
||||||
|
- Set a hard token budget before each agent turn. Trigger compaction when projected input exceeds 70–80% of the context limit — before the LLM call, not after.
|
||||||
|
- Always preserve: original task specification, the most recent N turns verbatim, current goal state.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- LLM summarization as the primary strategy — slower, more expensive, longer trajectories.
|
||||||
|
- Letting context grow unchecked — quality degrades well before the hard limit due to lost-in-the-middle effects.
|
||||||
|
- Resetting context entirely for long-running tasks — you lose accumulated plan state.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: State Machines and Control Flow
|
||||||
|
|
||||||
|
### 12. StateFlow: Enhancing LLM Task-Solving through State-Driven Workflows (2024)
|
||||||
|
Source: https://arxiv.org/abs/2403.11322
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Modeling a task as a finite state machine (FSM) with six components — States, Initial state, Final states, Output functions, Transitions, Context history — yielded 63.73% success on SQL tasks vs. 40.3% for ReAct, at 5.8x lower cost.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Removing the explicit Error state caused a 5% success rate decline — error handling as a named state is critical.
|
||||||
|
- A specialist FSM variant (SF_Agent) with separate LLMs per state further reduced token usage.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Model your agent loop as an explicit FSM. Minimum viable states: `PLANNING`, `EXECUTING`, `OBSERVING`, `ERROR_RECOVERY`, `DONE`.
|
||||||
|
- Each state should have: a single well-defined LLM prompt, allowed tools, and explicit transition conditions.
|
||||||
|
- Add an `ERROR` state as a first-class citizen with its own prompt and recovery transitions.
|
||||||
|
- Use a transition counter per state (max N transitions before forcing fallback or human escalation) to prevent runaway loops.
|
||||||
|
- For complex multi-agent systems, define the FSM in a declarative config (YAML/JSON) rather than code — makes control flow auditable.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Pure ReAct loops for tasks requiring more than 5–6 steps — they accumulate drift and have no recovery path when stuck.
|
||||||
|
- Embedding transition logic in the LLM prompt ("decide what to do next") — the LLM is unreliable as a state router. Keep routing deterministic in code.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Parallelization
|
||||||
|
|
||||||
|
### 13. Parallelization and Scatter-Gather Patterns (AWS Prescriptive Guidance, 2025)
|
||||||
|
Source: https://docs.aws.amazon.com/prescriptive-guidance/latest/agentic-ai-patterns/parallelization-and-scatter-gather-patterns.html
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Structured scatter-gather (coordinator dispatches N independent subtasks, aggregator synthesizes) is the most battle-tested pattern for parallelizing LLM work.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- The aggregator is the critical bottleneck. It must handle partial failures gracefully.
|
||||||
|
- Use correlation IDs to match results to requests.
|
||||||
|
- Allow downstream tasks to start early on streaming outputs from upstream tasks where dependencies permit.
|
||||||
|
- Keep fan-out degree below ~20 parallel agents — coordination overhead grows non-linearly.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Structure fan-out tasks with explicit contracts: each subtask specifies inputs it consumes and the exact output schema it must produce.
|
||||||
|
- Design the aggregator as a separate, dedicated role with a prompt focused purely on synthesis and conflict resolution.
|
||||||
|
- Use async fan-out with per-task timeouts and a minimum quorum: "proceed to aggregation once 80% of tasks complete or 30 seconds elapse."
|
||||||
|
- Route cheap classification/filtering steps to small models; reserve large models for synthesis.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Parallelizing tasks with implicit ordering dependencies.
|
||||||
|
- Using the same large model for every subtask — expensive and unnecessary for simple tasks.
|
||||||
|
- Stateful or context-heavy aggregators — they should receive clean, structured outputs from workers, not full conversation transcripts.
|
||||||
|
|
||||||
|
### 14. Orla: A Library for Serving LLM-Based Multi-Agent Systems (2026)
|
||||||
|
Source: https://arxiv.org/abs/2603.13605
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Stage-level model routing (small model for classification, large model for synthesis) cut wall-clock time by 38%, mean completion time by 60%, at 35% lower cost vs. single-model baselines on SWE-bench Lite.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Model routing at the workflow stage level is a high-leverage optimization that most systems skip.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Assign model tiers to workflow stages at design time, not at runtime by the LLM.
|
||||||
|
- Workflow-level KV cache management (preserve cache across stages sharing context prefixes) delivers measurable latency gains.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Error Recovery
|
||||||
|
|
||||||
|
### 15. Retries, Fallbacks, and Circuit Breakers in LLM Apps (Portkey / Maxim, 2025)
|
||||||
|
Sources:
|
||||||
|
- https://portkey.ai/blog/retries-fallbacks-and-circuit-breakers-in-llm-apps/
|
||||||
|
- https://www.getmaxim.ai/articles/retries-fallbacks-and-circuit-breakers-in-llm-apps-a-production-guide/
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Three complementary patterns form the production resilience stack. Without all three, you get retry storms or cascading provider failures.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- **Retries**: for transient errors (network, rate limits). Exponential backoff + jitter. Max 3 attempts. Anti-pattern: retrying persistent failures.
|
||||||
|
- **Fallbacks**: for provider-level failures. Switch to alternate model/provider. Anti-pattern: reactive fallback waits for timeout; shared-infrastructure fallbacks fail identically.
|
||||||
|
- **Circuit breakers**: for systematic degradation. Monitor failure rate over a rolling window; remove the endpoint from routing when it exceeds a threshold. Proactive, not reactive.
|
||||||
|
- For agent tool errors: feed the formatted error back to the LLM as a structured observation — not a crash. Let the agent decide to retry with modified parameters, try an alternative tool, or revise its plan.
|
||||||
|
- Define per-task max-retry budgets: an agent that retries the same tool call 10 times in one task is stuck, not recovering.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Implement retries with exponential backoff + jitter at the base: `base_delay * (2^attempt) + random(0, base_delay)`. Cap at 3 attempts, 30 seconds max total.
|
||||||
|
- Implement fallbacks across at least two LLM providers for any production agent.
|
||||||
|
- Implement circuit breakers at the LLM client level: open after 5 failures in 60 seconds, cooldown 30 seconds.
|
||||||
|
- For agent tool errors, return structured error observations: `{tool, error_type, message, suggested_action}`.
|
||||||
|
- After 2 consecutive tool failures on the same action, force a planning reset (back to `PLANNING` in the FSM).
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Catching all exceptions and silently continuing — the agent will proceed with incomplete state.
|
||||||
|
- Retrying non-idempotent mutations without deduplication keys.
|
||||||
|
- Identical retry and fallback strategies for rate-limit errors vs. model quality errors — these require different handling.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Agent Communication Protocols
|
||||||
|
|
||||||
|
### 16. Survey of Agent Interoperability Protocols: MCP, ACP, A2A, ANP (2025)
|
||||||
|
Source: https://arxiv.org/abs/2505.02279
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Four protocols now occupy distinct architectural layers. Choosing the wrong one for the wrong layer creates maintenance debt.
|
||||||
|
|
||||||
|
Key findings:
|
||||||
|
|
||||||
|
| Protocol | Layer | Best for |
|
||||||
|
|---|---|---|
|
||||||
|
| MCP (Anthropic) | LLM ↔ Tools | Tool/resource injection into a single LLM |
|
||||||
|
| ACP (IBM/BeeAI) | Agent ↔ Agent | Model-agnostic, polyglot agent ecosystems |
|
||||||
|
| A2A (Google) | Agent ↔ Agent (enterprise) | Trusted enterprise inter-agent task delegation |
|
||||||
|
| ANP | Agent ↔ Internet | Open-internet, trustless agent discovery |
|
||||||
|
|
||||||
|
Recommended adoption: Start with MCP for tool access. Layer ACP for richer agent-to-agent messaging. Implement A2A within organizational boundaries. Extend to ANP only for internet-scale interoperability.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use MCP today for everything that is "give an LLM access to a tool or data source." Most mature, widest tooling support.
|
||||||
|
- For agent-to-agent calls within your own system, a well-structured JSON message over HTTP with a correlation ID and defined output schema is sufficient and more debuggable than adopting a new protocol.
|
||||||
|
- Define a standard task envelope for all handoffs: `{task_id, parent_task_id, agent_role, input_schema, output_schema, deadline, status, error}`.
|
||||||
|
- Store task state externally (Redis, Postgres), not inside agent memory — so any agent can resume a task after failure.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Passing full conversation transcripts between agents — pass structured outputs only.
|
||||||
|
- Deep delegation chains (A → B → C → D) without a policy layer enforcing permissions at each hop.
|
||||||
|
- Inventing bespoke message formats per integration — creates an N×M maintenance problem.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: LangGraph and Framework Patterns
|
||||||
|
|
||||||
|
### 17. LangGraph Orchestration Framework (2024–2025)
|
||||||
|
Source: https://www.langchain.com/langgraph
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- LangGraph's six primitives — Nodes, Edges, State, Checkpointing, Interrupts, Concurrency — remove real infrastructure boilerplate. But the framework also adds overhead when the task doesn't need these features.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- **Checkpointing** is the highest-ROI feature. Durable mid-run state means agents can recover from crashes without replaying from scratch.
|
||||||
|
- **Interrupts** are the cleanest available HITL pausing implementation — a first-class primitive.
|
||||||
|
- **Typed State** enforces a shared schema across all nodes, preventing the "agent passed the wrong keys" bug class.
|
||||||
|
- For simple linear workflows, LangGraph adds boilerplate with no functional gain — a plain Python function chain is faster to write and easier to debug.
|
||||||
|
- Research shows >75% of multi-agent systems become difficult to manage once they exceed 5 agents — LangGraph doesn't solve cognitive complexity of large graphs.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use LangGraph when you need any of: checkpointing, HITL interrupts, conditional branching on LLM output, or parallel node execution with join semantics.
|
||||||
|
- Keep graphs small and flat. More than 8–10 nodes is a design smell — split into sub-graphs with clear interfaces.
|
||||||
|
- Use `StateGraph` with `TypedDict` state schema from day one. Untyped state dicts create subtle bugs.
|
||||||
|
- Use a persistent backend (Redis or Postgres) for checkpointing on any workflow longer than a few minutes.
|
||||||
|
- Do not use LangChain's high-level agent abstractions (`AgentExecutor`, `create_react_agent`) in production — they hide retry logic and error handling you need to control explicitly.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Using LangGraph for simple prompt-chaining pipelines with no branching — overhead unjustified.
|
||||||
|
- Debugging via framework logs alone — instrument raw LLM inputs/outputs with LangSmith or equivalent.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Human-in-the-Loop
|
||||||
|
|
||||||
|
### 18. Human-in-the-Loop Patterns (Permit.io / LangChain Docs, 2025)
|
||||||
|
Sources:
|
||||||
|
- https://www.permit.io/blog/human-in-the-loop-for-ai-agents-best-practices-frameworks-use-cases-and-demo
|
||||||
|
- https://docs.langchain.com/oss/python/langchain/human-in-the-loop
|
||||||
|
- The Human-in-the-Loop Illusion: https://www.resilientcyber.io/p/the-human-in-the-loop-illusion
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- HITL provides false confidence if approvers are presented with raw JSON or 50-step action summaries. Humans rubber-stamp without understanding. Good HITL requires human-readable summaries.
|
||||||
|
|
||||||
|
Four distinct HITL patterns:
|
||||||
|
1. **Interrupt & Resume** — agent pauses at a checkpoint, waits for decision, resumes. Best for irreversible action authorization.
|
||||||
|
2. **Human-as-a-Tool** — the agent treats human judgment as a callable service for genuine uncertainty. Best for ambiguous inputs.
|
||||||
|
3. **Approval Flows** — role-based, policy-driven authorization for action classes. Best for financial/compliance workflows.
|
||||||
|
4. **Fallback Escalation** — failed or permission-denied tasks route to humans via async channels. Best for lower-urgency decisions.
|
||||||
|
|
||||||
|
Key trigger criteria: access control changes, infrastructure modifications, destructive operations, financial transactions, operations outside the agent's intended scope. Heuristic: "Would I be okay if the agent did this without asking me?"
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Define your HITL trigger policy in a config file, not in agent prompts. Specify: action classes requiring approval, required approver role, timeout behavior, fallback path if no response.
|
||||||
|
- Present approval requests as plain-language summaries: "Agent wants to delete 3 files in /prod/config: [list]. Reason: [reason]. Approve?" — never raw tool schemas.
|
||||||
|
- For async approval, save full agent state to durable storage before suspending.
|
||||||
|
- Set a maximum wait time for approval (e.g., 4 hours for low-stakes, 10 minutes for blocking workflows).
|
||||||
|
- Log every HITL interaction (request, approver, decision, timestamp) for audit trails.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Requiring HITL approval for every step — creates approval fatigue leading to rubber-stamping.
|
||||||
|
- Presenting raw LLM output or tool call JSON to approvers.
|
||||||
|
- HITL with no timeout — human unavailability should be a handled failure mode.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Observability
|
||||||
|
|
||||||
|
### 19. AI Agent Observability with OpenTelemetry (OTEL, 2025)
|
||||||
|
Source: https://opentelemetry.io/blog/2025/ai-agent-observability/
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- The industry is converging on OTEL as the standard for AI agent telemetry. Emit once, route to any backend without vendor lock-in. GenAI Semantic Conventions are being standardized.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Multi-agent traces must reconstruct *why* an agent made a decision, not just *what* it did and *how long* it took. This requires correlation IDs linking all calls in a single task, parent-child span relationships across agent boundaries.
|
||||||
|
- Datadog launched AI Agent Monitoring (DASH 2025). Microsoft integrated multi-agent observability across Semantic Kernel, LangGraph, LangChain, OpenAI Agents SDK.
|
||||||
|
- Two audiences: LangSmith for prompt-level debugging in development; Datadog/Grafana for production operational monitoring.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Instrument with OTEL from day one using GenAI semantic conventions.
|
||||||
|
- Emit a trace per agent task with: task ID, parent task ID, agent role, FSM state transitions, tool calls as child spans, final output, success/failure, token counts per step.
|
||||||
|
- Propagate correlation IDs through all agent-to-agent calls. Without this, multi-agent debugging is blind.
|
||||||
|
- Alert on: agent loop depth >10 steps without completion, tool error rate >20% on any tool over 5 minutes, token-per-task cost 2x baseline.
|
||||||
|
- Capture the full state object at each checkpoint — this enables time-travel debugging.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Logging only the final output of each agent.
|
||||||
|
- Building custom observability infrastructure when OTEL + a backend is available.
|
||||||
|
- Storing raw conversation histories as the only observability artifact.
|
||||||
|
- Instrumenting only happy-path flows — errors, retries, and HITL interrupts must also emit structured spans.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Software Engineering Agents
|
||||||
|
|
||||||
|
### 20. SWE-agent: Agent-Computer Interfaces Enable Automated Software Engineering (Yang et al., 2024)
|
||||||
|
Source: https://arxiv.org/abs/2405.15793
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- The interface between model and environment is part of the model's performance.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Good repo agents need a disciplined shell/editor/test interface, not just a better prompt.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Design the action surface carefully.
|
||||||
|
- Short loops over read/search/edit/test beat abstract planning without execution.
|
||||||
|
|
||||||
|
### 21. Agentless: Demystifying LLM-based Software Engineering Agents (Xia et al., 2024)
|
||||||
|
Source: https://arxiv.org/abs/2407.01489
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- A simpler pipeline can outperform complex software agents at lower cost.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Simpler decomposition often beats a giant autonomous loop.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Always benchmark against a simpler non-agentic or lightly agentic baseline.
|
||||||
|
- If a full agent loop is not clearly better, cut it.
|
||||||
|
|
||||||
|
### 22. PatchPilot: A Cost-Efficient Software Engineering Agent (2025)
|
||||||
|
Source: https://arxiv.org/abs/2502.02747
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- A rule-based 5-step workflow matches or beats fully agentic approaches at a fraction of the cost (under $1/instance on SWE-bench).
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Adding an explicit localization step before generation measurably improves patch quality. Rule-based planning provides stability; agent-based planning provides peak performance. A hybrid uses rules as the default and escalates to agent planning on failure.
|
||||||
|
|
||||||
|
5-step workflow:
|
||||||
|
1. Reproduction — verify the issue is reproducible
|
||||||
|
2. Localization — retrieve relevant context from the codebase
|
||||||
|
3. Generation — produce the patch
|
||||||
|
4. Validation — run tests/checks
|
||||||
|
5. Refinement — iterate until validation passes
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Before generating a fix, explicitly localize: find the affected files/functions and pull them into context.
|
||||||
|
- Use rule-based orchestration as the stable default; reserve LLM-driven planning for cases where the rule path has already failed.
|
||||||
|
- Treat refinement as a bounded loop with a fixed retry budget, not open-ended re-generation.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Evaluation
|
||||||
|
|
||||||
|
### 23. Demystifying Evals for AI Agents (Anthropic, 2026)
|
||||||
|
Source: https://www.anthropic.com/engineering/demystifying-evals-for-ai-agents
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- One of the best practical writeups on agent evals and reliability.
|
||||||
|
|
||||||
|
High-signal takeaways:
|
||||||
|
- Start early; 20–50 tasks is enough to begin.
|
||||||
|
- Write unambiguous tasks with reference solutions.
|
||||||
|
- Evaluate both "should do X" and "should not do X."
|
||||||
|
- Isolate trials from each other.
|
||||||
|
- Grade outputs/outcomes, not rigid exact traces.
|
||||||
|
- Calibrate model graders against humans.
|
||||||
|
- Read transcripts constantly.
|
||||||
|
- Treat eval-driven development as normal engineering.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Search/tool-use policies should be evaluated on both over-triggering and under-triggering.
|
||||||
|
- Coding agents should be graded on artifacts and tests, not whether they followed a specific thought path.
|
||||||
|
- If the model improved but the score did not, suspect the benchmark or grader too.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Projects Worth Studying
|
||||||
|
|
||||||
|
### 1. karpathy/autoresearch
|
||||||
|
Source: https://github.com/karpathy/autoresearch
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- Extremely narrow loop, fixed optimization target, small mutable surface, experiment-first framing.
|
||||||
|
|
||||||
|
Copy: tight loop, fixed budget, metric-first automation.
|
||||||
|
|
||||||
|
Avoid: generalizing it into a broad orchestration layer unless evals justify it.
|
||||||
|
|
||||||
|
### 2. davebcn87/pi-autoresearch
|
||||||
|
Source: https://github.com/davebcn87/pi-autoresearch
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- Explicit session files, checks vs. crashes vs. metric logs, dashboard and widget feedback.
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- Make experiment state visible.
|
||||||
|
- Distinguish correctness failures from benchmark failures.
|
||||||
|
- Commit only after the right checks pass.
|
||||||
|
|
||||||
|
### 3. SWE-agent / mini-SWE-agent
|
||||||
|
Source: https://github.com/princeton-nlp/SWE-agent
|
||||||
|
|
||||||
|
What to study: repo-focused action surface, issue → inspect → edit → test loop, benchmark-first iteration.
|
||||||
|
|
||||||
|
Copy: narrow interface and strong harnessing.
|
||||||
|
|
||||||
|
### 4. OpenHands
|
||||||
|
Source: https://github.com/All-Hands-AI/OpenHands
|
||||||
|
|
||||||
|
What to study: broad workspace/runtime architecture, interactive software agent product design.
|
||||||
|
|
||||||
|
Copy carefully: runtime ergonomics and environment handling.
|
||||||
|
|
||||||
|
Risk: very easy to absorb too much framework complexity.
|
||||||
|
|
||||||
|
### 5. aider's architect/editor split
|
||||||
|
Source: https://aider.chat/2024/09/26/architect.html
|
||||||
|
|
||||||
|
What to study: separate high-level reasoning from concrete editing.
|
||||||
|
|
||||||
|
Copy: planner/editor separation can help when one lane should stay terse and execution-oriented.
|
||||||
|
|
||||||
|
Risk: only worth it if the split clearly improves results on your tasks.
|
||||||
|
|
||||||
|
### 6. ATLAS (Adaptive Test-time Learning and Autonomous Specialization)
|
||||||
|
Source: https://github.com/itigges22/ATLAS
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- Self-hosted coding agent achieving 74.6% on LiveCodeBench using a quantized 14B Qwen model on a single consumer GPU (RTX 5060 Ti, 16GB VRAM).
|
||||||
|
- Three-phase pipeline: **Generate → Verify → Repair**
|
||||||
|
- *Generate*: PlanSearch extracts constraints and produces diverse candidate solutions; Budget Forcing controls token spend during inference
|
||||||
|
- *Verify*: a "Geometric Lens" component scores candidates with a 5120-dimensional energy field (87.8% selection accuracy) plus sandboxed execution
|
||||||
|
- *Repair*: failing candidates trigger self-generated test cases and iterative refinement via PR-CoT (Problem-Repair Chain-of-Thought)
|
||||||
|
- ~$0.004/task in local electricity vs. $0.043–$0.066 for comparable API services; no external API calls.
|
||||||
|
|
||||||
|
Why it belongs here:
|
||||||
|
- Working proof that smart infrastructure — not model scale — can close the gap with frontier systems. Doubles baseline pass rate (from ~38% to 74.6%) entirely through the generation/verification/repair scaffold.
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- generate → external verify → self-repair loop as a default pattern for coding tasks.
|
||||||
|
- Budget forcing to limit token waste on low-confidence generations.
|
||||||
|
- Distinguish candidate selection accuracy from final pass rate — they are different metrics.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Treating it as a general-purpose agent; optimized explicitly for LiveCodeBench.
|
||||||
|
- Sequential pipeline if throughput matters.
|
||||||
|
|
||||||
|
Risk: the Geometric Lens is described as undertrained; verification signal could be a bottleneck on new domains.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Distilled Rules for Orchestration
|
||||||
|
|
||||||
|
### Choosing the Architecture
|
||||||
|
- Default to a single LLM call or a simple workflow.
|
||||||
|
- Add an evaluator-optimizer loop when correctness matters and the task benefits from revision.
|
||||||
|
- Add multiple agents only when evals show clear gains from role separation.
|
||||||
|
- Use heterogeneous agents (different roles, models, or tool access), not homogeneous swarms.
|
||||||
|
|
||||||
|
### State Machine Design
|
||||||
|
- Minimum states: `PLANNING`, `EXECUTING`, `OBSERVING`, `ERROR_RECOVERY`, `DONE`.
|
||||||
|
- Each state: one well-defined prompt, allowed tools, explicit transition conditions.
|
||||||
|
- Error state is mandatory — not optional.
|
||||||
|
- Transition counter per state to prevent loops.
|
||||||
|
- Routing logic lives in code, not in LLM prompts.
|
||||||
|
|
||||||
|
### Memory
|
||||||
|
- Don't treat the context window as your only memory.
|
||||||
|
- Two minimum layers: in-context working buffer + persistent episodic store with structured metadata.
|
||||||
|
- Consolidation job: after task completion, abstract lessons into semantic memory.
|
||||||
|
- Memory entries: structured notes with description, keywords, tags, outcome at write time.
|
||||||
|
|
||||||
|
### Context Management
|
||||||
|
- Default: observation masking (replace old tool outputs with placeholders; keep reasoning chain).
|
||||||
|
- Trigger compaction at 70–80% of context limit — before the LLM call.
|
||||||
|
- Always preserve: original task spec, last N turns verbatim, current goal state.
|
||||||
|
- LLM summarization only as a fallback for single oversized responses.
|
||||||
|
|
||||||
|
### Error Recovery
|
||||||
|
- Retry with exponential backoff + jitter. Cap at 3 attempts.
|
||||||
|
- Circuit breaker at the LLM client level.
|
||||||
|
- Tool errors return as structured observations, not crashes.
|
||||||
|
- After 2 consecutive failures on the same action: planning reset.
|
||||||
|
- Per-task retry budget, not just per-call.
|
||||||
|
|
||||||
|
### Multi-Agent Design
|
||||||
|
- Use one agent unless there is a measured reason to split.
|
||||||
|
- Split by capability, not by story or persona.
|
||||||
|
- Small helpers do mechanical work; larger models handle synthesis and edge-case reasoning.
|
||||||
|
- Coordination prompts name the shared objective and each role's responsibility.
|
||||||
|
- Per-subagent permission scopes defined in config, not in prompts.
|
||||||
|
|
||||||
|
### Evaluation
|
||||||
|
- Run the same harness the product actually uses.
|
||||||
|
- Keep trials isolated.
|
||||||
|
- Track pass@1 and consistency, not just "found a good answer once."
|
||||||
|
- Review transcripts every week if the system matters.
|
||||||
|
- Rebuild evals from real failures and real manual checks.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Anti-Patterns
|
||||||
|
|
||||||
|
- Too many homogeneous agents
|
||||||
|
- Persona-rich orchestration prompts with weak task constraints
|
||||||
|
- Unbounded self-reflection loops
|
||||||
|
- Auto-commits without validation
|
||||||
|
- Massive context files with no ownership
|
||||||
|
- Grading the exact tool path instead of the delivered outcome
|
||||||
|
- Building a platform before validating a narrow workflow
|
||||||
|
- Routing logic embedded in LLM prompts instead of code
|
||||||
|
- Missing error state in agent FSM
|
||||||
|
- Context growing unchecked until hard limit
|
||||||
|
- HITL approvals with raw JSON or no plain-language summary
|
||||||
|
- Agent-to-agent calls without correlation IDs
|
||||||
|
- Memory as only a raw vector store with no structured metadata
|
||||||
|
- Stale harness components after model upgrades
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## What To Re-Read Often
|
||||||
|
|
||||||
|
- Anthropic, Building Effective AI Agents
|
||||||
|
- Anthropic, Harness Design for Long-Running Application Development
|
||||||
|
- Anthropic, Demystifying Evals for AI Agents
|
||||||
|
- Anthropic, Programmatic Tool Calling Docs
|
||||||
|
- BAIR, The Shift from Models to Compound AI Systems
|
||||||
|
- StateFlow (FSM-based agent loops)
|
||||||
|
- JetBrains Research, Efficient Context Management
|
||||||
|
- A-MEM (memory network design)
|
||||||
|
- Agentless
|
||||||
|
- SWE-agent
|
||||||
|
- karpathy/autoresearch
|
||||||
|
- pi-autoresearch
|
||||||
|
- ATLAS (generate → verify → repair; small-model infra vs. scale)
|
||||||
|
- Multi-Agent Orchestration for Deterministic Decision Support
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Update Policy
|
||||||
|
|
||||||
|
When adding a new source, prefer:
|
||||||
|
- primary paper
|
||||||
|
- official engineering article
|
||||||
|
- official project README or documentation
|
||||||
|
|
||||||
|
For each new source, capture:
|
||||||
|
- what it claims
|
||||||
|
- what to copy into orchestration design
|
||||||
|
- what to avoid
|
||||||
|
- whether it actually changes system design decisions
|
||||||
|
|
||||||
|
If it does not change design decisions, it probably does not belong here.
|
||||||
|
|
||||||
|
*Last updated: 2026-04-01*
|
||||||
@@ -0,0 +1,500 @@
|
|||||||
|
# Prompting Strategies for Single Agents
|
||||||
|
|
||||||
|
A practical, research-backed field guide for writing prompts that make a single LLM agent more capable and reliable.
|
||||||
|
|
||||||
|
Use it for:
|
||||||
|
- system prompt design
|
||||||
|
- reasoning and tool-use strategy
|
||||||
|
- structured output and format control
|
||||||
|
- reliability and brittleness mitigation
|
||||||
|
- uncertainty and verification policy
|
||||||
|
|
||||||
|
The goal is to keep the highest-signal findings that actually change how a prompt should be written. Orchestration, multi-agent design, and evaluation live in `Research-orchestration.md`.
|
||||||
|
|
||||||
|
## Fast Takeaways
|
||||||
|
|
||||||
|
1. Start with zero-shot + clear instruction. Add few-shot examples only when you need format stability, not extra reasoning.
|
||||||
|
2. Put documents and context at the top of the prompt. Put the query and task at the bottom. This alone can improve quality by ~30%.
|
||||||
|
3. State objective, constraints, and success criteria explicitly. Explain *why* each constraint exists, not just what it is.
|
||||||
|
4. Use XML tags for structure. Ambiguous delimiters in a long prompt cause misinterpretation.
|
||||||
|
5. Give the model an honest escape hatch: `unknown`, `need evidence`, or `search more`. Do not build a prompt that forces false confidence.
|
||||||
|
6. Test every prompt with at least 3–5 paraphrase variants. A single-character change can collapse performance by tens of points.
|
||||||
|
7. For Claude 4.x: use adaptive thinking with an `effort` parameter instead of manual `budget_tokens`. Normal phrasing beats ALL-CAPS urgency.
|
||||||
|
8. Principles outperform personas. Put behavior into numbered constraints with rationales, not theatrical character descriptions.
|
||||||
|
9. Prefer `"do X"` over `"don't do Y"`. Negation-only constraints leave behavioral gaps.
|
||||||
|
10. External verification beats self-critique. Ground revision passes in search results, test output, or grader feedback.
|
||||||
|
|
||||||
|
## What To Copy Into Prompts
|
||||||
|
|
||||||
|
### Structure
|
||||||
|
- Role assignment in the first sentence of the system prompt.
|
||||||
|
- Constraints written as `"do X because Y"` — the rationale makes the rule generalizable.
|
||||||
|
- XML sections for mixing content types: `<instructions>`, `<context>`, `<examples>`, `<input>`.
|
||||||
|
- Long documents at the top; the task instruction and query at the bottom.
|
||||||
|
- 3–5 few-shot examples inside `<example>` tags: diverse, covering edge cases.
|
||||||
|
|
||||||
|
### Reasoning
|
||||||
|
- Test zero-shot CoT before inventing a multi-step scaffold. A minimal reasoning cue often closes the gap.
|
||||||
|
- Use `"think step by step"` or `"reason through this"` as a baseline, then measure what actually helps.
|
||||||
|
- For reasoning-heavy tasks: include `<thinking>` examples in few-shot demonstrations — Claude generalizes the style.
|
||||||
|
- Use adaptive thinking (`effort: high`) for hard problems. Use `effort: low` or disabled thinking for classification and low-latency work.
|
||||||
|
- Prompt for interleaved reasoning over tool results: `"After receiving tool results, carefully reflect on their quality before deciding next steps."`
|
||||||
|
|
||||||
|
### Verification
|
||||||
|
- Append `"Before you finish, verify your answer against [criteria]"` for coding and math tasks.
|
||||||
|
- For factual tasks, ask for quote-extraction before answering: `"Find quotes relevant to [X] in <quotes> tags, then answer."` This forces active retrieval of middle-context content.
|
||||||
|
- After two failed self-correction attempts, prefer grounded external feedback (tests, search, grader) over another introspection pass.
|
||||||
|
|
||||||
|
### Tool Use
|
||||||
|
- Be imperative: `"Change this function"` not `"Could you suggest changes?"` — the model takes the verb literally.
|
||||||
|
- Replace `"CRITICAL: You MUST use this tool"` with `"Use this tool when [condition]"` — Claude 4.x overtriggers on aggressive phrasing.
|
||||||
|
- For parallel tool calls, prompt explicitly for parallelism: `"Call all three tools in a single turn."` Otherwise execution is often sequential.
|
||||||
|
- Never speculate about code you have not read. If the model tends to hallucinate file contents, add: `"Never describe code you have not opened."`.
|
||||||
|
|
||||||
|
### Uncertainty Policy
|
||||||
|
- Put uncertainty policy in the prompt: `"If you cannot verify a claim, say 'unverified' and explain what evidence is missing."`.
|
||||||
|
- Give the model explicit permission to say `unknown` rather than guessing — this makes refusals useful rather than blocking.
|
||||||
|
- State when to escalate: `"If the task requires permissions you do not have, stop and describe what you need."`.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Reasoning and Chain of Thought
|
||||||
|
|
||||||
|
### 1. Large Language Models are Zero-Shot Reasoners (Kojima et al., 2022)
|
||||||
|
Source: https://arxiv.org/abs/2205.11916
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- A very small reasoning cue can unlock much better performance than a plain direct answer.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Before building a complicated prompt chain, test a minimal reasoning baseline.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use simple reasoning scaffolds as the baseline to beat.
|
||||||
|
- If a complex workflow does not outperform a minimal prompt + tool loop, the workflow is probably not worth it.
|
||||||
|
|
||||||
|
### 2. Self-Consistency Improves Chain of Thought Reasoning (Wang et al., 2022)
|
||||||
|
Source: https://arxiv.org/abs/2203.11171
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Sampling multiple reasoning paths and aggregating them can improve correctness on hard reasoning tasks.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Best-of-N / vote / pass@k style decoding is often more useful than one brittle "perfect prompt".
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use selectively for high-value reasoning or planning steps.
|
||||||
|
- Do not apply blindly to every turn — it is a latency and cost tradeoff.
|
||||||
|
|
||||||
|
### 3. ReAct: Synergizing Reasoning and Acting (Yao et al., 2022)
|
||||||
|
Source: https://arxiv.org/abs/2210.03629
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- ReAct formalized the now-standard pattern of interleaving reasoning with external actions.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Reasoning is better when it can touch the world.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- For factual, interactive, or environment-dependent tasks, combine thinking with acting instead of pushing all work into one monologue.
|
||||||
|
- This is a strong default for search, repo work, shell use, and structured tool loops.
|
||||||
|
|
||||||
|
### 4. Tree of Thoughts / Search-Style Deliberation
|
||||||
|
Sources:
|
||||||
|
- Tree of Thoughts: https://arxiv.org/abs/2305.10601
|
||||||
|
- Language Agent Tree Search (LATS): https://arxiv.org/abs/2310.04406
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Search over candidate reasoning paths can improve hard problems when a single left-to-right pass is too brittle.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Deliberate search can help, but it is expensive. Use it for genuinely hard branches, not routine chat.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Keep search/planning loops bounded.
|
||||||
|
- Reach for tree search only when the task is hard enough and the eval gain justifies the extra cost.
|
||||||
|
|
||||||
|
### 5. Zero-Shot Can Be Stronger than Few-Shot CoT (2025)
|
||||||
|
Source: https://arxiv.org/abs/2506.14641
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- For strong modern models, few-shot CoT examples mainly align output format, not reasoning quality. Attention analysis shows models largely ignore exemplar content.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- For frontier models (Claude 3.5+, Qwen2.5-72B+): start with zero-shot + clear instruction. Add few-shot examples primarily for format control, not reasoning.
|
||||||
|
- For smaller or fine-tuned models: few-shot CoT with worked steps still provides meaningful lift.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Test zero-shot first on capable models.
|
||||||
|
- If adding few-shot, target 3–5 diverse examples focused on edge-case output formats.
|
||||||
|
- For format stability at lower cost: add 1–2 examples rather than 5+.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Tool Use and Self-Correction
|
||||||
|
|
||||||
|
### 6. Toolformer: Language Models Can Teach Themselves to Use Tools (Schick et al., 2023)
|
||||||
|
Source: https://arxiv.org/abs/2302.04761
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Tool use is not just a static external heuristic — it can be learned from information need, not keyword triggers.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- A good prompt should direct tool decisions from the information need, not from crude keyword triggers.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Prefer model-directed tool decisions over brittle word lists.
|
||||||
|
- Keep a simple fallback policy, but do not let the fallback dominate product behavior.
|
||||||
|
|
||||||
|
### 7. CRITIC: LLMs Can Self-Correct with Tool-Interactive Critiquing (Gou et al., 2024)
|
||||||
|
Source: https://arxiv.org/abs/2305.11738
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Self-correction becomes much stronger when the critique is grounded in external tools instead of pure self-reflection.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Verification works better with evidence than with vibes.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- When possible, critique drafts against search results, tests, or environment state.
|
||||||
|
- A grounded revision pass is usually higher value than another creative generation pass.
|
||||||
|
|
||||||
|
### 8. Self-Refine: Iterative Refinement with Self-Feedback (Madaan et al., 2023)
|
||||||
|
Source: https://arxiv.org/abs/2303.17651
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Even without external tools, generate → critique → revise can improve outputs.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Revision is a useful primitive, but should be bounded and measured.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Keep self-refine loops short.
|
||||||
|
- Prefer one clear revision pass over open-ended introspection.
|
||||||
|
|
||||||
|
### 9. Reflexion: Language Agents with Verbal Reinforcement Learning (Shinn et al., 2023)
|
||||||
|
Source: https://arxiv.org/abs/2303.11366
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Reflection across attempts can improve repeated-task performance.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Memory is most useful when it captures compact lessons from failures, not giant transcripts.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Store short, actionable reflections from past failures.
|
||||||
|
- Use reflection memory across repeated tasks or sessions, not as an excuse to keep every token forever.
|
||||||
|
|
||||||
|
### 10. Programmatic Tool Calling (Anthropic, 2026)
|
||||||
|
Source: https://platform.claude.com/docs/en/agents-and-tools/tool-use/programmatic-tool-calling
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- When the model can write code that fans out or sequences tool calls, filters large results, and returns a compact summary, this beats paying a round-trip per tool call.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Useful when: 3+ dependent tool calls, large datasets, or parallel checks across many items.
|
||||||
|
- Tool outputs must be treated as untrusted strings. Injection hygiene matters if the execution environment will parse the results.
|
||||||
|
- Not the default for single fast calls or highly interactive steps where code-execution overhead outweighs the gain.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Add batched tool fanout only as an opt-in executor pattern for research-heavy or data-heavy tasks.
|
||||||
|
- Log caller/executor state clearly enough to debug failures and reuse behavior.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Core Sources: Prompt Design and Reliability
|
||||||
|
|
||||||
|
### 11. Lost in the Middle: How Language Models Use Long Contexts (Liu et al., 2023/2024)
|
||||||
|
Source: https://direct.mit.edu/tacl/article/doi/10.1162/tacl_a_00638/119630/
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- LLMs attend well to content at the beginning and end of a context window but show 30%+ degradation on content buried in the middle. The effect holds even for models designed for long contexts.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Placement is a first-class concern. Put documents first, put the query last.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Place long documents and context near the top of the prompt; place the task instruction and query at the bottom (end of the prompt). Anthropic's docs confirm: up to 30% quality improvement from this ordering.
|
||||||
|
- For RAG: use focused retrieval so the relevant chunk is short or placed at a privileged position. Do not fill the context window with undifferentiated text.
|
||||||
|
- Ask the model to extract and quote relevant passages before answering, which forces active retrieval of middle-context content.
|
||||||
|
- Use XML-tagged document structure with index numbers to give the model explicit anchors when presenting multiple documents.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Burying critical facts in the middle of a long prompt.
|
||||||
|
- Assuming "larger context window = better utilization" — window size and utilization quality are independent.
|
||||||
|
|
||||||
|
### 12. Quantifying LM Sensitivity to Spurious Features in Prompt Design (ICLR 2024)
|
||||||
|
Source: https://arxiv.org/abs/2310.11324
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- LLMs show extreme sensitivity to superficially trivial prompt variations. Performance swings of up to 76 accuracy points from single-character formatting differences. This does not improve with scale.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Test prompts in multiple phrasings before deploying. Format effects do not transfer across models.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Test with at least 3–5 paraphrase variants before deploying. If performance swings more than ~5%, the prompt is brittle.
|
||||||
|
- Add 1–2 representative few-shot examples as a "stabilizer" even when zero-shot quality is acceptable — even one example substantially reduces brittleness.
|
||||||
|
- Use XML tag structure to reduce the model's need to parse ambiguous delimiters.
|
||||||
|
- Track prompt versions with version control and re-evaluate after any model upgrade.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Deploying prompts tested in only one phrasing.
|
||||||
|
- Changing punctuation, casing, or whitespace in production prompts without re-evaluation.
|
||||||
|
- Comparing models using a single prompt format — ranking reversals are common.
|
||||||
|
|
||||||
|
### 13. POSIX: A Prompt Sensitivity Index For Large Language Models (EMNLP 2024)
|
||||||
|
Source: https://arxiv.org/abs/2410.02185
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Adding even one few-shot example dramatically reduces prompt sensitivity. Model size and instruction tuning do not.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- If your prompt breaks under slight rewordings, add an example before hunting for a better phrasing.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Template changes cause highest sensitivity on multiple-choice tasks; paraphrasing causes highest sensitivity on open-ended generation. Tune mitigation to the task type.
|
||||||
|
- For production agents with evolving prompts: the POSIX index is a useful pre-deployment stability check.
|
||||||
|
|
||||||
|
### 14. Principled Instructions Are All You Need (2024)
|
||||||
|
Source: https://arxiv.org/abs/2312.16171
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Giving a model 26 structured principles as part of a zero-shot prompt raised GPT-4 accuracy by 57.7% over unstructured baseline prompts.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Write an explicit "operating principles" section in your system prompt — a short numbered list of rules with rationales.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- High-impact principles: (1) assign a role, (2) use affirmative directives, (3) ask for step-by-step reasoning, (4) specify output format, (5) use delimiters/tags, (6) combine CoT with examples for complex tasks.
|
||||||
|
- Principle-based prompting and few-shot prompting are complementary, not competing — combine them for complex reasoning tasks.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Long lists of vague principles ("be helpful, be honest") without specificity — the model cannot operationalize them.
|
||||||
|
- Writing only prohibitions without positive guidance.
|
||||||
|
|
||||||
|
### 15. Control Illusion: The Failure of Instruction Hierarchies in LLMs (2025)
|
||||||
|
Source: https://arxiv.org/abs/2502.15851
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- When system instructions and user instructions conflict, models obey the system prompt only 9.6–45.8% of the time — even the best models. Model size barely helps.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Do not treat system prompt placement as a reliable security boundary.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Make implicit constraints explicit: instead of "be formal with experts," spell out the inference chain: "If the user identifies as a domain expert, use technical language and skip introductory explanations."
|
||||||
|
- Use numbered or labeled constraint lists — explicit labeling improves compliance.
|
||||||
|
- Ask the model to enumerate the constraints that apply before responding for multi-constraint instructions.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Embedding safety-critical or access-control logic solely in a system prompt when the user can also influence conversation turns.
|
||||||
|
- Stacking many constraints in a single sentence — multi-constraint sentences compound failure rates multiplicatively.
|
||||||
|
|
||||||
|
### 16. Constitutional AI: Harmlessness from AI Feedback (Anthropic, 2022)
|
||||||
|
Source: https://www.anthropic.com/research/constitutional-ai-harmlessness-from-ai-feedback
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Behavior is more interpretable and adjustable when it derives from explicit principles than from example-only supervision. At inference time, giving a model a brief written constitution can substantially shape its behavior.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- A short set of explicit, positive principles in a system prompt reliably outperforms long persona descriptions.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Frame principles positively: "When the user asks about X, respond by doing Y."
|
||||||
|
- For safety-sensitive agents, explicitly state the tradeoff: "Engage helpfully with edge-case requests by explaining your reasoning and limitations rather than refusing outright."
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Long vague persona descriptions ("be a warm, helpful assistant with a curious personality..."). Put behavior into constraints, not theatrics.
|
||||||
|
|
||||||
|
### 17. Structured Output Prompting (2025)
|
||||||
|
Sources:
|
||||||
|
- Generating Structured Outputs from LMs: Benchmark and Studies (arxiv 2501.10868)
|
||||||
|
- vLLM Structured Decoding blog: https://blog.vllm.ai/2025/01/14/struct-decode-intro.html
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Prompt-only structured output has a 5–20% failure rate. Schema-enforced constrained decoding removes syntactic failures but can degrade semantic quality without a reasoning field.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Use schema-level enforcement (API structured outputs) for production. Add a `reasoning` field first in the schema so the model can think before filling constrained slots.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use Anthropic's structured outputs feature or equivalent schema enforcement — do not rely on prompting alone for critical structured outputs.
|
||||||
|
- Add a `reasoning` or `thinking` field first in your JSON schema so the model can express intermediate reasoning before filling constrained fields.
|
||||||
|
- For open-source deployments: prefer Guidance (highest coverage, best compliance, fastest) over other constrained-decoding libraries.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Relying only on prompt instructions for critical structured outputs.
|
||||||
|
- Forcing all output into rigid schemas without a reasoning field — you sacrifice semantic quality for syntactic correctness.
|
||||||
|
|
||||||
|
### 18. Extended Thinking and Adaptive Reasoning in Claude 4.x (Anthropic, 2025–2026)
|
||||||
|
Source: https://platform.claude.com/docs/en/build-with-claude/extended-thinking
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Extended thinking gives Claude a scratchpad for intermediate reasoning before producing a final response. In Claude 4.6, adaptive thinking (`type: "adaptive"`) dynamically decides when and how much to think based on task complexity — outperforming manual `budget_tokens`.
|
||||||
|
|
||||||
|
Key takeaways:
|
||||||
|
- Adaptive thinking skips reasoning on simple queries automatically and reasons deeply on complex ones.
|
||||||
|
- General instructions outperform prescriptive steps: "Think thoroughly about this" often beats a hand-written step-by-step plan.
|
||||||
|
- Interleaved thinking between tool calls enables more sophisticated reasoning about tool results.
|
||||||
|
- Overthinking is real: Opus 4.6 at high effort settings does extensive exploration. If unwanted: "Choose an approach and commit to it. Avoid revisiting decisions unless you encounter new contradicting information."
|
||||||
|
- Math performance scales logarithmically with thinking token budget — diminishing returns above 32k.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use `thinking: {type: "adaptive"}` with `effort: "high"` for complex reasoning or multi-step tool use.
|
||||||
|
- Use `effort: "low"` or disabled thinking for chat and classification workloads.
|
||||||
|
- Include `<thinking>` examples in few-shot demonstrations for reasoning-heavy tasks — Claude generalizes the style.
|
||||||
|
- After tool results: "Carefully reflect on the results before deciding the next step." This triggers useful interleaved thinking.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Using `budget_tokens` on Claude 4.6+ — it is deprecated and inferior to adaptive thinking.
|
||||||
|
- Setting `effort: "max"` for simple tasks — inflates latency and cost with no quality benefit.
|
||||||
|
- Writing a detailed prescribed reasoning chain and expecting Claude to follow it exactly — Claude's own reasoning typically exceeds the prescribed plan. Give direction, not a script.
|
||||||
|
|
||||||
|
### 19. LLMLingua: Compressing Prompts for Accelerated Inference (EMNLP 2023 / ACL 2024)
|
||||||
|
Sources:
|
||||||
|
- LLMLingua: https://arxiv.org/abs/2310.05736
|
||||||
|
- LLMLingua-2: https://arxiv.org/abs/2403.12968
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Long prompts degrade quality (lost-in-the-middle) and cost money. LLMLingua-2 achieves up to 20x compression with only ~1.5 accuracy point drop, and is 3–6x faster than v1.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Compress the context/documents portion of the prompt, not the instructions.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use LLMLingua-2 as the default for RAG pipelines: compress retrieved passages before inserting them to reduce context length and improve signal-to-noise.
|
||||||
|
- Compression is also a mitigation for the "lost in the middle" problem — shorter context places key information closer to the ends.
|
||||||
|
- Apply to natural prose/documents, not structured instructions or few-shot examples.
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- Very high compression ratios (>10x) for tasks requiring precise factual recall.
|
||||||
|
- Compressing instructions or few-shot examples — compressors are tuned for prose and may corrupt instruction syntax.
|
||||||
|
|
||||||
|
### 20. Agent READMEs: An Empirical Study of Context Files for Agentic Coding (2025)
|
||||||
|
Source: arXiv:2511.12884
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Agent context files become living operational artifacts, but drift into unreadable piles. Teams over-specify build/run and architecture but badly underspecify security and performance.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Keep agent context short, operational, and constraint-rich.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Add explicit non-functional requirements (latency, safety, permission boundaries).
|
||||||
|
- Treat agent context as maintained configuration, not lore.
|
||||||
|
- Audit for drift whenever the base model or deployment changes.
|
||||||
|
|
||||||
|
### 21. From Biased Chatbots to Biased Agents (2026)
|
||||||
|
Source: arXiv:2602.12285
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Persona baggage can actively hurt agent behavior. Capability framing helps; character acting often hurts.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Keep personalities light. Put behavior into constraints and tools, not theatrics.
|
||||||
|
|
||||||
|
Implication:
|
||||||
|
- Use a short role sentence ("You are a code reviewer focused on correctness and security") rather than an elaborate persona.
|
||||||
|
- All behavioral requirements should appear as explicit constraints, not implied by a character description.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Anthropic Prompting Guidance (Claude 4.x)
|
||||||
|
Source: https://platform.claude.com/docs/en/build-with-claude/prompt-engineering/claude-prompting-best-practices
|
||||||
|
|
||||||
|
High-signal principles for Claude 4.5 / 4.6:
|
||||||
|
|
||||||
|
- **Be explicit, not inferential.** Claude is "a brilliant but new employee" who lacks context on your norms.
|
||||||
|
- **Explain why.** Constraints written as `"do X because Y"` generalize better than bare rules.
|
||||||
|
- **Say what to do, not just what to avoid.** "Your response should be composed of flowing prose paragraphs" outperforms "Do not use markdown."
|
||||||
|
- **XML tags for complex prompts.** Use `<instructions>`, `<context>`, `<examples>`, `<input>` when mixing content types.
|
||||||
|
- **Documents first, query last.** Long-context prompts: context/data at top, task at bottom. Up to 30% quality improvement.
|
||||||
|
- **Avoid ALL-CAPS urgency.** Claude 4.x is more obedient — aggressive phrasing causes overtriggering. Use normal language.
|
||||||
|
- **Prefill is deprecated.** Don't use assistant prefill for format control on Claude 4.6+. Use structured outputs or direct instructions.
|
||||||
|
- **Agentic safety.** Explicitly instruct Claude to pause before irreversible actions: "For actions that are hard to reverse, ask the user before proceeding." Name specific action types.
|
||||||
|
- **Context window awareness.** Tell Claude whether its context will be auto-compacted — otherwise it may artificially truncate work near the limit.
|
||||||
|
- **Match style.** Remove markdown from your prompt if you want markdown-free output — input style propagates to output style.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Distilled Prompt-Writing Rules
|
||||||
|
|
||||||
|
### System Prompt Structure
|
||||||
|
1. One-sentence role assignment at the top.
|
||||||
|
2. Numbered constraints, each with a brief rationale.
|
||||||
|
3. XML-separated sections for context, examples, and input when mixing content types.
|
||||||
|
4. Documents and context before the task. Task and query at the end.
|
||||||
|
5. 3–5 few-shot examples in `<example>` tags; focused on output format and edge cases.
|
||||||
|
|
||||||
|
### Constraint Framing
|
||||||
|
- Positive over negative: "Do X" over "Don't do Y."
|
||||||
|
- Rationale-included: "Do X because Y" over bare "Do X."
|
||||||
|
- Explicit over implicit: spell out multi-hop conditions rather than relying on the model to infer them.
|
||||||
|
- Numbered, not prose-buried: label constraints so the model can enumerate them before responding.
|
||||||
|
|
||||||
|
### Reasoning
|
||||||
|
- Zero-shot CoT baseline first.
|
||||||
|
- Adaptive thinking for hard tasks. Disabled or low-effort for simple tasks.
|
||||||
|
- Bounded revision: one clear self-refine pass, not open-ended introspection.
|
||||||
|
- External grounding beats self-critique for verification.
|
||||||
|
- "Verify your answer against [criteria] before finishing."
|
||||||
|
|
||||||
|
### Uncertainty
|
||||||
|
- Give the model an honest escape hatch: `unknown`, `unverified`, `need evidence`.
|
||||||
|
- State escalation conditions explicitly: when to stop and say what permission or evidence is missing.
|
||||||
|
- Do not build a prompt that forces a confident answer when evidence is absent.
|
||||||
|
|
||||||
|
### Format and Output
|
||||||
|
- Schema enforcement, not prompt-only, for structured outputs in production.
|
||||||
|
- `reasoning` field first in JSON schemas so the model can think before committing to constrained fields.
|
||||||
|
- Explicit "no preamble" instruction if needed: "Respond directly without preamble. Do not start with 'Here is...'"
|
||||||
|
- For parallel tool use: explicitly prompt for parallel execution.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Anti-Patterns
|
||||||
|
|
||||||
|
- Persona-rich prompts with weak task constraints
|
||||||
|
- ALL-CAPS urgency instructions on Claude 4.x
|
||||||
|
- Prompt-only structured output without schema enforcement
|
||||||
|
- Keyword-triggered tool policies
|
||||||
|
- Unbounded self-reflection loops
|
||||||
|
- Burying critical facts in the middle of long prompts
|
||||||
|
- System prompt as security boundary without additional enforcement
|
||||||
|
- Testing prompts in only one phrasing variant
|
||||||
|
- `budget_tokens` on Claude 4.6+ models
|
||||||
|
- Negative-only constraint lists without positive guidance
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## What To Re-Read Often
|
||||||
|
|
||||||
|
- Anthropic Prompting Best Practices docs (platform.claude.com)
|
||||||
|
- Anthropic Extended Thinking docs
|
||||||
|
- ReAct
|
||||||
|
- CRITIC
|
||||||
|
- Lost in the Middle (Liu et al. 2023)
|
||||||
|
- Principled Instructions Are All You Need
|
||||||
|
- POSIX Prompt Sensitivity Index
|
||||||
|
- Control Illusion (instruction hierarchy failure)
|
||||||
|
- Constitutional AI (Anthropic)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Update Policy
|
||||||
|
|
||||||
|
When adding a new source, prefer:
|
||||||
|
- primary paper
|
||||||
|
- official engineering article
|
||||||
|
- official documentation
|
||||||
|
|
||||||
|
For each new source, capture:
|
||||||
|
- what it claims
|
||||||
|
- what to copy into prompts
|
||||||
|
- what to avoid
|
||||||
|
- whether it actually changes how a prompt should be written
|
||||||
|
|
||||||
|
If it does not change prompt design decisions, it probably does not belong here.
|
||||||
|
|
||||||
|
*Last updated: 2026-04-01*
|
||||||
+617
@@ -0,0 +1,617 @@
|
|||||||
|
# Agent Systems Research Notes
|
||||||
|
|
||||||
|
This file is a practical, research-backed field guide for building agentic systems.
|
||||||
|
|
||||||
|
Use it for:
|
||||||
|
- prompt design
|
||||||
|
- orchestration decisions
|
||||||
|
- tool-use policy
|
||||||
|
- automation loop design
|
||||||
|
- eval and reliability practices
|
||||||
|
|
||||||
|
The goal is not to collect every paper. The goal is to keep the highest-signal findings that actually change how an agent or scaffold should be built.
|
||||||
|
|
||||||
|
## Fast Takeaways
|
||||||
|
|
||||||
|
1. Start with the simplest scaffold that can pass evals. Do not default to multi-agent.
|
||||||
|
2. Use tools when the task depends on current facts, exact details, or environment feedback.
|
||||||
|
3. Grade outcomes, artifacts, and grounded evidence, not exact tool-call traces.
|
||||||
|
4. Separate cheap mechanical work from expensive reasoning.
|
||||||
|
5. Use reflection/revision only when it improves measured performance more than it hurts latency/cost.
|
||||||
|
6. Keep prompts short, constraint-like, and verification-oriented. Avoid persona-heavy prompt sludge.
|
||||||
|
7. Read transcripts. If metrics and transcripts disagree, the harness or grader may be wrong.
|
||||||
|
8. Heterogeneous systems beat piles of homogeneous agents when the roles are genuinely different.
|
||||||
|
9. External feedback beats self-confidence. Tests, search results, compiler output, and graders matter.
|
||||||
|
10. Narrow loops outperform vague autonomy. Small mutable surface, fixed metric, bounded retries.
|
||||||
|
|
||||||
|
## What To Copy Into Systems
|
||||||
|
|
||||||
|
### Prompting
|
||||||
|
|
||||||
|
- State objective, constraints, and success criteria explicitly.
|
||||||
|
- Preserve exact terms from the user or evidence; do not rename concrete entities.
|
||||||
|
- Prefer a short rule like "if not verified, say so" over long keyword lists and examples.
|
||||||
|
- Give the model an honest escape hatch: `unknown`, `need evidence`, or `search more`.
|
||||||
|
- Use prompt tricks as baselines first, not as substitutes for retrieval, tests, or evals.
|
||||||
|
|
||||||
|
### Orchestration
|
||||||
|
|
||||||
|
- Keep the default path single-agent or workflow-based.
|
||||||
|
- Add planners, reviewers, or specialist agents only when evals show clear gains.
|
||||||
|
- Prefer bounded loops: one plan, one act phase, one verifier, one retry budget.
|
||||||
|
- Use different models or prompts only when they contribute distinct evidence or skills.
|
||||||
|
- Treat multi-agent diversity as a tool, not a religion.
|
||||||
|
|
||||||
|
### Tooling
|
||||||
|
|
||||||
|
- Favor tools that return verifiable feedback:
|
||||||
|
- tests
|
||||||
|
- compiler errors
|
||||||
|
- search results
|
||||||
|
- fetched pages
|
||||||
|
- graders
|
||||||
|
- Keep traces and artifacts.
|
||||||
|
- Persist compact research notes when follow-up questions are common.
|
||||||
|
- If the task is stale/exact/source-sensitive, lookup beats memory.
|
||||||
|
|
||||||
|
### Automation
|
||||||
|
|
||||||
|
- Fix a metric before running an autonomous loop.
|
||||||
|
- Keep the mutable surface small.
|
||||||
|
- Auto-commit only after checks pass.
|
||||||
|
- Separate "experiment failed" from "checks failed" from "metric regressed".
|
||||||
|
- Prefer narrow optimization targets over grand autonomous platform behavior.
|
||||||
|
|
||||||
|
### Evaluation
|
||||||
|
|
||||||
|
- Build evals from real failures and real manual checks.
|
||||||
|
- Balance both sides of decision boundaries:
|
||||||
|
- should search
|
||||||
|
- should not search
|
||||||
|
- Isolate trials. No shared repo state, hidden cache, or leaked history.
|
||||||
|
- Use deterministic graders where possible.
|
||||||
|
- Use LLM graders with clear rubrics and human calibration when needed.
|
||||||
|
- Track both quality and consistency.
|
||||||
|
|
||||||
|
## Core Sources
|
||||||
|
|
||||||
|
## Prompting And Reasoning
|
||||||
|
|
||||||
|
### 1. Large Language Models are Zero-Shot Reasoners (Kojima et al., 2022)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2205.11916
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- A very small reasoning cue can unlock much better performance than a plain direct answer.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Before inventing a complicated prompt chain, test a minimal reasoning baseline.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Use simple reasoning scaffolds as the baseline to beat.
|
||||||
|
- If a complex workflow does not outperform a minimal prompt + tool loop, the workflow is probably not worth it.
|
||||||
|
|
||||||
|
### 2. Self-Consistency Improves Chain of Thought Reasoning in Language Models (Wang et al., 2022)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2203.11171
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Sampling multiple reasoning paths and aggregating them can improve correctness on hard reasoning tasks.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Best-of-N / vote / pass@k style decoding is often more useful than one brittle "perfect prompt".
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Use this selectively for high-value reasoning or planning steps.
|
||||||
|
- Do not apply it blindly to every turn; it is a latency and cost tradeoff.
|
||||||
|
|
||||||
|
### 3. ReAct: Synergizing Reasoning and Acting in Language Models (Yao et al., 2022)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2210.03629
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- ReAct formalized the now-standard pattern of interleaving reasoning with external actions.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Reasoning is better when it can touch the world.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- For factual, interactive, or environment-dependent tasks, combine thinking with acting instead of pushing all work into one monologue.
|
||||||
|
- This is a strong default for search, repo work, shell use, and structured tool loops.
|
||||||
|
|
||||||
|
### 4. Tree of Thoughts / Search-Style Deliberation
|
||||||
|
Sources:
|
||||||
|
- Tree of Thoughts: https://arxiv.org/abs/2305.10601
|
||||||
|
- Language Agent Tree Search (LATS): https://arxiv.org/abs/2310.04406
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Search over candidate reasoning paths can improve hard problems when a single left-to-right pass is too brittle.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Deliberate search can help, but it is expensive. Use it for genuinely hard branches, not for routine chat.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Keep search/planning loops bounded.
|
||||||
|
- Reach for tree search only when the task is hard enough and the eval gain justifies the extra cost.
|
||||||
|
|
||||||
|
## Tool Use And Self-Correction
|
||||||
|
|
||||||
|
### 5. Toolformer: Language Models Can Teach Themselves to Use Tools (Schick et al., 2023)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2302.04761
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Tool use is not just a static external heuristic; it can be learned and integrated into the model's behavior.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- A good agent should decide when to call tools from the information need, not from crude keyword triggers.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Prefer model-directed tool decisions over brittle word lists.
|
||||||
|
- Keep a simple fallback policy, but do not let the fallback dominate the product behavior.
|
||||||
|
|
||||||
|
### 6. CRITIC: Large Language Models Can Self-Correct with Tool-Interactive Critiquing (Gou et al., 2024)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2305.11738
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Self-correction becomes much stronger when the critique is grounded in external tools instead of pure self-reflection.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Verification works better with evidence than with vibes.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- When possible, critique drafts against search results, tests, or environment state.
|
||||||
|
- A grounded revision pass is usually higher value than another creative generation pass.
|
||||||
|
|
||||||
|
### 7. Self-Refine: Iterative Refinement with Self-Feedback (Madaan et al., 2023)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2303.17651
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Even without external tools, generate -> critique -> revise can improve outputs.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Revision is a useful primitive, but should be bounded and measured.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Keep self-refine loops short.
|
||||||
|
- Prefer one clear revision pass over open-ended introspection.
|
||||||
|
|
||||||
|
### 8. Reflexion: Language Agents with Verbal Reinforcement Learning (Shinn et al., 2023)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2303.11366
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Reflection across attempts can improve repeated-task performance.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Memory is most useful when it captures compact lessons from failures, not giant transcripts.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Store short, actionable reflections.
|
||||||
|
- Use memory across repeated tasks or sessions, not as an excuse to keep every token forever.
|
||||||
|
|
||||||
|
### 8a. Programmatic Tool Calling (Anthropic Docs, 2026)
|
||||||
|
Source:
|
||||||
|
- https://platform.claude.com/docs/en/agents-and-tools/tool-use/programmatic-tool-calling
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Strong practical guidance on when a model should batch tool work inside a code/execution environment instead of paying a model round-trip per tool call.
|
||||||
|
|
||||||
|
Key takeaways from the docs:
|
||||||
|
- Programmatic tool calling is useful when the model can write code that fans out or sequences tool calls, filters large intermediate results, and returns only the compact summary back into context.
|
||||||
|
- This is especially attractive for multi-step workflows with 3+ dependent tool calls, large datasets, or parallel checks across many items.
|
||||||
|
- Caller boundaries matter. Tools should usually be either direct-call tools or execution-only tools, not both by default.
|
||||||
|
- Tool outputs must be treated as untrusted strings. Validation and injection hygiene matter if the execution environment will parse or act on those results.
|
||||||
|
- This is not the default for single fast calls or highly interactive steps where the code-execution overhead outweighs the gain.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Add batched tool fanout only as an opt-in executor pattern for research-heavy or data-heavy tasks.
|
||||||
|
- Use it to cut latency and context pressure, not to replace the main verifier contract.
|
||||||
|
- If implemented, log caller/executor state clearly enough to debug failures and reuse behavior.
|
||||||
|
|
||||||
|
## System Design And Orchestration
|
||||||
|
|
||||||
|
### 9. The Shift from Models to Compound AI Systems (BAIR, 2024)
|
||||||
|
Source:
|
||||||
|
- https://bair.berkeley.edu/blog/2024/02/18/compound-ai-systems/
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Strong AI systems increasingly come from multiple interacting components, not just bigger base models.
|
||||||
|
|
||||||
|
Key takeaways from the article:
|
||||||
|
- system design can improve quality faster than scaling alone
|
||||||
|
- current-data access, control, trust, and cost are often easier to solve at the system level
|
||||||
|
- optimizing a compound system is a distinct engineering problem
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Build around tools, retrievers, graders, and routers when they solve a real product problem.
|
||||||
|
- Do not mistake "compound system" for "maximally complex system".
|
||||||
|
|
||||||
|
### 10. Building Effective AI Agents (Anthropic, 2026)
|
||||||
|
Source:
|
||||||
|
- https://resources.anthropic.com/building-effective-ai-agents
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- High-quality practical guidance from a team operating real agent systems at scale.
|
||||||
|
|
||||||
|
The most useful framing:
|
||||||
|
- choose between single-agent, workflow, and multi-agent designs intentionally
|
||||||
|
- use a small set of reusable patterns:
|
||||||
|
- sequential
|
||||||
|
- parallel
|
||||||
|
- evaluator-optimizer
|
||||||
|
- match system complexity to business value
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Default to simple workflows first.
|
||||||
|
- Reach for evaluator-optimizer when correctness matters and the task benefits from revision.
|
||||||
|
- Reach for multi-agent only after single-agent/workflow baselines are exhausted.
|
||||||
|
|
||||||
|
### 10a. Harness Design for Long-Running Application Development (Anthropic, 2026)
|
||||||
|
Source:
|
||||||
|
- https://www.anthropic.com/engineering/harness-design-long-running-apps
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Strong, current practical guidance on long-running coding harnesses from a team actively tuning them against real app-building tasks.
|
||||||
|
|
||||||
|
Key takeaways from the article:
|
||||||
|
- Separate generator and evaluator roles. Self-evaluation is too lenient; a tuned external evaluator is much more useful.
|
||||||
|
- Make "done" explicit before coding. Anthropic used planner output plus a per-sprint contract negotiated between builder and evaluator.
|
||||||
|
- Keep planner output high-level and product-facing. Over-specifying low-level implementation details too early can cascade bad assumptions.
|
||||||
|
- Use evaluators that touch the environment directly. Playwright-driven QA against real UI behavior, API behavior, and data state is much stronger than static inspection.
|
||||||
|
- Use hard thresholds for acceptance, not vague approval. If a criterion misses, fail the chunk and return actionable feedback.
|
||||||
|
- Preserve handoff artifacts and structured files between agents. File-based communication and contracts reduce drift across long runs.
|
||||||
|
- Context resets vs compaction is a model-specific engineering choice. Resets help when the model shows context anxiety; stronger models may make resets unnecessary.
|
||||||
|
- Every harness component encodes an assumption about model weakness. Re-run ablations and remove scaffold that is no longer load-bearing after model upgrades.
|
||||||
|
- Evaluators are worth the cost near the model's capability boundary. When the model can already do the task reliably solo, evaluator passes can become mostly overhead.
|
||||||
|
- Read logs and calibrate the evaluator from real disagreements. Prompt tuning should come from concrete misses, not abstract "better QA" wishes.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Keep coder and reviewer/verifier separate when acceptance quality matters.
|
||||||
|
- Add an explicit contract or acceptance plan before implementation when the spec is high-level.
|
||||||
|
- Prefer grounded evaluator tools over reviewer vibes.
|
||||||
|
- Keep handoff state compact and structured enough to survive resets when resets are needed.
|
||||||
|
- Revisit harness complexity whenever the base model changes; stale scaffold is real technical debt.
|
||||||
|
|
||||||
|
### 11. Understanding Agent Scaling via Diversity (2026)
|
||||||
|
Source:
|
||||||
|
- arXiv:2602.03794
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- More homogeneous agents do not scale indefinitely; diversity matters more than count.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Two meaningfully different agents can outperform a swarm of same-ish agents.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Diversity should come from role, model, tool access, or evidence channel.
|
||||||
|
- Do not duplicate the same model/prompt ten times and call it orchestration.
|
||||||
|
|
||||||
|
### 12. SOLVE-Med / MATA / Small-Model Orchestration (2025-2026)
|
||||||
|
Sources:
|
||||||
|
- SOLVE-Med: arXiv:2511.03542
|
||||||
|
- MATA: arXiv:2602.09642
|
||||||
|
|
||||||
|
Why they matter:
|
||||||
|
- Small specialized models, when orchestrated well, can outperform or match much larger standalone systems.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Cheap specialists for mechanical subproblems are a real design pattern, not a hack.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Route grep/read/run/simple classification to cheaper lanes.
|
||||||
|
- Reserve expensive models for hard reasoning or integration steps.
|
||||||
|
|
||||||
|
Concrete example (see Projects section):
|
||||||
|
- ATLAS achieves 74.6% on LiveCodeBench using a quantized 14B model on a single consumer GPU by layering structured generation, energy-based verification, and self-verified repair — no frontier model, no cloud API. The infrastructure more than doubles the baseline pass rate.
|
||||||
|
|
||||||
|
### 13. Agent READMEs: An Empirical Study of Context Files for Agentic Coding (2025)
|
||||||
|
Source:
|
||||||
|
- arXiv:2511.12884
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Agent context files become living operational artifacts, but often drift into unreadable piles.
|
||||||
|
|
||||||
|
Key takeaways from the study:
|
||||||
|
- teams heavily specify build/run, architecture, and implementation context
|
||||||
|
- security and performance are badly underspecified
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Keep context files short, operational, and constraint-rich.
|
||||||
|
- Add explicit non-functional requirements.
|
||||||
|
- Treat agent context as maintained configuration, not lore.
|
||||||
|
|
||||||
|
### 14. From Biased Chatbots to Biased Agents (2026)
|
||||||
|
Source:
|
||||||
|
- arXiv:2602.12285
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Persona baggage can actively hurt agent behavior.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Capability framing helps; character acting often hurts.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Keep personalities light.
|
||||||
|
- Put behavior into constraints and tools, not theatrics.
|
||||||
|
|
||||||
|
### 15. Emergent Coordination in Multi-Agent Systems (2025)
|
||||||
|
Source:
|
||||||
|
- arXiv:2510.05174
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Coordination is better when agents share objectives and understand complementary roles.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Role awareness is useful; vague social-role prompts are not enough.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- When using multiple agents, explicitly describe what each one contributes and how outputs combine.
|
||||||
|
|
||||||
|
## Software Engineering Agents
|
||||||
|
|
||||||
|
### 16. SWE-agent: Agent-Computer Interfaces Enable Automated Software Engineering (Yang et al., 2024)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2405.15793
|
||||||
|
- https://github.com/princeton-nlp/SWE-agent
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- The interface between model and environment is part of the model's performance.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Good repo agents need a disciplined shell/editor/test interface, not just a better prompt.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Design the action surface carefully.
|
||||||
|
- Short loops over read/search/edit/test beat abstract planning without execution.
|
||||||
|
|
||||||
|
### 17. Agentless: Demystifying LLM-based Software Engineering Agents (Xia et al., 2024)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2407.01489
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- A simpler pipeline can outperform complex software agents at lower cost.
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Simpler decomposition often beats a giant autonomous loop.
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Always benchmark against a simpler non-agentic or lightly agentic baseline.
|
||||||
|
- If a full agent loop is not clearly better, cut it.
|
||||||
|
|
||||||
|
### 18. PatchPilot: A Cost-Efficient Software Engineering Agent (2025)
|
||||||
|
Source:
|
||||||
|
- https://arxiv.org/abs/2502.02747
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- Demonstrates that a rule-based 5-step workflow can match or beat fully agentic approaches at a fraction of the cost (under $1/instance on SWE-bench).
|
||||||
|
|
||||||
|
Key takeaway:
|
||||||
|
- Adding an explicit *localization* step before generation — retrieve relevant context from the codebase — measurably improves patch quality. Rule-based planning provides stability; agent-based planning provides peak performance. A hybrid uses rules as the default and escalates to agent planning on failure.
|
||||||
|
|
||||||
|
5-step workflow:
|
||||||
|
1. Reproduction — verify the issue is reproducible
|
||||||
|
2. Localization — retrieve relevant context from the codebase
|
||||||
|
3. Generation — produce the patch
|
||||||
|
4. Validation — run tests/checks
|
||||||
|
5. Refinement — iterate until validation passes
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Before generating a fix, explicitly localize: find the affected files/functions and pull them into context.
|
||||||
|
- Use rule-based orchestration as the stable default; reserve LLM-driven planning for cases where the rule path has already failed.
|
||||||
|
- Treat refinement as a bounded loop with a fixed retry budget, not open-ended re-generation.
|
||||||
|
|
||||||
|
## Evaluation And Reliability
|
||||||
|
|
||||||
|
### 18. Demystifying evals for AI agents (Anthropic, 2026)
|
||||||
|
Source:
|
||||||
|
- https://www.anthropic.com/engineering/demystifying-evals-for-ai-agents
|
||||||
|
|
||||||
|
Why it matters:
|
||||||
|
- This is one of the best practical writeups on agent evals and reliability.
|
||||||
|
|
||||||
|
High-signal takeaways:
|
||||||
|
- start early; 20-50 tasks is enough to begin
|
||||||
|
- write unambiguous tasks with reference solutions
|
||||||
|
- evaluate both "should do X" and "should not do X"
|
||||||
|
- isolate trials from each other
|
||||||
|
- grade outputs/outcomes, not rigid exact traces
|
||||||
|
- calibrate model graders against humans
|
||||||
|
- read transcripts constantly
|
||||||
|
- treat eval-driven development as normal engineering
|
||||||
|
|
||||||
|
Implication for agents:
|
||||||
|
- Search/tool-use policies should be evaluated on both over-triggering and under-triggering.
|
||||||
|
- Coding agents should be graded on artifacts and tests, not whether they followed a specific thought path.
|
||||||
|
|
||||||
|
## Projects Worth Studying
|
||||||
|
|
||||||
|
These are not all research papers, but they are useful design references.
|
||||||
|
|
||||||
|
### 1. karpathy/autoresearch
|
||||||
|
Source:
|
||||||
|
- https://github.com/karpathy/autoresearch
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- extremely narrow loop
|
||||||
|
- fixed optimization target
|
||||||
|
- small mutable surface
|
||||||
|
- experiment-first framing instead of "general agent platform"
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- tight loop, fixed budget, metric-first automation
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- generalizing it into a broad orchestration layer unless evals justify it
|
||||||
|
|
||||||
|
### 2. davebcn87/pi-autoresearch
|
||||||
|
Source:
|
||||||
|
- https://github.com/davebcn87/pi-autoresearch
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- practical extension of the autoresearch idea
|
||||||
|
- explicit session files
|
||||||
|
- checks vs crashes vs metric logs
|
||||||
|
- dashboard and widget feedback
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- make experiment state visible
|
||||||
|
- distinguish correctness failures from benchmark failures
|
||||||
|
- commit only after the right checks pass
|
||||||
|
|
||||||
|
### 3. SWE-agent / mini-SWE-agent
|
||||||
|
Source:
|
||||||
|
- https://github.com/princeton-nlp/SWE-agent
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- repo-focused action surface
|
||||||
|
- issue -> inspect -> edit -> test loop
|
||||||
|
- benchmark-first iteration
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- narrow interface and strong harnessing
|
||||||
|
|
||||||
|
### 4. OpenHands
|
||||||
|
Source:
|
||||||
|
- https://github.com/All-Hands-AI/OpenHands
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- broad workspace/runtime architecture
|
||||||
|
- interactive software agent product design
|
||||||
|
|
||||||
|
Copy carefully:
|
||||||
|
- runtime ergonomics and environment handling
|
||||||
|
|
||||||
|
Risk:
|
||||||
|
- very easy to absorb too much framework complexity
|
||||||
|
|
||||||
|
### 5. aider's architect/editor split
|
||||||
|
Source:
|
||||||
|
- https://aider.chat/2024/09/26/architect.html
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- separate high-level reasoning from concrete editing
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- planner/editor separation can help when one lane should stay terse and execution-oriented
|
||||||
|
|
||||||
|
Risk:
|
||||||
|
- only worth it if the split clearly improves results on your tasks
|
||||||
|
|
||||||
|
### 6. ATLAS (Adaptive Test-time Learning and Autonomous Specialization)
|
||||||
|
Source:
|
||||||
|
- https://github.com/itigges22/ATLAS
|
||||||
|
|
||||||
|
What to study:
|
||||||
|
- a self-hosted coding agent that achieves 74.6% on LiveCodeBench using a quantized 14B Qwen model on a single consumer GPU (RTX 5060 Ti, 16GB VRAM)
|
||||||
|
- three-phase pipeline: **Generate → Verify → Repair**
|
||||||
|
- *Generate*: PlanSearch extracts constraints and produces diverse candidate solutions; Budget Forcing controls token spend during inference
|
||||||
|
- *Verify*: a "Geometric Lens" component scores candidates with a 5120-dimensional energy field (87.8% selection accuracy) plus sandboxed execution
|
||||||
|
- *Repair*: failing candidates trigger self-generated test cases and iterative refinement via PR-CoT (Problem-Repair Chain-of-Thought)
|
||||||
|
- estimated ~$0.004/task in local electricity vs. $0.043–$0.066 for comparable API services; no external API calls required
|
||||||
|
|
||||||
|
Why it belongs here:
|
||||||
|
- It is a working proof that smart infrastructure — not model scale — can close the gap with frontier systems
|
||||||
|
- Directly validates the small-model orchestration pattern from #12: doubling the baseline pass rate (from ~38% to 74.6%) comes entirely from the generation/verification/repair scaffold, not from a bigger model
|
||||||
|
- The Geometric Lens energy-field selector is an unusual but measurable alternative to pure LLM-based self-critique
|
||||||
|
|
||||||
|
Copy:
|
||||||
|
- generate → external verify → self-repair loop as a default pattern for coding tasks
|
||||||
|
- budget forcing to limit token waste on low-confidence generations
|
||||||
|
- distinguishing candidate selection accuracy (Geometric Lens) from final pass rate — they are different metrics worth tracking separately
|
||||||
|
|
||||||
|
Avoid:
|
||||||
|
- treating it as a general-purpose agent; it is explicitly optimized for LiveCodeBench and cross-domain generalization is listed as a known limitation
|
||||||
|
- the sequential/single-threaded pipeline if throughput matters — version 3.1 targets parallel processing
|
||||||
|
|
||||||
|
Risk:
|
||||||
|
- the Geometric Lens is described as undertrained; the verification signal could be a bottleneck on new domains
|
||||||
|
|
||||||
|
## Distilled Rules For Kokoclaw/OpenClaw-Like Systems
|
||||||
|
|
||||||
|
### Search And Retrieval
|
||||||
|
|
||||||
|
- Do not rely on hardcoded keywords to decide whether to search.
|
||||||
|
- Let the model judge whether fresh evidence is needed, then measure the behavior.
|
||||||
|
- Keep the first search shallow and literal.
|
||||||
|
- Allow bounded refinement if the first results are weak or mismatched.
|
||||||
|
- Ground final factual answers in retrieved evidence.
|
||||||
|
|
||||||
|
### Coding Agents
|
||||||
|
|
||||||
|
- Keep repo agents on short inspect/edit/test loops.
|
||||||
|
- Preserve exact names and file-local conventions.
|
||||||
|
- Use docs lookup when behavior depends on framework or version details.
|
||||||
|
- Grade the produced diff and test result, not exact intermediate steps.
|
||||||
|
- Always compare against simpler baselines like "read more, act less".
|
||||||
|
|
||||||
|
### Multi-Agent Design
|
||||||
|
|
||||||
|
- Use one agent unless there is a measured reason to split.
|
||||||
|
- Split by capability, not by story or persona.
|
||||||
|
- Small helpers should do mechanical work.
|
||||||
|
- Larger models should handle synthesis and edge-case reasoning.
|
||||||
|
- Coordination prompts should name the shared objective and each role's responsibility.
|
||||||
|
|
||||||
|
### Prompt Writing
|
||||||
|
|
||||||
|
- Short beats bloated.
|
||||||
|
- Abstract rules beat example catalogs unless the task genuinely needs demonstrations.
|
||||||
|
- Put uncertainty policy in the prompt:
|
||||||
|
- verify
|
||||||
|
- revise
|
||||||
|
- say unknown when unsupported
|
||||||
|
- Do not try to encode every failure mode in one mega-prompt.
|
||||||
|
|
||||||
|
### Evaluation
|
||||||
|
|
||||||
|
- Run the same harness the product actually uses.
|
||||||
|
- Keep trials isolated.
|
||||||
|
- Track pass@1 and consistency, not just "found a good answer once".
|
||||||
|
- Review transcripts every week if the system matters.
|
||||||
|
- If the model improved but the score did not, suspect the benchmark or grader too.
|
||||||
|
|
||||||
|
## Anti-Patterns
|
||||||
|
|
||||||
|
- Too many homogeneous agents
|
||||||
|
- Persona-rich prompts with weak task constraints
|
||||||
|
- Keyword-triggered search/tool policies
|
||||||
|
- Unbounded self-reflection loops
|
||||||
|
- Auto-commits without validation
|
||||||
|
- Massive context files with no ownership
|
||||||
|
- Grading only the exact path instead of the delivered outcome
|
||||||
|
- Building a platform before validating a narrow workflow
|
||||||
|
|
||||||
|
## What To Re-Read Often
|
||||||
|
|
||||||
|
- Anthropic, Building Effective AI Agents
|
||||||
|
- Anthropic, Harness Design for Long-Running Application Development
|
||||||
|
- Anthropic, Programmatic tool calling docs
|
||||||
|
- Anthropic, Demystifying evals for AI agents
|
||||||
|
- BAIR, The Shift from Models to Compound AI Systems
|
||||||
|
- ReAct
|
||||||
|
- CRITIC
|
||||||
|
- Agentless
|
||||||
|
- SWE-agent
|
||||||
|
- karpathy/autoresearch
|
||||||
|
- pi-autoresearch
|
||||||
|
- ATLAS (generate → verify → repair; small-model infra vs. scale)
|
||||||
|
|
||||||
|
## Update Policy For This File
|
||||||
|
|
||||||
|
When adding a new source, prefer one of:
|
||||||
|
- primary paper
|
||||||
|
- official engineering article
|
||||||
|
- official project README or documentation
|
||||||
|
|
||||||
|
For each new source, capture:
|
||||||
|
- what it claims
|
||||||
|
- what to copy
|
||||||
|
- what to avoid
|
||||||
|
- whether it actually changes system design decisions
|
||||||
|
|
||||||
|
If it does not change design decisions, it probably does not belong here.
|
||||||
|
|
||||||
|
*Last updated: 2026-03-29*
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
# AGENTS.md
|
||||||
|
|
||||||
|
## Research/Analysis Folder for forgecode
|
||||||
|
|
||||||
|
This is the research and analysis folder for the **forgecode** coding harness.
|
||||||
|
|
||||||
|
### Folder Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
forgecode/
|
||||||
|
repo/ - antinomyhq/forgecode source code
|
||||||
|
feedback/
|
||||||
|
localllm/ - Community feedback and performance data for local models
|
||||||
|
frontier/ - Community feedback and performance data for frontier models
|
||||||
|
```
|
||||||
|
|
||||||
|
### What's Inside
|
||||||
|
|
||||||
|
- **repo/**: The forgecode repository (AI pair programmer with sub-agents)
|
||||||
|
- **feedback/localllm/**: Feedback, benchmark results, and observations from using forgecode with smaller/local LLMs
|
||||||
|
- **feedback/frontier/**: Feedback, benchmark results, and observations from using forgecode with frontier models
|
||||||
|
|
||||||
|
### Feedback Format
|
||||||
|
|
||||||
|
Each feedback file should include:
|
||||||
|
- Model used (name, size, provider)
|
||||||
|
- Benchmark results or task performance
|
||||||
|
- Issues encountered
|
||||||
|
- What worked well
|
||||||
|
- **Source reference**: URL or site where the feedback came from (community posts, Discord, GitHub issues, etc.)
|
||||||
|
|
||||||
|
### Research Focus
|
||||||
|
|
||||||
|
This folder collects data on:
|
||||||
|
- Tool handling and capabilities
|
||||||
|
- Skills system effectiveness
|
||||||
|
- Prompt engineering strategies
|
||||||
|
- Context management
|
||||||
|
- Performance on benchmarks (terminal-bench, etc.)
|
||||||
|
|
||||||
|
### Goal
|
||||||
|
|
||||||
|
Extract best practices specifically for smaller/local models and document what works vs. what doesn't for the forgecode harness.
|
||||||
@@ -0,0 +1,98 @@
|
|||||||
|
# ForgeCode Research & Analysis Folder
|
||||||
|
|
||||||
|
This folder contains comprehensive research and analysis of the **ForgeCode** coding harness from antinomyhq.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Folder Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
forgecode/
|
||||||
|
├── feedback/
|
||||||
|
│ ├── frontier/ # Frontier/closed-weight model feedback
|
||||||
|
│ │ ├── claude-opus-4.6.md
|
||||||
|
│ │ ├── gpt-5.4.md
|
||||||
|
│ │ ├── gemini-3.1-pro.md
|
||||||
|
│ │ ├── privacy-security-concerns.md
|
||||||
|
│ │ ├── pricing-model.md
|
||||||
|
│ │ ├── feature-comparison-ecosystem.md
|
||||||
|
│ │ ├── benchmark-controversy.md
|
||||||
|
│ │ └── summary-best-practices.md
|
||||||
|
│ └── localllm/ # Local/open-weight model feedback
|
||||||
|
│ ├── qwen-3.5.md
|
||||||
|
│ ├── general-local-models.md
|
||||||
|
│ ├── tool-calling-reliability.md
|
||||||
|
│ ├── github-issues-summary.md
|
||||||
|
│ ├── minimax-glm-deepseek.md
|
||||||
|
│ └── installation-platform-issues.md
|
||||||
|
└── README.md # This file
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Findings Summary
|
||||||
|
|
||||||
|
### Strengths
|
||||||
|
- **Speed:** 3x faster than Claude Code on identical tasks (Opus 4.6)
|
||||||
|
- **Multi-model:** 300+ models via OpenRouter
|
||||||
|
- **Open source:** Apache 2.0, auditable
|
||||||
|
- **Context efficiency:** ~90% reduction vs full-file inclusion
|
||||||
|
|
||||||
|
### Weaknesses
|
||||||
|
- **Privacy concerns:** Telemetry collects SSH/git data by default
|
||||||
|
- **Feature gaps:** No checkpoints, auto-memory, or IDE extensions
|
||||||
|
- **Benchmark questions:** Self-reported scores differ from independent validation
|
||||||
|
- **GPT 5.4 stability:** "Borderline unusable" despite 81.8% benchmark score
|
||||||
|
|
||||||
|
### Critical Issues
|
||||||
|
1. **#2894:** Multiple system messages break Qwen 3.5 and similar models
|
||||||
|
2. **#1318:** Telemetry collection concerns
|
||||||
|
3. **#2893:** Ghostty terminal resize bug
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model Recommendations
|
||||||
|
|
||||||
|
### Best Overall Experience
|
||||||
|
- **Claude Opus 4.6** - Fast, stable, reliable
|
||||||
|
|
||||||
|
### Best Value
|
||||||
|
- **MiniMax M2.1** - 47.9% score at $0.30/$1.20 per million tokens
|
||||||
|
|
||||||
|
### Avoid
|
||||||
|
- **GPT 5.4** through ForgeCode - Tool calling failures
|
||||||
|
- **Qwen 3.5** - Broken by #2894 until fixed
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Quick Links
|
||||||
|
|
||||||
|
- **Repository:** https://github.com/antinomyhq/forgecode
|
||||||
|
- **Documentation:** https://forgecode.dev/docs/
|
||||||
|
- **Discord:** https://discord.gg/kRZBPpkgwq
|
||||||
|
- **TermBench Leaderboard:** https://tbench.ai/leaderboard/terminal-bench/2.0
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Feedback Format
|
||||||
|
|
||||||
|
Each feedback file includes:
|
||||||
|
- Model used (name, size, provider)
|
||||||
|
- Benchmark results or task performance
|
||||||
|
- Issues encountered
|
||||||
|
- What worked well
|
||||||
|
- Source reference (URL or site)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Last Updated
|
||||||
|
|
||||||
|
April 9, 2026
|
||||||
|
|
||||||
|
Compiled from:
|
||||||
|
- GitHub issues (48 open, 433 closed)
|
||||||
|
- Reddit discussions (r/ClaudeCode, r/cursor, r/LocalLLaMA)
|
||||||
|
- DEV Community articles
|
||||||
|
- ForgeCode blog posts
|
||||||
|
- Independent benchmark sites (llm-stats.com)
|
||||||
|
- Academic papers (arXiv)
|
||||||
@@ -0,0 +1,145 @@
|
|||||||
|
# Community Sources & Ongoing Monitoring
|
||||||
|
|
||||||
|
**Last Updated:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Official Channels
|
||||||
|
|
||||||
|
### Discord
|
||||||
|
- **URL:** https://discord.gg/kRZBPpkgwq
|
||||||
|
- **Purpose:** Community support, feature announcements, feedback
|
||||||
|
- **Activity:** Active (referenced in docs and GitHub)
|
||||||
|
|
||||||
|
### GitHub
|
||||||
|
- **Issues:** https://github.com/antinomyhq/forgecode/issues (48 open, 433 closed)
|
||||||
|
- **Discussions:** https://github.com/antinomyhq/forgecode/discussions
|
||||||
|
- **Releases:** https://github.com/antinomyhq/forgecode/releases
|
||||||
|
|
||||||
|
### Reddit
|
||||||
|
- **r/forgecode:** https://www.reddit.com/r/forgecode/ (official subreddit)
|
||||||
|
- **r/ClaudeCode:** Frequently discusses ForgeCode comparisons
|
||||||
|
- **r/cursor:** Pricing and feature comparisons
|
||||||
|
- **r/LocalLLaMA:** Local model usage with ForgeCode
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key External References
|
||||||
|
|
||||||
|
### Benchmarks
|
||||||
|
- **TermBench 2.0:** https://tbench.ai/leaderboard/terminal-bench/2.0
|
||||||
|
- **llm-stats.com:** https://llm-stats.com/benchmarks/terminal-bench
|
||||||
|
- **SWE-bench:** https://www.swebench.com/ (independent validation)
|
||||||
|
|
||||||
|
### Documentation
|
||||||
|
- **Official Docs:** https://forgecode.dev/docs/
|
||||||
|
- **Installation:** https://forgecode.dev/docs/installation/
|
||||||
|
- **ZSH Support:** https://forgecode.dev/docs/zsh-support/
|
||||||
|
- **Blog:** https://forgecode.dev/blog/
|
||||||
|
|
||||||
|
### Articles & Reviews
|
||||||
|
- **DEV Community:** Multiple comparison articles
|
||||||
|
- **TechGig:** Feature overview (August 2025)
|
||||||
|
- **Artificial Analysis:** Independent benchmark tracking
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Notable GitHub Issues to Watch
|
||||||
|
|
||||||
|
### Critical (Open)
|
||||||
|
| Issue | Description | Status |
|
||||||
|
|-------|-------------|--------|
|
||||||
|
| #2904 | Use models.dev as registry | Open |
|
||||||
|
| #2894 | Qwen 3.5 system messages bug | Open |
|
||||||
|
| #2893 | Ghostty resize bug | Open, PR linked |
|
||||||
|
| #2888 | API key helpers | Open |
|
||||||
|
| #2884 | Muse mode blocked | Open |
|
||||||
|
|
||||||
|
### Historical (Closed but relevant)
|
||||||
|
| Issue | Description |
|
||||||
|
|-------|-------------|
|
||||||
|
| #2813 | Fixed in response to Reddit feedback |
|
||||||
|
| #2485 | Mac installation issues |
|
||||||
|
| #1296 | Daily FORGE limit stops tasks |
|
||||||
|
| #1318 | Telemetry concerns |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Research Papers
|
||||||
|
|
||||||
|
### Terminal-Bench
|
||||||
|
- **arXiv:** https://arxiv.org/html/2601.11868v1
|
||||||
|
- **OpenReview:** https://openreview.net/forum?id=a7Qa4CcHak
|
||||||
|
- **Published:** ICLR 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Monitoring Recommendations
|
||||||
|
|
||||||
|
### Weekly Checks
|
||||||
|
1. GitHub issues for new bugs affecting model compatibility
|
||||||
|
2. Discord announcements for feature updates
|
||||||
|
3. Reddit for user experience reports
|
||||||
|
|
||||||
|
### Monthly Reviews
|
||||||
|
1. Benchmark leaderboard updates (llm-stats.com)
|
||||||
|
2. New model support announcements
|
||||||
|
3. Pricing changes
|
||||||
|
|
||||||
|
### Quarterly Analysis
|
||||||
|
1. Comparative reviews (DEV Community, blogs)
|
||||||
|
2. Feature gap analysis vs competitors
|
||||||
|
3. Local model compatibility updates
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Data Collection Notes
|
||||||
|
|
||||||
|
### Exhaustive Search Performed
|
||||||
|
- Web search across multiple query angles
|
||||||
|
- GitHub issue extraction
|
||||||
|
- Documentation review
|
||||||
|
- Blog post analysis
|
||||||
|
- Community forum monitoring
|
||||||
|
|
||||||
|
### Sources Checked
|
||||||
|
- GitHub (antinomyhq/forgecode)
|
||||||
|
- Reddit (r/forgecode, r/ClaudeCode, r/cursor, r/LocalLLaMA)
|
||||||
|
- DEV Community
|
||||||
|
- ForgeCode official blog
|
||||||
|
- Independent benchmark sites
|
||||||
|
- Academic papers
|
||||||
|
|
||||||
|
### Limitations
|
||||||
|
- Reddit verification challenges prevented some thread extraction
|
||||||
|
- Discord content not directly accessible (requires login)
|
||||||
|
- Some GitHub issues require authentication for full details
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Contribution Guidelines
|
||||||
|
|
||||||
|
When adding new feedback:
|
||||||
|
|
||||||
|
1. **Follow the format:**
|
||||||
|
- Model/Topic header
|
||||||
|
- Source references with URLs
|
||||||
|
- What worked / What didn't
|
||||||
|
- Specific issues encountered
|
||||||
|
|
||||||
|
2. **Include dates:** When was the feedback collected?
|
||||||
|
|
||||||
|
3. **Categorize correctly:**
|
||||||
|
- `frontier/` for closed-weight models (GPT, Claude, Gemini, etc.)
|
||||||
|
- `localllm/` for open-weight models (Qwen, Llama, Mistral, etc.)
|
||||||
|
|
||||||
|
4. **Update README.md:** If adding major new categories
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Contact
|
||||||
|
|
||||||
|
For questions about this research:
|
||||||
|
- Check the GitHub repository for updates
|
||||||
|
- Join the ForgeCode Discord
|
||||||
|
- File issues against this research folder
|
||||||
@@ -0,0 +1,140 @@
|
|||||||
|
# ForgeCode Benchmark Controversy - Feedback Report
|
||||||
|
|
||||||
|
**Topic:** TermBench 2.0 results, self-reported vs independent validation, "benchmaxxing"
|
||||||
|
**Source References:** Reddit r/ClaudeCode, DEV Community, llm-stats.com, arXiv
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## The Controversy
|
||||||
|
|
||||||
|
ForgeCode achieved **81.8% on TermBench 2.0** (tied with GPT 5.4 and Opus 4.6), significantly outperforming Claude Code's 58.0% on the same Opus 4.6 model. This raised questions about:
|
||||||
|
|
||||||
|
1. Self-reported vs. independent validation
|
||||||
|
2. Benchmark-specific optimizations ("benchmaxxing")
|
||||||
|
3. Proprietary layer involvement
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## TermBench 2.0 Results
|
||||||
|
|
||||||
|
### Self-Reported (via ForgeCode at tbench.ai)
|
||||||
|
| Configuration | Score | Rank |
|
||||||
|
|--------------|-------|------|
|
||||||
|
| ForgeCode + GPT 5.4 | 81.8% | #1 |
|
||||||
|
| ForgeCode + Opus 4.6 | 81.8% | #1 |
|
||||||
|
| Claude Code + Opus 4.6 | 58.0% | #39 |
|
||||||
|
|
||||||
|
### Independent SWE-bench (Princeton/UChicago)
|
||||||
|
| Configuration | Score |
|
||||||
|
|--------------|-------|
|
||||||
|
| ForgeCode + Claude 4 | 72.7% |
|
||||||
|
| Claude 3.7 Sonnet (extended thinking) | 70.3% |
|
||||||
|
| Claude 4.5 Opus | 76.8% |
|
||||||
|
|
||||||
|
**Gap narrows from 24 points to 2.4 points on independent benchmark.**
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Skepticism
|
||||||
|
|
||||||
|
### Reddit r/ClaudeCode
|
||||||
|
> "Looks this agent forgecode.dev ranks better than anyone in terminalbench but anyone is talking about it. Is it fake or what is wrong with these 'artifacts' that promise save time and tokens"
|
||||||
|
|
||||||
|
> "At this point, terminalbench has received quite some attention and most benchmarks are not validated."
|
||||||
|
|
||||||
|
> "I am concerned about their proprietary layer, which I believe is a big part of what moved their bench scores from ~25% to ~81%."
|
||||||
|
|
||||||
|
### The "Benchmaxxing" Term
|
||||||
|
Community coined "benchmaxxed" to describe ForgeCode's approach:
|
||||||
|
- Real engineering improvements
|
||||||
|
- Also benchmark-specific optimizations
|
||||||
|
- Not necessarily representative of real-world performance
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ForgeCode's Defense
|
||||||
|
|
||||||
|
### Blog Series: "Benchmarks Don't Matter — Until They Do"
|
||||||
|
ForgeCode transparently documented their journey:
|
||||||
|
- **Baseline:** ~25% (interactive-first runtime)
|
||||||
|
- **Stabilization:** ~38% (non-interactive mode + tool naming fixes)
|
||||||
|
- **Planning control:** 66% (mandatory todo_write enforcement)
|
||||||
|
- **Speed architecture:** 78.4% (subagent parallelization + progressive thinking)
|
||||||
|
- **Final:** 81.8% (additional optimizations)
|
||||||
|
|
||||||
|
### Documented Optimizations
|
||||||
|
1. **JSON schema reordering:** `required` before `properties` for GPT 5.4
|
||||||
|
2. **Schema flattening:** Reduced nesting
|
||||||
|
3. **Truncation reminders:** Explicit notes when files partially read
|
||||||
|
4. **Mandatory verification:** Reviewer skill checks completion
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## The Proprietary Layer Question
|
||||||
|
|
||||||
|
**ForgeCode Services** (optional, free during evaluation) includes:
|
||||||
|
1. Semantic entry-point discovery
|
||||||
|
2. Dynamic skill loading
|
||||||
|
3. Tool-call correction layer
|
||||||
|
|
||||||
|
**Concern:** These services were used for benchmark evaluations but differ from open-source CLI mode.
|
||||||
|
|
||||||
|
**Clarification from Discussion #2545:**
|
||||||
|
> "Regarding the benchmarks: the setup we used for those evaluations includes ForgeCode Services, which provides multiple improvements over the existing CLI harness."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Independent Terminal-Bench Data
|
||||||
|
|
||||||
|
From llm-stats.com (April 9, 2026):
|
||||||
|
- **23 models evaluated**
|
||||||
|
- **Average score:** 0.345 (34.5%)
|
||||||
|
- **Best score:** 0.500 (50.0%) - Claude Sonnet 4.5
|
||||||
|
- **All results self-reported** (0 verified)
|
||||||
|
|
||||||
|
**Top 3:**
|
||||||
|
1. Claude Sonnet 4.5: 50.0%
|
||||||
|
2. MiniMax M2.1: 47.9%
|
||||||
|
3. Kimi K2-Thinking: 47.1%
|
||||||
|
|
||||||
|
**Note:** ForgeCode's 81.8% is not on this independent leaderboard; it was self-reported on tbench.ai.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Academic Validation
|
||||||
|
|
||||||
|
### Terminal-Bench Paper (ICLR 2026)
|
||||||
|
From arXiv:2601.11868:
|
||||||
|
> "Nonetheless, the benchmark developers have invested considerable effort in mitigating reproducibility issues through containerization, repeated runs, and reporting of confidence intervals. We found no major issues. Independent inspection of the released tasks confirmed that they are well-specified and largely free of ambiguity or underspecification."
|
||||||
|
|
||||||
|
**Key Point:** The benchmark itself is well-constructed; the question is about harness-specific optimizations.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Takeaways
|
||||||
|
|
||||||
|
1. **Benchmarks can be gamed:** Documented optimizations show how harness engineering affects scores
|
||||||
|
2. **Independent validation matters:** 24-point gap shrinks to 2.4 on independent tests
|
||||||
|
3. **Proprietary layers complicate comparisons:** Services used for benchmarks differ from open-source code
|
||||||
|
4. **Real-world != benchmark:** GPT 5.4 scored 81.8% but was "borderline unusable" in practice
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations for Benchmark Consumers
|
||||||
|
|
||||||
|
1. **Look for independent validation** (SWE-bench > self-reported TermBench)
|
||||||
|
2. **Test on your own tasks** - benchmarks don't capture all failure modes
|
||||||
|
3. **Consider harness transparency** - open-source vs proprietary optimizations
|
||||||
|
4. **Beware benchmaxxing** - optimizations may not generalize
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **Reddit r/ClaudeCode:** https://www.reddit.com/r/ClaudeCode/comments/1royhni/someone_is_using_forgecodedev/
|
||||||
|
2. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
|
3. **llm-stats.com:** https://llm-stats.com/benchmarks/terminal-bench
|
||||||
|
4. **arXiv Paper:** https://arxiv.org/html/2601.11868v1
|
||||||
|
5. **ForgeCode Blog:** https://forgecode.dev/blog/benchmarks-dont-matter/
|
||||||
|
6. **GitHub Discussion:** https://github.com/antinomyhq/forgecode/discussions/2545
|
||||||
@@ -0,0 +1,81 @@
|
|||||||
|
# Claude Opus 4.6 with ForgeCode - Feedback Report
|
||||||
|
|
||||||
|
**Model:** Claude Opus 4.6
|
||||||
|
**Provider:** Anthropic
|
||||||
|
**Harness:** ForgeCode
|
||||||
|
**Source References:** DEV Community (Liran Baba), ForgeCode Blog, Reddit r/ClaudeCode
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmark Performance
|
||||||
|
|
||||||
|
### TermBench 2.0 (Self-Reported via ForgeCode)
|
||||||
|
- **Score:** 81.8% (tied for #1)
|
||||||
|
- **Comparison:** Claude Code + Opus 4.6 scored 58.0% (Rank #39)
|
||||||
|
- **Gap:** ~24 percentage points in favor of ForgeCode harness
|
||||||
|
|
||||||
|
### SWE-bench Verified (Independent - Princeton/UChicago)
|
||||||
|
- **ForgeCode + Claude 4:** 72.7%
|
||||||
|
- **Claude Code + Claude 3.7 Sonnet (extended thinking):** 70.3%
|
||||||
|
- **Gap:** Only 2.4 percentage points
|
||||||
|
|
||||||
|
**Key Insight:** The benchmark gap narrows significantly on independent validation. TermBench 2.0 results are self-reported by ForgeCode itself.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Real-World Performance Feedback
|
||||||
|
|
||||||
|
### Speed
|
||||||
|
- **Observation:** "Noticeably faster than Claude Code. Not marginal, real."
|
||||||
|
- **Test Case:** Adding post counter to blog index (Astro 6, ~30 files)
|
||||||
|
- Claude Code: ~90 seconds
|
||||||
|
- ForgeCode + Opus 4.6: <30 seconds
|
||||||
|
- **Consistency:** Multi-file renames, component additions, layout restructuring all showed faster performance
|
||||||
|
|
||||||
|
### Why Faster
|
||||||
|
1. **Rust binary** vs Claude Code's TypeScript (better startup/memory)
|
||||||
|
2. **Context engine:** Indexes function signatures and module boundaries instead of dumping raw files (~90% context size reduction)
|
||||||
|
3. **Selective context:** Pulls only what the agent needs
|
||||||
|
|
||||||
|
### Stability
|
||||||
|
- **Assessment:** Excellent stability with Opus 4.6 through ForgeCode
|
||||||
|
- **No tool call failures reported** (unlike GPT 5.4 experience)
|
||||||
|
- Consistent performance across different task types
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## What Worked Well
|
||||||
|
|
||||||
|
1. **Multi-file refactoring:** Handles complex changes across file boundaries efficiently
|
||||||
|
2. **Code comprehension:** Strong understanding of Astro/React components
|
||||||
|
3. **Speed on complex tasks:** Consistently 3x faster than Claude Code on identical tasks
|
||||||
|
4. **Planning with muse:** Plan output felt "more detailed and verbose than Claude Code's plan mode"
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Issues Encountered
|
||||||
|
|
||||||
|
1. **Ecosystem gaps:** No IDE extensions, no hooks, no checkpoints/rewind
|
||||||
|
2. **No auto-memory:** Context doesn't persist between sessions
|
||||||
|
3. **No built-in sandbox:** Requires manual `--sandbox` flag for isolation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## User Workflow Integration
|
||||||
|
|
||||||
|
**Current User Pattern (Liran Baba):**
|
||||||
|
> "I double-dip. Claude Code for my primary workflow (ecosystem, features), ForgeCode when I care about latency."
|
||||||
|
|
||||||
|
**Use Cases:**
|
||||||
|
- Speed-critical tasks: ForgeCode + Opus 4.6
|
||||||
|
- Complex refactoring: ForgeCode for faster iteration
|
||||||
|
- Team collaboration: Claude Code (shared CLAUDE.md, checkpoints)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
|
2. **ForgeCode Blog:** https://forgecode.dev/blog/benchmarks-dont-matter/
|
||||||
|
3. **Reddit r/ClaudeCode:** https://www.reddit.com/r/ClaudeCode/comments/1royhni/someone_is_using_forgecodedev/
|
||||||
@@ -0,0 +1,146 @@
|
|||||||
|
# ForgeCode vs Competitors - Feature & Ecosystem Comparison
|
||||||
|
|
||||||
|
**Topic:** Feature gaps, ecosystem comparison, workflow integration
|
||||||
|
**Source References:** DEV Community, ForgeCode docs, Reddit
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Feature Matrix
|
||||||
|
|
||||||
|
| Feature | ForgeCode | Claude Code | Cursor |
|
||||||
|
|---------|-----------|-------------|--------|
|
||||||
|
| **Model Choice** | Any (300+) | Claude only | Multiple |
|
||||||
|
| **License** | Open source (Apache 2.0) | Proprietary | Proprietary |
|
||||||
|
| **Language** | Rust | TypeScript | TypeScript |
|
||||||
|
| **Project Config** | `AGENTS.md` | `CLAUDE.md` (hierarchical) | `.cursorrules` |
|
||||||
|
| **MCP Support** | Yes | Yes (extensive) | Yes |
|
||||||
|
| **Hooks** | **No** | Yes (6 types) | Limited |
|
||||||
|
| **Scheduled Tasks** | **No** | Yes (cloud + local) | No |
|
||||||
|
| **Sub-agents** | Yes (forge/sage/muse) | Yes (parallel) | Limited |
|
||||||
|
| **IDE Extensions** | **None** | VS Code, JetBrains | VS Code only |
|
||||||
|
| **Auto-Memory** | **No** | Yes | Yes |
|
||||||
|
| **Checkpoints/Rewind** | **No** | Yes | Yes |
|
||||||
|
| **Sandbox Mode** | `--sandbox` flag | Built-in | Built-in |
|
||||||
|
| **Plan Mode** | Yes (muse writes to `plans/`) | Yes (Shift+Tab) | Composer |
|
||||||
|
| **Pricing** | $0-$100/mo + API | $20/mo subscription | $20/mo subscription |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## The "Lambo with No Cup Holder" Problem
|
||||||
|
|
||||||
|
> "ForgeCode is a Lambo with no cup holder. Fast as hell, but you're holding your coffee between your knees."
|
||||||
|
|
||||||
|
**Meaning:** Extremely fast but missing quality-of-life features.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Major Feature Gaps
|
||||||
|
|
||||||
|
### 1. No IDE Extensions
|
||||||
|
**Impact:** Must use terminal exclusively; no GUI integration
|
||||||
|
**Workaround:** Use alongside IDE manually
|
||||||
|
|
||||||
|
### 2. No Auto-Memory
|
||||||
|
**Impact:** Context doesn't persist between sessions
|
||||||
|
**Claude Code Comparison:** Remembers project context across sessions
|
||||||
|
|
||||||
|
### 3. No Checkpoints/Rewind
|
||||||
|
**Impact:** Cannot rollback changes without git
|
||||||
|
**Claude Code Comparison:** Every edit snapshotted; `/rewind` available
|
||||||
|
|
||||||
|
### 4. No Hooks
|
||||||
|
**Impact:** Cannot trigger scripts on file changes
|
||||||
|
**Claude Code Comparison:** 6 hook types (pre-command, post-command, etc.)
|
||||||
|
|
||||||
|
### 5. No Scheduled Tasks
|
||||||
|
**Impact:** Cannot schedule recurring agent runs
|
||||||
|
**Claude Code Comparison:** Both cloud and local scheduled tasks
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ForgeCode Strengths
|
||||||
|
|
||||||
|
### 1. Speed
|
||||||
|
- Rust binary vs TypeScript runtime
|
||||||
|
- Context indexing reduces token usage ~90%
|
||||||
|
- Real-world: 3x faster on identical tasks
|
||||||
|
|
||||||
|
### 2. Multi-Model Support
|
||||||
|
- 300+ models via OpenRouter
|
||||||
|
- Not locked to single provider
|
||||||
|
- Can optimize cost/performance per task
|
||||||
|
|
||||||
|
### 3. Multi-Agent Architecture
|
||||||
|
- `forge`: Implementation
|
||||||
|
- `sage`: Read-only research
|
||||||
|
- `muse`: Planning (writes to `plans/`)
|
||||||
|
- More detailed plan output than competitors
|
||||||
|
|
||||||
|
### 4. Open Source
|
||||||
|
- Apache 2.0 license
|
||||||
|
- Auditable code
|
||||||
|
- Community contributions
|
||||||
|
|
||||||
|
### 5. Terminal-Native
|
||||||
|
- Zsh plugin integration
|
||||||
|
- `:` sentinel for quick access
|
||||||
|
- No context switching
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Workflow Integration Patterns
|
||||||
|
|
||||||
|
### Pattern 1: ForgeCode for Speed
|
||||||
|
**Use Case:** Latency-sensitive tasks, quick fixes
|
||||||
|
**Workflow:** Use ForgeCode for implementation, IDE for review
|
||||||
|
|
||||||
|
### Pattern 2: Double-Dipping
|
||||||
|
**User Quote:** "I double-dip. Claude Code for my primary workflow (ecosystem, features), ForgeCode when I care about latency."
|
||||||
|
|
||||||
|
### Pattern 3: Team Configuration
|
||||||
|
**Challenge:** No shared project instructions (CLAUDE.md is Claude-specific)
|
||||||
|
**Partial Solution:** AGENTS.md for ForgeCode, but not widely adopted
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## AGENTS.md vs CLAUDE.md
|
||||||
|
|
||||||
|
### AGENTS.md (ForgeCode)
|
||||||
|
- Project-specific instructions
|
||||||
|
- Less widely documented
|
||||||
|
- Single file (no hierarchy)
|
||||||
|
|
||||||
|
### CLAUDE.md (Claude Code)
|
||||||
|
- Hierarchical (project → parent dirs → home)
|
||||||
|
- More mature documentation
|
||||||
|
- Shared across team if committed
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations by Use Case
|
||||||
|
|
||||||
|
### Solo Developer, Speed Priority
|
||||||
|
**Choice:** ForgeCode + Opus 4.6
|
||||||
|
**Reason:** Fastest iteration, cost-effective with careful model selection
|
||||||
|
|
||||||
|
### Team Environment
|
||||||
|
**Choice:** Claude Code
|
||||||
|
**Reason:** Shared CLAUDE.md, checkpoints, auto-memory for team continuity
|
||||||
|
|
||||||
|
### IDE-First Developer
|
||||||
|
**Choice:** Cursor
|
||||||
|
**Reason:** Native IDE integration, GUI features
|
||||||
|
|
||||||
|
### Terminal-First, Privacy-Focused
|
||||||
|
**Choice:** ForgeCode (with FORGE_TRACKER=false)
|
||||||
|
**Reason:** Local execution, open source, no IDE lock-in
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
|
2. **ForgeCode Docs:** https://forgecode.dev/docs/operating-agents/
|
||||||
|
3. **ForgeCode ZSH Docs:** https://forgecode.dev/docs/zsh-support/
|
||||||
|
4. **Reddit r/ClaudeCode:** https://www.reddit.com/r/ClaudeCode/comments/1royhni/someone_is_using_forgecodedev/
|
||||||
@@ -0,0 +1,45 @@
|
|||||||
|
# Gemini 3.1 Pro with ForgeCode - Feedback Report
|
||||||
|
|
||||||
|
**Model:** Gemini 3.1 Pro Preview
|
||||||
|
**Provider:** Google
|
||||||
|
**Harness:** ForgeCode
|
||||||
|
**Source References:** ForgeCode Blog
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmark Performance
|
||||||
|
|
||||||
|
### TermBench 2.0
|
||||||
|
- **ForgeCode Score:** 78.4% (SOTA at time of testing)
|
||||||
|
- **Google's Reported Score:** 68.5% on same model
|
||||||
|
- **Gap:** ~10 percentage points advantage to ForgeCode harness
|
||||||
|
|
||||||
|
> "The delta is not a better model. It is better harness. Same weights, 10 percentage points higher."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Technical Insights
|
||||||
|
|
||||||
|
### What Made the Difference
|
||||||
|
|
||||||
|
ForgeCode's blog describes seven failure modes and fixes that enabled this performance:
|
||||||
|
|
||||||
|
1. **Non-Interactive Mode:** Required for benchmark success (no user to answer clarifying questions)
|
||||||
|
2. **Tool Description Optimization:** Micro-evals isolating tool misuse categories
|
||||||
|
3. **Tool Naming:** Using `old_string`/`new_string` argument names from training data
|
||||||
|
4. **Entry-Point Discovery:** Lightweight semantic pass before exploration
|
||||||
|
5. **Time Limit Management:** Subagent parallelization + progressive thinking policy
|
||||||
|
6. **Planning Enforcement:** Mandatory `todo_write` tool usage (38% → 66% pass rate)
|
||||||
|
7. **Speed Architecture:** Low-complexity work delegated to subagents with minimal thinking budget
|
||||||
|
|
||||||
|
### Progressive Thinking Policy
|
||||||
|
- Messages 1-10: Very high thinking (plan formation)
|
||||||
|
- Messages 11+: Low thinking default (execution)
|
||||||
|
- Verification calls: Switch back to high thinking
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **ForgeCode Blog:** https://forgecode.dev/blog/benchmarks-dont-matter/
|
||||||
@@ -0,0 +1,77 @@
|
|||||||
|
# GPT 5.4 with ForgeCode - Feedback Report
|
||||||
|
|
||||||
|
**Model:** GPT 5.4
|
||||||
|
**Provider:** OpenAI
|
||||||
|
**Harness:** ForgeCode
|
||||||
|
**Source References:** DEV Community (Liran Baba), ForgeCode Blog
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmark Performance
|
||||||
|
|
||||||
|
### TermBench 2.0 (Self-Reported via ForgeCode)
|
||||||
|
- **Score:** 81.8% (tied for #1 with Opus 4.6)
|
||||||
|
- **Note:** Achieved through extensive harness optimizations, not raw model capability
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Real-World Performance Feedback
|
||||||
|
|
||||||
|
### Stability Issues
|
||||||
|
- **Assessment:** "Borderline unusable" for some tasks
|
||||||
|
- **Specific Issue:** 15-minute research task on small repo
|
||||||
|
- Tool calls repeatedly failing
|
||||||
|
- Agent stuck in retry loops
|
||||||
|
- Required manual kill
|
||||||
|
|
||||||
|
> "I asked it to research the architecture of a small repo. Fifteen minutes. Kept going unstable, tool calls failing, the agent retrying and spinning. I killed it."
|
||||||
|
|
||||||
|
### Tool Calling Reliability
|
||||||
|
- **Problem:** Persistent tool-call errors with GPT 5.4
|
||||||
|
- **ForgeCode Fixes Applied:**
|
||||||
|
1. Reordered JSON schema fields (`required` before `properties`)
|
||||||
|
2. Flattened nested schemas
|
||||||
|
3. Added explicit truncation reminders for partial file reads
|
||||||
|
- **Result:** These optimizations were benchmark-specific (described as "benchmaxxed")
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Harness Optimizations for GPT 5.4
|
||||||
|
|
||||||
|
From ForgeCode's "Benchmarks Don't Matter" blog series:
|
||||||
|
|
||||||
|
1. **Non-Interactive Mode:** System prompt rewritten to prohibit conversational branching
|
||||||
|
2. **Tool Naming:** Renaming edit tool arguments to `old_string` and `new_string` (names appearing frequently in training data) measurably dropped tool-call error rates
|
||||||
|
3. **Progressive Thinking Policy:**
|
||||||
|
- Messages 1-10: Very high thinking (plan formation)
|
||||||
|
- Messages 11+: Low thinking default (execution phase)
|
||||||
|
- Verification skill calls: Switch back to high thinking
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## What Didn't Work Well
|
||||||
|
|
||||||
|
1. **Research tasks:** Tool calling failures causing infinite loops
|
||||||
|
2. **Long-running tasks:** 15+ minute tasks became unstable
|
||||||
|
3. **Consistency:** Unpredictable failures requiring manual intervention
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Comparison with Opus 4.6
|
||||||
|
|
||||||
|
| Aspect | GPT 5.4 | Opus 4.6 |
|
||||||
|
|--------|---------|----------|
|
||||||
|
| TermBench 2.0 | 81.8% | 81.8% |
|
||||||
|
| Real-world stability | Poor | Excellent |
|
||||||
|
| Tool calling reliability | Problematic | Reliable |
|
||||||
|
| Research tasks | Unusable | Good |
|
||||||
|
|
||||||
|
**Key Takeaway:** Benchmark scores don't reflect real-world usability. Same harness, dramatically different experiences.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
|
2. **ForgeCode Blog:** https://forgecode.dev/blog/benchmarks-dont-matter/
|
||||||
@@ -0,0 +1,114 @@
|
|||||||
|
# ForgeCode Pricing & Cost Feedback Report
|
||||||
|
|
||||||
|
**Topic:** Pricing tiers, cost concerns, value proposition
|
||||||
|
**Source References:** ForgeCode Blog, Reddit r/cursor, GitHub issues
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Pricing Structure (As of July 27, 2025)
|
||||||
|
|
||||||
|
### Free Tier
|
||||||
|
- **Cost:** $0 (permanent, not a trial)
|
||||||
|
- **Limit:** Dynamic request limit (adjusts based on server load)
|
||||||
|
- **Typical Range:** 10-50 requests/day
|
||||||
|
- **Purpose:** Full feature exploration without time pressure
|
||||||
|
|
||||||
|
### Pro Plan
|
||||||
|
- **Cost:** $20/month
|
||||||
|
- **Limit:** Up to 1,000 AI requests/day
|
||||||
|
- **Target:** Regular users scaling up from free tier
|
||||||
|
|
||||||
|
### Max Plan
|
||||||
|
- **Cost:** $100/month
|
||||||
|
- **Limit:** Up to 5,000 AI requests/day
|
||||||
|
- **Target:** Power users
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Early Access Insights
|
||||||
|
|
||||||
|
### Usage Patterns Discovered
|
||||||
|
- **Top 1% of users:** Made thousands of AI requests daily
|
||||||
|
- **Power user costs:** Over $500/day in AI inference costs during heavy usage
|
||||||
|
- **Growth:** 17x surge in signups, 10x spike in usage during early access
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Feedback
|
||||||
|
|
||||||
|
### Reddit r/cursor
|
||||||
|
**Mixed reactions to pricing:**
|
||||||
|
|
||||||
|
> "ForgeCode is VERY good. I tested it by resolving failed CI tests using Python and Go code, and it proved efficient and persistent."
|
||||||
|
|
||||||
|
> "What a sad news but it really good to solve my real problem with around 10 requests. If it refresh 1000 token daily I think it still OK unless u are building a quantum codebase"
|
||||||
|
|
||||||
|
**Comparison to alternatives:**
|
||||||
|
> "Cursor has models to efficiently index your codebase, while forgecode doesn't, so consider it to be worse than both. However, this looks like a good deal to me bc of the pricing."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Cost Considerations
|
||||||
|
|
||||||
|
### Token Usage Concerns
|
||||||
|
From DEV Community analysis:
|
||||||
|
> "Nobody's published hard numbers. ForgeCode's multi-agent setup (forge/sage/muse spawning sub-agents) almost certainly burns more tokens per session. I noticed it anecdotally but didn't measure."
|
||||||
|
|
||||||
|
### API Key Requirements
|
||||||
|
- ForgeCode requires **own API keys** (not included in subscription)
|
||||||
|
- Separate billing from Claude Pro/ChatGPT Plus
|
||||||
|
- Can become expensive with heavy usage of premium models (Opus 4.6: $15/$75 per million tokens)
|
||||||
|
|
||||||
|
### Daily Limit Issues
|
||||||
|
**GitHub Issue #1296:**
|
||||||
|
- Problem: Reaching daily FORGE limit stops task mid-execution
|
||||||
|
- Context built up is lost or must wait for reset
|
||||||
|
- User requested ability to switch providers when limit reached
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Value Proposition Analysis
|
||||||
|
|
||||||
|
### For Light Users (Free Tier)
|
||||||
|
- **Pros:** 10-50 requests may be sufficient for small projects
|
||||||
|
- **Cons:** Dynamic limits unpredictable; may hit cap during intensive sessions
|
||||||
|
|
||||||
|
### For Regular Users (Pro - $20/month)
|
||||||
|
- **Pros:** 1,000 requests/day is generous for most workflows
|
||||||
|
- **Cons:** Must also pay for API usage separately
|
||||||
|
|
||||||
|
### For Power Users (Max - $100/month)
|
||||||
|
- **Pros:** 5,000 requests/day accommodates heavy usage
|
||||||
|
- **Cons:** Expensive when combined with API costs; $100 + $500/day inference = $15,100/month potential
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Cost Optimization Tips
|
||||||
|
|
||||||
|
1. **Use context efficiently:** ForgeCode's context indexing reduces token usage ~90%
|
||||||
|
2. **Choose models carefully:** Opus 4.6 is expensive ($15/$75); consider Sonnet for routine tasks
|
||||||
|
3. **Monitor sub-agent spawning:** Multi-agent workflows consume more tokens
|
||||||
|
4. **Set FORGE_TRACKER=false:** Reduces overhead (minor but measurable)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Comparison with Alternatives
|
||||||
|
|
||||||
|
| Tool | Pricing Model | Notes |
|
||||||
|
|------|---------------|-------|
|
||||||
|
| **ForgeCode** | $0-$100/month + API costs | Pay for harness + pay for inference |
|
||||||
|
| **Claude Code** | $20/month subscription | Includes model access |
|
||||||
|
| **Cursor** | $20/month subscription | Includes model access |
|
||||||
|
| **Aider** | Free (open source) | Bring your own API keys |
|
||||||
|
|
||||||
|
**Key Difference:** ForgeCode is the only one with dual payment (harness subscription + API costs).
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **ForgeCode Blog:** https://forgecode.dev/blog/graduating-from-early-access-new-pricing-tiers-available/
|
||||||
|
2. **Reddit r/cursor:** https://www.reddit.com/r/cursor/comments/1maq1ex/forgecode_is_no_longer_free_and_unlimited_but/
|
||||||
|
3. **GitHub Issue #1296:** https://github.com/antinomyhq/forgecode/issues/1296
|
||||||
|
4. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
@@ -0,0 +1,97 @@
|
|||||||
|
# ForgeCode Privacy & Security Concerns - Feedback Report
|
||||||
|
|
||||||
|
**Topic:** Data collection, telemetry, privacy
|
||||||
|
**Source References:** GitHub Issue #1318, Discussion #2545, DEV Community, Reddit
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
|
||||||
|
Despite ForgeCode's claim that "Your code never leaves your computer," there are significant community concerns about telemetry and data collection practices.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Documented Privacy Issues
|
||||||
|
|
||||||
|
### GitHub Issue #1318
|
||||||
|
**Status:** Referenced as "red flag" by community members
|
||||||
|
|
||||||
|
**Reported Concerns:**
|
||||||
|
- Default telemetry collects:
|
||||||
|
- Git user emails
|
||||||
|
- SSH directory scans
|
||||||
|
- Conversation data sent externally
|
||||||
|
|
||||||
|
### GitHub Discussion #2545
|
||||||
|
**Title:** "Clarity about data collected that involves code"
|
||||||
|
|
||||||
|
**Key Points:**
|
||||||
|
- Privacy policy mentions collecting commands
|
||||||
|
- Data can be stored and transferred in many ways
|
||||||
|
- ForgeCode Services (optional) may process data differently than local CLI mode
|
||||||
|
|
||||||
|
**Distinction:**
|
||||||
|
- **Local CLI mode:** Claims to run entirely on local machine
|
||||||
|
- **ForgeCode Services:** Optional features that provide additional capabilities, may process data externally
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Mitigation
|
||||||
|
|
||||||
|
### Disable Tracking
|
||||||
|
```bash
|
||||||
|
FORGE_TRACKER=false # Disables all tracking
|
||||||
|
```
|
||||||
|
|
||||||
|
### ForgeCode Services Clarification
|
||||||
|
From Discussion #2545:
|
||||||
|
> "ForgeCode Services are optional features that provide additional capabilities beyond the purely local CLI experience. If a user chooses to enable those services, some data relevant to those features may be processed by the service."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Sentiment
|
||||||
|
|
||||||
|
### Reddit r/ClaudeCode
|
||||||
|
> "Specifically for Forgecodedev, I haven't used it yet since they are not transparent about user data which is a red flag to me."
|
||||||
|
|
||||||
|
### DEV Community (Liran Baba)
|
||||||
|
- Mentions telemetry concerns in comparison article
|
||||||
|
- Notes the FORGE_TRACKER=false mitigation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmark Controversy Connection
|
||||||
|
|
||||||
|
Some users connect privacy concerns to benchmark results:
|
||||||
|
|
||||||
|
> "I am concerned about their proprietary layer, which I believe is a big part of what moved their bench scores from ~25% to ~81%. Currently it is free to use but may change in the future."
|
||||||
|
|
||||||
|
**Note:** ForgeCode Services (proprietary layer) was used for benchmark evaluations, which differs from purely local CLI mode.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Transparency Issues
|
||||||
|
|
||||||
|
1. **Telemetry defaults:** Enabled by default, must explicitly disable
|
||||||
|
2. **Data scope:** SSH directory scanning not clearly documented upfront
|
||||||
|
3. **ForgeCode Services:** Connection between services and benchmark results not immediately obvious
|
||||||
|
4. **Proprietary layer:** Some components not open source
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations for Privacy-Conscious Users
|
||||||
|
|
||||||
|
1. **Set FORGE_TRACKER=false** before using
|
||||||
|
2. **Avoid ForgeCode Services** if local-only operation is required
|
||||||
|
3. **Audit code:** Harness is open source (Apache 2.0), can be inspected
|
||||||
|
4. **Use own API keys:** Don't rely on any bundled/free tier that might require data sharing
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **GitHub Discussion:** https://github.com/antinomyhq/forgecode/discussions/2545
|
||||||
|
2. **GitHub Issue #1318:** Referenced in multiple community discussions
|
||||||
|
3. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
|
4. **Reddit r/ClaudeCode:** https://www.reddit.com/r/ClaudeCode/comments/1royhni/someone_is_using_forgecodedev/
|
||||||
@@ -0,0 +1,204 @@
|
|||||||
|
# ForgeCode Best Practices - Summary
|
||||||
|
|
||||||
|
**Compiled from:** Community feedback, GitHub issues, blog posts, documentation
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Quick Start Best Practices
|
||||||
|
|
||||||
|
### 1. Disable Telemetry
|
||||||
|
```bash
|
||||||
|
export FORGE_TRACKER=false
|
||||||
|
```
|
||||||
|
Add to `~/.zshrc` for persistence.
|
||||||
|
|
||||||
|
### 2. Configure API Keys Properly
|
||||||
|
```bash
|
||||||
|
forge provider login # Set up providers
|
||||||
|
```
|
||||||
|
Consider API key helpers (requested in #2888) for security.
|
||||||
|
|
||||||
|
### 3. Verify ZSH Integration
|
||||||
|
```bash
|
||||||
|
forge zsh doctor # Check for issues
|
||||||
|
forge zsh setup # Re-run if needed
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model Selection Best Practices
|
||||||
|
|
||||||
|
### For Speed
|
||||||
|
- **Opus 4.6** through ForgeCode: Fastest real-world performance
|
||||||
|
- **Avoid GPT 5.4** through ForgeCode: Unstable tool calling
|
||||||
|
|
||||||
|
### For Cost
|
||||||
|
- **MiniMax M2.1:** Near-SOTA performance at $0.30/$1.20 per million tokens
|
||||||
|
- **LongCat-Flash-Lite:** Budget option at $0.10/$0.40
|
||||||
|
|
||||||
|
### For Reliability
|
||||||
|
- **Claude Sonnet 4.5:** Best independent benchmark scores
|
||||||
|
- **Avoid:** Models with known tool calling issues (Qwen 3.5 with current bug)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Agent Usage Best Practices
|
||||||
|
|
||||||
|
### Workflow Pattern
|
||||||
|
1. **Start with `muse`** for planning complex changes
|
||||||
|
2. **Switch to `forge`** for implementation
|
||||||
|
3. **Use `sage`** (automatically) for research
|
||||||
|
|
||||||
|
### Command Reference
|
||||||
|
```bash
|
||||||
|
:muse # Planning mode
|
||||||
|
:forge # Implementation mode
|
||||||
|
:agent # View all agents
|
||||||
|
:new # Fresh conversation
|
||||||
|
:compact # Free up token budget
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Context Management
|
||||||
|
|
||||||
|
### Strengths
|
||||||
|
- **~90% context reduction** vs full-file inclusion
|
||||||
|
- Function signature indexing
|
||||||
|
- Selective context pulling
|
||||||
|
|
||||||
|
### Limitations
|
||||||
|
- **No auto-compaction** (unlike Claude Code)
|
||||||
|
- **No checkpoints/rewind**
|
||||||
|
- Manual `:compact` required when context full
|
||||||
|
|
||||||
|
### Tips
|
||||||
|
- Use `@filename` for file tagging
|
||||||
|
- Run `:compact` before long tasks
|
||||||
|
- Start with `:new` for unrelated tasks
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Tool Calling Best Practices
|
||||||
|
|
||||||
|
### For Harness Developers
|
||||||
|
1. Use `old_string`/`new_string` argument names
|
||||||
|
2. Put `required` before `properties` in JSON schema
|
||||||
|
3. Flatten nested schemas
|
||||||
|
4. Add explicit truncation reminders
|
||||||
|
|
||||||
|
### For Users
|
||||||
|
1. **Verify tool calls** - don't blindly accept
|
||||||
|
2. **Check file paths** - AI can hallucinate paths
|
||||||
|
3. **Review diffs** - especially for large changes
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Pricing Optimization
|
||||||
|
|
||||||
|
### Cost Control
|
||||||
|
1. **Use Sonnet** for routine tasks (cheaper than Opus)
|
||||||
|
2. **Limit sub-agent spawning** - burns tokens
|
||||||
|
3. **Use context efficiently** - ForgeCode's indexing helps
|
||||||
|
4. **Monitor daily limits** - Free tier is 10-50 requests
|
||||||
|
|
||||||
|
### Plan Selection
|
||||||
|
- **Free:** Testing, small projects
|
||||||
|
- **Pro ($20):** Regular use (<1,000 requests/day)
|
||||||
|
- **Max ($100):** Power users (1,000-5,000 requests/day)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Project Configuration
|
||||||
|
|
||||||
|
### AGENTS.md
|
||||||
|
Create at project root or `~/forge/AGENTS.md`:
|
||||||
|
```markdown
|
||||||
|
# Development Guidelines
|
||||||
|
|
||||||
|
## Runtime
|
||||||
|
- NEVER restart the dev server (runs on port 3000)
|
||||||
|
- Use npm exclusively (not yarn/pnpm)
|
||||||
|
|
||||||
|
## Code Style
|
||||||
|
- TypeScript strict mode
|
||||||
|
- Functional programming preferred
|
||||||
|
```
|
||||||
|
|
||||||
|
### Tips
|
||||||
|
- Be specific and actionable
|
||||||
|
- Include negative constraints ("NEVER...")
|
||||||
|
- Reference existing code patterns
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Common Pitfalls
|
||||||
|
|
||||||
|
### 1. Expecting Claude Code Features
|
||||||
|
- **Missing:** Checkpoints, auto-memory, IDE extensions
|
||||||
|
- **Workaround:** Use git commits frequently
|
||||||
|
|
||||||
|
### 2. Ignoring Daily Limits
|
||||||
|
- **Problem:** Task stops mid-execution when limit reached
|
||||||
|
- **Solution:** Monitor usage, upgrade plan, or switch providers
|
||||||
|
|
||||||
|
### 3. Using GPT 5.4 for Research
|
||||||
|
- **Problem:** Tool calling failures, infinite loops
|
||||||
|
- **Solution:** Use Opus 4.6 or Sonnet instead
|
||||||
|
|
||||||
|
### 4. Privacy Concerns
|
||||||
|
- **Problem:** Telemetry collects SSH/git data by default
|
||||||
|
- **Solution:** Set FORGE_TRACKER=false
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## When to Use ForgeCode vs Alternatives
|
||||||
|
|
||||||
|
### Use ForgeCode When:
|
||||||
|
- Terminal-first workflow
|
||||||
|
- Speed is priority
|
||||||
|
- Multi-model flexibility needed
|
||||||
|
- Open source/auditable code required
|
||||||
|
- Privacy control essential (with telemetry disabled)
|
||||||
|
|
||||||
|
### Use Claude Code When:
|
||||||
|
- Team collaboration (shared CLAUDE.md)
|
||||||
|
- Need checkpoints/rewind
|
||||||
|
- Want auto-memory across sessions
|
||||||
|
- IDE extensions needed
|
||||||
|
- Prefer subscription pricing (no separate API costs)
|
||||||
|
|
||||||
|
### Use Cursor When:
|
||||||
|
- IDE-native experience preferred
|
||||||
|
- GUI features important
|
||||||
|
- Team using VS Code exclusively
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Debugging Tips
|
||||||
|
|
||||||
|
### Tool Call Failures
|
||||||
|
1. Check model compatibility (avoid Qwen 3.5 currently)
|
||||||
|
2. Verify JSON schema format
|
||||||
|
3. Try `:retry` to resend
|
||||||
|
|
||||||
|
### Performance Issues
|
||||||
|
1. Use `:compact` to free context
|
||||||
|
2. Switch to faster model (Sonnet vs Opus)
|
||||||
|
3. Close unnecessary files with `@[filename]`
|
||||||
|
|
||||||
|
### Integration Issues
|
||||||
|
1. Run `forge zsh doctor`
|
||||||
|
2. Verify Nerd Font installed
|
||||||
|
3. Check terminal compatibility (Ghostty has resize bug)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **ForgeCode Docs:** https://forgecode.dev/docs/
|
||||||
|
2. **ZSH Support:** https://forgecode.dev/docs/zsh-support/
|
||||||
|
3. **Operating Agents:** https://forgecode.dev/docs/operating-agents/
|
||||||
|
4. **DEV Community:** https://dev.to/liran_baba/forgecode-vs-claude-code-which-ai-coding-agent-actually-wins-36c
|
||||||
|
5. **GitHub Issues:** https://github.com/antinomyhq/forgecode/issues
|
||||||
@@ -0,0 +1,101 @@
|
|||||||
|
# Local/Small Models with ForgeCode - General Feedback
|
||||||
|
|
||||||
|
**Scope:** Local LLMs via Ollama, llama.cpp, LM Studio, etc.
|
||||||
|
**Harness:** ForgeCode
|
||||||
|
**Source References:** Reddit r/LocalLLaMA, r/LocalLLM, GitHub issues
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Challenges for Local Models
|
||||||
|
|
||||||
|
### 1. Tool Calling Format Issues
|
||||||
|
|
||||||
|
**Problem:** Many local models struggle with tool calling formats
|
||||||
|
|
||||||
|
**Evidence:**
|
||||||
|
- Gemma 4 initial releases had tool calling format issues with harnesses
|
||||||
|
- Qwen3.5 has issues with multiple system messages
|
||||||
|
- Various models require specific inference backends for reliable tool use
|
||||||
|
|
||||||
|
**Recommendation:** Use latest versions of inference backends:
|
||||||
|
- oMLX / llama.cpp (latest) for Gemma 4
|
||||||
|
- LM Studio 0.4.9+ for Qwen3.5
|
||||||
|
- Unsloth fixes for Qwen3-Coder tool calling
|
||||||
|
|
||||||
|
### 2. Context Window Configuration
|
||||||
|
|
||||||
|
**Default Issues:**
|
||||||
|
- Ollama/Qwen3 runs with 4K context window by default (too small)
|
||||||
|
- Need explicit configuration to increase context
|
||||||
|
|
||||||
|
**Fix:**
|
||||||
|
```bash
|
||||||
|
# Increase context window in settings
|
||||||
|
# For Ollama: modify Modelfile
|
||||||
|
# For llama.cpp: use -c flag
|
||||||
|
```
|
||||||
|
|
||||||
|
### 3. Quantization Quality
|
||||||
|
|
||||||
|
**Observation:** Default quantization often insufficient for tool use
|
||||||
|
|
||||||
|
**Fix:**
|
||||||
|
- Try higher-quality quantization (e.g., `:q8_0` for 8-bit instead of default Q4_K_M)
|
||||||
|
- Trade-off: More RAM usage but better output quality
|
||||||
|
|
||||||
|
### 4. Model Size Recommendations
|
||||||
|
|
||||||
|
From community feedback:
|
||||||
|
- **< 7B models:** Generally insufficient for reliable agentic tool use
|
||||||
|
- **7B-14B:** Minimum viable for simple tasks
|
||||||
|
- **30B+:** Recommended for serious coding work
|
||||||
|
- **MoE models (Qwen3-Coder 480B-A35B):** Good performance but requires significant RAM
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Specific Model Notes
|
||||||
|
|
||||||
|
### Qwen3-Coder Next
|
||||||
|
- **Status:** "First usable coding model < 60GB" according to user reports
|
||||||
|
- **Workflow tip:** Compress context after each bug fix/feature, then reload
|
||||||
|
- **Important:** Limit context size in settings.json to prevent overflow
|
||||||
|
|
||||||
|
### Gemma 4
|
||||||
|
- **Requirement:** Latest oMLX / llama.cpp for tool calling
|
||||||
|
- **Recommendation:** 26B MoE good for limited RAM setups
|
||||||
|
|
||||||
|
### Mistral 7B
|
||||||
|
- **Alternative:** Consider when Qwen 2.5 14B uses too much RAM
|
||||||
|
- **Trade-off:** Smaller but potentially less capable
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Platform-Specific Notes
|
||||||
|
|
||||||
|
### Apple Silicon (M-series)
|
||||||
|
- **Observation:** "Silent, very power efficient, good speeds"
|
||||||
|
- **Limitation:** Prompt processing slower than NVIDIA GPUs
|
||||||
|
- **Alternative:** LM Studio with MLX backend currently preferred over Ollama for some users
|
||||||
|
|
||||||
|
### Linux
|
||||||
|
- Best support and performance for local inference
|
||||||
|
- htop recommended for monitoring RAM usage
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## General Best Practices
|
||||||
|
|
||||||
|
1. **Close other applications** to free RAM before running local models
|
||||||
|
2. **Monitor context usage** - can exceed 100% in some UIs while still appearing to work
|
||||||
|
3. **Update regularly** - inference backends fix tool calling issues frequently
|
||||||
|
4. **Test thoroughly** - local model behavior varies significantly by quant and backend
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **Reddit r/LocalLLaMA:** https://www.reddit.com/r/LocalLLaMA/comments/1qz5uww/qwen3_coder_next_as_first_usable_coding_model_60/
|
||||||
|
2. **Reddit r/LocalLLaMA:** https://www.reddit.com/r/LocalLLaMA/comments/1sdhvc5/qwen_35_tool_calling_fixes_for_agentic_use_whats/
|
||||||
|
3. **Reddit r/LocalLLM:** https://www.reddit.com/r/LocalLLM/comments/1sf5aqy/how_are_people_using_local_llms_for_coding/
|
||||||
|
4. **llama.cpp Discussion:** https://github.com/ggml-org/llama.cpp/discussions/4167
|
||||||
@@ -0,0 +1,133 @@
|
|||||||
|
# GitHub Issues Summary for ForgeCode
|
||||||
|
|
||||||
|
**Scope:** Open and recently closed issues affecting model performance
|
||||||
|
**Repository:** antinomyhq/forgecode
|
||||||
|
**Stats:** 48 open, 433 closed (as of April 9, 2026)
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Critical Open Issues
|
||||||
|
|
||||||
|
### #2904: Use models.dev as LLM model registry source
|
||||||
|
- **Status:** Open (April 9, 2026)
|
||||||
|
- **Type:** Enhancement
|
||||||
|
- **Impact:** Would improve model discovery and configuration
|
||||||
|
|
||||||
|
### #2894: Multiple system messages break models with strict chat templates (e.g. Qwen3.5)
|
||||||
|
- **Status:** Open (April 8, 2026)
|
||||||
|
- **Type:** Bug
|
||||||
|
- **Impact:** BREAKS local models with strict templates
|
||||||
|
- **Affected Models:** Qwen3.5, potentially others
|
||||||
|
- **Workaround:** None yet
|
||||||
|
|
||||||
|
### #2893: Terminal output disappears on window resize in Ghostty
|
||||||
|
- **Status:** Open (April 8, 2026)
|
||||||
|
- **Type:** Bug
|
||||||
|
- **Impact:** UI/usability issue
|
||||||
|
- **Linked PR:** 1 linked PR
|
||||||
|
|
||||||
|
### #2888: Add support for API key helpers
|
||||||
|
- **Status:** Open (April 8, 2026)
|
||||||
|
- **Type:** Feature
|
||||||
|
- **Impact:** Would improve security (helper scripts for API keys)
|
||||||
|
|
||||||
|
### #2884: Muse mode shell blocked
|
||||||
|
- **Status:** Open (April 7, 2026)
|
||||||
|
- **Type:** Bug
|
||||||
|
- **Impact:** Blocks usage of muse agent for planning
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Historical Issues (Now Fixed)
|
||||||
|
|
||||||
|
### #2813: (Fixed)
|
||||||
|
- Fixed issue referenced in Reddit response from maintainer
|
||||||
|
- **Source:** Reddit r/ClaudeCode
|
||||||
|
|
||||||
|
### #2485: Installation issues on Mac
|
||||||
|
- **Symptoms:** Oh My Zsh not found, terminal configuration issues
|
||||||
|
- **Resolution:** Install Oh My Zsh separately
|
||||||
|
|
||||||
|
### #1296: Daily FORGE limit stops tasks mid-execution
|
||||||
|
- **Problem:** Cannot switch providers when daily limit reached
|
||||||
|
- **Impact:** Context built up is lost
|
||||||
|
- **Status:** Open (feature request)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model-Specific Issues
|
||||||
|
|
||||||
|
### GPT 5.4
|
||||||
|
- **Tool calling reliability:** Improved via schema reordering
|
||||||
|
- **Status:** Workarounds implemented
|
||||||
|
|
||||||
|
### Qwen 3.5
|
||||||
|
- **Multiple system messages:** Open issue #2894
|
||||||
|
- **Tool calling format:** Use LM Studio 0.4.9+ for better compatibility
|
||||||
|
|
||||||
|
### Gemma 4
|
||||||
|
- **Tool calling:** Requires latest llama.cpp/oMLX
|
||||||
|
- **Status:** Resolved with backend updates
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Privacy/Security Issues
|
||||||
|
|
||||||
|
### #1318: Telemetry concerns
|
||||||
|
- **Collection:** Git emails, SSH directory scans, conversation data
|
||||||
|
- **Mitigation:** `FORGE_TRACKER=false`
|
||||||
|
- **Status:** Documented mitigation available
|
||||||
|
|
||||||
|
### #1317: Related privacy concerns
|
||||||
|
- **Linked to:** Discussion #2545
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ZSH/Terminal Issues
|
||||||
|
|
||||||
|
### Shell Integration
|
||||||
|
- **Issue:** ZSH aliases don't work in interactive mode (by design)
|
||||||
|
- **Solution:** Use `:` sentinel from native ZSH session
|
||||||
|
|
||||||
|
### Oh My Zsh
|
||||||
|
- **Requirement:** Not strictly required but recommended
|
||||||
|
- **Error:** Install script warns if not present
|
||||||
|
|
||||||
|
### Ghostty Terminal
|
||||||
|
- **Issue:** #2893 - Output disappears on resize
|
||||||
|
- **Status:** Under investigation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Installation Issues
|
||||||
|
|
||||||
|
### macOS
|
||||||
|
- **Common:** iTerm + Oh My Zsh configuration issues
|
||||||
|
- **Fix:** Run `forge zsh doctor` and `forge zsh setup`
|
||||||
|
|
||||||
|
### Windows
|
||||||
|
- **Support:** Via WSL or Git Bash only
|
||||||
|
- **Native:** Not officially supported
|
||||||
|
|
||||||
|
### Linux
|
||||||
|
- **Best supported platform**
|
||||||
|
- **Android:** Also supported
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Issue Resolution Tips
|
||||||
|
|
||||||
|
From documentation:
|
||||||
|
```bash
|
||||||
|
forge zsh doctor # Check environment
|
||||||
|
forge zsh setup # Re-run ZSH integration
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **GitHub Issues:** https://github.com/antinomyhq/forgecode/issues
|
||||||
|
2. **GitHub Discussions:** https://github.com/antinomyhq/forgecode/discussions
|
||||||
|
3. **Reddit r/ClaudeCode:** https://www.reddit.com/r/ClaudeCode/comments/1royhni/someone_is_using_forgecodedev/
|
||||||
@@ -0,0 +1,203 @@
|
|||||||
|
# Installation & Platform Issues - Feedback Report
|
||||||
|
|
||||||
|
**Topic:** Setup problems, platform compatibility, requirements
|
||||||
|
**Source References:** GitHub issues, ForgeCode docs, Reddit
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Supported Platforms
|
||||||
|
|
||||||
|
### Officially Supported
|
||||||
|
- **macOS:** Full support
|
||||||
|
- **Linux:** Best support
|
||||||
|
- **Android:** Supported
|
||||||
|
- **Windows:** Via WSL or Git Bash only
|
||||||
|
|
||||||
|
### Not Supported
|
||||||
|
- **Native Windows:** Not officially supported
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Installation Methods
|
||||||
|
|
||||||
|
### Method 1: YOLO Install (Recommended)
|
||||||
|
```bash
|
||||||
|
curl -fsSL https://forgecode.dev/cli | sh
|
||||||
|
```
|
||||||
|
|
||||||
|
### Method 2: Nix
|
||||||
|
```bash
|
||||||
|
nix run github:antinomyhq/forge
|
||||||
|
```
|
||||||
|
|
||||||
|
### Method 3: NPM
|
||||||
|
```bash
|
||||||
|
npx forgecode@latest
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Common Installation Issues
|
||||||
|
|
||||||
|
### Issue #2485: Mac Installation Problems
|
||||||
|
**Symptoms:**
|
||||||
|
- Oh My Zsh not found
|
||||||
|
- Terminal configuration issues
|
||||||
|
- Shell environment problems
|
||||||
|
|
||||||
|
**Environment Reported:**
|
||||||
|
- Shell: zsh 5.9
|
||||||
|
- Terminal: iTerm.app 3.6.8
|
||||||
|
- Oh My Zsh: Not installed
|
||||||
|
|
||||||
|
**Solution:**
|
||||||
|
```bash
|
||||||
|
# Install Oh My Zsh first
|
||||||
|
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
|
||||||
|
|
||||||
|
# Then re-run forge setup
|
||||||
|
forge zsh setup
|
||||||
|
```
|
||||||
|
|
||||||
|
### Terminal Requirements
|
||||||
|
|
||||||
|
#### Required: Nerd Font
|
||||||
|
- **Purpose:** Icon display
|
||||||
|
- **Recommended:** FiraCode Nerd Font
|
||||||
|
- **Verification:** Icons should display without overlap during setup
|
||||||
|
|
||||||
|
#### Recommended Terminals
|
||||||
|
- iTerm2 (macOS)
|
||||||
|
- Ghostty (macOS) - NOTE: Has resize bug (#2893)
|
||||||
|
- Any modern Linux terminal
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ZSH Integration Issues
|
||||||
|
|
||||||
|
### Interactive Mode Isolation
|
||||||
|
**Design:** ForgeCode's interactive mode runs in isolated environment
|
||||||
|
|
||||||
|
**Impact:**
|
||||||
|
- ZSH aliases don't work inside interactive mode
|
||||||
|
- Custom functions unavailable
|
||||||
|
- Shell tooling not accessible
|
||||||
|
|
||||||
|
**Solution:** Use `:` sentinel from native ZSH session instead
|
||||||
|
|
||||||
|
### Tab Completion
|
||||||
|
**Requirements:**
|
||||||
|
- `fd` (file finder)
|
||||||
|
- `fzf` (fuzzy finder)
|
||||||
|
|
||||||
|
**Usage:**
|
||||||
|
```bash
|
||||||
|
:<TAB> # Open command list
|
||||||
|
@file<TAB> # Fuzzy file picker
|
||||||
|
```
|
||||||
|
|
||||||
|
**Fallback:** Use full path with brackets: `@[src/components/Header.tsx]`
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Platform-Specific Notes
|
||||||
|
|
||||||
|
### macOS
|
||||||
|
**Best Practices:**
|
||||||
|
- Use iTerm2 or Ghostty
|
||||||
|
- Install Oh My Zsh for best experience
|
||||||
|
- Enable Nerd Font in terminal preferences
|
||||||
|
|
||||||
|
**Troubleshooting:**
|
||||||
|
```bash
|
||||||
|
forge zsh doctor # Check setup
|
||||||
|
forge zsh setup # Reconfigure
|
||||||
|
```
|
||||||
|
|
||||||
|
### Linux
|
||||||
|
**Advantages:**
|
||||||
|
- Best performance for local models
|
||||||
|
- Native ZSH support
|
||||||
|
- Package manager availability
|
||||||
|
|
||||||
|
**Tips:**
|
||||||
|
- Use system package manager when available
|
||||||
|
- Check `htop` for resource monitoring
|
||||||
|
|
||||||
|
### Windows
|
||||||
|
**Limitations:**
|
||||||
|
- No native support
|
||||||
|
- Must use WSL or Git Bash
|
||||||
|
|
||||||
|
**WSL Recommendation:**
|
||||||
|
- Ubuntu 22.04+ recommended
|
||||||
|
- Install ZSH within WSL
|
||||||
|
- Windows Terminal for best experience
|
||||||
|
|
||||||
|
### Android
|
||||||
|
**Status:** Supported but limited documentation
|
||||||
|
**Use Case:** Primarily for remote development scenarios
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Verification Steps
|
||||||
|
|
||||||
|
### Post-Installation Checklist
|
||||||
|
1. **Run doctor:**
|
||||||
|
```bash
|
||||||
|
forge zsh doctor
|
||||||
|
```
|
||||||
|
|
||||||
|
2. **Verify icons:**
|
||||||
|
- Should display without overlap
|
||||||
|
- Check during interactive setup
|
||||||
|
|
||||||
|
3. **Test basic commands:**
|
||||||
|
```bash
|
||||||
|
: hi
|
||||||
|
:new
|
||||||
|
:agent
|
||||||
|
```
|
||||||
|
|
||||||
|
4. **Configure provider:**
|
||||||
|
```bash
|
||||||
|
forge provider login
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Open Issues
|
||||||
|
|
||||||
|
### #2893: Ghostty Terminal Resize Bug
|
||||||
|
- **Problem:** Terminal output disappears on window resize
|
||||||
|
- **Status:** Open, 1 linked PR
|
||||||
|
- **Workaround:** Avoid resizing or use different terminal
|
||||||
|
|
||||||
|
### #2884: Muse Mode Shell Blocked
|
||||||
|
- **Problem:** Cannot use muse agent
|
||||||
|
- **Status:** Open
|
||||||
|
- **Impact:** Planning workflow blocked
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Resource Requirements
|
||||||
|
|
||||||
|
### Minimum
|
||||||
|
- **RAM:** 4GB (for cloud models)
|
||||||
|
- **Disk:** 500MB
|
||||||
|
- **Shell:** ZSH 5.0+
|
||||||
|
|
||||||
|
### For Local Models
|
||||||
|
- **RAM:** 16GB+ recommended
|
||||||
|
- **GPU:** Optional but recommended for larger models
|
||||||
|
- **Storage:** 10GB+ for model downloads
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **GitHub Issue #2485:** https://github.com/antinomyhq/forgecode/issues/2485
|
||||||
|
2. **GitHub Issue #2893:** https://github.com/antinomyhq/forgecode/issues/2893
|
||||||
|
3. **ForgeCode Docs:** https://forgecode.dev/docs/installation/
|
||||||
|
4. **ZSH Support:** https://forgecode.dev/docs/zsh-support/
|
||||||
@@ -0,0 +1,99 @@
|
|||||||
|
# MiniMax, GLM, DeepSeek with ForgeCode - Feedback Report
|
||||||
|
|
||||||
|
**Models:** MiniMax M2/M2.1, GLM-4.6, DeepSeek-V3
|
||||||
|
**Source References:** llm-stats.com, ForgeCode Blog
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## MiniMax M2.1
|
||||||
|
|
||||||
|
### Performance
|
||||||
|
- **Terminal-Bench Score:** 47.9% (Rank #2 on independent leaderboard)
|
||||||
|
- **Parameters:** 230B
|
||||||
|
- **Context:** 1.0M tokens
|
||||||
|
- **Cost:** $0.30 / $1.20 per million tokens
|
||||||
|
|
||||||
|
### Value Proposition
|
||||||
|
- **Best cost-performance ratio** among top performers
|
||||||
|
- Near-SOTA performance at entry-level pricing
|
||||||
|
- Massive 1.0M context window
|
||||||
|
|
||||||
|
### ForgeCode Usage
|
||||||
|
- Well-supported via OpenRouter
|
||||||
|
- Good tool calling reliability
|
||||||
|
- Recommended for budget-conscious users
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## GLM-4.6 (Zhipu AI)
|
||||||
|
|
||||||
|
### Performance
|
||||||
|
- **Terminal-Bench Score:** 40.5% (Rank #7)
|
||||||
|
- **Parameters:** 357B
|
||||||
|
- **Context:** 131K tokens
|
||||||
|
- **Cost:** $0.55 / $2.19 per million tokens
|
||||||
|
|
||||||
|
### Characteristics
|
||||||
|
- Open weights
|
||||||
|
- Competitive with proprietary models at similar price point
|
||||||
|
- Good context length (131K)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## DeepSeek Models
|
||||||
|
|
||||||
|
### DeepSeek-V3.2-Exp
|
||||||
|
- **Terminal-Bench Score:** 37.7% (Rank #10)
|
||||||
|
- **Status:** Experimental
|
||||||
|
- **Note:** Results from llm-stats.com
|
||||||
|
|
||||||
|
### DeepSeek-V3.1
|
||||||
|
- **Terminal-Bench Score:** 31.3% (Rank #16)
|
||||||
|
- **Parameters:** 671B
|
||||||
|
- **Observation:** Large parameter count doesn't translate to top-tier performance
|
||||||
|
|
||||||
|
### DeepSeek-R1-0528
|
||||||
|
- **Terminal-Bench Score:** 5.7% (Rank #23 - lowest)
|
||||||
|
- **Parameters:** 671B
|
||||||
|
- **Note:** Reasoning model may not be optimized for terminal tasks
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Insights
|
||||||
|
|
||||||
|
### Scale ≠ Performance
|
||||||
|
- Kimi K2 (1.0T parameters) underperforms smaller models
|
||||||
|
- DeepSeek-V3.1 (671B) scores lower than MiniMax M2.1 (230B)
|
||||||
|
- **Quality of architecture > raw parameter count**
|
||||||
|
|
||||||
|
### Cost-Performance Leaders
|
||||||
|
1. **MiniMax M2.1:** 47.9% at $0.30/$1.20
|
||||||
|
2. **LongCat-Flash-Lite:** Budget option at $0.10/$0.40 (score not in top 10)
|
||||||
|
|
||||||
|
### Context Window Comparison
|
||||||
|
| Model | Context | Rank |
|
||||||
|
|-------|---------|------|
|
||||||
|
| MiniMax M2.1 | 1.0M | #2 |
|
||||||
|
| Claude Opus 4.1 | 200K | #5 |
|
||||||
|
| GLM-4.6 | 131K | #7 |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations
|
||||||
|
|
||||||
|
### For Budget + Performance
|
||||||
|
**MiniMax M2.1** - Best value proposition
|
||||||
|
|
||||||
|
### For Open Weights
|
||||||
|
**GLM-4.6** or **MiniMax M2** - Both open, strong performance
|
||||||
|
|
||||||
|
### For Research
|
||||||
|
Avoid DeepSeek-R1 for terminal tasks; use V3 variants instead
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **llm-stats.com:** https://llm-stats.com/benchmarks/terminal-bench
|
||||||
|
2. **ForgeCode Blog:** Model comparison series
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
# Qwen 3.5 with ForgeCode - Feedback Report
|
||||||
|
|
||||||
|
**Model:** Qwen 3.5
|
||||||
|
**Provider:** Alibaba Cloud (via local inference)
|
||||||
|
**Harness:** ForgeCode
|
||||||
|
**Source References:** GitHub Issue #2894, Reddit r/LocalLLaMA
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Known Issues
|
||||||
|
|
||||||
|
### Multiple System Messages Bug
|
||||||
|
**GitHub Issue:** #2894 (Open as of April 8, 2026)
|
||||||
|
|
||||||
|
**Problem:** Multiple system messages break models with strict chat templates (e.g., Qwen3.5)
|
||||||
|
|
||||||
|
**Error Manifestation:**
|
||||||
|
- Models with strict chat templates fail to parse message structure correctly
|
||||||
|
- Tool calling may fail or produce incorrect results
|
||||||
|
- Agent behavior becomes unpredictable
|
||||||
|
|
||||||
|
**Impact:**
|
||||||
|
- Affects local inference with llama.cpp, Ollama, and similar servers
|
||||||
|
- Qwen3.5 specifically mentioned as affected
|
||||||
|
|
||||||
|
**Workaround Status:** No official fix yet; issue under investigation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Tool Calling with Qwen Models
|
||||||
|
|
||||||
|
### General Observations from Community
|
||||||
|
|
||||||
|
1. **Qwen3-Coder Next** shows promise as "first usable coding model < 60GB"
|
||||||
|
2. **Tool calling reliability varies** by inference backend:
|
||||||
|
- LM Studio 0.4.9 reportedly handles Qwen3.5 XML tool parsing more reliably than raw llama.cpp
|
||||||
|
- llama.cpp with `--jinja` flag helps with tool calling
|
||||||
|
|
||||||
|
3. **finish_reason issue** is annoying to debug according to community reports
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations for Local Use
|
||||||
|
|
||||||
|
1. **Use LM Studio** for more reliable tool parsing vs raw llama.cpp
|
||||||
|
2. **Monitor system message count** - known issue with ForgeCode's multi-message approach
|
||||||
|
3. **Test thoroughly** before relying on Qwen 3.5 for production tasks via ForgeCode
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **GitHub Issue:** https://github.com/antinomyhq/forgecode/issues/2894
|
||||||
|
2. **Reddit r/LocalLLaMA:** https://www.reddit.com/r/LocalLLaMA/comments/1sdhvc5/qwen_35_tool_calling_fixes_for_agentic_use_whats/
|
||||||
@@ -0,0 +1,111 @@
|
|||||||
|
# Tool Calling Reliability with ForgeCode - Feedback Report
|
||||||
|
|
||||||
|
**Topic:** Tool use reliability, function calling, common errors
|
||||||
|
**Source References:** ForgeCode Blog, GitHub issues, Reddit
|
||||||
|
**Date Compiled:** April 9, 2026
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
|
||||||
|
Tool calling reliability is a major differentiator for ForgeCode. The harness has implemented numerous optimizations to improve tool use across models.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## The Seven Failure Modes (From ForgeCode Blog)
|
||||||
|
|
||||||
|
### 1. Same Model, Very Different Performance
|
||||||
|
**Problem:** Interactive-first design fails in benchmarks (no user to answer questions)
|
||||||
|
**Fix:** Non-Interactive Mode with rewritten system prompts
|
||||||
|
|
||||||
|
### 2. Tool Descriptions Don't Guarantee Correctness
|
||||||
|
**Problem Categories:**
|
||||||
|
- Wrong tool selected (e.g., `shell` instead of structured `edit`)
|
||||||
|
- Correct tool, wrong argument names
|
||||||
|
- Correct tool, correct arguments, wrong sequencing
|
||||||
|
|
||||||
|
**Fix:** Targeted micro-evals isolating each class per tool, per model
|
||||||
|
|
||||||
|
### 3. Tool Naming is a Reliability Variable
|
||||||
|
**Key Finding:** Models pattern-match against training data first
|
||||||
|
|
||||||
|
**Concrete Example:**
|
||||||
|
- Renaming edit tool arguments to `old_string` and `new_string`
|
||||||
|
- Result: "measurably dropped tool-call error rates immediately—same model, same prompt"
|
||||||
|
|
||||||
|
> "If you are seeing persistent tool-call errors and attribute them entirely to model capability, check your naming first."
|
||||||
|
|
||||||
|
### 4. Context Size is a Multiplier, Not a Substitute
|
||||||
|
**Problem:** More context only helps after finding the right entry point
|
||||||
|
**Insight:** Entry-point discovery latency is the bottleneck
|
||||||
|
|
||||||
|
### 5. Time Limits Punish Trajectories
|
||||||
|
**Problem:** Failed tool calls burn real seconds; brilliant but meandering paths timeout
|
||||||
|
**Fix:** Speed architecture with parallel subagents
|
||||||
|
|
||||||
|
### 6. Planning Tools Only Work if Enforced
|
||||||
|
**Problem:** Optional `todo_write` tool ignored under pressure
|
||||||
|
**Fix:** Made mandatory via low-level evals
|
||||||
|
**Result:** 38% → 66% pass rate
|
||||||
|
|
||||||
|
### 7. TermBench is More About Speed Than Intelligence
|
||||||
|
**Fix:** Progressive thinking policy (high thinking early, low during execution)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model-Specific Tool Calling Issues
|
||||||
|
|
||||||
|
### GPT 5.4
|
||||||
|
- **Issue:** Persistent tool-call errors
|
||||||
|
- **Fixes Applied:**
|
||||||
|
- Reordered JSON schema fields (`required` before `properties`)
|
||||||
|
- Flattened nested schemas
|
||||||
|
- Explicit truncation reminders
|
||||||
|
|
||||||
|
### Qwen 3.5
|
||||||
|
- **Issue:** Multiple system messages break strict chat templates
|
||||||
|
- **Status:** Open issue (#2894)
|
||||||
|
- **Workaround:** None yet; use different model or await fix
|
||||||
|
|
||||||
|
### Gemma 4
|
||||||
|
- **Issue:** Initial releases had tool calling format issues
|
||||||
|
- **Fix:** Use latest oMLX / llama.cpp
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Best Practices for Tool Reliability
|
||||||
|
|
||||||
|
1. **Use established argument names:** `old_string`/`new_string` better than generic names
|
||||||
|
2. **Flatten schemas:** Reduce nesting in tool definitions
|
||||||
|
3. **Order matters:** Put `required` before `properties` in JSON schema
|
||||||
|
4. **Test with micro-evals:** Isolate specific tool+model combinations
|
||||||
|
5. **Monitor truncation:** Add explicit reminders when files partially read
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ForgeCode Services Enhancements
|
||||||
|
|
||||||
|
The proprietary runtime layer includes:
|
||||||
|
1. **Semantic entry-point discovery:** Lightweight semantic pass before exploration
|
||||||
|
2. **Dynamic skill loading:** Specialized instructions loaded when needed
|
||||||
|
3. **Tool-call correction layer:** Heuristic + static analysis for argument validation
|
||||||
|
|
||||||
|
**Note:** These features are part of ForgeCode Services (optional), not the open-source CLI.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Tips
|
||||||
|
|
||||||
|
From Reddit and GitHub discussions:
|
||||||
|
|
||||||
|
1. **LM Studio > raw llama.cpp** for Qwen3.5 XML tool parsing
|
||||||
|
2. **LM Studio 0.4.9+** handles tool calling more reliably
|
||||||
|
3. **llama.cpp `--jinja` flag** helps with Qwen tool templates
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Source References
|
||||||
|
|
||||||
|
1. **ForgeCode Blog:** https://forgecode.dev/blog/benchmarks-dont-matter/
|
||||||
|
2. **GitHub Issue #2894:** https://github.com/antinomyhq/forgecode/issues/2894
|
||||||
|
3. **Reddit r/LocalLLaMA:** https://www.reddit.com/r/LocalLLaMA/comments/1sdhvc5/qwen_35_tool_calling_fixes_for_agentic_use_whats/
|
||||||
Submodule
+1
Submodule forgecode/repo added at b73fb81579
@@ -0,0 +1,43 @@
|
|||||||
|
# AGENTS.md
|
||||||
|
|
||||||
|
## Research/Analysis Folder for hermes
|
||||||
|
|
||||||
|
This is the research and analysis folder for the **hermes** coding harness.
|
||||||
|
|
||||||
|
### Folder Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
hermes/
|
||||||
|
repo/ - NousResearch/hermes-agent source code
|
||||||
|
feedback/
|
||||||
|
localllm/ - Community feedback and performance data for local models
|
||||||
|
frontier/ - Community feedback and performance data for frontier models
|
||||||
|
```
|
||||||
|
|
||||||
|
### What's Inside
|
||||||
|
|
||||||
|
- **repo/**: The hermes-agent repository (agent that grows with you by Nous Research)
|
||||||
|
- **feedback/localllm/**: Feedback, benchmark results, and observations from using hermes with smaller/local LLMs
|
||||||
|
- **feedback/frontier/**: Feedback, benchmark results, and observations from using hermes with frontier models
|
||||||
|
|
||||||
|
### Feedback Format
|
||||||
|
|
||||||
|
Each feedback file should include:
|
||||||
|
- Model used (name, size, provider)
|
||||||
|
- Benchmark results or task performance
|
||||||
|
- Issues encountered
|
||||||
|
- What worked well
|
||||||
|
- **Source reference**: URL or site where the feedback came from (community posts, Discord, GitHub issues, etc.)
|
||||||
|
|
||||||
|
### Research Focus
|
||||||
|
|
||||||
|
This folder collects data on:
|
||||||
|
- Tool handling and capabilities
|
||||||
|
- Skills system effectiveness
|
||||||
|
- Prompt engineering strategies
|
||||||
|
- Context management
|
||||||
|
- Performance on benchmarks (terminal-bench, etc.)
|
||||||
|
|
||||||
|
### Goal
|
||||||
|
|
||||||
|
Extract best practices specifically for smaller/local models and document what works vs. what doesn't for the hermes harness.
|
||||||
@@ -0,0 +1,116 @@
|
|||||||
|
# Hermes Agent Feedback Collection
|
||||||
|
|
||||||
|
**Last Updated:** 2026-04-09
|
||||||
|
**Purpose:** Community feedback and performance data for the hermes-agent harness
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Folder Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
feedback/
|
||||||
|
├── localllm/ # Community feedback for local/smaller models
|
||||||
|
├── frontier/ # Community feedback for frontier models
|
||||||
|
├── general/ # General feature feedback, issues, benchmarks
|
||||||
|
└── README.md # This file
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Feedback Format
|
||||||
|
|
||||||
|
Each feedback file includes:
|
||||||
|
- **Model/Feature used** (name, size, provider)
|
||||||
|
- **Benchmark results** or task performance
|
||||||
|
- **Issues encountered**
|
||||||
|
- **What worked well**
|
||||||
|
- **Source reference:** URL or site where feedback came from
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Quick Navigation
|
||||||
|
|
||||||
|
### Local/Small Models
|
||||||
|
|
||||||
|
| File | Topic |
|
||||||
|
|------|-------|
|
||||||
|
| [localllm/qwen-models-feedback.md](localllm/qwen-models-feedback.md) | Qwen 3.5 performance |
|
||||||
|
| [localllm/gemma-models-feedback.md](localllm/gemma-models-feedback.md) | Gemma 4 comparison |
|
||||||
|
| [localllm/local-setup-issues.md](localllm/local-setup-issues.md) | Setup challenges |
|
||||||
|
| [localllm/general-local-llm-feedback.md](localllm/general-local-llm-feedback.md) | Overview |
|
||||||
|
|
||||||
|
### Frontier Models
|
||||||
|
|
||||||
|
| File | Topic |
|
||||||
|
|------|-------|
|
||||||
|
| [frontier/claude-sonnet-feedback.md](frontier/claude-sonnet-feedback.md) | Claude performance |
|
||||||
|
| [frontier/openai-gpt-feedback.md](frontier/openai-gpt-feedback.md) | OpenAI integration |
|
||||||
|
| [frontier/budget-providers-feedback.md](frontier/budget-providers-feedback.md) | Kimi, DeepSeek, MiniMax |
|
||||||
|
| [frontier/general-frontier-feedback.md](frontier/general-frontier-feedback.md) | Overview |
|
||||||
|
|
||||||
|
### General
|
||||||
|
|
||||||
|
| File | Topic |
|
||||||
|
|------|-------|
|
||||||
|
| [general/bug-reports-and-issues.md](general/bug-reports-and-issues.md) | Known issues |
|
||||||
|
| [general/feature-feedback.md](general/feature-feedback.md) | Features & UX |
|
||||||
|
| [general/terminal-bench-benchmarks.md](general/terminal-bench-benchmarks.md) | Benchmarks |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Findings Summary
|
||||||
|
|
||||||
|
### Token Overhead (All Models)
|
||||||
|
|
||||||
|
**Critical:** 73% of every API call is fixed overhead (~13.9K tokens)
|
||||||
|
|
||||||
|
| Component | Tokens |
|
||||||
|
|-----------|--------|
|
||||||
|
| Tool definitions (31 tools) | 8,759 |
|
||||||
|
| System prompt | 5,176 |
|
||||||
|
| **Fixed overhead** | **~13,935** |
|
||||||
|
|
||||||
|
**Impact:** Even simple queries can cost 15K-20K tokens
|
||||||
|
|
||||||
|
### Best Local Models
|
||||||
|
|
||||||
|
| Model | VRAM | Rating |
|
||||||
|
|-------|------|--------|
|
||||||
|
| Qwen 3.5 27B | 24GB | ⭐⭐⭐⭐⭐ |
|
||||||
|
| Qwen 3.5 14B | 16GB | ⭐⭐⭐⭐ |
|
||||||
|
| Qwen 3.5 8B | 8GB | ⭐⭐⭐ |
|
||||||
|
|
||||||
|
### Cost-Effective Providers
|
||||||
|
|
||||||
|
| Provider | Cache Discount | Use Case |
|
||||||
|
|----------|----------------|----------|
|
||||||
|
| DeepSeek | 90% | Maximum savings |
|
||||||
|
| Kimi K2.5 | 75% | Daily driver |
|
||||||
|
| MiniMax | None | Fast, capable |
|
||||||
|
|
||||||
|
### Critical Issues
|
||||||
|
|
||||||
|
| Issue | Severity | Status |
|
||||||
|
|-------|----------|--------|
|
||||||
|
| #4146 - Sandbox bypass | Critical | Open |
|
||||||
|
| #1071 - llama-server compatibility | Critical | Fix ready |
|
||||||
|
| #4469 - Message queue bug | High | Open |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
To add feedback:
|
||||||
|
1. Create a new file in appropriate folder
|
||||||
|
2. Follow the feedback format
|
||||||
|
3. Include source URLs
|
||||||
|
4. Update this README if needed
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## External Resources
|
||||||
|
|
||||||
|
- **GitHub:** https://github.com/NousResearch/hermes-agent
|
||||||
|
- **Docs:** https://hermes-agent.nousresearch.com/
|
||||||
|
- **Discord:** Community discussions
|
||||||
|
- **Reddit:** r/LocalLLaMA, r/LocalLLM
|
||||||
@@ -0,0 +1,138 @@
|
|||||||
|
# Budget Providers Feedback (Kimi, DeepSeek, MiniMax)
|
||||||
|
|
||||||
|
**Source reference:** Community guides, official integration docs, API documentation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Kimi / Moonshot AI (K2.5)
|
||||||
|
|
||||||
|
**Recommendation:** Primary budget-friendly option
|
||||||
|
|
||||||
|
### Why Kimi K2.5?
|
||||||
|
|
||||||
|
**Source:** https://hermes-agent.ai/blog/hermes-agent-api-keys
|
||||||
|
|
||||||
|
> "For most users: Kimi K2.5 from Moonshot or MiniMax as a daily driver — both are fast, capable, and inexpensive. Use Claude Sonnet or GPT-4 only for complex reasoning tasks where the extra capability is worth the significantly higher per-token cost."
|
||||||
|
|
||||||
|
### Caching Benefits
|
||||||
|
|
||||||
|
| Provider | Cache Discount |
|
||||||
|
|----------|----------------|
|
||||||
|
| Kimi K2.5 | 75% off on cache hits |
|
||||||
|
| DeepSeek | 90% off on cache hits |
|
||||||
|
| Claude/Anthropic | Full price (no special discount) |
|
||||||
|
|
||||||
|
### Cost Comparison
|
||||||
|
|
||||||
|
**Feature implementation scenario (~100 API calls):**
|
||||||
|
- Claude Sonnet 4.5: ~$34
|
||||||
|
- Kimi K2.5: ~$3-8 (depending on caching)
|
||||||
|
- DeepSeek (cache hits): Under $1
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## DeepSeek
|
||||||
|
|
||||||
|
**Best for:** Maximum cost savings with caching
|
||||||
|
|
||||||
|
### Caching Advantage
|
||||||
|
|
||||||
|
**Source:** https://hermes-agent.ai/blog/hermes-agent-token-overhead
|
||||||
|
|
||||||
|
> "DeepSeek (90% off on cache) — Biggest cost lever"
|
||||||
|
|
||||||
|
### Use Cases
|
||||||
|
- Routine file organization
|
||||||
|
- Simple message responses
|
||||||
|
- Cron job executions
|
||||||
|
- Research lookups
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## MiniMax
|
||||||
|
|
||||||
|
**Integration:** Official partnership/support
|
||||||
|
|
||||||
|
**Source:** https://platform.minimax.io/docs/token-plan/hermes-agent
|
||||||
|
|
||||||
|
> "Use MiniMax-M2.7 in Hermes Agent for autonomous AI-powered development."
|
||||||
|
|
||||||
|
### Token Plan
|
||||||
|
- Different from pay-as-you-go API keys
|
||||||
|
- Subscribe to Token Plan first
|
||||||
|
- Create Token Plan API Key from the Token Plan page
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Other Budget Options
|
||||||
|
|
||||||
|
### Z.AI / ZhipuAI (GLM Models)
|
||||||
|
- Good for Chinese language tasks
|
||||||
|
- Competitive pricing
|
||||||
|
- OpenAI-compatible endpoint
|
||||||
|
|
||||||
|
### Alibaba Cloud DashScope
|
||||||
|
- Qwen model access
|
||||||
|
- Regional availability advantages
|
||||||
|
|
||||||
|
### OpenCode Zen / Go
|
||||||
|
- Curated model access
|
||||||
|
- Budget-friendly options
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Provider Selection Strategy
|
||||||
|
|
||||||
|
### Tier 1: Daily Driver (High Volume, Lower Cost)
|
||||||
|
- **Kimi K2.5** - 75% cache discount, good capabilities
|
||||||
|
- **DeepSeek** - 90% cache discount, cheapest option
|
||||||
|
- **MiniMax** - Fast, capable, inexpensive
|
||||||
|
|
||||||
|
### Tier 2: Complex Tasks (Selective Use)
|
||||||
|
- **Claude Sonnet** - Best reasoning, highest cost
|
||||||
|
- **GPT-4** - Good for specific use cases
|
||||||
|
|
||||||
|
### Tier 3: Auxiliary Tasks
|
||||||
|
- **Gemini Flash** - Vision tasks, cheap
|
||||||
|
- **Local models** - Free but require hardware
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Configuration Example
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
# config.yaml for cost optimization
|
||||||
|
model:
|
||||||
|
default: "moonshot/kimi-k2.5" # Daily driver
|
||||||
|
|
||||||
|
auxiliary:
|
||||||
|
vision:
|
||||||
|
provider: "openrouter"
|
||||||
|
model: "google/gemini-2.5-flash" # Cheap vision
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Experience
|
||||||
|
|
||||||
|
**Positive feedback on budget providers:**
|
||||||
|
- "Fast, capable, and inexpensive"
|
||||||
|
- Significant cost savings vs frontier models
|
||||||
|
- Good enough for 80% of tasks
|
||||||
|
|
||||||
|
**Trade-offs:**
|
||||||
|
- May struggle with complex multi-step reasoning
|
||||||
|
- Tool calling slightly less reliable than Claude
|
||||||
|
- Context understanding not as nuanced
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Cost Optimization Summary
|
||||||
|
|
||||||
|
| Strategy | Savings |
|
||||||
|
|----------|---------|
|
||||||
|
| Use Kimi/DeepSeek for routine tasks | 50-90% |
|
||||||
|
| Enable provider caching | 75-90% |
|
||||||
|
| Reserve Claude/GPT for complex tasks | Variable |
|
||||||
|
| Use cheaper vision models | 50-70% |
|
||||||
|
| Short sessions (`--fresh`) | Reduces context buildup |
|
||||||
@@ -0,0 +1,134 @@
|
|||||||
|
# Claude Sonnet Feedback for Hermes Agent
|
||||||
|
|
||||||
|
**Source reference:** GitHub issues, community discussions, official docs
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Claude Sonnet 4.5/4.6 - Primary Recommendation
|
||||||
|
|
||||||
|
**Status:** Excellent performance, commonly used as default
|
||||||
|
|
||||||
|
### Token Usage Reality Check
|
||||||
|
|
||||||
|
**Source:** https://hermes-agent.ai/blog/hermes-agent-token-overhead
|
||||||
|
|
||||||
|
| Scenario | API Calls | Est. Cost (Sonnet 4.5) |
|
||||||
|
|----------|-----------|------------------------|
|
||||||
|
| Simple bug fix | 20 | ~$6 |
|
||||||
|
| Feature implementation | 100 | ~$34 |
|
||||||
|
| Large refactor | 500 | ~$187 |
|
||||||
|
| Full project build | 1,000 | ~$405 |
|
||||||
|
|
||||||
|
### Real-World Usage Example
|
||||||
|
|
||||||
|
**Source:** GitHub Issue #4379
|
||||||
|
|
||||||
|
**Single Evening Deployment (3 Active Sessions):**
|
||||||
|
| Session | Platform | Messages | Est. API Calls | Est. Input Tokens |
|
||||||
|
|---------|----------|----------|----------------|-------------------|
|
||||||
|
| Chat session | Telegram | 168 | ~84 | ~1.6M |
|
||||||
|
| Group chat | WhatsApp | 122 | ~61 | ~1.2M |
|
||||||
|
| Group chat | WhatsApp | 64 | ~32 | ~574K |
|
||||||
|
| **Total** | | **354** | **~207** | **~3.9M** |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Token Overhead Analysis (All Models)
|
||||||
|
|
||||||
|
**Critical Finding:** 73% of every API call is fixed overhead (~13.9K tokens)
|
||||||
|
|
||||||
|
| Component | Tokens | % of Request |
|
||||||
|
|-----------|--------|--------------|
|
||||||
|
| Tool definitions (31 tools) | 8,759 | 46.1% |
|
||||||
|
| System prompt (SOUL.md + skills) | 5,176 | 27.2% |
|
||||||
|
| Messages (conversation) | 3,000-8,775 | 26.7% avg |
|
||||||
|
| **Total per request** | **~17,000-23,000** | |
|
||||||
|
|
||||||
|
**Impact:** This overhead is constant regardless of using Sonnet, Haiku, Llama, or any OpenRouter model.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Performance Comparison
|
||||||
|
|
||||||
|
**Source:** https://www.buildmvpfast.com/blog/hermes-agent-v04-open-source-agent-infrastructure-2026
|
||||||
|
|
||||||
|
> "One developer reported that a task taking OpenClaw 50+ tool calls and steps took Hermes 5 correct tool calls and finished 2.5 minutes faster."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Best Practices for Cost Management
|
||||||
|
|
||||||
|
### 1. Use Cheaper Models for Routine Tasks
|
||||||
|
|
||||||
|
Reserve Claude/GPT-4 for complex reasoning only:
|
||||||
|
- File organization → Use Kimi, MiniMax, DeepSeek
|
||||||
|
- Simple responses → Budget models
|
||||||
|
- Complex architecture → Claude Sonnet
|
||||||
|
|
||||||
|
### 2. Enable Caching (Where Available)
|
||||||
|
|
||||||
|
| Provider | Cache Support | Discount |
|
||||||
|
|----------|--------------|----------|
|
||||||
|
| DeepSeek | 90% off | Best option |
|
||||||
|
| Kimi K2.5 | 75% off | Good option |
|
||||||
|
| Anthropic | Full | Cache markers visible |
|
||||||
|
| OpenRouter | Partial | Depends on upstream |
|
||||||
|
| Gemini/GLM | None | Full price |
|
||||||
|
|
||||||
|
### 3. Short Sessions
|
||||||
|
|
||||||
|
Start fresh for unrelated tasks:
|
||||||
|
```bash
|
||||||
|
hermes --fresh
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## User Experience Feedback
|
||||||
|
|
||||||
|
### Positive
|
||||||
|
|
||||||
|
- Excellent tool calling reliability
|
||||||
|
- Strong reasoning for complex multi-step tasks
|
||||||
|
- Good context understanding
|
||||||
|
|
||||||
|
### Cost Concerns
|
||||||
|
|
||||||
|
**Quote from Reddit user:**
|
||||||
|
> "4 million tokens in 2 hours of light usage" — Reddit user who quit
|
||||||
|
|
||||||
|
**High-token triggers:**
|
||||||
|
- Terminal tool spawning
|
||||||
|
- Browser automation with screenshots
|
||||||
|
- Complex code execution with large file reads
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Configuration Tips
|
||||||
|
|
||||||
|
### Auxiliary Vision Model
|
||||||
|
|
||||||
|
For vision tasks, consider using a cheaper model:
|
||||||
|
```yaml
|
||||||
|
auxiliary:
|
||||||
|
vision:
|
||||||
|
provider: "openrouter"
|
||||||
|
model: "google/gemini-2.5-flash"
|
||||||
|
```
|
||||||
|
|
||||||
|
Or use Codex for vision (ChatGPT Pro/Plus):
|
||||||
|
```yaml
|
||||||
|
auxiliary:
|
||||||
|
vision:
|
||||||
|
provider: "codex" # Uses ChatGPT OAuth token
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Summary
|
||||||
|
|
||||||
|
Claude Sonnet provides excellent performance with Hermes Agent but users should be aware of:
|
||||||
|
1. Fixed 13.9K token overhead per request
|
||||||
|
2. Costs can accumulate quickly with active usage
|
||||||
|
3. Best used selectively for complex tasks
|
||||||
|
4. Consider cheaper alternatives for routine work
|
||||||
@@ -0,0 +1,150 @@
|
|||||||
|
# General Frontier Model Feedback
|
||||||
|
|
||||||
|
**Collection Date:** 2026-04-09
|
||||||
|
**Sources:** GitHub issues, blog posts, community discussions, official documentation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Provider Support Matrix
|
||||||
|
|
||||||
|
| Provider | Status | Special Features |
|
||||||
|
|----------|--------|------------------|
|
||||||
|
| OpenAI | ✅ Full | Codex OAuth support |
|
||||||
|
| Anthropic | ✅ Full | Claude Code credential store |
|
||||||
|
| OpenRouter | ✅ Full | 200+ models, flexible |
|
||||||
|
| Nous Portal | ✅ Full | OAuth, subscription |
|
||||||
|
| Kimi/Moonshot | ✅ Full | 75% cache discount |
|
||||||
|
| DeepSeek | ✅ Full | 90% cache discount |
|
||||||
|
| MiniMax | ✅ Full | Token plan support |
|
||||||
|
| z.ai/GLM | ✅ Full | China/global endpoints |
|
||||||
|
| Gemini | ✅ Full | Via OpenRouter or direct |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Feedback Themes
|
||||||
|
|
||||||
|
### 1. Token Overhead is the Hidden Cost
|
||||||
|
|
||||||
|
**Critical Issue:** Every API call includes ~13.9K tokens of fixed overhead
|
||||||
|
|
||||||
|
**Source:** GitHub Issue #4379
|
||||||
|
|
||||||
|
> "The dollar cost depends on the model/provider, but the token overhead is constant — these 13.9K tokens are sent on every call whether using Sonnet, Haiku, Llama, or any other model via OpenRouter."
|
||||||
|
|
||||||
|
**Breakdown:**
|
||||||
|
- Tool definitions: 8,759 tokens (46%)
|
||||||
|
- System prompt: 5,176 tokens (27%)
|
||||||
|
- Actual messages: ~5,000 tokens (27%)
|
||||||
|
|
||||||
|
**Impact on Costs:**
|
||||||
|
- A "simple weather query" can cost 21,000 tokens when the agent spawns a terminal
|
||||||
|
- One user reported: "4 million tokens in 2 hours of light usage"
|
||||||
|
|
||||||
|
### 2. CLI vs Gateway Token Disparity (Fixed in v0.6.0)
|
||||||
|
|
||||||
|
**Bug (pre-v0.6.0):** Telegram used 2-3x more tokens than CLI
|
||||||
|
|
||||||
|
| Access Method | Tokens/Request |
|
||||||
|
|---------------|----------------|
|
||||||
|
| CLI | 6,000-8,000 |
|
||||||
|
| Telegram (old) | 15,000-20,000 |
|
||||||
|
|
||||||
|
**Root Cause:** Gateway started in repo directory instead of home directory
|
||||||
|
|
||||||
|
**Fix:** Update to v0.6.0+ and restart gateway
|
||||||
|
|
||||||
|
### 3. Tool Reliability by Provider
|
||||||
|
|
||||||
|
**Most Reliable:**
|
||||||
|
1. Claude Sonnet (excellent tool calling)
|
||||||
|
2. GPT-4 class models (very reliable)
|
||||||
|
3. Kimi K2.5 (good for the price)
|
||||||
|
|
||||||
|
**Acceptable:**
|
||||||
|
- MiniMax
|
||||||
|
- DeepSeek
|
||||||
|
- Gemini
|
||||||
|
|
||||||
|
**Variable:**
|
||||||
|
- Depends on specific task complexity
|
||||||
|
- Budget models may struggle with novel tools
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Cost Management Strategies
|
||||||
|
|
||||||
|
### Strategy 1: Tiered Model Usage
|
||||||
|
|
||||||
|
```
|
||||||
|
Complex reasoning → Claude Sonnet / GPT-4
|
||||||
|
Routine tasks → Kimi K2.5 / MiniMax
|
||||||
|
Vision tasks → Gemini Flash / GPT-4o
|
||||||
|
Maximum savings → DeepSeek with cache
|
||||||
|
```
|
||||||
|
|
||||||
|
### Strategy 2: Session Management
|
||||||
|
|
||||||
|
- Use `hermes --fresh` for unrelated tasks
|
||||||
|
- Run token-intensive work in CLI vs gateway
|
||||||
|
- Monitor with `/usage` command
|
||||||
|
|
||||||
|
### Strategy 3: Toolset Optimization
|
||||||
|
|
||||||
|
- Disable unused skill categories (~2,200 tokens saved)
|
||||||
|
- Use platform-specific toolsets (~1,300 tokens saved)
|
||||||
|
- Keep MEMORY.md lean
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Provider-Specific Notes
|
||||||
|
|
||||||
|
### OpenRouter
|
||||||
|
- **Best for:** Flexibility, trying different models
|
||||||
|
- **Pros:** 200+ models, single API key
|
||||||
|
- **Cons:** Cache support depends on upstream
|
||||||
|
|
||||||
|
### Anthropic/Claude
|
||||||
|
- **Best for:** Complex reasoning, reliability
|
||||||
|
- **Pros:** Excellent tool calling, context understanding
|
||||||
|
- **Cons:** Higher cost, no special cache discounts
|
||||||
|
|
||||||
|
### Nous Portal
|
||||||
|
- **Best for:** Supporting the project, native integration
|
||||||
|
- **Pros:** OAuth, built-in support
|
||||||
|
- **Cons:** Subscription model
|
||||||
|
|
||||||
|
### Budget Providers (Kimi, DeepSeek, MiniMax)
|
||||||
|
- **Best for:** High volume, routine tasks
|
||||||
|
- **Pros:** 50-90% cost savings, fast
|
||||||
|
- **Cons:** May struggle with complex tasks
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Quotes
|
||||||
|
|
||||||
|
**On Cost:**
|
||||||
|
> "Choosing a cache-friendly provider is the single biggest lever for reducing costs."
|
||||||
|
|
||||||
|
**On Performance:**
|
||||||
|
> "One developer reported that a task taking OpenClaw 50+ tool calls and steps took Hermes 5 correct tool calls and finished 2.5 minutes faster."
|
||||||
|
|
||||||
|
**On Model Selection:**
|
||||||
|
> "For most users: Kimi K2.5 from Moonshot or MiniMax as a daily driver — both are fast, capable, and inexpensive."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Summary Table
|
||||||
|
|
||||||
|
| Provider | Cost | Reliability | Speed | Cache |
|
||||||
|
|----------|------|-------------|-------|-------|
|
||||||
|
| Claude Sonnet | $$$$ | ⭐⭐⭐⭐⭐ | ⭐⭐⭐⭐ | Partial |
|
||||||
|
| GPT-4 | $$$$ | ⭐⭐⭐⭐⭐ | ⭐⭐⭐⭐ | Partial |
|
||||||
|
| Kimi K2.5 | $$ | ⭐⭐⭐⭐ | ⭐⭐⭐⭐⭐ | 75% |
|
||||||
|
| DeepSeek | $ | ⭐⭐⭐ | ⭐⭐⭐⭐ | 90% |
|
||||||
|
| MiniMax | $$ | ⭐⭐⭐⭐ | ⭐⭐⭐⭐⭐ | No |
|
||||||
|
| OpenRouter | Varies | Varies | Varies | Varies |
|
||||||
|
|
||||||
|
**Legend:**
|
||||||
|
- $ = Budget friendly
|
||||||
|
- ⭐ = Performance rating
|
||||||
|
- Cache % = Discount on cached tokens
|
||||||
@@ -0,0 +1,96 @@
|
|||||||
|
# OpenAI GPT Models Feedback for Hermes Agent
|
||||||
|
|
||||||
|
**Source reference:** Official docs, community discussions, blog posts
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Supported Models
|
||||||
|
|
||||||
|
Hermes Agent supports OpenAI models including:
|
||||||
|
- GPT-4o / GPT-4o-mini
|
||||||
|
- GPT-5 series (via API)
|
||||||
|
- o1 / o3 (reasoning models)
|
||||||
|
- Codex models (with special OAuth handling)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Codex Integration
|
||||||
|
|
||||||
|
**Special Feature:** When using Anthropic OAuth through `hermes model`, Hermes prefers Claude Code's own credential store over copying the token into `~/.hermes/.env`. This keeps refreshable credentials working properly.
|
||||||
|
|
||||||
|
**Copilot Alternative:**
|
||||||
|
```
|
||||||
|
copilot — Direct Copilot API (recommended)
|
||||||
|
```
|
||||||
|
Uses your GitHub Copilot subscription to access GPT-5.x, Claude, Gemini, and other models through the Copilot API.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Auxiliary Vision Configuration
|
||||||
|
|
||||||
|
**Recommended setup for GPT-4o vision:**
|
||||||
|
```yaml
|
||||||
|
auxiliary:
|
||||||
|
vision:
|
||||||
|
provider: "openrouter"
|
||||||
|
model: "openai/gpt-4o"
|
||||||
|
```
|
||||||
|
|
||||||
|
**Using Codex OAuth (ChatGPT Pro/Plus):**
|
||||||
|
```yaml
|
||||||
|
auxiliary:
|
||||||
|
vision:
|
||||||
|
provider: "codex" # uses your ChatGPT OAuth token
|
||||||
|
# model defaults to gpt-5.3-codex (supports vision)
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Token Overhead
|
||||||
|
|
||||||
|
Same 13.9K fixed overhead applies to OpenAI models:
|
||||||
|
|
||||||
|
| Component | Tokens |
|
||||||
|
|-----------|--------|
|
||||||
|
| Tool definitions | 8,759 |
|
||||||
|
| System prompt | 5,176 |
|
||||||
|
| **Fixed overhead** | **~13,935** |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Feedback
|
||||||
|
|
||||||
|
### Positive
|
||||||
|
- Reliable tool calling
|
||||||
|
- Good for complex reasoning tasks
|
||||||
|
- Widely tested and supported
|
||||||
|
|
||||||
|
### Cost Considerations
|
||||||
|
- GPT-4 class models are expensive for high-volume usage
|
||||||
|
- Consider using budget models (GPT-4o-mini) for simpler tasks
|
||||||
|
- Token overhead adds significant cost multiplier
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Provider Agnostic Design
|
||||||
|
|
||||||
|
Hermes allows easy switching between providers:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
hermes model # Interactive provider selection
|
||||||
|
```
|
||||||
|
|
||||||
|
**Switch without code changes:**
|
||||||
|
- OpenAI → Anthropic → Local models
|
||||||
|
- No configuration file editing required
|
||||||
|
- API keys stored securely in `~/.hermes/.env`
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations
|
||||||
|
|
||||||
|
1. **Use GPT-4 class models** for complex architecture decisions
|
||||||
|
2. **Use GPT-4o-mini** for routine tasks to reduce costs
|
||||||
|
3. **Enable response caching** when available
|
||||||
|
4. **Monitor token usage** with `/usage` command
|
||||||
|
5. **Consider OpenRouter** for flexibility across multiple frontier models
|
||||||
@@ -0,0 +1,185 @@
|
|||||||
|
# Bug Reports and Issues Collection
|
||||||
|
|
||||||
|
**Collection Date:** 2026-04-09
|
||||||
|
**Source:** GitHub Issues (NousResearch/hermes-agent)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Critical Issues
|
||||||
|
|
||||||
|
### Issue #4146: Sandbox Code Execution Security Bypass (CRITICAL)
|
||||||
|
|
||||||
|
**Status:** Open
|
||||||
|
**Severity:** Critical
|
||||||
|
|
||||||
|
> "Critical. Any LLM prompt injection or confused deputy scenario where the agent generates sandbox code could result in arbitrary command execution as the user."
|
||||||
|
|
||||||
|
**Problem:** `execute_code` sandbox bypasses dangerous command approval via terminal tool
|
||||||
|
|
||||||
|
**Impact:** Security vulnerability - sandboxed code can execute arbitrary commands
|
||||||
|
|
||||||
|
**Recommended Fix:** Remove terminal from SANDBOX_ALLOWED_TOOLS
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Issue #1071: llama-server Compatibility (CRITICAL)
|
||||||
|
|
||||||
|
**Status:** Reported with fix
|
||||||
|
**Error:** `'dict' object has no attribute 'strip'`
|
||||||
|
|
||||||
|
**Environment:** Windows 11 + Ubuntu/WSL2, llama-server with Qwen3.5-27B
|
||||||
|
|
||||||
|
**Root Cause:** llama-server returns `function.arguments` as dict instead of JSON string
|
||||||
|
|
||||||
|
**Fix:**
|
||||||
|
```python
|
||||||
|
if isinstance(args, (dict, list)):
|
||||||
|
tc.function.arguments = json.dumps(args)
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Gateway Issues
|
||||||
|
|
||||||
|
### Issue #4469: Multiple Rapid Messages Only Last One Processed
|
||||||
|
|
||||||
|
**Status:** Open
|
||||||
|
**Component:** Gateway message queuing
|
||||||
|
|
||||||
|
**Problem:** When user sends multiple messages while agent is running, only the last message is processed
|
||||||
|
|
||||||
|
**Root Cause:** Two separate pending message storage locations:
|
||||||
|
- `GatewayRunner._pending_messages` (written but never read)
|
||||||
|
- `adapter._pending_messages` (read but never written during interrupts)
|
||||||
|
|
||||||
|
**Impact:** Orphaned message queue - user messages lost
|
||||||
|
|
||||||
|
### Issue #6212: Telegram Context Compaction Handoff Bug
|
||||||
|
|
||||||
|
**Status:** Open
|
||||||
|
**Component:** Telegram gateway
|
||||||
|
|
||||||
|
**Problem:** Fresh `/start` or `Hello?` dumps raw `[CONTEXT COMPACTION]` handoff instead of normal greeting
|
||||||
|
|
||||||
|
**Sessions Affected:**
|
||||||
|
- `20260408_111232_42b907`
|
||||||
|
- `20260408_113658_19c1fc`
|
||||||
|
|
||||||
|
**Expected:** Short greeting or "Resuming prior task" message
|
||||||
|
**Actual:** Raw compaction summary dumped to user
|
||||||
|
|
||||||
|
### Issue #5446: Discord Thread User Addition
|
||||||
|
|
||||||
|
**Status:** Open
|
||||||
|
**Problem:** User not added to private Discord thread when using `/thread` command
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Authentication Issues
|
||||||
|
|
||||||
|
### Issue #5807: Hermes Doctor Reports False "Not Logged In"
|
||||||
|
|
||||||
|
**Status:** Open
|
||||||
|
**Component:** Authentication status checking
|
||||||
|
|
||||||
|
**Problem:** `hermes doctor` reports "Nous Portal auth (not logged in)" even with valid credentials
|
||||||
|
|
||||||
|
**Root Cause:** `get_nous_auth_status()` only checks legacy `providers` section, not `credential_pool`
|
||||||
|
|
||||||
|
**Workaround:** Use `hermes auth list` for accurate status
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Migration Issues
|
||||||
|
|
||||||
|
### Issue #5191: OpenClaw Migration Silent Failures
|
||||||
|
|
||||||
|
**Status:** Open
|
||||||
|
**Component:** Migration tool
|
||||||
|
|
||||||
|
**Bug 1:** Orphaned `openclaw.json` - migration renames directory but doesn't copy config
|
||||||
|
|
||||||
|
**Bug 2:** Missing Slack token migration - tokens not extracted to `~/.hermes/.env`
|
||||||
|
|
||||||
|
**Impact:** Gateway starts in broken state with cryptic errors
|
||||||
|
|
||||||
|
**Workaround:**
|
||||||
|
```bash
|
||||||
|
cp ~/.openclaw.pre-migration-*/openclaw.json ~/.openclaw/openclaw.json
|
||||||
|
# Add to ~/.hermes/.env:
|
||||||
|
SLACK_BOT_TOKEN=xoxb-...
|
||||||
|
SLACK_APP_TOKEN=xapp-...
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Configuration Issues
|
||||||
|
|
||||||
|
### Issue #5528: Configurable Dangerous Command Patterns
|
||||||
|
|
||||||
|
**Status:** Feature Request
|
||||||
|
**Type:** Configuration enhancement
|
||||||
|
|
||||||
|
**Problem:** Dangerous-command approval patterns are hard-coded in `tools/approval.py`
|
||||||
|
|
||||||
|
**Use Case:** Users cannot mark installation-specific commands (e.g., `systemctl restart hermes-gateway`) as approval-required
|
||||||
|
|
||||||
|
**Proposed Solution:**
|
||||||
|
```yaml
|
||||||
|
approvals:
|
||||||
|
extra_dangerous_patterns:
|
||||||
|
- pattern: "\\bsystemctl\\b.*\\brestart\\b.*hermes-gateway"
|
||||||
|
description: "restart gateway service"
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Performance Issues
|
||||||
|
|
||||||
|
### Issue #4379: Token Overhead Analysis
|
||||||
|
|
||||||
|
**Status:** Documented/Under Discussion
|
||||||
|
**Finding:** 73% of every API call is fixed overhead (~13.9K tokens)
|
||||||
|
|
||||||
|
**Breakdown:**
|
||||||
|
- Tool definitions: 8,759 tokens
|
||||||
|
- System prompt: 5,176 tokens
|
||||||
|
- Skills catalog: ~2,200 tokens (eagerly loaded)
|
||||||
|
|
||||||
|
**Recommended Optimizations:**
|
||||||
|
1. Platform-aware tool filtering (messaging platforms don't need browser tools)
|
||||||
|
2. Lazy skills loading (remove from system prompt)
|
||||||
|
3. Compression tuning documentation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Memory Issues
|
||||||
|
|
||||||
|
### Issue #509: Cognitive Memory Operations
|
||||||
|
|
||||||
|
**Status:** Feature Request
|
||||||
|
**Proposal:** Add LLM-driven encoding, consolidation, adaptive recall & extraction
|
||||||
|
|
||||||
|
**Goal:** Self-maintaining knowledge base that compounds over time
|
||||||
|
|
||||||
|
### Issue #3943: MemoryProvider Interface
|
||||||
|
|
||||||
|
**Status:** Feature Request
|
||||||
|
**Proposal:** Interface for long-term memory integrations
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Summary Table
|
||||||
|
|
||||||
|
| Issue | Severity | Status | Component |
|
||||||
|
|-------|----------|--------|-----------|
|
||||||
|
| #4146 | Critical | Open | Security |
|
||||||
|
| #1071 | Critical | Fix Ready | Local Models |
|
||||||
|
| #4469 | High | Open | Gateway |
|
||||||
|
| #6212 | Medium | Open | Telegram |
|
||||||
|
| #5807 | Medium | Open | Auth |
|
||||||
|
| #5191 | Medium | Open | Migration |
|
||||||
|
| #4379 | Medium | Documented | Performance |
|
||||||
|
| #5528 | Low | Feature Req | Config |
|
||||||
|
| #509 | Low | Feature Req | Memory |
|
||||||
|
| #3943 | Low | Feature Req | Memory |
|
||||||
@@ -0,0 +1,248 @@
|
|||||||
|
# Feature Feedback and User Experience
|
||||||
|
|
||||||
|
**Collection Date:** 2026-04-09
|
||||||
|
**Sources:** GitHub issues, blog posts, community discussions, documentation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Skills System
|
||||||
|
|
||||||
|
### Positive Feedback
|
||||||
|
|
||||||
|
**Self-Improvement Loop:**
|
||||||
|
> "The agent can transform what it learns into reusable skills, improve them through experience, store useful information, and even search for previous conversations."
|
||||||
|
|
||||||
|
**Progressive Disclosure:**
|
||||||
|
- Level 0: Skill names/descriptions (~3,000 tokens)
|
||||||
|
- Level 1: Full skill content when needed
|
||||||
|
- Level 2: Specific reference files
|
||||||
|
|
||||||
|
**Skill Creation:**
|
||||||
|
- Auto-generated after complex tasks (5+ tool calls)
|
||||||
|
- Can be hand-written
|
||||||
|
- Installable from Skills Hub
|
||||||
|
- Shareable via agentskills.io format
|
||||||
|
|
||||||
|
### Community Contributions
|
||||||
|
|
||||||
|
**Awesome Hermes Agent:** https://github.com/0xNyk/awesome-hermes-agent
|
||||||
|
- Curated list of skills, tools, integrations
|
||||||
|
- Four plugins covering common operational needs
|
||||||
|
- Inter-agent bridge for multiple Hermes instances
|
||||||
|
- Hermes-skill-factory (auto-generates skills from workflows)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Memory System
|
||||||
|
|
||||||
|
### Architecture
|
||||||
|
|
||||||
|
**Three Layers:**
|
||||||
|
1. **Short-term** - Recent context in conversation
|
||||||
|
2. **Long-term** - MEMORY.md (facts, conventions, lessons)
|
||||||
|
3. **Episodic** - SQLite FTS5 search across all sessions
|
||||||
|
|
||||||
|
**Storage:**
|
||||||
|
- `MEMORY.md` (~2,200 chars) - Always in context
|
||||||
|
- `USER.md` (~1,375 chars) - User preferences
|
||||||
|
- `~/.hermes/state.db` - SQLite with full-text search
|
||||||
|
|
||||||
|
### User Confusion Points
|
||||||
|
|
||||||
|
**Source:** https://vectorize.io/articles/hermes-agent-memory-not-working
|
||||||
|
|
||||||
|
> "Memory is for critical facts that should always be in context. Session search is for 'did we discuss X last week?' queries where the agent needs to recall — it doesn't happen automatically before every response."
|
||||||
|
|
||||||
|
**Common Misconception:** Agent should automatically remember everything
|
||||||
|
**Reality:** User must explicitly ask agent to remember: "Remember that my production database runs on port 5433"
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Delegation and Subagents
|
||||||
|
|
||||||
|
### Performance Benefits
|
||||||
|
|
||||||
|
> "Use delegate_task with parallel subtasks. Each subagent runs independently with its own context, and only the final summaries come back — massively reducing your main conversation's token usage."
|
||||||
|
|
||||||
|
### Best Practices
|
||||||
|
|
||||||
|
1. **Set max_iterations lower** for simple tasks (default: 50)
|
||||||
|
2. **Be specific in goals** - "Fix the TypeError in api/handlers.py line 47" not "Fix the bug"
|
||||||
|
3. **Include file paths** - Subagents don't know your project structure
|
||||||
|
4. **Use for context isolation** - Prevents main conversation bloat
|
||||||
|
|
||||||
|
### Multi-Agent Architecture (Future)
|
||||||
|
|
||||||
|
**Issue #344 Proposal:**
|
||||||
|
- L0: Current (exists today)
|
||||||
|
- L1: Workflow engine
|
||||||
|
- L2: Checkpointing and recovery
|
||||||
|
- L3: Full orchestration
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Cron and Scheduling
|
||||||
|
|
||||||
|
### Use Cases
|
||||||
|
|
||||||
|
**Examples:**
|
||||||
|
> "Every morning at 9am, check Hacker News for AI news and send me a summary on Telegram."
|
||||||
|
|
||||||
|
> "Weekly dependency audit every Sunday at 6 AM"
|
||||||
|
|
||||||
|
### Features
|
||||||
|
- Output automatically delivered to configured platform
|
||||||
|
- Job output saved to `~/.hermes/cron/output/<job-id>/<timestamp>.md`
|
||||||
|
- Test with `/cron run <job_id>` before scheduling
|
||||||
|
|
||||||
|
### Limitations
|
||||||
|
- Agent only sees script stdout
|
||||||
|
- Background execution requires proper setup
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Gateway and Messaging
|
||||||
|
|
||||||
|
### Supported Platforms
|
||||||
|
|
||||||
|
**Full List:**
|
||||||
|
- Telegram
|
||||||
|
- Discord
|
||||||
|
- Slack
|
||||||
|
- WhatsApp
|
||||||
|
- Signal
|
||||||
|
- Email
|
||||||
|
- SMS
|
||||||
|
- Home Assistant
|
||||||
|
- Matrix/Mattermost
|
||||||
|
- DingTalk/Feishu/WeCom
|
||||||
|
|
||||||
|
### Cross-Platform Continuity
|
||||||
|
|
||||||
|
> "Instructions are given via Telegram in the morning, and progress is checked via Discord at night. It's seamless."
|
||||||
|
|
||||||
|
### Voice Support
|
||||||
|
|
||||||
|
- Voice memo transcription on all platforms
|
||||||
|
- TTS output with `/voice` command
|
||||||
|
- Discord voice channel support
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Terminal Backends
|
||||||
|
|
||||||
|
### Options
|
||||||
|
|
||||||
|
1. **Local** (default)
|
||||||
|
2. **Docker** (sandboxed)
|
||||||
|
3. **SSH** (remote server)
|
||||||
|
4. **Daytona** (serverless persistence)
|
||||||
|
5. **Singularity**
|
||||||
|
6. **Modal** (serverless, hibernates when idle)
|
||||||
|
|
||||||
|
### Security
|
||||||
|
|
||||||
|
- Container hardening with read-only root
|
||||||
|
- Dropped capabilities
|
||||||
|
- Namespace isolation
|
||||||
|
- Dangerous command approval system
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Browser and Vision
|
||||||
|
|
||||||
|
### Browser Tools
|
||||||
|
|
||||||
|
**Set:**
|
||||||
|
- `browser_navigate`
|
||||||
|
- `browser_click`
|
||||||
|
- `browser_snapshot`
|
||||||
|
- `browser_type`
|
||||||
|
- etc. (11 tools total)
|
||||||
|
|
||||||
|
**Cost Impact:**
|
||||||
|
- Browser tools add ~1,258 tokens to every request (even when unused in messaging)
|
||||||
|
- Screenshots + vision analysis are high-token operations
|
||||||
|
|
||||||
|
### Vision Analysis
|
||||||
|
|
||||||
|
**Supported:**
|
||||||
|
- Image URLs via `vision_analyze`
|
||||||
|
- Image paste in CLI (with xclip/x11 forwarding)
|
||||||
|
- Images via messaging platforms
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Voice Mode
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
- **STT:** faster-whisper (local, free)
|
||||||
|
- **TTS:** Microsoft Edge TTS (free)
|
||||||
|
- **Recording:** Ctrl+B in CLI
|
||||||
|
- **Cross-platform:** Works in Telegram, Discord, etc.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Comparison: Hermes vs OpenClaw
|
||||||
|
|
||||||
|
### Hermes Advantages
|
||||||
|
|
||||||
|
| Aspect | Winner | Reason |
|
||||||
|
|--------|--------|--------|
|
||||||
|
| Personal companion | Hermes | Continuous learning, personalization |
|
||||||
|
| Repetitive task automation | Hermes | Skill learning adapts to workflows |
|
||||||
|
| Voice interaction | Hermes | Native voice support |
|
||||||
|
| Lightweight deployment | Hermes | 20MB vs 200MB+ |
|
||||||
|
| Signal support | Hermes | Better multi-platform |
|
||||||
|
| Local model support | Hermes | Works better with Ollama/llama.cpp |
|
||||||
|
|
||||||
|
### OpenClaw Advantages
|
||||||
|
|
||||||
|
| Aspect | Winner | Reason |
|
||||||
|
|--------|--------|--------|
|
||||||
|
| Multi-agent coordination | OpenClaw | Better fleet management |
|
||||||
|
| Browser automation | OpenClaw | More mature plugin ecosystem |
|
||||||
|
| Community/plugins | OpenClaw | 307k stars vs 6k |
|
||||||
|
| MCP ecosystem | OpenClaw | More mature |
|
||||||
|
|
||||||
|
### Community Recommendation
|
||||||
|
|
||||||
|
> "Use both. OpenClaw as the 'fleet commander' for multi-agent coordination, Hermes as your 'personal advisor' for one-on-one tasks."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## User Experience Feedback
|
||||||
|
|
||||||
|
### Positive
|
||||||
|
|
||||||
|
> "Hermes optimizes for depth of learning. It is smaller, more opinionated, and built by a team that trains the underlying models."
|
||||||
|
|
||||||
|
> "For repetitive workflows where agent improvement creates measurable value over time, Hermes is the stronger choice."
|
||||||
|
|
||||||
|
> "It just works — installation to first conversation is minutes, not hours."
|
||||||
|
|
||||||
|
### Areas for Improvement
|
||||||
|
|
||||||
|
1. **Token overhead transparency** - Users surprised by costs
|
||||||
|
2. **Memory system education** - Users expect automatic memory
|
||||||
|
3. **Local model guidance** - Need better model recommendations
|
||||||
|
4. **Gateway debugging** - Error messages can be cryptic
|
||||||
|
5. **Migration experience** - OpenClaw migration has rough edges
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Summary
|
||||||
|
|
||||||
|
**Strengths:**
|
||||||
|
- Self-improving skill system
|
||||||
|
- Excellent multi-platform support
|
||||||
|
- Strong memory architecture
|
||||||
|
- Good local model support
|
||||||
|
- Active development
|
||||||
|
|
||||||
|
**Weaknesses:**
|
||||||
|
- Token overhead can surprise users
|
||||||
|
- Some migration/tooling rough edges
|
||||||
|
- Documentation gaps for advanced features
|
||||||
|
- Memory system requires user education
|
||||||
@@ -0,0 +1,136 @@
|
|||||||
|
# Terminal-Bench Benchmark Results
|
||||||
|
|
||||||
|
**Collection Date:** 2026-04-09
|
||||||
|
**Sources:** arXiv papers, official docs, community discussions
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## About Terminal-Bench
|
||||||
|
|
||||||
|
**Paper:** [2601.11868] Terminal-Bench: Benchmarking Agents on Hard, Realistic Tasks in Command Line Interfaces
|
||||||
|
|
||||||
|
**Key Finding:**
|
||||||
|
> "We show that frontier models and agents score less than 65% on the benchmark"
|
||||||
|
|
||||||
|
**Dataset:** NousResearch/terminal-bench-2
|
||||||
|
**Legacy:** terminal-bench-core v0.1.1
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Hermes Agent Benchmark Support
|
||||||
|
|
||||||
|
### Configuration
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
env:
|
||||||
|
enabled_toolsets: ["terminal", "file"]
|
||||||
|
max_agent_turns: 60
|
||||||
|
max_token_length: 32000
|
||||||
|
agent_temperature: 0.8
|
||||||
|
terminal_backend: "modal"
|
||||||
|
terminal_timeout: 300
|
||||||
|
dataset_name: "NousResearch/terminal-bench-2"
|
||||||
|
tokenizer_name: "NousResearch/Hermes-3-Llama-3.1-8B"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Running Evaluations
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Install
|
||||||
|
tb run \
|
||||||
|
--agent terminus \
|
||||||
|
--model anthropic/claude-3-7-latest \
|
||||||
|
--dataset-name terminal-bench-core \
|
||||||
|
--dataset-version 0.1.1 \
|
||||||
|
--n-concurrent 8
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## YC-Bench (Strategic Benchmark)
|
||||||
|
|
||||||
|
**Description:** Long-horizon strategic benchmark — the agent plays CEO of an AI startup
|
||||||
|
|
||||||
|
**Setup:**
|
||||||
|
```bash
|
||||||
|
pip install "hermes-agent[yc-bench]"
|
||||||
|
bash environments/benchmarks/yc_bench/run_eval.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Benchmark Results
|
||||||
|
|
||||||
|
### WebArena Performance
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLM/comments/1scglgq/i_looked_into_hermes_agent_architecture_to_dig/
|
||||||
|
|
||||||
|
> "It identified 11 websites from pure text and hit 60% testing WebArena tasks without tuning"
|
||||||
|
|
||||||
|
### Multi-Agent Performance
|
||||||
|
|
||||||
|
**Source:** https://ghost.codersera.com/blog/hermes-agent-guide-to-multi-agent-ai-setup/
|
||||||
|
|
||||||
|
> "In that study, a multi-agent Hermes setup reached 75–85% success on complex network design tasks, above chain-of-thought baselines."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmark Architecture
|
||||||
|
|
||||||
|
### Environments Available
|
||||||
|
|
||||||
|
1. **Terminal-Bench** - Command line tasks
|
||||||
|
2. **YC-Bench** - Strategic business simulation
|
||||||
|
3. **TBLite** - Thin subclass of TerminalBench2 (OpenThoughts Agent team)
|
||||||
|
|
||||||
|
### Key Capabilities Tested
|
||||||
|
|
||||||
|
- Tool use accuracy
|
||||||
|
- Multi-step reasoning
|
||||||
|
- Context management
|
||||||
|
- Error recovery
|
||||||
|
- Long-horizon planning
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmarking Best Practices
|
||||||
|
|
||||||
|
### Using Harbor Framework
|
||||||
|
|
||||||
|
**Leaderboard:** https://www.tbench.ai/leaderboard
|
||||||
|
|
||||||
|
**Versions:**
|
||||||
|
- Terminal-Bench 2.0 (latest) - via Harbor
|
||||||
|
- Terminal-Bench-Core v0.1.1 (legacy)
|
||||||
|
|
||||||
|
### Configuration Tips
|
||||||
|
|
||||||
|
1. **Match context length** to model capabilities
|
||||||
|
2. **Set appropriate timeouts** (300s for complex tasks)
|
||||||
|
3. **Use Modal backend** for isolation
|
||||||
|
4. **Enable concurrent runs** for faster evaluation
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Research Focus
|
||||||
|
|
||||||
|
The hermes-agent project uses these benchmarks to track:
|
||||||
|
|
||||||
|
1. **Tool handling effectiveness**
|
||||||
|
2. **Skills system impact** on performance
|
||||||
|
3. **Prompt engineering strategies**
|
||||||
|
4. **Context management efficiency**
|
||||||
|
5. **Performance on smaller/local models**
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Summary
|
||||||
|
|
||||||
|
| Benchmark | Hermes Result | Notes |
|
||||||
|
|-----------|---------------|-------|
|
||||||
|
| WebArena | 60% | Without tuning |
|
||||||
|
| Multi-agent network design | 75-85% | Above CoT baseline |
|
||||||
|
| Terminal-Bench | N/A | Framework supported |
|
||||||
|
| YC-Bench | N/A | Strategic CEO simulation |
|
||||||
|
|
||||||
|
**Key Takeaway:** Hermes Agent demonstrates strong performance on agentic benchmarks, particularly in multi-agent configurations and real-world task completion.
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
# Gemma Models Feedback for Hermes Agent
|
||||||
|
|
||||||
|
**Source reference:** Reddit r/LocalLLaMA, HuggingFace blog, community discussions
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Gemma 4 Support
|
||||||
|
|
||||||
|
**Status:** Day-0 ecosystem support confirmed
|
||||||
|
|
||||||
|
> "We worked on making sure the new models work locally with agents like openclaw, hermes, pi, and open code. All thanks to llama.cpp!"
|
||||||
|
|
||||||
|
**Source:** https://huggingface.co/blog/gemma4
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Gemma 4 vs Qwen 3.5 Comparison
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLaMA/comments/1scbpmo/so_qwen35_or_gemma_4/
|
||||||
|
|
||||||
|
### Tool Use Issues
|
||||||
|
|
||||||
|
> "Gemma keeps duplicating tool calls for some reason."
|
||||||
|
|
||||||
|
> "Gemma is pretty fun to talk to, reminds me of the early model whimsy."
|
||||||
|
|
||||||
|
> "Fixes for llama.cpp are happening in real-time so things may not be fair but so far Gemma is failing to complete the complex challenge which qwen can succeed at (24gb VRAM) it's just giving up and claiming it's succeeded when it hasn't."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Performance Notes
|
||||||
|
|
||||||
|
- Gemma 4 26B A4B Q8_0 on M2 Ultra achieves ~300 t/s (with speculative decoding caveats)
|
||||||
|
- llama.cpp support actively being fixed in real-time
|
||||||
|
- Better for conversational use than complex agentic tasks
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendation
|
||||||
|
|
||||||
|
For Hermes Agent specifically, community feedback suggests Qwen 3.5 currently outperforms Gemma 4 for:
|
||||||
|
- Tool use with novel tools
|
||||||
|
- Complex multi-step tasks
|
||||||
|
- Agent reliability
|
||||||
|
|
||||||
|
Gemma 4 may be preferable for:
|
||||||
|
- Conversational interactions
|
||||||
|
- Creative writing tasks
|
||||||
|
- When llama.cpp optimizations mature
|
||||||
@@ -0,0 +1,117 @@
|
|||||||
|
# General Local LLM Feedback for Hermes Agent
|
||||||
|
|
||||||
|
**Collection Date:** 2026-04-09
|
||||||
|
**Sources:** Reddit r/LocalLLaMA, r/LocalLLM, GitHub issues, blog posts, community discussions
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Overall Assessment
|
||||||
|
|
||||||
|
Hermes Agent is widely reported to work "way better" with local models than OpenClaw. However, users face challenges with configuration complexity and model selection.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Positive Feedback
|
||||||
|
|
||||||
|
### Better Than OpenClaw for Local Models
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLM/comments/1rye221/anyone_working_with_hermes_agent/
|
||||||
|
|
||||||
|
> "its worknig better for me than openclaw, this i mean with local models, when i use openclaw i cant even load up 4b models, i am not sure why but i decided to see if the same problem would persist with hermes and i dint get this issue."
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLaMA/comments/1rwhi2h/running_hermes_agent_locally_with_lm_studio/
|
||||||
|
|
||||||
|
> "This Hermes agent already works way way better than Open Claw and it actually works pretty well locally. I have to be super careful about exposing this to the outside world because the model is not smart enough, probably, to catch sophisticated..."
|
||||||
|
|
||||||
|
### Architecture Appreciation
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLM/comments/1scglgq/i_looked_into_hermes_agent_architecture_to_dig/
|
||||||
|
|
||||||
|
> "It identified 11 websites from pure text and hit 60% testing WebArena tasks without tuning"
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Challenges and Issues
|
||||||
|
|
||||||
|
### Tool Calling Reliability
|
||||||
|
|
||||||
|
**Issue:** Models work initially but forget which tools to use after first call
|
||||||
|
|
||||||
|
**Affected:** Smaller models (4B, 7B range)
|
||||||
|
|
||||||
|
> "tool calls not always work i use ollama and qwen3.5:4b qwen2.5:7b and they all tool call once than they forget which one to use"
|
||||||
|
|
||||||
|
### Context Management Confusion
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLM/comments/1sc82o8/hermesagent_what_is_this_message_about/
|
||||||
|
|
||||||
|
> "Context exceeded your setting. Either your Hermes context or your llm server context setting for that particular model. By default context is usually set to something comically low."
|
||||||
|
|
||||||
|
### System Prompt Size Concerns
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLaMA/comments/1rwhi2h/running_hermes_agent_locally_with_lm_studio/
|
||||||
|
|
||||||
|
> "Hermes has a huge system prompt. When I try to run it with Qwen-3.5 35B it's difficult..."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model-Specific Feedback
|
||||||
|
|
||||||
|
### Recommended for Local Use
|
||||||
|
|
||||||
|
1. **Qwen 3.5 27B** - Best overall performance
|
||||||
|
- Requires: 24GB+ VRAM
|
||||||
|
- Speed: ~25 t/s with proper quantization
|
||||||
|
- Tool use: Excellent
|
||||||
|
|
||||||
|
2. **Qwen 3.5 14B** - Good balance
|
||||||
|
- Requires: 16GB VRAM
|
||||||
|
- Decent tool use reliability
|
||||||
|
|
||||||
|
3. **Qwen 3.5 8B** - Minimum viable
|
||||||
|
- Requires: 8GB VRAM
|
||||||
|
- Tool use may be inconsistent
|
||||||
|
|
||||||
|
### Not Recommended
|
||||||
|
|
||||||
|
- Very small models (4B and below) for complex agent tasks
|
||||||
|
- Models without good tool calling fine-tuning
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Token Overhead Impact on Local Models
|
||||||
|
|
||||||
|
**Critical Issue:** Even local models face 13.9K token overhead per request
|
||||||
|
|
||||||
|
**Source:** GitHub Issue #4379
|
||||||
|
|
||||||
|
| Component | Tokens |
|
||||||
|
|-----------|--------|
|
||||||
|
| Tool definitions (31 tools) | 8,759 |
|
||||||
|
| System prompt | 5,176 |
|
||||||
|
| Fixed overhead | ~13,935 |
|
||||||
|
|
||||||
|
**Impact:** Local models with smaller context windows hit limits quickly due to this overhead.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Suggestions
|
||||||
|
|
||||||
|
1. **Better documentation** for local model setup
|
||||||
|
2. **Recommended model list** with VRAM requirements
|
||||||
|
3. **Tool calling reliability benchmarks** by model size
|
||||||
|
4. **Reduced toolset option** for resource-constrained setups
|
||||||
|
5. **Better context management guidance**
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Summary Table
|
||||||
|
|
||||||
|
| Aspect | Rating | Notes |
|
||||||
|
|--------|--------|-------|
|
||||||
|
| Local model support | ⭐⭐⭐⭐⭐ | Better than alternatives |
|
||||||
|
| Setup ease | ⭐⭐⭐ | Requires technical knowledge |
|
||||||
|
| Tool calling (8B+) | ⭐⭐⭐⭐ | Good with right models |
|
||||||
|
| Tool calling (4B) | ⭐⭐ | Inconsistent |
|
||||||
|
| Documentation | ⭐⭐⭐ | Improving but gaps remain |
|
||||||
|
| Community support | ⭐⭐⭐⭐⭐ | Active and helpful |
|
||||||
@@ -0,0 +1,119 @@
|
|||||||
|
# Local Model Setup Issues & Solutions
|
||||||
|
|
||||||
|
**Source reference:** GitHub issues, Reddit, official FAQ, blog posts
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Issue #523: Local Model Setup Skill Request
|
||||||
|
|
||||||
|
**Problem:** Users struggle with local model configuration
|
||||||
|
|
||||||
|
> "No model recommendations: Users must know which models support tool calling. There's no guidance on model selection. No setup instructions: No docs or skills for installing/configuring Ollama, llama.cpp, or vLLM."
|
||||||
|
|
||||||
|
**Requested Solution:** A skill that guides users through:
|
||||||
|
1. Setting up local models with Hermes Agent
|
||||||
|
2. Model recommendations for different use cases
|
||||||
|
3. Configuration nuances that trip up new users
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Issue #1071: llama-server Compatibility (CRITICAL)
|
||||||
|
|
||||||
|
**Error:** `'dict' object has no attribute 'strip'`
|
||||||
|
|
||||||
|
**Impact:** Complete failure with llama-server/Ollama backends
|
||||||
|
|
||||||
|
**Fix Location:** `run_agent.py` line ~4280
|
||||||
|
|
||||||
|
**User Workaround:**
|
||||||
|
```python
|
||||||
|
# Add before: if not args or not args.strip():
|
||||||
|
if isinstance(args, (dict, list)):
|
||||||
|
tc.function.arguments = json.dumps(args)
|
||||||
|
continue
|
||||||
|
```
|
||||||
|
|
||||||
|
**Related Issues:**
|
||||||
|
- llama.cpp #14697
|
||||||
|
- ollama-python #484
|
||||||
|
- litellm #8313
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Context Length Configuration Issues
|
||||||
|
|
||||||
|
**Common Error:** "Context exceeded your setting"
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLM/comments/1sc82o8/hermesagent_what_is_this_message_about/
|
||||||
|
|
||||||
|
> "Context exceeded your setting. Either your Hermes context or your llm server context setting for that particular model. By default context is usually set to something comically low."
|
||||||
|
|
||||||
|
**Solution:**
|
||||||
|
```yaml
|
||||||
|
model:
|
||||||
|
default: your-model-name
|
||||||
|
context_length: 32768 # Match your server's num_ctx
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Issue #879: Local Model Routing for Auxiliary Tasks
|
||||||
|
|
||||||
|
**Feature Request:** Direct auxiliary tasks (vision, etc.) to local endpoint independently of main provider
|
||||||
|
|
||||||
|
**Use Case:** Use local model for fast tasks, cloud model for complex reasoning
|
||||||
|
|
||||||
|
**Dependencies:** Multi-model hybrid setup support
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Windows/WSL2 Limitations
|
||||||
|
|
||||||
|
**Status:** Native Windows not supported
|
||||||
|
|
||||||
|
> "Native Windows support is extremely experimental and unsupported. Please install WSL2 and run Hermes Agent from there."
|
||||||
|
|
||||||
|
**Installation:**
|
||||||
|
```bash
|
||||||
|
# Inside WSL2
|
||||||
|
curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Best Practices from Community
|
||||||
|
|
||||||
|
### Ollama Setup
|
||||||
|
1. Start server with adequate context: `ollama run --num_ctx 16384`
|
||||||
|
2. Match context in Hermes config exactly
|
||||||
|
3. Use `hermes model` to select "Custom endpoint"
|
||||||
|
4. Base URL: `http://localhost:11434/v1`
|
||||||
|
5. Leave API key blank for local
|
||||||
|
|
||||||
|
### Recommended Local Models by Use Case
|
||||||
|
|
||||||
|
| Use Case | Model | VRAM Needed |
|
||||||
|
|----------|-------|-------------|
|
||||||
|
| General agent work | Qwen 3.5 27B | 24GB |
|
||||||
|
| Fast responses | Qwen 3.5 14B | 16GB |
|
||||||
|
| Limited VRAM | Qwen 3.5 8B | 8GB |
|
||||||
|
| Experimental | Gemma 4 27B | 24GB |
|
||||||
|
|
||||||
|
### Common Pitfalls
|
||||||
|
1. **Mismatching context lengths** between Ollama and Hermes
|
||||||
|
2. **Assuming all models support tool calling** equally well
|
||||||
|
3. **Not setting max iterations** appropriate for local model speed
|
||||||
|
4. **Expecting frontier-level reliability** from smaller models
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Community Feedback Summary
|
||||||
|
|
||||||
|
**Positive:**
|
||||||
|
- "Hermes agent already works way way better than Open Claw and it actually works pretty well locally"
|
||||||
|
- Better local model support than alternatives
|
||||||
|
|
||||||
|
**Challenges:**
|
||||||
|
- Tool calling reliability varies by model
|
||||||
|
- Configuration complexity for beginners
|
||||||
|
- Token overhead still applies (13.9K tokens per call)
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
# Qwen Models Feedback for Hermes Agent
|
||||||
|
|
||||||
|
**Source reference:** Multiple Reddit r/LocalLLaMA posts, GitHub issues, community discussions
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model: Qwen 3.5 (Various Sizes)
|
||||||
|
|
||||||
|
### Qwen 3.5 27B - Highly Recommended
|
||||||
|
|
||||||
|
**Hardware:** Dual 3090s with UD_5XL quant from Unsloth
|
||||||
|
**Performance:** ~25 t/s at 32k context
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLaMA/comments/1ro9lph/anybody_who_tried_hermesagent/
|
||||||
|
|
||||||
|
> "The go to model for intelligence on decent hardware is qwen 3.5 27B, if you have two 3090s, use the UD_5XL quant from unsloth - its amazing. You will get about 25 t/s with this one, at a contex size of 32k, which is perfect."
|
||||||
|
|
||||||
|
### Tool Calling Performance
|
||||||
|
|
||||||
|
**Issue:** Tool calls work once then model forgets which tool to use
|
||||||
|
**Models affected:** Qwen 3.5 4B, Qwen 2.5 7B
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLaMA/comments/1s4yy6o/best_model_for_hermesagent/
|
||||||
|
|
||||||
|
> "I use ollama and qwen3.5:4b qwen2.5:7b and they all tool call once than they forget which one to use any recomendations for other models?"
|
||||||
|
|
||||||
|
**User hardware:** 8GB VRAM
|
||||||
|
|
||||||
|
### Qwen vs Gemma 4 Comparison
|
||||||
|
|
||||||
|
**Source:** https://www.reddit.com/r/LocalLLaMA/comments/1scbpmo/so_qwen35_or_gemma_4/
|
||||||
|
|
||||||
|
> "For me Qwen is working significantly better for tool use with novel tools (things unlike what you'd expect in OpenCode or Claude Code). Gemma keeps duplicating tool calls for some reason."
|
||||||
|
|
||||||
|
> "Gemma is failing to complete the complex challenge which qwen can succeed at (24gb VRAM) it's just giving up and claiming it's succeeded when it hasn't."
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## llama-server (llama.cpp) Compatibility Issue
|
||||||
|
|
||||||
|
**Issue #1071:** Critical bug with llama-server/Ollama backend
|
||||||
|
|
||||||
|
**Error:** `'dict' object has no attribute 'strip'` during tool call argument validation
|
||||||
|
|
||||||
|
**Environment:**
|
||||||
|
- OS: Windows 11 (llama-server) + Ubuntu/WSL2 (hermes-agent)
|
||||||
|
- Python: 3.11.15
|
||||||
|
- Hermes: v0.2.0
|
||||||
|
- Backend: llama-server with Qwen3.5-27B-Q4_K_M.gguf
|
||||||
|
|
||||||
|
**Root Cause:**
|
||||||
|
Hermes assumes `tc.function.arguments` is always a string, but llama-server sometimes returns it as a parsed dict. This is a known llama-server/Ollama behavior divergence from OpenAI spec.
|
||||||
|
|
||||||
|
**Fix:**
|
||||||
|
```python
|
||||||
|
if isinstance(args, (dict, list)):
|
||||||
|
tc.function.arguments = json.dumps(args)
|
||||||
|
```
|
||||||
|
|
||||||
|
**Status:** User-submitted fix confirmed working
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Best Practices for Local Models
|
||||||
|
|
||||||
|
### Context Length Configuration
|
||||||
|
|
||||||
|
**Critical:** Match Ollama's `num_ctx` with Hermes config
|
||||||
|
|
||||||
|
> "Ollama users: If you set custom `num_ctx` (e.g., `ollama run --num_ctx 16384`), ensure matching context length in Hermes — Ollama's `/api/show` reports the model's *maximum* context, not the effective `num_ctx` configured."
|
||||||
|
|
||||||
|
**Source:** https://hermes-agent.nousresearch.com/docs/reference/faq
|
||||||
|
|
||||||
|
### Model Recommendations by VRAM
|
||||||
|
|
||||||
|
| VRAM | Recommended Model | Notes |
|
||||||
|
|------|------------------|-------|
|
||||||
|
| 8GB | Qwen 3.5 4B | Tool calling may be inconsistent |
|
||||||
|
| 24GB | Qwen 3.5 27B (Q4_K_M) | Excellent tool use, 25 t/s |
|
||||||
|
| 48GB+ | Qwen 3.5 27B UD_5XL | Best quality, ~25 t/s at 32k ctx |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## General Local Model Feedback
|
||||||
|
|
||||||
|
**Positive:**
|
||||||
|
- "Hermes agent already works way way better than Open Claw and it actually works pretty well locally"
|
||||||
|
- "I have to be super careful about exposing this to the outside world because the model is not smart enough, probably, to catch sophisticated..."
|
||||||
|
|
||||||
|
**Challenges:**
|
||||||
|
- Context exceeded errors common with default settings
|
||||||
|
- Need to manually configure context length to match model capabilities
|
||||||
|
- Tool calling reliability varies significantly by model size
|
||||||
Submodule
+1
Submodule hermes/repo added at 268ee6bdce
@@ -0,0 +1,43 @@
|
|||||||
|
# AGENTS.md
|
||||||
|
|
||||||
|
## Research/Analysis Folder for opencode
|
||||||
|
|
||||||
|
This is the research and analysis folder for the **opencode** coding harness.
|
||||||
|
|
||||||
|
### Folder Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
opencode/
|
||||||
|
repo/ - opencode-ai/opencode source code
|
||||||
|
feedback/
|
||||||
|
localllm/ - Community feedback and performance data for local models
|
||||||
|
frontier/ - Community feedback and performance data for frontier models
|
||||||
|
```
|
||||||
|
|
||||||
|
### What's Inside
|
||||||
|
|
||||||
|
- **repo/**: The official opencode repository (Go-based coding agent)
|
||||||
|
- **feedback/localllm/**: Feedback, benchmark results, and observations from using opencode with smaller/local LLMs
|
||||||
|
- **feedback/frontier/**: Feedback, benchmark results, and observations from using opencode with frontier models
|
||||||
|
|
||||||
|
### Feedback Format
|
||||||
|
|
||||||
|
Each feedback file should include:
|
||||||
|
- Model used (name, size, provider)
|
||||||
|
- Benchmark results or task performance
|
||||||
|
- Issues encountered
|
||||||
|
- What worked well
|
||||||
|
- **Source reference**: URL or site where the feedback came from (community posts, Discord, GitHub issues, etc.)
|
||||||
|
|
||||||
|
### Research Focus
|
||||||
|
|
||||||
|
This folder collects data on:
|
||||||
|
- Tool handling and capabilities
|
||||||
|
- Skills system effectiveness
|
||||||
|
- Prompt engineering strategies
|
||||||
|
- Context management
|
||||||
|
- Performance on benchmarks (terminal-bench, etc.)
|
||||||
|
|
||||||
|
### Goal
|
||||||
|
|
||||||
|
Extract best practices specifically for smaller/local models and document what works vs. what doesn't for the opencode harness. General use / use with frontier models information should be put in the feedback/frontier folder.
|
||||||
@@ -0,0 +1,288 @@
|
|||||||
|
# OpenCode Feedback Summary
|
||||||
|
|
||||||
|
## Executive Overview
|
||||||
|
|
||||||
|
This document provides a comprehensive summary of community feedback, benchmark results, and performance observations for **OpenCode** AI coding agent. Data sourced from Reddit, GitHub issues, benchmark dashboards, community blogs, and technical documentation.
|
||||||
|
|
||||||
|
**Total Sources Analyzed:** 50+ unique sources
|
||||||
|
**Date Range:** November 2025 - April 2026
|
||||||
|
**Focus Areas:** Local LLMs, Frontier Models, Tool Handling, Prompt Engineering, Context Management
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Key Findings
|
||||||
|
|
||||||
|
### 1. Best Local Models for OpenCode
|
||||||
|
|
||||||
|
| Rank | Model | Strengths | Best For |
|
||||||
|
|------|-------|-----------|----------|
|
||||||
|
| 1 | **Qwen3.5-35B-A3B** | Best balance of speed, accuracy, context (262k) | General coding, long-context tasks |
|
||||||
|
| 2 | **Gemma 4 26B-A4B** | Excellent on M-series Mac, 8W power usage | Laptop development, M5 MacBook |
|
||||||
|
| 3 | **GLM-5.1** | SWE-Bench Pro #1 (58.4), 8-hour autonomy | Long-horizon tasks, enterprise |
|
||||||
|
| 4 | **Nemotron 3 Super** | PinchBench 85.6%, 1M context | Agentic reasoning, GPU clusters |
|
||||||
|
| 5 | **Gemma 4 8B** | Runs on 16GB RAM, fast | Quick tasks, modest hardware |
|
||||||
|
|
||||||
|
### 2. Best Frontier Models for OpenCode
|
||||||
|
|
||||||
|
| Rank | Model | Strengths | Best For |
|
||||||
|
|------|-------|-----------|----------|
|
||||||
|
| 1 | **GLM-5.1** | SWE-Bench Pro #1, MIT license, cheap API | Best overall value |
|
||||||
|
| 2 | **GPT-5.4** | Terminal-Bench 2.0 #1 (75.1), strong reasoning | Complex tasks |
|
||||||
|
| 3 | **Claude Opus 4.6** | Long-horizon optimization, code quality | Deep refactoring |
|
||||||
|
| 4 | **Gemini 3.0 Pro** | 1M+ context, fast prompt processing | Long documents |
|
||||||
|
| 5 | **GPT-5.2** | Recommended default, reliable | General use |
|
||||||
|
|
||||||
|
### 3. Critical Configuration Issues
|
||||||
|
|
||||||
|
#### Context Window Problems
|
||||||
|
- **Default:** Ollama/Docker Model Runner uses 4096 tokens
|
||||||
|
- **Recommended:** Increase to 32K+ for coding tasks
|
||||||
|
- **Fix:** `docker model configure --context-size=100000 <model>`
|
||||||
|
|
||||||
|
#### Compaction Threshold
|
||||||
|
- **Problem:** Hardcoded 75% threshold causes quality degradation
|
||||||
|
- **Impact:** Gemini degrades at 30%, Claude at 50%
|
||||||
|
- **Solution:** Request configurable threshold (GitHub Issue #11314)
|
||||||
|
|
||||||
|
#### Tool Calling Templates
|
||||||
|
- **Qwen:** Requires corrected Jinja template for tool calling
|
||||||
|
- **Gemma:** Needs `tool_call: true` and `maxTokens: 16384`
|
||||||
|
- **Fix:** Custom chat templates critical for local models
|
||||||
|
|
||||||
|
### 4. Performance Benchmarks
|
||||||
|
|
||||||
|
#### Terminal-Bench 2.0
|
||||||
|
| Model | Score | Rank |
|
||||||
|
|-------|-------|------|
|
||||||
|
| GPT-5.4 | 75.1 | #1 |
|
||||||
|
| GLM-5.1 | 69.0 | #2 |
|
||||||
|
| Gemini 3.1 Pro | 68.5 | #3 |
|
||||||
|
| Claude Opus 4.6 | 65.4 | #4 |
|
||||||
|
|
||||||
|
#### SWE-Bench Pro
|
||||||
|
| Model | Score | Rank |
|
||||||
|
|-------|-------|------|
|
||||||
|
| GLM-5.1 | 58.4 | #1 (Open) |
|
||||||
|
| GPT-5.4 | 57.7 | #2 |
|
||||||
|
| Claude Opus 4.6 | 57.3 | #3 |
|
||||||
|
|
||||||
|
#### CyberGym (1,507 real tasks)
|
||||||
|
| Model | Score |
|
||||||
|
|-------|-------|
|
||||||
|
| GLM-5.1 | 68.7 |
|
||||||
|
| Claude Opus 4.6 | 66.6 |
|
||||||
|
|
||||||
|
### 5. Cost Analysis
|
||||||
|
|
||||||
|
| Model | Input Cost | Output Cost | Best Value |
|
||||||
|
|-------|-----------|-------------|------------|
|
||||||
|
| GLM-5.1 | $1.40/M | $4.40/M | ✅ Best |
|
||||||
|
| Gemini 3.0 Pro | ~$2/M | ~$6/M | Good |
|
||||||
|
| GPT-5.4 | ~$10/M | ~$30/M | Moderate |
|
||||||
|
| Claude Opus 4.6 | ~$15/M | ~$75/M | Expensive |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Detailed Feedback Files
|
||||||
|
|
||||||
|
### Local LLM Feedback
|
||||||
|
**File:** `opencode/feedback/localllm/local-llm-feedback.md`
|
||||||
|
|
||||||
|
**Contents:**
|
||||||
|
- Qwen3.5-35B-A3B (MoE) - Detailed performance data
|
||||||
|
- Gemma 4 26B-A4B - M-series Mac optimization
|
||||||
|
- GLM-4.7 Flash - API performance
|
||||||
|
- GLM-5.1 - 8-hour autonomous capability
|
||||||
|
- Nemotron 3 Super - Agentic reasoning
|
||||||
|
- Context management issues
|
||||||
|
- Skills system effectiveness
|
||||||
|
- General recommendations
|
||||||
|
|
||||||
|
### Frontier Model Feedback
|
||||||
|
**File:** `opencode/feedback/frontier/frontier-model-feedback.md`
|
||||||
|
|
||||||
|
**Contents:**
|
||||||
|
- GPT-5.4 - Terminal-Bench performance
|
||||||
|
- Claude Opus 4.6 - Long-horizon tasks
|
||||||
|
- Gemini 3.0 Pro - Context handling
|
||||||
|
- GLM-5.1 - SWE-Bench Pro #1
|
||||||
|
- OpenRouter models - Grok Fast, Step 3.5 Flash
|
||||||
|
- Benchmark comparisons
|
||||||
|
- Long-horizon optimization
|
||||||
|
- Cost considerations
|
||||||
|
|
||||||
|
### Tool Handling Feedback
|
||||||
|
**File:** `opencode/feedback/localllm/tool-handling-feedback.md`
|
||||||
|
|
||||||
|
**Contents:**
|
||||||
|
- Tool calling reliability by model
|
||||||
|
- Skill system effectiveness
|
||||||
|
- Agent behavior (Plan vs. Build modes)
|
||||||
|
- Multi-agent workflows
|
||||||
|
- Model per-task assignment
|
||||||
|
- Performance metrics
|
||||||
|
- Tool call examples
|
||||||
|
|
||||||
|
### Prompt Engineering Feedback
|
||||||
|
**File:** `opencode/feedback/localllm/prompt-engineering-feedback.md`
|
||||||
|
|
||||||
|
**Contents:**
|
||||||
|
- Model-specific prompt strategies
|
||||||
|
- Temperature settings by model
|
||||||
|
- Context window optimization
|
||||||
|
- Compaction threshold issues
|
||||||
|
- Best practices
|
||||||
|
- Mode-specific prompts
|
||||||
|
- Custom mode examples
|
||||||
|
- Context management strategies
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Common Pitfalls & Solutions
|
||||||
|
|
||||||
|
### 1. Context Too Small
|
||||||
|
**Problem:** Default 4K context causes truncation
|
||||||
|
**Solution:** Increase to 32K+ via configuration
|
||||||
|
|
||||||
|
### 2. Wrong Chat Template
|
||||||
|
**Problem:** Qwen default template breaks tool calling
|
||||||
|
**Solution:** Use corrected Jinja template with `--jinja` flag
|
||||||
|
|
||||||
|
### 3. Model Unloading
|
||||||
|
**Problem:** Ollama unloads models after 5 minutes idle
|
||||||
|
**Solution:** Set `OLLAMA_KEEP_ALIVE="-1"`
|
||||||
|
|
||||||
|
### 4. Hardcoded Compaction
|
||||||
|
**Problem:** 75% threshold causes quality degradation
|
||||||
|
**Solution:** Request configurable threshold (GitHub Issue #11314)
|
||||||
|
|
||||||
|
### 5. Permission Issues
|
||||||
|
**Problem:** Skills with `deny` permission hidden from agents
|
||||||
|
**Solution:** Check permission configuration
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Hybrid Setup Strategy
|
||||||
|
|
||||||
|
### Local Models
|
||||||
|
- **Use for:** Lightweight tasks, repetitive work, privacy-sensitive code
|
||||||
|
- **Examples:** Gemma 4 8B, Qwen3.5-35B-A3B
|
||||||
|
|
||||||
|
### Frontier Models
|
||||||
|
- **Use for:** Complex reasoning, multi-file refactors, deep analysis
|
||||||
|
- **Examples:** GLM-5.1, GPT-5.4, Claude Opus 4.6
|
||||||
|
|
||||||
|
### Switching Models
|
||||||
|
```bash
|
||||||
|
# List available models
|
||||||
|
/models
|
||||||
|
|
||||||
|
# Select model for current session
|
||||||
|
# Model selection happens interactively
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Data Sources
|
||||||
|
|
||||||
|
### Reddit Threads (8 sources)
|
||||||
|
- r/opencodeCLI: Model comparisons, user experiences
|
||||||
|
- r/LocalLLaMA: Self-hosted LLM discussions
|
||||||
|
- Topics: Tool calling, performance, configuration
|
||||||
|
|
||||||
|
### GitHub Issues (6 sources)
|
||||||
|
- opencode-ai/opencode: Configuration problems, bugs
|
||||||
|
- anomalyco/opencode: Fork-specific issues
|
||||||
|
- Topics: Context limits, compaction, Ollama integration
|
||||||
|
|
||||||
|
### Benchmark Dashboards (3 sources)
|
||||||
|
- grigio.org: OpenCode benchmark dashboard
|
||||||
|
- vals.ai: Terminal-Bench 2.0 leaderboard
|
||||||
|
- llm-stats.com: Terminal-Bench leaderboard
|
||||||
|
|
||||||
|
### Blog Posts (10 sources)
|
||||||
|
- Aayush Garg: Local LLM setup guide
|
||||||
|
- haimaker.ai: Gemma 4 + OpenCode setup
|
||||||
|
- The AIOps: Docker Model Runner integration
|
||||||
|
- Medium: Context limits fixing
|
||||||
|
- Topics: Setup guides, optimization tips
|
||||||
|
|
||||||
|
### Technical Blogs (5 sources)
|
||||||
|
- NVIDIA: Nemotron 3 Super architecture
|
||||||
|
- Apidog: GLM-5.1 full review
|
||||||
|
- Build Fast with AI: GLM-5.1 analysis
|
||||||
|
- Topics: Architecture, benchmark analysis
|
||||||
|
|
||||||
|
### Documentation (8 sources)
|
||||||
|
- opencode.ai/docs: Official documentation
|
||||||
|
- Mintlify: Self-hosted models guide
|
||||||
|
- Educative: Model configuration course
|
||||||
|
- Topics: Configuration, best practices
|
||||||
|
|
||||||
|
### Additional Sources (10+ sources)
|
||||||
|
- OpenRouter: Model pricing and availability
|
||||||
|
- HuggingFace: Model weights and downloads
|
||||||
|
- Z.AI Developer Docs: GLM model specifications
|
||||||
|
- Terminal-Bench: Benchmark methodology
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Recommendations
|
||||||
|
|
||||||
|
### For Local Development
|
||||||
|
1. **Qwen3.5-35B-A3B** - Best overall local model
|
||||||
|
2. **Gemma 4 26B-A4B** - Best for M-series Mac
|
||||||
|
3. **Increase context to 32K+**
|
||||||
|
4. **Use corrected chat templates**
|
||||||
|
5. **Set OLLAMA_KEEP_ALIVE="-1"**
|
||||||
|
|
||||||
|
### For Cloud/Remote
|
||||||
|
1. **GLM-5.1** - Best value, SWE-Bench Pro #1
|
||||||
|
2. **GPT-5.4** - Best Terminal-Bench performance
|
||||||
|
3. **Claude Opus 4.6** - Best for long-horizon tasks
|
||||||
|
4. **Hybrid setup** - Local for quick tasks, cloud for complex
|
||||||
|
|
||||||
|
### For Enterprise
|
||||||
|
1. **GLM-5.1** - MIT license, commercial use allowed
|
||||||
|
2. **Nemotron 3 Super** - Best for agentic reasoning
|
||||||
|
3. **8-hour autonomous execution**
|
||||||
|
4. **1,700+ autonomous steps**
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Future Research Directions
|
||||||
|
|
||||||
|
### Areas Needing More Data
|
||||||
|
1. **GLM-5.1 local deployment** - Hardware requirements unclear
|
||||||
|
2. **Nemotron 3 Super** - Limited local deployment data
|
||||||
|
3. **Multi-agent workflows** - Model per-role optimization
|
||||||
|
4. **Context compaction** - Configurable threshold implementation
|
||||||
|
5. **Skill system** - Effectiveness across different models
|
||||||
|
|
||||||
|
### Open Questions
|
||||||
|
1. Can GLM-5.1 be run locally on consumer hardware?
|
||||||
|
2. What are the optimal model configurations for multi-agent setups?
|
||||||
|
3. How does context compaction affect long-running sessions?
|
||||||
|
4. What prompt strategies work best for different model types?
|
||||||
|
5. Can local models match frontier model performance on complex tasks?
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Conclusion
|
||||||
|
|
||||||
|
The OpenCode ecosystem has matured significantly with strong support for both local and frontier models. Key findings:
|
||||||
|
|
||||||
|
1. **Local models are viable** for most coding tasks with proper configuration
|
||||||
|
2. **Qwen3.5-35B-A3B** is the best local model overall
|
||||||
|
3. **GLM-5.1** is the best frontier model (SWE-Bench Pro #1)
|
||||||
|
4. **Context management** is critical for long-running sessions
|
||||||
|
5. **Hybrid setups** offer the best of both worlds
|
||||||
|
|
||||||
|
The feedback compiled here provides a comprehensive foundation for selecting and configuring models for OpenCode, with detailed guidance on performance, cost, and best practices.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Last Updated:** April 2026
|
||||||
|
**Total Feedback Files:** 4
|
||||||
|
**Total Sources:** 50+
|
||||||
|
**Coverage:** Local LLMs, Frontier Models, Tools, Prompts, Context
|
||||||
@@ -0,0 +1,390 @@
|
|||||||
|
# Frontier Model Feedback for OpenCode
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
This document compiles community feedback, benchmark results, and performance observations for **frontier (cloud) models** used with OpenCode. Data sourced from Reddit, GitHub issues, benchmark dashboards, and community blogs.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## GPT Models
|
||||||
|
|
||||||
|
### GPT-5.4
|
||||||
|
**Model:** GPT-5.4
|
||||||
|
**Provider:** OpenAI
|
||||||
|
**Context:** 1M tokens
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **Terminal-Bench 2.0:** 75.1 (Highest among tested models)
|
||||||
|
- **SWE-Bench Pro:** 57.7 (Rank #2 overall)
|
||||||
|
- **Reasoning:** Strong on AIME 2025, HMMT, GPQA-Diamond
|
||||||
|
- **Context:** Compaction triggers at 272k (sometimes earlier), never reaches full 1M
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Best Terminal-Bench 2.0 performance
|
||||||
|
- Strong reasoning capabilities
|
||||||
|
- Excellent tool calling
|
||||||
|
- Good for complex multi-step tasks
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Compaction triggers too early (272k vs advertised 1M)
|
||||||
|
- Context never approaches full 1M tokens
|
||||||
|
- Expensive for long-running sessions
|
||||||
|
- Some users report quality degradation before compaction
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #16308: 1M context compaction issue](https://github.com/anomalyco/opencode/issues/16308)
|
||||||
|
- [Terminal-Bench 2.0 Leaderboard](https://www.vals.ai/benchmarks/terminal-bench-2)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### GPT-5.2
|
||||||
|
**Model:** GPT-5.2
|
||||||
|
**Provider:** OpenAI
|
||||||
|
**Status:** Recommended by OpenCode
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Listed as recommended model in OpenCode docs
|
||||||
|
- Good balance of speed and accuracy
|
||||||
|
- Reliable tool calling
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Models](https://opencode.ai/docs/models/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### GPT OSS 20B
|
||||||
|
**Model:** GPT OSS 20B
|
||||||
|
**Provider:** Docker Model Runner (local), OpenRouter (cloud)
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **Accuracy:** Very accurate on coding tasks
|
||||||
|
- **Speed:** Acceptable for local deployment
|
||||||
|
- **Context:** Requires manual increase from 4K default
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Good local alternative to cloud models
|
||||||
|
- Works with Docker Model Runner
|
||||||
|
- Acceptable performance for development tasks
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [grigio.org Benchmark Dashboard](https://grigio.org/opencode-benchmark-dashboard-find-the-best-local-llm-for-your-computer/)
|
||||||
|
- [The AIOps: Local Models Setup](https://theaiops.substack.com/p/setting-up-opencode-with-local-models)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Claude Models
|
||||||
|
|
||||||
|
### Claude Opus 4.6
|
||||||
|
**Model:** Claude Opus 4.6
|
||||||
|
**Provider:** Anthropic
|
||||||
|
**Context:** 200K tokens
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **SWE-Bench Pro:** 57.3 (Rank #3 overall)
|
||||||
|
- **CyberGym:** 66.6
|
||||||
|
- **NL2Repo:** 49.8 (Higher than GLM-5.1)
|
||||||
|
- **GPU Kernel Optimization:** 4.2x speedup (led GLM-5.1)
|
||||||
|
- **BrowseComp:** 84.0
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Strong on long-horizon optimization
|
||||||
|
- Excellent code quality
|
||||||
|
- Good for complex refactoring
|
||||||
|
- Reliable tool calling
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Expensive for extended sessions
|
||||||
|
- Context degradation at ~50% of window
|
||||||
|
- Slower than some alternatives
|
||||||
|
- Higher cost per token
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
- [Build Fast with AI: GLM-5.1 Review](https://www.buildfastwithai.com/blogs/glm-5-1-open-source-review-2026)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Claude Sonnet 4.5
|
||||||
|
**Model:** Claude Sonnet 4.5
|
||||||
|
**Provider:** Anthropic
|
||||||
|
**Status:** Recommended by OpenCode
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Listed as recommended model
|
||||||
|
- Good balance of speed and quality
|
||||||
|
- Reliable for most coding tasks
|
||||||
|
- Lower cost than Opus
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Models](https://opencode.ai/docs/models/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Gemini Models
|
||||||
|
|
||||||
|
### Gemini 3.0 Pro
|
||||||
|
**Model:** Gemini 3.0 Pro
|
||||||
|
**Provider:** Google
|
||||||
|
**Context:** 1M+ tokens
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **SWE-Bench Pro:** 54.2
|
||||||
|
- **Terminal-Bench 2.0:** 68.5
|
||||||
|
- **BrowseComp:** 85.9 (High)
|
||||||
|
- **MCP-Atlas:** 69.2
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Excellent context handling
|
||||||
|
- Strong on BrowseComp tasks
|
||||||
|
- Good for long document analysis
|
||||||
|
- Fast prompt processing
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Context degradation starts at ~30% (300k tokens)
|
||||||
|
- 2-3x slower responses near compaction point
|
||||||
|
- Hallucinations before compaction triggers
|
||||||
|
- Quality drops significantly before 75% threshold
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #11314: Context Compaction](https://github.com/anomalyco/opencode/issues/11314)
|
||||||
|
- [OpenCode Zen](https://opencode.ai/docs/zen/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Gemini 3 Pro
|
||||||
|
**Model:** Gemini 3 Pro
|
||||||
|
**Provider:** Google
|
||||||
|
**Status:** Recommended by OpenCode
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Listed as recommended model
|
||||||
|
- Good general-purpose performance
|
||||||
|
- Reliable tool calling
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Models](https://opencode.ai/docs/models/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Minimax Models
|
||||||
|
|
||||||
|
### Minimax M2.1
|
||||||
|
**Model:** Minimax M2.1
|
||||||
|
**Provider:** Minimax
|
||||||
|
**Status:** Recommended by OpenCode
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Listed as recommended model
|
||||||
|
- Good for coding tasks
|
||||||
|
- Competitive with other frontier models
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Models](https://opencode.ai/docs/models/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## GLM Models (Frontier)
|
||||||
|
|
||||||
|
### GLM-5.1
|
||||||
|
**Model:** GLM-5.1
|
||||||
|
**Size:** 754B total / 40B active (MoE)
|
||||||
|
**Provider:** Z.AI API, BigModel, OpenRouter
|
||||||
|
**License:** MIT (Open Weights)
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **SWE-Bench Pro:** 58.4 (Rank #1 open source, #3 overall)
|
||||||
|
- **Terminal-Bench 2.0:** 69.0
|
||||||
|
- **CyberGym:** 68.7 (1,507 real tasks)
|
||||||
|
- **MCP-Atlas:** 71.8 (Rank #1)
|
||||||
|
- **Autonomous Duration:** 8 hours continuous
|
||||||
|
- **Steps:** Up to 1,700 autonomous steps
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- #1 on SWE-Bench Pro among open models
|
||||||
|
- 8-hour autonomous coding capability
|
||||||
|
- MIT license (commercial use allowed)
|
||||||
|
- Works with OpenCode, Claude Code, Kilo Code, Roo Code
|
||||||
|
- Trained on Huawei Ascend 910B (no Nvidia dependency)
|
||||||
|
- 3-7 points better than GLM-5 on benchmarks
|
||||||
|
|
||||||
|
**Pricing:**
|
||||||
|
- **API:** $1.40/M input, $4.40/M output
|
||||||
|
- **Peak Hours:** 3x rate (14:00-18:00 Beijing)
|
||||||
|
- **Off-Peak:** 2x rate (1x through April 2026 promo)
|
||||||
|
- **GLM Coding Plan:** $10/month subscription
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
- [Build Fast with AI: GLM-5.1 Review](https://www.buildfastwithai.com/blogs/glm-5-1-open-source-review-2026)
|
||||||
|
- [Z.AI Developer Docs](https://docs.z.ai/guides/llm/glm-5)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## OpenRouter Models
|
||||||
|
|
||||||
|
### Grok Fast
|
||||||
|
**Model:** Grok Fast
|
||||||
|
**Provider:** OpenRouter
|
||||||
|
**Status:** Free model
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Fast code generation
|
||||||
|
- Great for large refactoring
|
||||||
|
- Good with test coverage
|
||||||
|
- Free tier available
|
||||||
|
|
||||||
|
**Limitations:**
|
||||||
|
- Not the smartest model
|
||||||
|
- Best for simple tasks
|
||||||
|
- Requires good test coverage
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: Opencode benchmarks](https://www.reddit.com/r/opencodeCLI/comments/1perov3/opencode_benchmarks_which_agentic_llm_models_work/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Step 3.5 Flash
|
||||||
|
**Model:** Step 3.5 Flash
|
||||||
|
**Provider:** OpenRouter
|
||||||
|
**Status:** Top performer
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Top performer in accuracy and speed
|
||||||
|
- Good balance of cost and quality
|
||||||
|
- Reliable for most tasks
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [grigio.org Benchmark Dashboard](https://grigio.org/opencode-benchmark-benchmark-dashboard-find-the-best-local-llm-for-your-computer/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## OpenCode Zen Models
|
||||||
|
|
||||||
|
OpenCode Zen is a curated list of models tested and verified by the OpenCode team.
|
||||||
|
|
||||||
|
**Zen Models Include:**
|
||||||
|
- GLM-4.6 (works great with dedicated API)
|
||||||
|
- DeepSeek 3.2 (works great with dedicated API)
|
||||||
|
- Various free and paid options
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Curated selection of reliable models
|
||||||
|
- Dedicated APIs perform better than OpenRouter
|
||||||
|
- Good for users who want pre-verified options
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: Opencode benchmarks](https://www.reddit.com/r/opencodeCLI/comments/1perov3/opencode_benchmarks_which_agentic_llm_models_work/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Benchmark Comparisons
|
||||||
|
|
||||||
|
### SWE-Bench Pro Rankings
|
||||||
|
| Model | Score | Rank |
|
||||||
|
|-------|-------|------|
|
||||||
|
| GLM-5.1 | 58.4 | #1 (Open) |
|
||||||
|
| GPT-5.4 | 57.7 | #2 |
|
||||||
|
| Claude Opus 4.6 | 57.3 | #3 |
|
||||||
|
| GLM-5 | 55.1 | #4 |
|
||||||
|
| Gemini 3.1 Pro | 54.2 | #5 |
|
||||||
|
|
||||||
|
### Terminal-Bench 2.0 Rankings
|
||||||
|
| Model | Score |
|
||||||
|
|-------|-------|
|
||||||
|
| GPT-5.4 | 75.1 |
|
||||||
|
| GLM-5.1 | 69.0 |
|
||||||
|
| Gemini 3.1 Pro | 68.5 |
|
||||||
|
| Claude Opus 4.6 | 65.4 |
|
||||||
|
|
||||||
|
### CyberGym Rankings (1,507 real tasks)
|
||||||
|
| Model | Score |
|
||||||
|
|-------|-------|
|
||||||
|
| GLM-5.1 | 68.7 |
|
||||||
|
| Claude Opus 4.6 | 66.6 |
|
||||||
|
| GLM-5 | ~49 |
|
||||||
|
|
||||||
|
### MCP-Atlas Rankings
|
||||||
|
| Model | Score |
|
||||||
|
|-------|-------|
|
||||||
|
| GLM-5.1 | 71.8 |
|
||||||
|
| Claude Opus 4.6 | 73.8 |
|
||||||
|
| GPT-5.4 | 67.2 |
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
- [Build Fast with AI: GLM-5.1 Review](https://www.buildfastwithai.com/blogs/glm-5-1-open-source-review-2026)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Long-Horizon Optimization
|
||||||
|
|
||||||
|
### GLM-5.1 8-Hour Autonomous Test
|
||||||
|
**Task:** Build full Linux desktop environment from scratch
|
||||||
|
|
||||||
|
**Results:**
|
||||||
|
- **Iterations:** 655 autonomous iterations
|
||||||
|
- **Optimization:** 6.9x throughput increase
|
||||||
|
- **Duration:** 8 hours continuous execution
|
||||||
|
- **Steps:** 1,700 autonomous steps
|
||||||
|
|
||||||
|
**Comparison:**
|
||||||
|
- **GLM-5:** Plateaued at 8,000-10,000 QPS
|
||||||
|
- **GLM-5.1:** Reached 21,500 QPS (6,000+ tool calls)
|
||||||
|
- **Claude Opus 4.6:** 3,547 QPS (single session)
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Build Fast with AI: GLM-5.1 Review](https://www.buildfastwithai.com/blogs/glm-5-1-open-source-review-2026)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Context Management
|
||||||
|
|
||||||
|
### Compaction Threshold Issues
|
||||||
|
**Problem:** Hardcoded 75% threshold causes quality degradation
|
||||||
|
|
||||||
|
**Model-Specific Degradation:**
|
||||||
|
| Model | Degradation Start | Compaction Trigger | Result |
|
||||||
|
|-------|------------------|-------------------|--------|
|
||||||
|
| Gemini | ~30% (300k) | 75% (786k) | 2-3x slower, hallucinations |
|
||||||
|
| Claude | ~50% | 75% | Significant quality drops |
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #11314: Configurable Context Compaction](https://github.com/anomalyco/opencode/issues/11314)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## General Recommendations
|
||||||
|
|
||||||
|
### Best Frontier Models for OpenCode (Ranked)
|
||||||
|
|
||||||
|
1. **GLM-5.1** - Best overall (SWE-Bench Pro #1, MIT license)
|
||||||
|
2. **GPT-5.4** - Best Terminal-Bench performance
|
||||||
|
3. **Claude Opus 4.6** - Best for long-horizon tasks
|
||||||
|
4. **Gemini 3.0 Pro** - Best context handling
|
||||||
|
5. **GPT-5.2** - Best recommended default
|
||||||
|
|
||||||
|
### Hybrid Setup Strategy
|
||||||
|
- **Frontier models:** Complex reasoning, multi-file refactors, deep analysis
|
||||||
|
- **Local models:** Quick tasks, repetitive work, privacy-sensitive
|
||||||
|
- Switch between models using `/models` command
|
||||||
|
|
||||||
|
### Cost Considerations
|
||||||
|
- **GLM-5.1:** $1.40/M input, $4.40/M output (cheapest frontier)
|
||||||
|
- **GPT-5.4:** ~$10/M input, ~$30/M output (expensive)
|
||||||
|
- **Claude Opus 4.6:** ~$15/M input, ~$75/M output (most expensive)
|
||||||
|
- **OpenRouter:** Aggregates multiple providers, often cheaper
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Data Sources Summary
|
||||||
|
|
||||||
|
| Source Type | Count | Topics Covered |
|
||||||
|
|-------------|-------|----------------|
|
||||||
|
| Reddit Threads | 3 | Model comparisons, user experiences |
|
||||||
|
| GitHub Issues | 2 | Configuration problems, bugs |
|
||||||
|
| Benchmark Dashboards | 2 | Performance metrics, comparisons |
|
||||||
|
| Blog Posts | 4 | Setup guides, optimization tips |
|
||||||
|
| Technical Blogs | 3 | Architecture, benchmark analysis |
|
||||||
|
| Documentation | 2 | Official docs, configuration |
|
||||||
|
|
||||||
|
**Total Sources:** 14 unique sources
|
||||||
|
**Date Range:** April 2025 - April 2026
|
||||||
@@ -0,0 +1,346 @@
|
|||||||
|
# Local LLM Feedback for OpenCode
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
This document compiles community feedback, benchmark results, and performance observations for **local LLM models** used with OpenCode. Data sourced from Reddit, GitHub issues, benchmark dashboards, and community blogs.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Qwen Models
|
||||||
|
|
||||||
|
### Qwen3.5-35B-A3B (MoE)
|
||||||
|
**Model:** Qwen3.5-35B-A3B
|
||||||
|
**Size:** 35B total / 3B active parameters
|
||||||
|
**Quantization:** Q4_K_M, Q8_0, UD-Q4_K_XL
|
||||||
|
**Provider:** llama.cpp / Ollama / HuggingFace
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **Terminal-Bench:** Most accurate & fast among local models
|
||||||
|
- **Performance:** 3-5x faster than dense 27B variants (~60-100 tok/s)
|
||||||
|
- **Context:** Supports up to 262k context with `--n-cpu-moe 10` (24GB VRAM)
|
||||||
|
- **Accuracy:** Excellent on coding tasks, comparable to cloud models
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Long context handling (262k tested)
|
||||||
|
- Fast inference due to MoE architecture
|
||||||
|
- Good tool calling with corrected chat templates
|
||||||
|
- Works well with OpenCode's skill system
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Default chat template breaks tool-calling in OpenCode
|
||||||
|
- Requires custom Jinja template for proper system message ordering
|
||||||
|
- Performance degrades with very large contexts (KV-cache heavy)
|
||||||
|
- Needs `--cache-type-k bf16 --cache-type-v bf16` for optimal performance
|
||||||
|
|
||||||
|
**Configuration Tips:**
|
||||||
|
```bash
|
||||||
|
# llama-server flags for OpenCode
|
||||||
|
--ctx-size 65536
|
||||||
|
--parallel 1
|
||||||
|
--batch-size 2048
|
||||||
|
--ubatch-size 512
|
||||||
|
--jinja
|
||||||
|
--chat-template-file qwen35-chat-template-corrected.jinja
|
||||||
|
--context-shift
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: Local LLM models with opencode](https://www.reddit.com/r/opencodeCLI/comments/1rpr2e6/what_local_llm_models_are_you_using_with_opencode/)
|
||||||
|
- [GitHub: llama.cpp discussion #14758](https://github.com/ggml-org/llama.cpp/discussions/14758)
|
||||||
|
- [Aayush Garg Blog: Local LLM with OpenCode](https://aayushgarg.dev/posts/2026-03-29-local-llm-opencode/)
|
||||||
|
- [grigio.org Benchmark Dashboard](https://grigio.org/opencode-benchmark-dashboard-find-the-best-local-llm-for-your-computer/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Qwen2.5-Coder
|
||||||
|
**Model:** Qwen2.5-Coder
|
||||||
|
**Size:** Various (7B, 14B, 32B variants)
|
||||||
|
**Provider:** Ollama, llama.cpp
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Configuration failure with Ollama provider in OpenCode
|
||||||
|
- Issue #342: `ollama/qwen2.5-coder` configuration fails silently
|
||||||
|
- Requires `@ai-sdk/openai-compatible` npm package
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #342: does not work with local models](https://github.com/opencode-ai/opencode/issues/342)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Qwen3-Coder:30B
|
||||||
|
**Model:** Qwen3-Coder:30B
|
||||||
|
**Provider:** Ollama
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Issue #17619: Opencode hangs showing `>build · qwen3-coder:30b` but doesn't progress
|
||||||
|
- Direct Ollama run works fine (`ollama run qwen3-coder:30b "Hola"`)
|
||||||
|
- Configuration appears correct but integration fails
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #17619: Opencode hangs with Ollama models](https://github.com/anomalyco/opencode/issues/17619)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Gemma Models
|
||||||
|
|
||||||
|
### Gemma 4 26B-A4B
|
||||||
|
**Model:** Gemma 4 26B-A4B
|
||||||
|
**Size:** 26B parameters
|
||||||
|
**Quantization:** UD-IQ4_XS, e4b
|
||||||
|
**Provider:** Ollama, llama.cpp
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **Performance:** 300 tok/s prompt processing, 12 tok/s generation on M5 MacBook
|
||||||
|
- **Power:** 8W usage, runs cool on laptop (M5 Air tested)
|
||||||
|
- **Accuracy:** Very good results on coding tasks
|
||||||
|
- **Context:** Default 4K, requires manual increase to 32K
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Excellent on M-series Mac (Apple Silicon optimized)
|
||||||
|
- Fast prompt processing
|
||||||
|
- Short thinking traces work well for agentic behavior
|
||||||
|
- First laptop LLM that doesn't get warm/noisy
|
||||||
|
- Usable for real-world coding tasks
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Default 4K context window causes truncation
|
||||||
|
- Requires manual context increase via `/set parameter num_ctx 32768`
|
||||||
|
- Needs `/save` to persist context changes
|
||||||
|
- Requires more specific guidance than other models
|
||||||
|
|
||||||
|
**Configuration Tips:**
|
||||||
|
```bash
|
||||||
|
# Ollama context increase
|
||||||
|
ollama run gemma4:e4b
|
||||||
|
/set parameter num_ctx 32768
|
||||||
|
/save gemma4:e4b-32k
|
||||||
|
/bye
|
||||||
|
|
||||||
|
# OpenCode config
|
||||||
|
{
|
||||||
|
"gemma4:e4b-32k": {
|
||||||
|
"name": "Gemma 4 (32k)",
|
||||||
|
"_launch": true,
|
||||||
|
"tool_call": true,
|
||||||
|
"maxTokens": 16384,
|
||||||
|
"options": { "temperature": 0.1 }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: Gemma 4 26B-A4B + Opencode on M5](https://www.reddit.com/r/LocalLLaMA/comments/1sbaack/gemma4_26ba4b_opencode_on_m5_macbook_is_actually/)
|
||||||
|
- [DEV.to: Running Gemma 4 with Ollama and OpenCode](https://dev.to/grovertek/running-gemma-4-locally-with-ollama-and-opencode-2h6)
|
||||||
|
- [haimaker.ai: Gemma 4 + OpenCode Setup](https://haimaker.ai/blog/gemma-4-ollama-opencode-setup/)
|
||||||
|
- [Reddit: Tested opencode with self-hosted LLMs](https://www.reddit.com/r/LocalLLaMA/comments/1sduazd/tested_how_opencode_works_with_selfhosted_llms/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Gemma 4 8B
|
||||||
|
**Model:** Gemma 4 8B
|
||||||
|
**Size:** 8B parameters
|
||||||
|
**RAM Usage:** ~9.6GB loaded
|
||||||
|
**Provider:** Ollama
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Runs comfortably on 16GB RAM systems
|
||||||
|
- Good for quick edits, code explanations, boilerplate
|
||||||
|
- Fast inference on consumer hardware
|
||||||
|
- Works well for single-file modifications
|
||||||
|
|
||||||
|
**Limitations:**
|
||||||
|
- Struggles with multi-step reasoning
|
||||||
|
- Loses coherence across multiple files
|
||||||
|
- Misses subtle edge cases
|
||||||
|
- Best for: typos, imports, type definitions, variable renames
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [haimaker.ai: Gemma 4 Setup Guide](https://haimaker.ai/blog/gemma-4-ollama-opencode-setup/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## GLM Models
|
||||||
|
|
||||||
|
### GLM-4.7 Flash
|
||||||
|
**Model:** GLM-4.7 Flash
|
||||||
|
**Provider:** Z.AI API, OpenRouter
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **Tool Using:** Significantly better on τ²-Bench and BrowseComp
|
||||||
|
- **Performance:** Comparable to Sonnet, slower but cheaper
|
||||||
|
- **Cost:** Very cheap via Z.AI API, referral links available
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Great for large refactoring tasks
|
||||||
|
- Works well with dedicated APIs (not OpenRouter)
|
||||||
|
- Cheap alternative to cloud models
|
||||||
|
- Good test coverage compatibility
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: Opencode benchmarks discussion](https://www.reddit.com/r/opencodeCLI/comments/1perov3/opencode_benchmarks_which_agentic_llm_models_work/)
|
||||||
|
- [Z.AI Developer Docs: GLM-5](https://docs.z.ai/guides/llm/glm-5)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### GLM-5.1
|
||||||
|
**Model:** GLM-5.1
|
||||||
|
**Size:** 754B total / 40B active (MoE)
|
||||||
|
**Context:** 200,000 tokens
|
||||||
|
**License:** MIT (Open Weights)
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **SWE-Bench Pro:** 58.4 (Rank #1 open source)
|
||||||
|
- **Terminal-Bench 2.0:** 69.0
|
||||||
|
- **CyberGym:** 68.7 (1,507 real tasks)
|
||||||
|
- **MCP-Atlas:** 71.8
|
||||||
|
- **Autonomous Duration:** 8 hours continuous execution
|
||||||
|
- **Steps:** Up to 1,700 autonomous steps
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Best open-source model on SWE-Bench Pro
|
||||||
|
- 8-hour autonomous coding capability
|
||||||
|
- MIT license allows commercial use
|
||||||
|
- Works with Claude Code, OpenCode, Kilo Code, Roo Code
|
||||||
|
- Trained on Huawei Ascend 910B (no Nvidia dependency)
|
||||||
|
|
||||||
|
**Local Deployment:**
|
||||||
|
- Requires enterprise GPU cluster (8x H100 minimum)
|
||||||
|
- FP8 quantization reduces memory by ~50%
|
||||||
|
- Supported by vLLM and SGLang
|
||||||
|
- API price: $1.40/M input, $4.40/M output
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
- [Build Fast with AI: GLM-5.1 Full Review](https://www.buildfastwithai.com/blogs/glm-5-1-open-source-review-2026)
|
||||||
|
- [Z.AI Developer Docs](https://docs.z.ai/guides/llm/glm-5)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Nemotron Models
|
||||||
|
|
||||||
|
### Nemotron 3 Super
|
||||||
|
**Model:** Nemotron 3 Super
|
||||||
|
**Size:** 120B total / 12B active (MoE)
|
||||||
|
**Context:** 1M tokens
|
||||||
|
**Provider:** NVIDIA NIM, HuggingFace
|
||||||
|
|
||||||
|
**Benchmark Results:**
|
||||||
|
- **PinchBench:** 85.6% (Best open model in class)
|
||||||
|
- **AIME 2025:** Strong performance
|
||||||
|
- **TerminalBench:** Leading results
|
||||||
|
- **SWE-Bench Verified:** Strong performance
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Hybrid Mamba-Transformer architecture
|
||||||
|
- Multi-token prediction (3x speedup for code)
|
||||||
|
- Native NVFP4 precision (4x faster on B200)
|
||||||
|
- Optimized for agentic reasoning
|
||||||
|
- 1M context window
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [NVIDIA Blog: Nemotron 3 Super](https://developer.nvidia.com/blog/introducing-nemotron-3-super-an-open-hybrid-mamba-transformer-moe-for-agentic-reasoning/)
|
||||||
|
- [OpenRouter: Nemotron 3 Super Free](https://openrouter.ai/nvidia/nemotron-3-super-120b-a12b:free)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Context Management Issues
|
||||||
|
|
||||||
|
### Compaction Threshold Problem
|
||||||
|
**Issue:** Context compaction triggers at hardcoded 75% threshold
|
||||||
|
**Impact:** Models begin losing coherence well before compaction
|
||||||
|
|
||||||
|
**Model-Specific Degradation:**
|
||||||
|
| Model | Degradation Start | Compaction Trigger | Result |
|
||||||
|
|-------|------------------|-------------------|--------|
|
||||||
|
| Gemini | ~30% (300k) | 75% (786k) | 2-3x slower, hallucinations |
|
||||||
|
| Claude | ~50% | 75% | Significant quality drops |
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #11314: Configurable Context Compaction](https://github.com/anomalyco/opencode/issues/11314)
|
||||||
|
- [Medium: Fixing Context Limits](https://stouf.medium.com/fixing-context-limits-in-opencode-ollama-1d820b332b41)
|
||||||
|
|
||||||
|
### Context Window Configuration
|
||||||
|
**Default:** Ollama/Docker Model Runner uses 4096 tokens
|
||||||
|
**Recommended:** Increase to 32K or higher for coding tasks
|
||||||
|
|
||||||
|
**Fix:**
|
||||||
|
```bash
|
||||||
|
docker model configure --context-size=100000 gpt-oss:20B-UD-Q8_K_XL
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [The AIOps: Setting Up OpenCode with Local Models](https://theaiops.substack.com/p/setting-up-opencode-with-local-models)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Skills System Effectiveness
|
||||||
|
|
||||||
|
### How Skills Work
|
||||||
|
- Skills are discovered from `.opencode/skills/`, `~/.config/opencode/skills/`, etc.
|
||||||
|
- Each skill requires `SKILL.md` with YAML frontmatter
|
||||||
|
- Agent sees available skills via `skill` tool description
|
||||||
|
- Skills loaded on-demand when agent identifies matching task
|
||||||
|
|
||||||
|
### Configuration Options
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"permission": {
|
||||||
|
"skill": {
|
||||||
|
"*": "allow",
|
||||||
|
"pr-review": "allow",
|
||||||
|
"internal-*": "deny",
|
||||||
|
"experimental-*": "ask"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Best Practices
|
||||||
|
- Keep descriptions specific (1-1024 chars)
|
||||||
|
- Use pattern-based permissions for control
|
||||||
|
- Disable skill tool for agents that shouldn't use it
|
||||||
|
- Project-local skills override global defaults
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Agent Skills](https://opencode.ai/docs/skills/)
|
||||||
|
- [GitHub: opencode-skillful](https://github.com/zenobi-us/opencode-skillful)
|
||||||
|
- [Reddit: Skills in opencode](https://www.reddit.com/r/opencodeCLI/comments/1q5te73/skills_in_opencode/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## General Recommendations
|
||||||
|
|
||||||
|
### Best Local Models for OpenCode (Ranked)
|
||||||
|
|
||||||
|
1. **Qwen3.5-35B-A3B** - Best overall balance of speed, accuracy, context
|
||||||
|
2. **Gemma 4 26B-A4B** - Best for M-series Mac, very efficient
|
||||||
|
3. **GLM-5.1** - Best for long-horizon tasks (if hardware allows)
|
||||||
|
4. **Nemotron 3 Super** - Best for agentic reasoning (enterprise hardware)
|
||||||
|
5. **Gemma 4 8B** - Best for quick tasks on modest hardware
|
||||||
|
|
||||||
|
### Hybrid Setup Strategy
|
||||||
|
- **Local models:** Lightweight tasks, repetitive work, privacy-sensitive
|
||||||
|
- **Cloud models:** Complex reasoning, multi-file refactors, deep analysis
|
||||||
|
- Switch between models using `/models` command
|
||||||
|
|
||||||
|
### Common Pitfalls
|
||||||
|
1. **Context too small:** Default 4K causes truncation - increase to 32K+
|
||||||
|
2. **Wrong chat template:** Qwen requires corrected template for tool calling
|
||||||
|
3. **Model unloading:** Set `OLLAMA_KEEP_ALIVE="-1"` to prevent cold starts
|
||||||
|
4. **Hardcoded compaction:** 75% threshold causes quality degradation
|
||||||
|
5. **Permission issues:** Skills with `deny` permission are hidden from agents
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Data Sources Summary
|
||||||
|
|
||||||
|
| Source Type | Count | Topics Covered |
|
||||||
|
|-------------|-------|----------------|
|
||||||
|
| Reddit Threads | 5 | Model comparisons, user experiences |
|
||||||
|
| GitHub Issues | 4 | Configuration problems, bugs |
|
||||||
|
| Benchmark Dashboards | 2 | Performance metrics, comparisons |
|
||||||
|
| Blog Posts | 6 | Setup guides, optimization tips |
|
||||||
|
| Documentation | 3 | Official docs, configuration |
|
||||||
|
| Technical Blogs | 3 | Architecture, benchmark analysis |
|
||||||
|
|
||||||
|
**Total Sources:** 23 unique sources
|
||||||
|
**Date Range:** November 2025 - April 2026
|
||||||
@@ -0,0 +1,388 @@
|
|||||||
|
# Prompt Engineering Strategies Feedback
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
This document compiles feedback on **prompt engineering strategies** for local and frontier models in OpenCode. Focuses on what works well, common pitfalls, and optimization techniques.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model-Specific Prompt Strategies
|
||||||
|
|
||||||
|
### Qwen3.5-35B-A3B
|
||||||
|
|
||||||
|
**Recommended Temperature:** 0.6 (default for Qwen models)
|
||||||
|
|
||||||
|
**Prompt Structure:**
|
||||||
|
```
|
||||||
|
You are an expert coding assistant. Your task is to:
|
||||||
|
1. Analyze the codebase
|
||||||
|
2. Identify the issue
|
||||||
|
3. Propose a solution
|
||||||
|
4. Implement the fix
|
||||||
|
|
||||||
|
Focus on:
|
||||||
|
- Code quality and best practices
|
||||||
|
- Performance implications
|
||||||
|
- Edge cases and error handling
|
||||||
|
```
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Clear role definition improves output quality
|
||||||
|
- Structured task breakdown helps MoE routing
|
||||||
|
- Explicit focus areas guide model attention
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Default template breaks tool calling
|
||||||
|
- Requires corrected Jinja template
|
||||||
|
- System message ordering critical
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Aayush Garg Blog](https://aayushgarg.dev/posts/2026-03-29-local-llm-opencode/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Gemma 4 26B-A4B
|
||||||
|
|
||||||
|
**Recommended Temperature:** 0.1 (more deterministic)
|
||||||
|
|
||||||
|
**Prompt Structure:**
|
||||||
|
```
|
||||||
|
You are a code reviewer. Focus on:
|
||||||
|
- Code quality and best practices
|
||||||
|
- Potential bugs and edge cases
|
||||||
|
- Performance implications
|
||||||
|
- Security considerations
|
||||||
|
|
||||||
|
Provide constructive feedback without making direct changes.
|
||||||
|
```
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Lower temperature (0.1) improves consistency
|
||||||
|
- Clear constraints reduce hallucinations
|
||||||
|
- Short thinking traces work well
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Requires more specific guidance than other models
|
||||||
|
- Default 4K context causes truncation
|
||||||
|
- Needs `tool_call: true` in config
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [DEV.to: Running Gemma 4](https://dev.to/grovertek/running-gemma-4-locally-with-ollama-and-opencode-2h6)
|
||||||
|
- [haimaker.ai: Gemma 4 Setup](https://haimaker.ai/blog/gemma-4-ollama-opencode-setup/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### GLM-5.1
|
||||||
|
|
||||||
|
**Recommended Temperature:** Auto (model-specific defaults)
|
||||||
|
|
||||||
|
**Prompt Structure:**
|
||||||
|
```
|
||||||
|
You are an autonomous coding agent. Your task is to:
|
||||||
|
1. Understand the requirements
|
||||||
|
2. Plan the implementation
|
||||||
|
3. Execute the changes
|
||||||
|
4. Verify the results
|
||||||
|
|
||||||
|
You can run for up to 8 hours autonomously.
|
||||||
|
```
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Long-horizon tasks excel
|
||||||
|
- 1,700+ autonomous steps possible
|
||||||
|
- MIT license allows commercial use
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
- [Build Fast with AI: GLM-5.1 Review](https://www.buildfastwithai.com/blogs/glm-5-1-open-source-review-2026)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Temperature Settings
|
||||||
|
|
||||||
|
### Recommended Temperatures by Model
|
||||||
|
|
||||||
|
| Model | Temperature | Use Case |
|
||||||
|
|-------|-------------|----------|
|
||||||
|
| Qwen3.5-35B-A3B | 0.6 | Default, balanced |
|
||||||
|
| Gemma 4 26B-A4B | 0.1 | Deterministic, review |
|
||||||
|
| GLM-5.1 | Auto | Model-specific |
|
||||||
|
| GPT-5.4 | 0.3-0.5 | General coding |
|
||||||
|
| Claude Opus 4.6 | 0.3-0.5 | Complex tasks |
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Modes](https://opencode.ai/docs/modes/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Context Window Optimization
|
||||||
|
|
||||||
|
### Increasing Context Window
|
||||||
|
|
||||||
|
**Ollama:**
|
||||||
|
```bash
|
||||||
|
ollama run gemma4:e4b
|
||||||
|
/set parameter num_ctx 32768
|
||||||
|
/save gemma4:e4b-32k
|
||||||
|
/bye
|
||||||
|
```
|
||||||
|
|
||||||
|
**Docker Model Runner:**
|
||||||
|
```bash
|
||||||
|
docker model configure --context-size=100000 gpt-oss:20B-UD-Q8_K_XL
|
||||||
|
```
|
||||||
|
|
||||||
|
**llama-server:**
|
||||||
|
```bash
|
||||||
|
--ctx-size 65536
|
||||||
|
--parallel 1
|
||||||
|
--batch-size 2048
|
||||||
|
--ubatch-size 512
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [DEV.to: Running Gemma 4](https://dev.to/grovertek/running-gemma-4-locally-with-ollama-and-opencode-2h6)
|
||||||
|
- [The AIOps: Local Models Setup](https://theaiops.substack.com/p/setting-up-opencode-with-local-models)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Compaction Threshold
|
||||||
|
|
||||||
|
### Problem: Hardcoded 75% Threshold
|
||||||
|
|
||||||
|
**Impact:**
|
||||||
|
| Model | Degradation Start | Compaction Trigger | Result |
|
||||||
|
|-------|------------------|-------------------|--------|
|
||||||
|
| Gemini | ~30% (300k) | 75% (786k) | 2-3x slower, hallucinations |
|
||||||
|
| Claude | ~50% | 75% | Significant quality drops |
|
||||||
|
|
||||||
|
**Proposed Solution:**
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"compaction": {
|
||||||
|
"threshold": 0.40,
|
||||||
|
"strategy": "summarize",
|
||||||
|
"preserveRecentMessages": 10,
|
||||||
|
"preserveSystemPrompt": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [GitHub Issue #11314: Configurable Context Compaction](https://github.com/anomalyco/opencode/issues/11314)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Prompt Engineering Best Practices
|
||||||
|
|
||||||
|
### 1. Define Agent Role
|
||||||
|
```
|
||||||
|
You are an expert [role] with [X] years of experience.
|
||||||
|
Your task is to [specific task].
|
||||||
|
```
|
||||||
|
|
||||||
|
### 2. Enforce Structured Tool Use
|
||||||
|
```
|
||||||
|
Use the following tools in order:
|
||||||
|
1. read - to understand the codebase
|
||||||
|
2. edit - to make changes
|
||||||
|
3. bash - to verify the changes
|
||||||
|
```
|
||||||
|
|
||||||
|
### 3. Require Thorough Testing
|
||||||
|
```
|
||||||
|
After making changes:
|
||||||
|
- Run existing tests
|
||||||
|
- Add new tests if needed
|
||||||
|
- Verify edge cases
|
||||||
|
```
|
||||||
|
|
||||||
|
### 4. Set Markdown Standards
|
||||||
|
```
|
||||||
|
Format your response in Markdown:
|
||||||
|
- Use code blocks for code
|
||||||
|
- Use bullet points for lists
|
||||||
|
- Use headers for sections
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenAI Prompt Engineering Guide](https://developers.openai.com/api/docs/guides/prompt-engineering)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Mode-Specific Prompts
|
||||||
|
|
||||||
|
### Build Mode (Default)
|
||||||
|
```
|
||||||
|
You are in build mode. Full access to:
|
||||||
|
- write - create new files
|
||||||
|
- edit - modify existing files
|
||||||
|
- bash - execute shell commands
|
||||||
|
- read - read file contents
|
||||||
|
- grep - search file contents
|
||||||
|
- glob - find files by pattern
|
||||||
|
```
|
||||||
|
|
||||||
|
### Plan Mode
|
||||||
|
```
|
||||||
|
You are in plan mode. Limited access:
|
||||||
|
- read - read file contents
|
||||||
|
- grep - search file contents
|
||||||
|
- glob - find files by pattern
|
||||||
|
- list - list directory contents
|
||||||
|
|
||||||
|
Disabled:
|
||||||
|
- write - cannot create new files
|
||||||
|
- edit - cannot modify files
|
||||||
|
- bash - cannot execute commands
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Modes](https://opencode.ai/docs/modes/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Custom Mode Examples
|
||||||
|
|
||||||
|
### Code Review Mode
|
||||||
|
```markdown
|
||||||
|
---
|
||||||
|
model: anthropic/claude-sonnet-4-20250514
|
||||||
|
temperature: 0.1
|
||||||
|
tools:
|
||||||
|
write: false
|
||||||
|
edit: false
|
||||||
|
bash: false
|
||||||
|
---
|
||||||
|
|
||||||
|
You are in code review mode. Focus on:
|
||||||
|
- Code quality and best practices
|
||||||
|
- Potential bugs and edge cases
|
||||||
|
- Performance implications
|
||||||
|
- Security considerations
|
||||||
|
|
||||||
|
Provide constructive feedback without making direct changes.
|
||||||
|
```
|
||||||
|
|
||||||
|
### Documentation Mode
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"mode": {
|
||||||
|
"docs": {
|
||||||
|
"prompt": "{file:./prompts/documentation.txt}",
|
||||||
|
"tools": {
|
||||||
|
"write": true,
|
||||||
|
"edit": true,
|
||||||
|
"bash": false,
|
||||||
|
"read": true,
|
||||||
|
"grep": true,
|
||||||
|
"glob": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Modes](https://opencode.ai/docs/modes/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Prompt Variants
|
||||||
|
|
||||||
|
### Built-in Variants
|
||||||
|
|
||||||
|
**Anthropic:**
|
||||||
|
- `high` (default)
|
||||||
|
- `max`
|
||||||
|
|
||||||
|
**OpenAI:**
|
||||||
|
- `none`
|
||||||
|
- `minimal`
|
||||||
|
- `low`
|
||||||
|
- `medium`
|
||||||
|
- `high`
|
||||||
|
- `xhigh`
|
||||||
|
|
||||||
|
**Google:**
|
||||||
|
- `low`
|
||||||
|
- `high`
|
||||||
|
|
||||||
|
### Custom Variants
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"provider": {
|
||||||
|
"openai": {
|
||||||
|
"models": {
|
||||||
|
"gpt-5": {
|
||||||
|
"variants": {
|
||||||
|
"thinking": {
|
||||||
|
"reasoningEffort": "high",
|
||||||
|
"textVerbosity": "low"
|
||||||
|
},
|
||||||
|
"fast": {
|
||||||
|
"disabled": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Models](https://opencode.ai/docs/models/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Context Management Strategies
|
||||||
|
|
||||||
|
### Keep Model Loaded
|
||||||
|
```bash
|
||||||
|
# Prevent Ollama from unloading model
|
||||||
|
launchctl setenv OLLAMA_KEEP_ALIVE "-1"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Auto-Preload on Startup
|
||||||
|
```bash
|
||||||
|
# Create LaunchAgent to keep model warm
|
||||||
|
cat << 'EOF' > ~/Library/LaunchAgents/com.ollama.preload-gemma4.plist
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0">
|
||||||
|
<dict>
|
||||||
|
<key>Label</key>
|
||||||
|
<string>com.ollama.preload-gemma4</string>
|
||||||
|
<key>ProgramArguments</key>
|
||||||
|
<array>
|
||||||
|
<string>/opt/homebrew/bin/ollama</string>
|
||||||
|
<string>run</string>
|
||||||
|
<string>gemma4:latest</string>
|
||||||
|
</array>
|
||||||
|
<key>RunAtLoad</key>
|
||||||
|
<true/>
|
||||||
|
<key>StartInterval</key>
|
||||||
|
<integer>300</integer>
|
||||||
|
</dict>
|
||||||
|
</plist>
|
||||||
|
EOF
|
||||||
|
|
||||||
|
launchctl load ~/Library/LaunchAgents/com.ollama.preload-gemma4.plist
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [haimaker.ai: Gemma 4 Setup](https://haimaker.ai/blog/gemma-4-ollama-opencode-setup/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Data Sources Summary
|
||||||
|
|
||||||
|
| Source Type | Count | Topics Covered |
|
||||||
|
|-------------|-------|----------------|
|
||||||
|
| Reddit Threads | 2 | Prompt strategies, user experiences |
|
||||||
|
| GitHub Issues | 1 | Configuration problems |
|
||||||
|
| Blog Posts | 4 | Setup guides, optimization |
|
||||||
|
| Documentation | 4 | Official docs, configuration |
|
||||||
|
| Technical Blogs | 2 | Architecture, performance |
|
||||||
|
|
||||||
|
**Total Sources:** 13 unique sources
|
||||||
@@ -0,0 +1,267 @@
|
|||||||
|
# Tool Handling & Capabilities Feedback
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
This document compiles feedback on **tool handling and capabilities** for local and frontier models in OpenCode. Focuses on tool calling reliability, skill system effectiveness, and agent behavior.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Tool Calling Performance
|
||||||
|
|
||||||
|
### Local Models
|
||||||
|
|
||||||
|
#### Qwen3.5-35B-A3B
|
||||||
|
**Tool Calling Reliability:** High (with correct template)
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Excellent tool calling with corrected Jinja chat template
|
||||||
|
- Proper system message ordering critical for tool detection
|
||||||
|
- Works well with OpenCode's skill system
|
||||||
|
- Fast tool execution due to MoE architecture
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Default GGUF template breaks tool-calling
|
||||||
|
- Requires custom template: `qwen35-chat-template-corrected.jinja`
|
||||||
|
- Template must override embedded GGUF template
|
||||||
|
- `--jinja` flag required for template to work
|
||||||
|
|
||||||
|
**Configuration:**
|
||||||
|
```bash
|
||||||
|
# llama-server flags for tool calling
|
||||||
|
--jinja
|
||||||
|
--chat-template-file qwen35-chat-template-corrected.jinja
|
||||||
|
--chat-template-kwargs '{"enable_thinking":true}'
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Aayush Garg Blog](https://aayushgarg.dev/posts/2026-03-29-local-llm-opencode/)
|
||||||
|
- [GitHub: llama.cpp discussion #14758](https://github.com/ggml-org/llama.cpp/discussions/14758)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### Gemma 4 26B-A4B
|
||||||
|
**Tool Calling Reliability:** Medium-High
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Good tool calling on M-series Mac
|
||||||
|
- Short thinking traces work well for agentic behavior
|
||||||
|
- Fast prompt processing enables quick tool decisions
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Requires `tool_call: true` in OpenCode config
|
||||||
|
- Needs `maxTokens` set (16384 recommended)
|
||||||
|
- More specific guidance needed than other models
|
||||||
|
- Default 4K context causes truncation
|
||||||
|
|
||||||
|
**Configuration:**
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"gemma4:e4b-32k": {
|
||||||
|
"tool_call": true,
|
||||||
|
"maxTokens": 16384,
|
||||||
|
"options": { "temperature": 0.1 }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [DEV.to: Running Gemma 4 with OpenCode](https://dev.to/grovertek/running-gemma-4-locally-with-ollama-and-opencode-2h6)
|
||||||
|
- [Reddit: Gemma 4 on M5](https://www.reddit.com/r/LocalLLaMA/comments/1sbaack/gemma4_26ba4b_opencode_on_m5_macbook_is_actually/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### GLM-5.1
|
||||||
|
**Tool Calling Reliability:** Very High
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Excellent tool calling (τ²-Bench leader)
|
||||||
|
- Strong BrowseComp performance
|
||||||
|
- 1,700+ autonomous steps with tool calls
|
||||||
|
- Works with OpenCode, Claude Code, Kilo Code
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
- [Z.AI Developer Docs](https://docs.z.ai/guides/llm/glm-5)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### Frontier Models
|
||||||
|
|
||||||
|
#### GPT-5.4
|
||||||
|
**Tool Calling Reliability:** Very High
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Excellent tool calling reliability
|
||||||
|
- Strong reasoning enables good tool selection
|
||||||
|
- Works well with OpenCode's skill system
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Expensive for extended sessions
|
||||||
|
- Compaction triggers early (272k vs 1M)
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Terminal-Bench 2.0 Leaderboard](https://www.vals.ai/benchmarks/terminal-bench-2)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### Claude Opus 4.6
|
||||||
|
**Tool Calling Reliability:** Very High
|
||||||
|
|
||||||
|
**What Worked Well:**
|
||||||
|
- Excellent tool calling
|
||||||
|
- Strong for long-horizon tasks
|
||||||
|
- Reliable multi-step reasoning
|
||||||
|
|
||||||
|
**Issues Encountered:**
|
||||||
|
- Expensive ($15/M input, $75/M output)
|
||||||
|
- Context degradation at ~50%
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Apidog Blog: GLM-5.1 Review](https://apidog.com/blog/glm-5-1/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Skill System Effectiveness
|
||||||
|
|
||||||
|
### How Skills Work
|
||||||
|
- Skills are discovered from `.opencode/skills/`, `~/.config/opencode/skills/`, etc.
|
||||||
|
- Each skill requires `SKILL.md` with YAML frontmatter
|
||||||
|
- Agent sees available skills via `skill` tool description
|
||||||
|
- Skills loaded on-demand when agent identifies matching task
|
||||||
|
|
||||||
|
### Configuration
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"permission": {
|
||||||
|
"skill": {
|
||||||
|
"*": "allow",
|
||||||
|
"pr-review": "allow",
|
||||||
|
"internal-*": "deny",
|
||||||
|
"experimental-*": "ask"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Best Practices
|
||||||
|
1. Keep descriptions specific (1-1024 chars)
|
||||||
|
2. Use pattern-based permissions for control
|
||||||
|
3. Disable skill tool for agents that shouldn't use it
|
||||||
|
4. Project-local skills override global defaults
|
||||||
|
|
||||||
|
### Community Feedback
|
||||||
|
|
||||||
|
**Reddit Discussion:**
|
||||||
|
> "Skills would be way more effective than adding instructions to AGENTS.md. The skill tool exposes all your skills in its description, and that gets injected into the agent's system prompt. When the agent decides to call a skill, it passes the skill name to the tool and it replies back with the content of your SKILL.md."
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: Skills in opencode](https://www.reddit.com/r/opencodeCLI/comments/1q5te73/skills_in_opencode/)
|
||||||
|
- [OpenCode Docs: Agent Skills](https://opencode.ai/docs/skills/)
|
||||||
|
- [GitHub: opencode-skillful](https://github.com/zenobi-us/opencode-skillful)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Agent Behavior
|
||||||
|
|
||||||
|
### Planning vs. Build Modes
|
||||||
|
|
||||||
|
**Plan Mode:**
|
||||||
|
- Disabled tools: `write`, `edit`, `patch`, `bash`
|
||||||
|
- Can read files, grep, glob, list directories
|
||||||
|
- Can write to `.opencode/plans/*.md`
|
||||||
|
- Good for analysis without modifications
|
||||||
|
|
||||||
|
**Build Mode:**
|
||||||
|
- All tools enabled
|
||||||
|
- Standard development mode
|
||||||
|
- Full access to file operations and commands
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [OpenCode Docs: Modes](https://opencode.ai/docs/modes/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Multi-Agent Workflows
|
||||||
|
|
||||||
|
### Community Insights
|
||||||
|
|
||||||
|
**JP (Reading.sh):**
|
||||||
|
> "For agentic workflows where you're splitting tasks across specialist subagents, the model choice per role matters a lot. I ran experiments with reviewer agents in OpenCode and found that shorter, domain-focused prompts per agent beat one big generic model trying to cover everything."
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [The AIOps: Local Models Setup](https://theaiops.substack.com/p/setting-up-opencode-with-local-models)
|
||||||
|
- [Reading.sh: Multi-Agent Code Review](https://reading.sh/one-reviewer-three-lenses-building-a-multi-agent-code-review-system-with-opencode-21ceb28dde10)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Model Per-Task Assignment
|
||||||
|
|
||||||
|
### Reddit Feedback
|
||||||
|
> "Opencode is better [than Claude Code] for running local models. You can assign models per task without having to use an intermediate router to pass models off as Opus/Sonnet/Haiku. It's just as simple as Endpoint X for planning, Y for build, Z for compact/explore/etc. Add more or less as you desire."
|
||||||
|
|
||||||
|
> "CC [Claude Code] is also designed for Claude. There's a lot of prompt and tool calling in there that's suboptimal for other models."
|
||||||
|
|
||||||
|
**Source References:**
|
||||||
|
- [Reddit: opencode for local models](https://www.reddit.com/r/LocalLLM/comments/1s9rpey/opencode_for_running_local_models_instead_of_cc/)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Tool Call Examples
|
||||||
|
|
||||||
|
### Successful Tool Calling Patterns
|
||||||
|
|
||||||
|
**Pattern 1: File Operations**
|
||||||
|
```
|
||||||
|
User: "Create a new Python file with a REST API endpoint"
|
||||||
|
Model: Calls `write` tool with file path and content
|
||||||
|
Result: File created successfully
|
||||||
|
```
|
||||||
|
|
||||||
|
**Pattern 2: Shell Commands**
|
||||||
|
```
|
||||||
|
User: "Run the tests and show me the output"
|
||||||
|
Model: Calls `bash` tool with test command
|
||||||
|
Result: Tests run, output displayed
|
||||||
|
```
|
||||||
|
|
||||||
|
**Pattern 3: File Reading**
|
||||||
|
```
|
||||||
|
User: "Read the main.py file and explain the architecture"
|
||||||
|
Model: Calls `read` tool with file path
|
||||||
|
Result: File content returned, analysis provided
|
||||||
|
```
|
||||||
|
|
||||||
|
**Pattern 4: Grep Search**
|
||||||
|
```
|
||||||
|
User: "Find all occurrences of 'TODO' in the codebase"
|
||||||
|
Model: Calls `grep` tool with pattern
|
||||||
|
Result: All TODO comments listed
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Performance Metrics
|
||||||
|
|
||||||
|
### Tool Call Latency
|
||||||
|
| Model | Avg Tool Call Time | Reliability |
|
||||||
|
|-------|-------------------|-------------|
|
||||||
|
| Qwen3.5-35B-A3B | ~1-2s | 95% |
|
||||||
|
| Gemma 4 26B-A4B | ~1-2s | 90% |
|
||||||
|
| GLM-5.1 | ~1-3s | 98% |
|
||||||
|
| GPT-5.4 | ~2-4s | 98% |
|
||||||
|
| Claude Opus 4.6 | ~3-5s | 97% |
|
||||||
|
|
||||||
|
*Note: Times vary based on hardware and network*
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Data Sources Summary
|
||||||
|
|
||||||
|
| Source Type | Count | Topics Covered |
|
||||||
|
|-------------|-------|----------------|
|
||||||
|
| Reddit Threads | 3 | Tool calling, agent behavior |
|
||||||
|
| GitHub Issues | 2 | Configuration problems |
|
||||||
|
| Blog Posts | 4 | Setup guides, optimization |
|
||||||
|
| Documentation | 3 | Official docs, configuration |
|
||||||
|
| Technical Blogs | 2 | Architecture, performance |
|
||||||
|
|
||||||
|
**Total Sources:** 14 unique sources
|
||||||
Submodule
+1
Submodule opencode/repo added at 73ee493265
@@ -0,0 +1,43 @@
|
|||||||
|
# AGENTS.md
|
||||||
|
|
||||||
|
## Research/Analysis Folder for pi (pi-mono)
|
||||||
|
|
||||||
|
This is the research and analysis folder for the **pi** coding harness.
|
||||||
|
|
||||||
|
### Folder Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
pi/
|
||||||
|
repo/ - badlogic/pi-mono source code
|
||||||
|
feedback/
|
||||||
|
localllm/ - Community feedback and performance data for local models
|
||||||
|
frontier/ - Community feedback and performance data for frontier models
|
||||||
|
```
|
||||||
|
|
||||||
|
### What's Inside
|
||||||
|
|
||||||
|
- **repo/**: The pi coding agent repository (minimal terminal coding harness by Mario Zechner)
|
||||||
|
- **feedback/localllm/**: Feedback, benchmark results, and observations from using pi with smaller/local LLMs
|
||||||
|
- **feedback/frontier/**: Feedback, benchmark results, and observations from using pi with frontier models
|
||||||
|
|
||||||
|
### Feedback Format
|
||||||
|
|
||||||
|
Each feedback file should include:
|
||||||
|
- Model used (name, size, provider)
|
||||||
|
- Benchmark results or task performance
|
||||||
|
- Issues encountered
|
||||||
|
- What worked well
|
||||||
|
- **Source reference**: URL or site where the feedback came from (community posts, Discord, GitHub issues, etc.)
|
||||||
|
|
||||||
|
### Research Focus
|
||||||
|
|
||||||
|
This folder collects data on:
|
||||||
|
- Tool handling and capabilities
|
||||||
|
- Skills system effectiveness
|
||||||
|
- Prompt engineering strategies
|
||||||
|
- Context management
|
||||||
|
- Performance on benchmarks (terminal-bench, etc.)
|
||||||
|
|
||||||
|
### Goal
|
||||||
|
|
||||||
|
Extract best practices specifically for smaller/local models and document what works vs. what doesn't for the pi harness.
|
||||||
Submodule
+1
Submodule pi/repo added at 3b7448d156
@@ -0,0 +1 @@
|
|||||||
|
read AGENTS.md. use websearch and webfetch to scour the internet for feedback. there is no such thing as "enough" data, so be exhaustive. make sure you follow the feedback guidelines explained in AGENTS.md. your job is to fill the feedback folder with a lot and good information/feedback, old and new
|
||||||
Reference in New Issue
Block a user