feat(openai): add GPT-5.4 and GPT-5.4-mini (#67)

Add the two GPT-5.4 variants exposed by OpenAI's API (source:
https://developers.openai.com/api/docs/models/gpt-5.4 and
https://developers.openai.com/api/docs/models/gpt-5.4-mini):

- **gpt-5.4** — frontier tier, 1,050,000 context window, 128k max output,
  $2.50 / input MTok, $15.00 / output MTok.
- **gpt-5.4-mini** — balanced tier (matching the naming convention used
  by `gpt-5-mini`, `gpt-4.1-mini`, etc.), 400,000 context window,
  128k max output, $0.75 / input MTok, $4.50 / output MTok.

Ordered right after the GPT-5.2 family and before the Codex variants
section to keep the frontier-GPT chain in release order.

Addresses librefang/librefang-registry#65 — the original request filed
these under the `codex-cli` provider, but Codex CLI's upstream
`models.json` doesn't list `gpt-5.4-mini` (only the full `gpt-5.4`
slug is list-visible there, and it's already tracked in
`providers/codex-cli.toml`). The correct home for OpenAI-API-direct
access is this file; users who want `gpt-5.4-mini` should configure
`provider = "openai"` rather than `provider = "codex-cli"`.
This commit is contained in:
Evan authored and GitHub committed 2026-04-20 14:15:20 +09:00
1 parent dc23636656
commit 396c88dc49
1 file changed
+27 -1
+27 -1
View File
@@ -1,5 +1,5 @@
# OpenAI — https://openai.com # OpenAI — https://openai.com
# Models: 13 (including 2 Codex variants) # Models: 15 (including 2 Codex variants)
[provider] [provider]
id = "openai" id = "openai"
@@ -154,6 +154,32 @@ supports_vision = true
supports_streaming = true supports_streaming = true
aliases = [] aliases = []
[[models]]
id = "gpt-5.4"
display_name = "GPT-5.4"
tier = "frontier"
context_window = 1050000
max_output_tokens = 128000
input_cost_per_m = 2.50
output_cost_per_m = 15.0
supports_tools = true
supports_vision = true
supports_streaming = true
aliases = []
[[models]]
id = "gpt-5.4-mini"
display_name = "GPT-5.4 Mini"
tier = "balanced"
context_window = 400000
max_output_tokens = 128000
input_cost_per_m = 0.75
output_cost_per_m = 4.50
supports_tools = true
supports_vision = true
supports_streaming = true
aliases = []
# Codex variants (same OpenAI driver & API key) # Codex variants (same OpenAI driver & API key)
[[models]] [[models]]