Skip to content

fix(webui): promote provisional router cards - #1502

Open
mikemikimike wants to merge 2 commits into
TokenRhythm:mainfrom
mikemikimike:fix/router-card-promotion-1477
Open

fix(webui): promote provisional router cards#1502
mikemikimike wants to merge 2 commits into
TokenRhythm:mainfrom
mikemikimike:fix/router-card-promotion-1477

Conversation

@mikemikimike

Copy link
Copy Markdown
Contributor

Fixes #1477

Summary

When ensemble progress or handoff arrives before the real router decision, the Web UI creates a provisional router card. The later decision was appended under a new sequence-backed message ID, so one route attempt could render duplicate cards.

This change promotes only a runtime-created provisional card when the session, exact turn, and router replay generation match. Promotion updates the decision and message identity in place while retaining ensemble members and existing message metadata, including physical execution state supplied by compatible runtime changes. Router-control replay boundaries, distinct turns, and already-real decisions remain separate.

Tests

  • npm run test:unit -- src/composables/chat/useChatRouterDecisionRuntime.test.ts (24 passed)
  • npm run typecheck (passed)
  • npm run build (passed, including artifact and bundle validation)
  • uv run --frozen ruff check src tests (passed)
  • uv build --wheel (passed)
  • npm run test:unit (401 files / 5086 tests passed; the suite emitted existing localhost:3000 connection-refused activity and required process cleanup after the passing summary)
  • uv run --frozen pytest -q (1437 passed, 66 skipped, 6 failed in migration tests because Windows default GBK could not decode migration source files; the changed Web UI files are outside those paths)

Third-party origin

None.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Ensemble router cards duplicate and can persist on New Task

1 participant