feat: add runner failover rules and cache affinity

This commit is contained in:
2026-06-28 20:50:23 +08:00
parent 41bb3a6525
commit 0e675e259c
31 changed files with 2939 additions and 470 deletions
@@ -118,6 +118,19 @@ CROSS JOIN (
'{"formula":"ceil(input_tokens / 1000) * base_price"}'::jsonb,
10
),
(
'text_cached_input_tokens',
'文本缓存输入 Token',
'text_cached_input',
'1k_tokens',
0.001::numeric,
'{"meter":"cached_input_tokens"}'::jsonb,
'{}'::jsonb,
'token_usage',
'{"metrics":["cached_input_tokens"],"unitScale":1000}'::jsonb,
'{"formula":"ceil(cached_input_tokens / 1000) * base_price"}'::jsonb,
15
),
(
'text_output_tokens',
'文本输出 Token',