| … | … | @@ -141,22 +183,51 @@ function sameTokenRates(a: TokenRates | null, b: TokenRates | null): boolean { | |
| 150 | 212 | !sameTokenRates(fast, b.fast ?? fast) || | |
| 151 | - | !sameTokenRates(ultrafast, b.ultrafast ?? ultrafast) | |
| 213 | + | !sameTokenRates(ultrafast, b.ultrafast ?? ultrafast) || | |
| 214 | + | (b.contextTiers.length > 0 && !sameContextTiers(contextTiers, b.contextTiers)) | |
🟡 Medium usage/usagePricing.ts:214
A bare alias is rejected even when both providers agree on its standard context-tier price, so priceUsage reports short standard requests as unpriced. sameContextTiers treats a missing fast or ultrafast rate as a conflict instead of filling it from the other matching tier; merge those missing speed variants before checking for conflicts.
🚀 Reply "fix it for me" or copy this AI Prompt for your agent:
| 1 | In file @apps/server/src/usage/usagePricing.ts around line 214: |
| 2 | |
| 3 | A bare alias is rejected even when both providers agree on its standard context-tier price, so `priceUsage` reports short standard requests as unpriced. `sameContextTiers` treats a missing `fast` or `ultrafast` rate as a conflict instead of filling it from the other matching tier; merge those missing speed variants before checking for conflicts. |