Skip to content

Conversation

@shivasubrahmanya
Copy link

@shivasubrahmanya shivasubrahmanya commented Jan 24, 2026

What does this PR do?
Introduces a major overhaul to the agent architecture to improve performance and reliability, alongside app fixes.

Parallel Processing: Decoupled reasoning from execution to enable concurrent subtasks.
Persistent Context: Subagents now retain state across invocations within a session.
Smart Context: Implemented a priority-based sliding window to preserve recent and high-value context.
Self-Healing: Agents can now auto-recover from tool failures via a supervisor feedback loop.
App Fixes: Resolved missing folder suggestions and project icon rendering issues.
How did you verify your code works?
Parallel Execution: Verified concurrent subtask execution and result aggregation.
Persistence: Tested subagent memory retention across multiple calls.
Resilience: Simulated tool failures to confirm the supervisor correctly triggers retries.
App: Verified folder suggestion paths and fallback icons in the UI.

Parallel processing - Handle multiple independent tasks simultaneously
Persistent context - Remember conversations across subagent calls
Smart context management - Handle long conversations without losing important info
Self-healing - Automatically recover from most tool errors without manual intervention
@github-actions
Copy link
Contributor

Hey! Your PR title This PR introduces major architectural enhancements to the agent framework, improving performance, context management, and reliability: doesn't follow conventional commit format.

Please update it to start with one of:

  • feat: or feat(scope): new feature
  • fix: or fix(scope): bug fix
  • docs: or docs(scope): documentation changes
  • chore: or chore(scope): maintenance tasks
  • refactor: or refactor(scope): code refactoring
  • test: or test(scope): adding or updating tests

Where scope is the package name (e.g., app, desktop, opencode).

See CONTRIBUTING.md for details.

@github-actions
Copy link
Contributor

The following comment was made by an LLM, it may be inaccurate:

Based on my search results, I found a couple of potentially related PRs that touch on related areas, though none appear to be direct duplicates of PR #10340:

Potentially Related PRs:

  1. PR Enforce subagent delegation to maintain clean main sessions #2830 - "Enforce subagent delegation to maintain clean main sessions"

  2. PR feat(session): add ts_before and breakpoint params to Session.messages API #8996 - "feat(session): add ts_before and breakpoint params to Session.messages API"

However, these are older PRs addressing narrower aspects of session/subagent management. PR #10340 appears to be a comprehensive architectural redesign covering parallel processing, persistent context, smart context management, and self-healing execution all in one major update.

The search results consistently return PR #10340 itself when searching for the core keywords, suggesting this is a unique, large-scale architectural enhancement without a direct duplicate.

@shivasubrahmanya shivasubrahmanya changed the title This PR introduces major architectural enhancements to the agent framework, improving performance, context management, and reliability: feat(opencode): agent architecture overhaul and app fixes Fixes #<ISSUE_ID> Jan 24, 2026
@github-actions
Copy link
Contributor

Thanks for your contribution!

This PR doesn't have a linked issue. All PRs must reference an existing issue.

Please:

  1. Open an issue describing the bug/feature (if one doesn't exist)
  2. Add Fixes #<number> or Closes #<number> to this PR description

See CONTRIBUTING.md for details.

@AviGopal
Copy link

ACP Bug Fixes Added

I've added critical fixes for ACP communication bugs that were causing application stalls and memory leaks:

Fixes Included

  1. Missing Directory Parameter - Added query: { directory } to setSessionMode agent lookup
  2. Event Subscription Memory Leak - Added cleanup tracking with eventCleanup Map and isActive flag
  3. Silent Failures - Added error handling for event subscription failures

Test Results

✅ All 19 new regression tests pass
✅ TypeScript compilation succeeds
✅ No breaking changes

Documentation

  • ACP_BUG_ROOT_CAUSE_ANALYSIS.md - Root cause analysis
  • ACP_BUG_FIXES_AND_PREVENTION.md - Prevention strategies
  • ACP_QUICK_REFERENCE.md - Quick debugging reference

These fixes resolve critical issues preventing ACP from working reliably when the client runs in a different directory than the server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants