Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
陈曦
sub2api
Commits
15f3ffb1
Commit
15f3ffb1
authored
Feb 25, 2026
by
shaw
Browse files
chore: 调整模型定价文件仓库
parent
02db1010
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
backend/internal/config/config.go
View file @
15f3ffb1
...
...
@@ -1088,9 +1088,9 @@ func setDefaults() {
// RateLimit
viper
.
SetDefault
(
"rate_limit.overload_cooldown_minutes"
,
10
)
// Pricing - 从
price-mirror 分支同步,该分支维护了 sha256 哈希文件用于增量更新检查
viper
.
SetDefault
(
"pricing.remote_url"
,
"https://
raw.
github
usercontent
.com/Wei-Shaw/
claude-relay-service/price-mirror
/model_prices_and_context_window.json"
)
viper
.
SetDefault
(
"pricing.hash_url"
,
"https://
raw.
github
usercontent
.com/Wei-Shaw/
claude-relay-service/price-mirror
/model_prices_and_context_window.sha256"
)
// Pricing - 从
model-price-repo 同步模型定价和上下文窗口数据的配置
viper
.
SetDefault
(
"pricing.remote_url"
,
"https://github.com/Wei-Shaw/
model-price-repo/raw/refs/heads/main
/model_prices_and_context_window.json"
)
viper
.
SetDefault
(
"pricing.hash_url"
,
"https://github.com/Wei-Shaw/
model-price-repo/raw/refs/heads/main
/model_prices_and_context_window.sha256"
)
viper
.
SetDefault
(
"pricing.data_dir"
,
"./data"
)
viper
.
SetDefault
(
"pricing.fallback_file"
,
"./resources/model-pricing/model_prices_and_context_window.json"
)
viper
.
SetDefault
(
"pricing.update_interval_hours"
,
24
)
...
...
backend/resources/model-pricing/model_prices_and_context_window.json
View file @
15f3ffb1
This diff is collapsed.
Click to expand it.
deploy/config.example.yaml
View file @
15f3ffb1
...
...
@@ -781,10 +781,10 @@ rate_limit:
pricing
:
# URL to fetch model pricing data (default: LiteLLM)
# 获取模型定价数据的 URL(默认:LiteLLM)
remote_url
:
"
https://
raw.
github
usercontent.com/BerriAI/litellm
/main/model_prices_and_context_window.json"
remote_url
:
"
https://github
.com/Wei-Shaw/model-price-repo/raw/refs/heads
/main/model_prices_and_context_window.json"
# Hash verification URL (optional)
# 哈希校验 URL(可选)
hash_url
:
"
"
hash_url
:
"
https://github.com/Wei-Shaw/model-price-repo/raw/refs/heads/main/model_prices_and_context_window.sha256
"
# Local data directory for caching
# 本地数据缓存目录
data_dir
:
"
./data"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment