Skip to content

feat: multi-model Compare view#8367

Open
caezium wants to merge 1 commit into
janhq:mainfrom
caezium:feature/multi-model-compare
Open

feat: multi-model Compare view#8367
caezium wants to merge 1 commit into
janhq:mainfrom
caezium:feature/multi-model-compare

Conversation

@caezium

@caezium caezium commented Jun 30, 2026

Copy link
Copy Markdown

Describe Your Changes

Adds a multi-model Compare view (/compare): send one prompt to several models and watch their answers stream side by side — across any configured providers at once (local + cloud).

Compare — generation stats, fastest highlight, reasoning

What it does

  • Execution modesBy backend (default: run backends in parallel, but one model at a time within each backend, so a single local server like LM Studio / llama.cpp that serializes generation doesn't drop a column), Concurrent (all at once), and Sequential.
  • Per-model generation stats — tokens/sec (live while streaming, exact on completion from the provider's usage), time-to-first-token, output tokens, and total time; the fastest model is highlighted.
  • Reasoning support — streams via fullStream, so reasoning models (which return empty content) surface their reasoning_content in a collapsible block instead of rendering blank:

Compare — reasoning streaming live

Adds a /compare route and a sidebar nav entry. No existing flows are modified — the diff is additive only.

Fixes Issues

  • No linked issue — standalone feature proposal. Happy to open a tracking issue if the maintainers prefer one first.

Self Checklist

  • Added relevant comments, esp in complex areas
  • Added tests (web-app/src/routes/__tests__/compare.test.tsx)
  • Updated docs (for bug fixes / features)
  • Created issues for follow-up changes or refactoring needed

Verified end-to-end against LM Studio over an OpenAI-compatible provider (both instruct and reasoning models): execution modes, live + exact stats, fastest highlighting, and reasoning rendering all confirmed. yarn build:web, ESLint, and the new vitest suite all pass.

Run one prompt across several models side by side, across any configured
providers (local + cloud together).

- New /compare route + sidebar nav entry.
- Execution modes: By backend (parallel across backends, sequential within
  each so a single local server that serializes generation doesn't drop a
  column), Concurrent, and Sequential.
- Per-model generation stats: tokens/sec (live while streaming, exact on
  completion from provider usage), time-to-first-token, output tokens, total
  time; fastest model highlighted.
- Streams via fullStream so reasoning models surface reasoning_content in a
  collapsible block instead of rendering blank.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant