From 8e12f0a2773e99fe29bbebeedfdc5eeaae3369a7 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Sat, 21 Mar 2026 18:02:41 +0000 Subject: [PATCH] docs: replace gpt-3.5-turbo with gpt-4o in pages and blog examples Co-authored-by: Krish Dholakia --- docs/my-website/blog/litellm_observatory/index.md | 2 +- docs/my-website/src/pages/completion/supported.md | 12 ++++++------ docs/my-website/src/pages/observability/callbacks.md | 2 +- .../src/pages/observability/helicone_integration.md | 4 ++-- .../src/pages/observability/supabase_integration.md | 2 +- docs/my-website/src/pages/stream.md | 6 +++--- docs/my-website/src/pages/token_usage.md | 6 +++--- 7 files changed, 17 insertions(+), 17 deletions(-) diff --git a/docs/my-website/blog/litellm_observatory/index.md b/docs/my-website/blog/litellm_observatory/index.md index 36366e5de22..972db9f2ff5 100644 --- a/docs/my-website/blog/litellm_observatory/index.md +++ b/docs/my-website/blog/litellm_observatory/index.md @@ -93,7 +93,7 @@ Our focus moving forward is on being the first to detect issues, even when they The `TestOAIAzureRelease` test is designed to catch a class of bugs that only surface after sustained runtime: - **Duration**: Runs continuously for 3 hours -- **Behavior**: Cycles through specified models (such as `gpt-4` and `gpt-3.5-turbo`), issuing requests continuously +- **Behavior**: Cycles through specified models (such as `gpt-4` and `gpt-4o`), issuing requests continuously - **Why 3 Hours**: This helps catch issues where HTTP clients degrade or fail after extended use (for example, a bug observed in LiteLLM v1.81.3) - **Pass / Fail Criteria**: The test passes if fewer than 1% of requests fail. If the failure rate exceeds 1%, the test fails and we are notified in Slack - **Key Detail**: The same HTTP client is reused for the entire run, allowing us to detect lifecycle-related bugs that only appear under prolonged reuse diff --git a/docs/my-website/src/pages/completion/supported.md b/docs/my-website/src/pages/completion/supported.md index e146e6efc97..42d9417daf3 100644 --- a/docs/my-website/src/pages/completion/supported.md +++ b/docs/my-website/src/pages/completion/supported.md @@ -4,9 +4,9 @@ | Model Name | Function Call | Required OS Variables | |------------------|----------------------------------------|--------------------------------------| -| gpt-3.5-turbo | `completion('gpt-3.5-turbo', messages)` | `os.environ['OPENAI_API_KEY']` | -| gpt-3.5-turbo-16k | `completion('gpt-3.5-turbo-16k', messages)` | `os.environ['OPENAI_API_KEY']` | -| gpt-3.5-turbo-16k-0613 | `completion('gpt-3.5-turbo-16k-0613', messages)` | `os.environ['OPENAI_API_KEY']` | +| gpt-4o | `completion('gpt-4o', messages)` | `os.environ['OPENAI_API_KEY']` | +| gpt-4o-16k | `completion('gpt-4o-16k', messages)` | `os.environ['OPENAI_API_KEY']` | +| gpt-4o-16k-0613 | `completion('gpt-4o-16k-0613', messages)` | `os.environ['OPENAI_API_KEY']` | | gpt-4 | `completion('gpt-4', messages)` | `os.environ['OPENAI_API_KEY']` | | gpt-5-pro | `completion('gpt-5-pro', messages)` | `os.environ['OPENAI_API_KEY']` | @@ -15,7 +15,7 @@ For Azure calls add the `azure/` prefix to `model`. If your azure deployment nam | Model Name | Function Call | Required OS Variables | |------------------|-----------------------------------------|-------------------------------------------| -| gpt-3.5-turbo | `completion('azure/gpt-3.5-turbo-deployment', messages)` | `os.environ['AZURE_API_KEY']`,`os.environ['AZURE_API_BASE']`,`os.environ['AZURE_API_VERSION']` | +| gpt-4o | `completion('azure/gpt-4o-deployment', messages)` | `os.environ['AZURE_API_KEY']`,`os.environ['AZURE_API_BASE']`,`os.environ['AZURE_API_VERSION']` | | gpt-4 | `completion('azure/gpt-4-deployment', messages)` | `os.environ['AZURE_API_KEY']`,`os.environ['AZURE_API_BASE']`,`os.environ['AZURE_API_VERSION']` | ### OpenAI Text Completion Models @@ -62,8 +62,8 @@ All the text models from [OpenRouter](https://openrouter.ai/docs) are supported | Model Name | Function Call | Required OS Variables | |------------------|--------------------------------------------|--------------------------------------| -| openai/gpt-3.5-turbo | `completion('openai/gpt-3.5-turbo', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | -| openai/gpt-3.5-turbo-16k | `completion('openai/gpt-3.5-turbo-16k', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | +| openai/gpt-4o | `completion('openai/gpt-4o', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | +| openai/gpt-4o-16k | `completion('openai/gpt-4o-16k', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | | openai/gpt-4 | `completion('openai/gpt-4', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | | openai/gpt-4-32k | `completion('openai/gpt-4-32k', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | | anthropic/claude-2 | `completion('anthropic/claude-2', messages)` | `os.environ['OR_SITE_URL']`,`os.environ['OR_APP_NAME']`,`os.environ['OR_API_KEY']` | diff --git a/docs/my-website/src/pages/observability/callbacks.md b/docs/my-website/src/pages/observability/callbacks.md index 2ec288d5e48..4c538e5f6a3 100644 --- a/docs/my-website/src/pages/observability/callbacks.md +++ b/docs/my-website/src/pages/observability/callbacks.md @@ -26,5 +26,5 @@ os.environ['SENTRY_DSN'], os.environ['SENTRY_API_TRACE_RATE']= "" os.environ['POSTHOG_API_KEY'], os.environ['POSTHOG_API_URL'] = "api-key", "api-url" os.environ["HELICONE_API_KEY"] = "" -response = completion(model="gpt-3.5-turbo", messages=messages) +response = completion(model="gpt-4o", messages=messages) ``` diff --git a/docs/my-website/src/pages/observability/helicone_integration.md b/docs/my-website/src/pages/observability/helicone_integration.md index 273d22d4feb..f271557b684 100644 --- a/docs/my-website/src/pages/observability/helicone_integration.md +++ b/docs/my-website/src/pages/observability/helicone_integration.md @@ -24,7 +24,7 @@ os.environ["OPENAI_API_KEY"], os.environ["COHERE_API_KEY"] = "", "" litellm.success_callback=["helicone"] #openai call -response = completion(model="gpt-3.5-turbo", messages=[{"role": "user", "content": "Hi 👋 - i'm openai"}]) +response = completion(model="gpt-4o", messages=[{"role": "user", "content": "Hi 👋 - i'm openai"}]) #cohere call response = completion(model="command-nightly", messages=[{"role": "user", "content": "Hi 👋 - i'm cohere"}]) @@ -47,7 +47,7 @@ litellm.api_base = "https://oai.hconeai.com/v1" litellm.headers = {"Helicone-Auth": f"Bearer {os.getenv('HELICONE_API_KEY')}"} response = litellm.completion( - model="gpt-3.5-turbo", + model="gpt-4o", messages=[{"role": "user", "content": "how does a court case get to the Supreme Court?"}] ) diff --git a/docs/my-website/src/pages/observability/supabase_integration.md b/docs/my-website/src/pages/observability/supabase_integration.md index 6ae4f65daee..e99c075c883 100644 --- a/docs/my-website/src/pages/observability/supabase_integration.md +++ b/docs/my-website/src/pages/observability/supabase_integration.md @@ -55,7 +55,7 @@ litellm.success_callback=["supabase"] litellm.failure_callback=["supabase"] #openai call -response = completion(model="gpt-3.5-turbo", messages=[{"role": "user", "content": "Hi 👋 - i'm openai"}]) +response = completion(model="gpt-4o", messages=[{"role": "user", "content": "Hi 👋 - i'm openai"}]) #bad call response = completion(model="chatgpt-test", messages=[{"role": "user", "content": "Hi 👋 - i'm a bad call to test error logging"}]) diff --git a/docs/my-website/src/pages/stream.md b/docs/my-website/src/pages/stream.md index a524f4ba695..bfef4d82c48 100644 --- a/docs/my-website/src/pages/stream.md +++ b/docs/my-website/src/pages/stream.md @@ -7,7 +7,7 @@ LiteLLM supports streaming the model response back by passing `stream=True` as an argument to the completion function ### Usage ```python -response = completion(model="gpt-3.5-turbo", messages=messages, stream=True) +response = completion(model="gpt-4o", messages=messages, stream=True) for chunk in response: print(chunk['choices'][0]['delta']) @@ -24,7 +24,7 @@ import asyncio async def test_get_response(): user_message = "Hello, how are you?" messages = [{"content": user_message, "role": "user"}] - response = await acompletion(model="gpt-3.5-turbo", messages=messages) + response = await acompletion(model="gpt-4o", messages=messages) return response response = asyncio.run(test_get_response()) @@ -47,7 +47,7 @@ import os os.environ["OPENAI_API_KEY"] = "" -response = completion(model="gpt-3.5-turbo", messages=messages, stream=True, stream_options={"include_usage": True}) +response = completion(model="gpt-4o", messages=messages, stream=True, stream_options={"include_usage": True}) for chunk in response: print(chunk['choices'][0]['delta']) ``` diff --git a/docs/my-website/src/pages/token_usage.md b/docs/my-website/src/pages/token_usage.md index 61deb61c94f..acd95df1a46 100644 --- a/docs/my-website/src/pages/token_usage.md +++ b/docs/my-website/src/pages/token_usage.md @@ -17,7 +17,7 @@ However, we also expose 3 public helper functions to calculate token usage acros from litellm import token_counter messages = [{"role": "user", "content": "Hey, how's it going"}] -print(token_counter(model="gpt-3.5-turbo", messages=messages)) +print(token_counter(model="gpt-4o", messages=messages)) ``` 2. `cost_per_token` @@ -27,7 +27,7 @@ from litellm import cost_per_token prompt_tokens = 5 completion_tokens = 10 -prompt_tokens_cost_usd_dollar, completion_tokens_cost_usd_dollar = cost_per_token(model="gpt-3.5-turbo", prompt_tokens=prompt_tokens, completion_tokens=completion_tokens) +prompt_tokens_cost_usd_dollar, completion_tokens_cost_usd_dollar = cost_per_token(model="gpt-4o", prompt_tokens=prompt_tokens, completion_tokens=completion_tokens) print(prompt_tokens_cost_usd_dollar, completion_tokens_cost_usd_dollar) ``` @@ -39,7 +39,7 @@ from litellm import completion_cost prompt = "Hey, how's it going" completion = "Hi, I'm gpt - I am doing well" -cost_of_query = completion_cost(model="gpt-3.5-turbo", prompt=prompt, completion=completion)) +cost_of_query = completion_cost(model="gpt-4o", prompt=prompt, completion=completion)) print(cost_of_query) ```