Skip to content

Bench chat defaults with per-channel context-window overrides - #3

Merged
TheGreatAxios merged 5 commits into
mainfrom
cl-5653-per-channel-settings
Aug 9, 2026
Merged

Bench chat defaults with per-channel context-window overrides#3
TheGreatAxios merged 5 commits into
mainfrom
cl-5653-per-channel-settings

Conversation

@TheGreatAxios

Copy link
Copy Markdown
Contributor

Summary

Bench-wide chat defaults plus per-channel context-window overrides in chat-ui and settings-ui.

Test plan

  • Settings package tests
  • Chat-ui per-channel panel

@TheGreatAxios
TheGreatAxios force-pushed the cl-5653-per-channel-settings branch from ecd325b to a7a4a1d Compare August 9, 2026 01:46
@TheGreatAxios

Copy link
Copy Markdown
Contributor Author

Self-critique (orchestrator)

Verdict: likely merge-ready after CI + greybeard/bruckheimer

Looks good

  • Domain stays in packages (chat settings + chat-ui panel + settings-ui bench defaults).
  • Migration + store + routes for per-channel context-window overrides.
  • Tests for channel-settings, migrations, UI components.
  • Docs commit present.

Verify

  1. arktype parse at route boundary for PATCH settings body.
  2. Override vs bench-default precedence is tested and documented.
  3. CI green; greybeard + bruckheimer.

@TheGreatAxios
TheGreatAxios force-pushed the cl-5653-per-channel-settings branch 2 times, most recently from 1c8e284 to 587ce11 Compare August 9, 2026 02:05
Channels can now inherit their context window from a new per-tenant
chat_bench_settings table instead of only ever reading a code-level
constant; chat/contextWindow becomes nullable (null/absent means
inherit) and a new resolveContextWindow function folds a channel's
override against the bench default into one effective value, exposed
through GET/PATCH /channels/:id/settings and a new GET/PATCH
/bench/settings route. A migration makes every pre-existing row's
implicit default explicit as null rather than silently reinterpreting
already-set values.
chat/contextWindow is now a bench-wide default every channel inherits,
so the chat settings section edits only that single number rather than
per-channel values. context-window.ts keeps null meaning "not ready to
submit" for the bench-default field (a bench default is never itself an
inherited value — there is nothing beneath it), distinct from a
channel's own nullable override which means "inherit."
A channel's settings dialog (ChannelSettingsPanel) surfaces name, pinned,
and the context-window inherit/override control driven by the resolved
{ value, source } shape from the channel and bench settings routes:
"Use bench default (N)" vs an explicit numeric override, where choosing
inherit always PATCHes chat/contextWindow back to null. The sidebar's
each row gains a hover-revealed ellipsis menu (rename, pin/unpin, open
settings) wrapping the existing row button, preserving the legacy badge
and agent badge from the app-shell layout.
Adds the "Bench defaults and per-channel overrides" section and the
GET/PATCH /bench/settings and /channels/:id/settings routes to the HTTP
surface table, covering the null-means-inherit semantics and the
resolveContextWindow folding behind both UI controls.
@TheGreatAxios
TheGreatAxios force-pushed the cl-5653-per-channel-settings branch from 587ce11 to 7703e26 Compare August 9, 2026 02:28
Per-channel settings adds a fifth chat product table for bench defaults.
@TheGreatAxios

Copy link
Copy Markdown
Contributor Author

Greybeard: MERGE — bench default + per-channel context-window inherit/override; arktype; grant-gated.

@TheGreatAxios
TheGreatAxios merged commit ef906a3 into main Aug 9, 2026
2 checks passed
@TheGreatAxios
TheGreatAxios deleted the cl-5653-per-channel-settings branch August 9, 2026 03:23
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.

1 participant