skingstyle48487 on X runs more than ten relays and asked for something
like the "pelican test" to spot one that waters a model down. In a
follow-up (2122694296054972815) they said speed, failures and the model's
name show whether a relay is fast and stable, not whether the model got
weaker. They asked for small tests with known answers, the share of right
answers and of right tool calls, and relays compared side by side.
On Usage › Requests › Model speed › Providers, each row has a Check… that
opens a dialog. Opening it sends nothing; only its Check makes the calls.
POST /api/relay-check (gateway.CheckRelay) makes 6 small streamed Chat
Completions calls through the gateway, pinned to provider/model as an
agent would, three at a time:
- write 1 to 40;
- 1234 × 5678, 987 × 654 and 2468 × 1357;
- weather in Paris and time in Tokyo, each call offering both tools,
so the right one has to be picked.
Each part says what it found, never a verdict on the provider:
- whether the answer was the expected one, and what came back;
- the model the reply named, when the ledger would call it another
model (usage.Swapped, not SameSpelled or ListedAs);
- the provider that answered, when the call was handed on;
- how many input tokens the 118-character prompt was counted as;
- first token, tok/s and the whole time.
The dialog heads the parts with "Answers right: n of m" and "Right tool
calls: n of m". The numbers come from the gateway's own usage records (a
tap in appendUsage keyed on the request's context), not from each
protocol's reply. The tally of each provider's last check is kept in the
window's storage. The Providers table then shows Answers and Tool calls
columns: sortable, amber when short of all, a dash for providers not
checked, so relays are compared side by side. The dialog code is a
lazily loaded root script (relaycheck.js), as app.js has no room left.
Run, at this head:
- mote: go test -timeout 45m ./internal/gateway ./internal/gui
./internal/cli ./internal/usage: ok (the full ./... suite passed at
41d88731c, before the fixed-answer calls; mote and mica were each
running another session's GUI suite at this head);
- gofmt -l, GOOS=linux go vet -tags nogui ./... and GOOS=windows go
vet ./...: clean;
- go test -run 'CheckRelay|ReadChatStream' -v ./internal/gateway
(5 tests pass);
- usage-model-speed.test.cjs, chromium and webkit, en, zh, zh-TW, ja and
de at 400px: 12/12;
- i18n-keys and old-webkit: their only reds are the three on origin/main,
each filed (#6877 ", with an image", #5919 :has(), #6030
headerpresets.js);
- TestCoreScriptBudget and the app.js budget: ok, not raised.
Broken by hand:
- taking tapUsage out of appendUsage turns TestCheckRelayAnsweredAsAsked
and TestCheckRelaySaysWhatDiffers red;
- dropping the tool-name check turns TestCheckRelayCountsEachAnswer red
(get_weather for Tokyo read as right);
- pressing Check as the dialog opens turns the GUI test red ("opening the
dialog sends no call").
Not tried:
- the whole GUI suite at this head (both machines busy with another
session's suite);
- a real relay (fakes only);
- a context-window probe;
- a comparison with the vendor's own count_tokens;
- a periodic check (the check runs only on a press).