Define + export `ServiceTiers` string literal
Open
Beginner friendly
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 31.6k
- Forks
- 5.7k
- Avg merge
- 1d 6h
- Merged PRs (30d)
- 96
Description
Confirm this is a feature request for the Python library and not the underlying OpenAI API.
- This is a feature request for the Python library
Describe the feature or improvement you're requesting
If I want to annotate service_tier in my code, I have to hard-code a type like Literal["auto", "default", "flex", "scale", "priority", "fast"], and then the hard-coded type annotation breaks if I'm using anything other than the latest version of the sdk.
Additional context
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Search the Python library for the existing service_tier definitions and exported string-literal types. Define and export ServiceTiers so callers can use it for annotations, while keeping compatibility with SDK versions that support different service tiers; verify the relevant existing tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100