코워크·코드 실행 중 UI 멈춤 체감 완화

에이전트 이벤트를 UI 스레드에서 과하게 즉시 처리하던 경로를 정리해 코워크·코드 실행 중 입력과 렌더가 먼저 흐르도록 조정했다.

- ChatWindow agent dispatcher 우선순위를 Background로 낮춰 이벤트 폭주 시 UI 응답성을 확보

- OnAgentEvent 즉시 갱신을 완료/오류 중심으로 축소하고 나머지는 배치 타이머 경로로 이관

- ChatWindow.AgentEventProcessor에서 execution event 중복 append를 제거해 대화 히스토리 반영을 백그라운드 1회 처리로 단순화

- README.md, docs/DEVELOPMENT.md에 2026-04-10 09:03 (KST) 기준 작업 이력 반영

검증: dotnet build src/AxCopilot/AxCopilot.csproj -c Release -v minimal -p:OutputPath=bin\\verify\\ -p:IntermediateOutputPath=obj\\verify\\ / 경고 0, 오류 0
This commit is contained in:
2026-04-10 09:08:14 +09:00
parent 5511c620de
commit 9175dfe657
4 changed files with 204 additions and 8638 deletions

View File

@@ -555,3 +555,16 @@ owKindCounts를 함께 남겨 %APPDATA%\\AxCopilot\\perf 기준으로 transcript
- `src/AxCopilot/Views/ChatWindow.TranscriptRendering.cs`
- performance log detail??`processFeedAppends`, `processFeedMerges`瑜?異붽???grouped activity row???④낵瑜??ㅼ궗??濡쒓렇?먯꽌 ?뺤씤?????덇쾶 ?덉뒿?덈떎.
## Cowork/Code 실행 중 UI 멈춤 완화 (2026-04-10 09:03 KST)
- `claude-code`처럼 실행 이벤트를 얇게 소비하도록, AX Agent의 Cowork/Code UI 이벤트 경로를 다시 줄였습니다.
- `src/AxCopilot/Views/ChatWindow.xaml.cs`
- agent loop dispatcher 우선순위를 `DispatcherPriority.Normal`에서 `DispatcherPriority.Background`로 낮춰, 대량의 에이전트 이벤트가 들어와도 사용자 입력과 렌더가 먼저 처리되도록 바꿨습니다.
- `OnAgentEvent()`는 이제 완료/오류 같은 종료 이벤트만 즉시 처리하고, ToolCall/ToolResult/Thinking의 라이브 카드 갱신은 기존 `_agentUiEventTimer` 기반 배치 경로로 넘깁니다.
- `src/AxCopilot/Views/ChatWindow.AgentEventProcessor.cs`
- execution event를 UI 스레드에서 즉시 append한 뒤 백그라운드에서 다시 append하던 중복 경로를 제거했습니다.
- 대화 히스토리 반영, agent run 기록, 저장은 백그라운드 단일 리더에서 한 번만 처리하도록 정리해 Cowork/Code 실행 중 UI 점유를 줄였습니다.
- 기대 효과
- 긴 tool/thinking 이벤트가 연속으로 들어와도 창 전체가 끝날 때까지 얼어붙는 느낌이 줄어듭니다.
- transcript 저장과 실행 이력 반영이 한 번만 일어나, 실행 길이가 길수록 커지던 UI 스레드 부담이 완화됩니다.