Use core v0.57.0: search the whole history, upstream check-up, ID and card redaction - #264
Merged
Merged
Conversation
… card redaction Traffic search reaches the whole request history. The page loads the latest 2,000 requests and filters them on the spot as before; when the list is full, the same filter goes to `POST /history/search` for the older records, and the results join the table. A text-search toggle inside the search box also searches the content of requests and answers (core reads the payloads in budgeted pages): each match shows its excerpt under the row, and the footer says how far back the search got, offers to search further, and from which day payloads are kept. Error messages are matched as displayed: in the Chinese UI the codes whose translation may contain the query go along, and rows matched only by record are filtered again against the text on screen. Upstreams get a Check-up tab (`GET /upstreams/health`) over 24 hours, 7 days, 30 days or a custom range: requests and failure rate, whether the model named in the answers matches the one sent, reported input against other upstreams serving the same model, the share of input read from the prompt cache, and median time to first token and speed. Figures come with sample sizes; a deviation is shown in amber only with enough samples on both sides, and for input only on the upstream further from the local estimate, so the honest side of a two-upstream comparison is not flagged. The two new redaction rules (Chinese resident ID number, bank card number) get their names, matcher descriptions and the "Personal information" group on the Security page. Both endpoints are added to the webview whitelist, and the screenshot pipeline's mock core answers them. Upgrading to core 0.57.0 clears the request history (store schema 23) and needs protocol 31 on a remote core. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Moves ThinkWatch Lite to core v0.57.0 (protocol 31) and builds the UI for its three additions.
Traffic: search the whole history
POST /history/search, starting from the oldest loaded row, and older matches join the table.error_codes). Rows matched only by record are filtered again against the text on screen.Upstreams: Check-up tab
GET /upstreams/healthover 24 hours, 7 days, 30 days or a custom range. One row per upstream:Everything comes with sample sizes, and no column draws conclusions. Amber marks a deviation only when both sides have enough samples (20 requests / 10 turns):
The rules live in
src/upstreams/checkup.ts, with tests.Security
cn-resident-idandbank-cardget names, matcher descriptions (birth-year floor, card networks) and the "Personal information" group.Plumbing
HistorySearchandUpstreamHealthare added to the webview whitelist (call.rs,control.ts).tw-api.ts.rowFromHistoryis shared between history loading and search.matchesis factored out offilterRows.README
Upgrade notes for the next release
input_tokensnow see core's token-count estimate.Checks
pnpm typecheck,pnpm buildvitest: 611 testscargo fmt --check,clippy --all-targets -D warnings,cargo testagainst the published twcore v0.57.0🤖 Generated with Claude Code