ide на основе vs code
Это ide на основе vs code(code oss), в ней будет встроенный умный апи роутинг, свой маркет с плагинами(агент харнесс, поддержка java/kotlin/мобильной разработки, командная разработка проектов, orca, оркестратор агентов
Это ide на основе vs code(code oss), в ней будет встроенный умный апи роутинг, свой маркет с плагинами(агент харнесс, поддержка java/kotlin/мобильной разработки, командная разработка проектов, orca, оркестратор агентов
> Generated by super-planner. Source: roadmap.md (phase 10.5). > Last updated: 2026-05-21 after grill-with-docs session.
Status: ✅ DONE
Verification:
npm run typecheck-client clean.--agents Code OSS (run dir /tmp/phase10.5-e2e/logs/20260521T114550). Validated live:b0b896c5-..., e40afbbb-..., 749dc491-...).setClientTools registered 13 workbench tools pre-materialize.installPipeline materialized cleanly (enableFileCheckpointing=true isResume=false).openBrowserPage → permission prompt fired through workbench UI → user approval → workbench opened the page → tool_result (Page Title: Example Domain) fed back to SDK → final result for sdkUuid=....Cannot materialize unknown provisional session, rebind: no rematerializer attached)./tmp/code-oss-screenshots/2026-05-21T13-05-33/ (01-launched, 02-session-type-picker, 03-after-select-claude, 04-prompt-typed, 05-permission-prompt, 06-tool-completed).rebindForClientTools, subagent spawn, abort mid-turn, UI dispose. Playwright type-into-Monaco hit focus-sync edge cases on the new-session form; refactor-sensitive plumbing was already proven by the browser-tool scenario above.agent-host-claude:/<id> and claude-code:/<id>) because both providers index the same on-disk JSONL store — NOT a Phase 10.5 regression.Replace Claude's dual-map session lifecycle (_provisionalSessions + _sessions) with one session object identity per sessionId, owned by ClaudeAgentSession, so Phase 10's race-compensation code can be removed structurally instead of patched around.
In scope
_sessions map of ClaudeSessionEntry values.ClaudeAgentSession.materialize()._pipeline, _materializePromise, disposed state), not a separate enum.SequencerByKey<string> to per-session Sequencer.IAgent) while moving internals.ClaudeMaterializer class and extract pure SDK option helpers to claudeSdkOptions.ts.Out of scope
IAgent API changes.src/vs/platform/agentHost/node/copilot/copilotAgent.ts) - owned by a separate phase. ./scripts/test.sh --runGlob "**/agentHost/test/**/*.test.js".
launch and code-oss-logs.Use an incremental, bisectable refactor where each step stays testable and revertible. First introduce session-owned materialization and delegation while preserving current behavior, then collapse map topology, then delete compensation paths, then retire obsolete abstractions. Keep E2E coverage on every step to catch wiring regressions early. Preserve domain terms from CONTEXT.md (materialization, session overlay, proxy) and avoid scope drift into neighboring phases.
1. ✓ Add provisional factory on `ClaudeAgentSession` - allow session instances to exist pre-materialization.
src/vs/platform/agentHost/node/claude/claudeAgentSession.tscreateProvisional(...) exists, _pipeline is nullable pre-materialize, _requirePipeline() guard exists, and tests prove no SDK startup occurs during provisional construction.2. ✓ Add `session.materialize()` implementation (2a) - add session-owned lifecycle orchestration and idempotent in-flight materialize promise.
src/vs/platform/agentHost/node/claude/claudeAgentSession.ts, src/vs/platform/agentHost/node/claude/claudeMaterializer.ts3. ✓ Delegate agent materialize/resume methods to session (2b) - make production path exercise session.materialize().
src/vs/platform/agentHost/node/claude/claudeAgent.ts_materializeProvisional and _resumeSession delegate to session materialization and existing agent tests remain green.4. ✓ Collapse to one map while keeping compensation (3a) - remove _provisionalSessions and keep compensation temporarily for safe bisecting.
src/vs/platform/agentHost/node/claude/claudeAgent.ts, src/vs/platform/agentHost/node/claude/claudeAgentSession.tsSequencer is in use, and all Phase 10 regressions still pass.5. ✓ Delete race compensation (3b) - removed during 3a since there is no longer a separate provisional record to re-sync.
src/vs/platform/agentHost/node/claude/claudeAgent.ts6. ✓ Polish per-phase dispatch in session (4) - setClientTools, setProvisionalModel/queueModelChange, requestPermission, requestUserInput, and abort are pipeline-aware on session.
src/vs/platform/agentHost/node/claude/claudeAgentSession.ts7. ✓ Fold disk-only resume into same object pattern (5) - _resumeSession uses createProvisional + materializer.materialize(ctx) with the same session object identity.
src/vs/platform/agentHost/node/claude/claudeAgent.ts, src/vs/platform/agentHost/node/claude/claudeSessionMetadataStore.tsisResume: true, and resume-bootstrap regression remains green.8. ✓ Extract pure SDK options module and retire materializer class (6) - claudeSdkOptions.ts now holds the pure buildOptions / buildClientMcpServers / buildSubprocessEnv helpers; session.materialize(ctx) owns SDK startup, abort gate, DB ref open, pipeline construct, rematerializer wire; ClaudeMaterializer class + file deleted; tests relocated to claudeSdkOptions.test.ts.
| Path | Change | Notes | |------|--------|-------| | src/vs/platform/agentHost/node/claude/claudeAgent.ts | modify | Collapse maps, delegate/cleanup materialize/resume, remove compensation, drop materializer dependency | | src/vs/platform/agentHost/node/claude/claudeAgentSession.ts | modify | Provisional factory, nullable pipeline guard, materialize flow, per-session sequencer, mutation dispatch | | src/vs/platform/agentHost/node/claude/claudeMaterializer.ts | modify then delete | Transitional helper extraction; final removal | | src/vs/platform/agentHost/node/claude/claudeSdkOptions.ts | create | Pure buildOptions/buildClientMcpServers/buildSubprocessEnv helpers | | src/vs/platform/agentHost/node/claude/claudeSessionMetadataStore.ts | modify (minimal) | Keep workspace-wide overlay store; optional project() helper extraction | | src/vs/platform/agentHost/test/node/claudeAgent.test.ts | modify | Adjust assertions for one-map + compensation deletion + resume flow | | src/vs/platform/agentHost/test/node/claudeAgentSession*.test.ts | modify/create | Materialize idempotency and provisional-session tests | | src/vs/platform/agentHost/test/node/claudeMaterializer.test.ts | modify/rename | Move helper coverage to new module | | src/vs/platform/agentHost/test/node/claudeSdkPipeline.test.ts | modify if needed | Ensure rebind/recover expectations still hold | | src/vs/platform/agentHost/test/node/claudeAgent.integrationTest.ts | modify | Pre-materialize setClientTools integration scenario |
claudeSdkOptions.ts for two-call-site reuse.3a before 4) to avoid impossible write-through assumptions.3a (structure) and 3b (pure deletion) for bisectability.2a/2b so implementation lands first, then production wiring lands as its own commit.ClaudeSessionMetadataStore workspace-wide (required for listSessions on unseen sessions). Session consumes it via DI for writes.Sequencer (not SequencerByKey) once each session owns its own queue._pipeline, _materializePromise, disposed state) to avoid duplicated state machines.markDirty() retry behavior on failed rebind startup.onDidMaterializeSession forwarding remains intact for AgentService consumers../scripts/test.sh --runGlob "**/agentHost/test/**/*.test.js"./scripts/test.sh --grep "materialize gap|resume bootstrap gap|rebind failure leaves"src/vs/platform/agentHost/test/node/claudeAgent.integrationTest.tslaunch - drives Agents window UI and Claude session turns in local Code OSS.code-oss-logs - reads agenthost.log and related logs to validate runtime behavior. 1. Use launch to start ./scripts/code.sh --agents and open a new session with the Claude entry under Local Agent Host. 2. Before first send, change model; send turn 1; send turn 2. 3. Trigger client-tools change and send turn 3. 4. Abort an in-flight turn, then dispose the session. 5. Use code-oss-logs to confirm expected lifecycle lines and absence of legacy failures. 6. Confirm no leaked Claude subprocesses.
Expected checks after each run:
RUN="$(ls -td /tmp/phase10.5-e2e/logs/* | head -1)"
rg -n "Session materialized|enableFileCheckpointing|resume rebuild|setClientTools|rebind|CancellationError|error" "$RUN/agenthost.log"
rg -n "Cannot materialize unknown provisional session" "$RUN/agenthost.log" && echo FAIL
rg -n "rebind: no rematerializer attached" "$RUN/agenthost.log" && echo FAIL
rg -c "Session materialized.*<session-id>" "$RUN/agenthost.log"
ps aux | grep claude | grep -v grep choose lower Claude entry under Local Agent Host and confirm POST /v1/messages appears in agenthost.log after a probe send.
None.
./roadmap.md (phase 10.5)./CONTEXT.md./phase10-plan.mdlaunch, code-oss-logs../../../../../.agents/skills/launch/references/agents-window-guide.mdsrc/vs/platform/agentHost/node/claude/claudeAgentSession.tssrc/vs/platform/agentHost/test/node/claudeAgent.test.tssrc/vs/platform/agentHost/test/node/claudeAgent.test.ts:createProvisional creates a session without SDK startup contactpipeline methods throw before materialize on provisional sessionssession.materialize is idempotent across concurrent callssession.materialize retries after a failed attemptsession.materialize(ctx) owns idempotency and in-flight promise caching but defers SDK startup / DB ref / pipeline construction to the caller-supplied ctx.materialize(). The full orchestration migration folds into Step 3a (structural collapse), where the agent will construct provisional ClaudeAgentSessions and pass an orchestration closure that invokes the existing materializer. Intentional design realignment to avoid building then immediately dismantling a stateful intermediate./avoid-private-methods follow-up: extracted private _currentPermissionMode() into file-level helper resolveCurrentPermissionMode(...) in claudeAgentSession.ts./avoid-private-methods audit after Step 3a: _requirePipeline collapsed to single-concern guard, _runMaterialize deleted entirely along with the legacy callback shape. No outstanding session-level findings.ClaudeMaterializer was an orphan class (one caller, no polymorphism, no real boundary) once the session owned identity; net change is -50 lines and one obvious lifecycle owner._findAnySession(sessionId) discriminated-union helper in claudeAgent.ts.setClientTools through helper.changeModel through helper.disposeSession, abortSession, getSessionMessages provisional check through helper.sendMessage materialize/resume dispatch through helper._provisionalSessions and IClaudeProvisionalSession; provisional state now lives on ClaudeAgentSession (project, provisionalModel, provisionalConfig, abortController, isPipelineReady, installPipeline); materializer rewritten to install onto an existing session; _findAnySession collapsed to single-map lookup; shutdown/dispose iterate _sessions only; compensation re-sync paths removed naturally.createSession now uses ClaudeAgentSession.createProvisionalClaudeLocal Agent Host[LOCAL]_sessions