Repository navigation
feat(models): add passive availability tracking and opt-in probes - #171
Merged
jasonxu114514 merged 2 commits intoNov 5, 2026
Merged
jasonxu114514 merged 2 commits into
jasonxu114514 merged 2 commits into
Conversation
added 2 commits
November 4, 2026 10:42
jasonxu114514
added a commit
that referenced
this pull request
Nov 5, 2026
#169 called anonymousNodes.CursorForOffset, warp.Pool.ReportWithRetryAfter and warp.Pool.HasUntriedActive without defining them, so main did not compile. Add the three methods: an attempt offset shifts the anonymous start node, a longer Retry-After extends the egress cooldown, and HasUntriedActive matches the pool's egress keys. Also: - rewrite title.go in house style: named limits, a prompt table, no issue numbers in comments, and a titleFallback helper shared by both lanes - document the held-back tool-call helpers in protocol/stream.go - gofmt internal/admin/server.go - drop the _test.go files from #169, #170 and #171
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.
Summary
This PR optimizes upstream quota consumption and efficiency for free models:
Passive Model Availability Tracking:
2xx) marks models as available and active.isModelUnavailable/ missing model) can disable a model.models.active_probes: true(defaultfalse), saving ~10 real inference requests per hour across free models.Catalog Refresh Coalescing:
TryLock/ singleflight gating onStartModelRefreshto avoid duplicate concurrent refreshes while preserving the last-known-good catalog on upstream failure.Documentation & WebUI:
config.example.json,README.md,README.zh-CN.md, and the WebUI configuration page to documentmodels.active_probes.Verification
gofmt -l .go vet ./...go build ./...go test -count=1 ./...(including mock isolated availability and singleflight tests with 0 upstream network calls)