2026-02-19 16:09:13 +00:00
|
|
|
module forge.lthn.ai/core/go-ratelimit
|
|
|
|
|
|
|
|
|
|
go 1.25.5
|
2026-02-19 16:10:06 +00:00
|
|
|
|
|
|
|
|
require gopkg.in/yaml.v3 v3.0.1
|
feat(ratelimit): generalise beyond Gemini with provider profiles and push coverage to 95%
Phase 0: Rewrite test suite with testify (77.1% -> 95.1% coverage).
Add boundary tests, concurrent access tests, benchmarks, error path
coverage for Load/Persist, Reset, Stats, and CountTokens.
Phase 1: Extract hardcoded Gemini quotas into provider-agnostic config.
Add Provider type, DefaultProfiles(), NewWithConfig(), SetQuota(), and
AddProvider(). Pre-configured profiles for Gemini, OpenAI, Anthropic,
and Local. New() retains exact backward compatibility via delegation.
Co-Authored-By: Charon <developers@lethean.io>
2026-02-20 01:07:57 +00:00
|
|
|
|
|
|
|
|
require (
|
|
|
|
|
github.com/davecgh/go-spew v1.1.1 // indirect
|
|
|
|
|
github.com/pmezard/go-difflib v1.0.0 // indirect
|
|
|
|
|
github.com/stretchr/testify v1.11.1
|
|
|
|
|
)
|