FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Add Responses API model constants (ResponsesModels) by RushitaThakkar · Pull Request #90 · digitalocean/gradient-python · GitHub

This repository was archived by the owner on Aug 17, 2026. It is now read-only.

Add Responses API model constants (ResponsesModels) - #90

Open
RushitaThakkar wants to merge 2 commits into
responses-api-resourcefrom
responses-api-models
Open

Add Responses API model constants (ResponsesModels)#90
RushitaThakkar wants to merge 2 commits into
responses-api-resourcefrom
responses-api-models

Conversation

Copy link
Copy Markdown
Collaborator

Summary

Adds recommended model ID constants for the Responses API so callers can use stable names instead of raw strings.

Changes

  • src/gradient/responses_models.py — New ResponsesModels class with:
    • GPT_5_2_PRO = "openai-gpt-5.2-pro"
    • GPT_5_1_CODEX_MAX = "openai-gpt-5.1-codex-max"
  • src/gradient/__init__.py — Export ResponsesModels in the public API.
  • tests/test_responses_models.py — Tests that both constants exist and have the expected string values.

Usageython

from gradient import Gradient, ResponsesModels

client = Gradient()
response = client.responses.create(
model_access_key="...",
input=[{"role": "user", "content": "Hello"}],
model=ResponsesModels.GPT_5_2_PRO,
)

rushitat and others added 2 commits February 6, 2026 15:52
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL