[PR #634] [CLOSED] feat: Add Gemini pricing tier config option #9673

Closed
opened 2026-02-16 18:13:57 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/anomalyco/opencode/pull/634
Author: @ghost
Created: 7/3/2025
Status: Closed

Base: devHead: gemini-pricing-tier-config


📝 Commits (6)

📊 Changes

6 files changed (+616 additions, -37 deletions)

View changed files

config.schema.json (+448 -0)
📝 packages/opencode/src/config/config.ts (+6 -4)
📝 packages/opencode/src/provider/models.ts (+23 -6)
📝 packages/opencode/src/provider/provider.ts (+12 -25)
packages/opencode/src/test/provider.test.ts (+110 -0)
📝 packages/web/src/content/docs/docs/config.mdx (+17 -2)

📄 Description

This commit introduces a new configuration option use_standard_pricing_only
that allows users to force the use of the standard pricing tier for Gemini
models, even for large contexts. in relevance of this issue 592

  • Modified models.ts and provider.ts to handle tiered pricing.
  • Added use_standard_pricing_only to config.ts and updated
    config.schema.json.
  • Added tests for the pricing tier logic in provider.test.ts.
  • Updated documentation in config.mdx.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/anomalyco/opencode/pull/634 **Author:** [@ghost](https://github.com/ghost) **Created:** 7/3/2025 **Status:** ❌ Closed **Base:** `dev` ← **Head:** `gemini-pricing-tier-config` --- ### 📝 Commits (6) - [`d969ba2`](https://github.com/anomalyco/opencode/commit/d969ba2839662fccd1ebc6e07dc29ad32afb12fb) Create config.schema.json - [`415301d`](https://github.com/anomalyco/opencode/commit/415301d3eb7263b33aa9887c540efb3041d35544) Update config.ts - [`f949bcd`](https://github.com/anomalyco/opencode/commit/f949bcdc75953deae4b4e3b1479a65fd3833f6f2) Update models.ts - [`d1cce65`](https://github.com/anomalyco/opencode/commit/d1cce657a91c5694548d60703c849e70704254f5) Update provider.ts - [`0b04861`](https://github.com/anomalyco/opencode/commit/0b048614bd25c1a039a28e4c04b3f1f8f3c4bf54) Create provider.test.ts - [`cfe029a`](https://github.com/anomalyco/opencode/commit/cfe029a47923a92baaa895ec779b3e0ea59da520) Update config.mdx ### 📊 Changes **6 files changed** (+616 additions, -37 deletions) <details> <summary>View changed files</summary> ➕ `config.schema.json` (+448 -0) 📝 `packages/opencode/src/config/config.ts` (+6 -4) 📝 `packages/opencode/src/provider/models.ts` (+23 -6) 📝 `packages/opencode/src/provider/provider.ts` (+12 -25) ➕ `packages/opencode/src/test/provider.test.ts` (+110 -0) 📝 `packages/web/src/content/docs/docs/config.mdx` (+17 -2) </details> ### 📄 Description This commit introduces a new configuration option `use_standard_pricing_only` that allows users to force the use of the standard pricing tier for Gemini models, even for large contexts. in relevance of this issue [592](https://github.com/sst/opencode/issues/592) - Modified `models.ts` and `provider.ts` to handle tiered pricing. - Added `use_standard_pricing_only` to `config.ts` and updated `config.schema.json`. - Added tests for the pricing tier logic in `provider.test.ts`. - Updated documentation in `config.mdx`. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 18:13:57 -05:00
yindo closed this issue 2026-02-16 18:13:58 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9673