feat(models): add GPT-6 Astra and refresh OpenAI model pricing - #7482
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Greptile SummaryThis PR adds GPT-6 Astra as OpenAI’s recommended model, refreshes OpenAI catalog metadata and pricing, introduces reusable long-context pricing tiers, and applies those tiers per provider request across normal, cached, and multi-turn usage. It also surfaces tiered rates on model pages, aligns model-comparison plotting areas, removes truncated provider descriptions, and regenerates related documentation and tests.
Confidence Score: 5/5The PR appears safe to merge; no outstanding correctness, security, or repository-rule violations were identified. The prior inline-style finding is fully addressed by replacing style props with SVG geometry and presentation attributes, and the subsequent registered-pricing lookup changes preserve zero-cost behavior for unknown dynamic models without disrupting tiered pricing.
|
| Filename | Overview |
|---|---|
| apps/sim/providers/models.ts | Adds GPT-6 Astra and refreshes OpenAI pricing, capabilities, recommendation, and lifecycle metadata. |
| apps/sim/providers/pricing.ts | Centralizes registered-model pricing lookup and resolves the highest applicable request-size tier. |
| apps/sim/providers/cost-policy.ts | Applies one resolved pricing tier consistently to uncached input, cache reads, cache writes, and output. |
| apps/sim/providers/openai/usage.ts | Retains and prices individual OpenAI turns so long-context thresholds are evaluated per provider request. |
| apps/sim/app/(landing)/models/components/model-comparison-charts.tsx | Replaces inline percentage styles with proportional SVG bars and uses fixed label plotting areas. |
| apps/sim/app/(landing)/models/utils.ts | Prioritizes recommended models and incorporates tiered rates into pricing bounds and generated FAQs. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart LR
U[Provider usage] --> T[Split usage by request]
T --> P[Resolve registered model pricing]
P --> S{Input exceeds tier threshold?}
S -->|No| B[Use base token rates]
S -->|Yes| L[Use highest matching tier]
B --> C[Price input, cache, and output]
L --> C
C --> A[Aggregate execution cost]
Reviews (3): Last reviewed commit: "fix(models): address catalog review find..." | Re-trigger Greptile
There was a problem hiding this comment.
All reported issues were addressed across 17 files
Reply with feedback, questions, or to request a fix.
Fix all with cubic | Re-trigger cubic
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 17 files
Reply with feedback, questions, or to request a fix.
Fix all with cubic | Re-trigger cubic
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
Summary
Testing
bun run checkbun run lintbun run type-checkbun run check:auditsbun run check:api-validationbun run docs-manifest:checkbun run agent-stream-docs:checkcd apps/sim && bunx vitest run providers/pricing.test.ts providers/cost-policy.test.ts providers/openai/usage.test.ts providers/models.test.ts providers/utils.test.ts "app/(landing)/models/utils.test.ts"Change Type
Checklist