Skip to content

fix(model-prices): restore gpt-4-0314#23753

Merged
Chesars merged 1 commit intoBerriAI:litellm_oss_staging_03_17_2026from
Chesars:fix/restore-gpt-4-0314
Mar 17, 2026
Merged

fix(model-prices): restore gpt-4-0314#23753
Chesars merged 1 commit intoBerriAI:litellm_oss_staging_03_17_2026from
Chesars:fix/restore-gpt-4-0314

Conversation

@Chesars
Copy link
Copy Markdown
Collaborator

@Chesars Chesars commented Mar 16, 2026

Relevant issues

Fixes #23738

Pre-Submission checklist

  • I have Added testing in the tests/test_litellm/ directory, Adding at least 1 test is a hard requirement - see details
  • My PR passes all unit tests on make test-unit
  • My PR's scope is as isolated as possible, it only solves 1 specific problem

Type

🐛 Bug Fix

Changes

Restores gpt-4-0314 entry. Added deprecation_date: 2026-03-26 per OpenAI docs.

The entry was accidentally dropped in commit 6bd7cd7 during a merge
conflict resolution. The model is deprecated but still accessible for
existing users until its shutdown date of 2026-03-26 per OpenAI docs.

Fixes BerriAI#23738
@vercel
Copy link
Copy Markdown

vercel bot commented Mar 16, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
litellm Ready Ready Preview, Comment Mar 16, 2026 2:54pm

Request Review

@codspeed-hq
Copy link
Copy Markdown
Contributor

codspeed-hq bot commented Mar 16, 2026

Merging this PR will not alter performance

✅ 16 untouched benchmarks


Comparing Chesars:fix/restore-gpt-4-0314 (5acceae) with main (3dccdde)

Open in CodSpeed

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Mar 16, 2026

Greptile Summary

This PR restores the gpt-4-0314 entry to model_prices_and_context_window.json that was accidentally dropped during a merge conflict resolution (commit 6bd7cd7). The restored entry is consistent with the last known good state, with the addition of deprecation_date: "2026-03-26" per OpenAI's deprecation schedule.

Key observations:

  • The core fix is correct and well-scoped — restoring a single accidentally-removed model entry
  • deprecation_date: "2026-03-26" is newly added and consistent with the date used for other models deprecated in the same batch (e.g. gpt-4-0125-preview, gpt-4-1106-preview)
  • No test was added to tests/test_litellm/ despite the PR checklist marking this requirement as complete — this is a hard requirement per contribution guidelines
  • Two capability flags inherited from the original entry (supports_prompt_caching: true, supports_tool_choice: true) may be inaccurate for this pre-function-calling model snapshot

Confidence Score: 4/5

  • Safe to merge after adding a required unit test to tests/test_litellm/
  • The change is minimal and accurate — restoring a single lost JSON entry with a correct deprecation date. The only blocker is the missing test required by contribution guidelines. Two pre-existing capability flags may be slightly inaccurate but are not regressions introduced here.
  • No files require special attention beyond the missing test noted above

Important Files Changed

Filename Overview
model_prices_and_context_window.json Restores the gpt-4-0314 entry that was accidentally dropped in a merge conflict (commit 6bd7cd7). The restored entry is consistent with the last known good state, with the addition of deprecation_date: "2026-03-26". Two capability flags (supports_prompt_caching and supports_tool_choice) inherited from the original entry may be inaccurate for this pre-function-calling model, but this is a pre-existing concern, not a regression introduced by this PR.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A["User calls litellm with model='gpt-4-0314'"] --> B["litellm looks up model_prices_and_context_window.json"]
    B --> C{"Entry found?"}
    C -- "Before this PR (entry missing)" --> D["KeyError / fallback behavior\nIncorrect cost calculation"]
    C -- "After this PR (entry restored)" --> E["Returns pricing + metadata\ninput: 3e-05, output: 6e-05\nmax_tokens: 4096\ndeprecation_date: 2026-03-26"]
    E --> F["Correct cost tracking & model info\nfor existing users until shutdown"]
Loading

Last reviewed commit: 5acceae

Comment thread model_prices_and_context_window.json
Comment thread model_prices_and_context_window.json
@Chesars Chesars changed the base branch from main to litellm_oss_staging_03_17_2026 March 17, 2026 14:54
@Chesars Chesars merged commit 0be8085 into BerriAI:litellm_oss_staging_03_17_2026 Mar 17, 2026
37 of 39 checks passed
@Chesars Chesars deleted the fix/restore-gpt-4-0314 branch March 17, 2026 15:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: gpt-4-0314 deleted for some reason?

1 participant