From e92b6472d2b4de174e8fcfea521c87beeb04cac7 Mon Sep 17 00:00:00 2001 From: Abhijeet Prasad Date: Fri, 14 Aug 2026 15:33:32 -0400 Subject: [PATCH] test(openai): update BTX specs to v0.0.10 Add positive-number matcher support and refresh the OpenAI attachment and reasoning-completions cassettes across the supported version matrix. --- py/src/braintrust/btx/span_validator.py | 5 + py/src/braintrust/btx/spec-ref.txt | 2 +- .../cassettes/1.71.0/btx/attachments.yaml | 158 +++++------------- .../1.71.0/btx/reasoning_completions.yaml | 82 +++++++++ .../cassettes/1.77.0/btx/attachments.yaml | 157 +++++------------ .../1.77.0/btx/reasoning_completions.yaml | 80 +++++++++ .../cassettes/1.92.0/btx/attachments.yaml | 157 +++++------------ .../1.92.0/btx/reasoning_completions.yaml | 78 +++++++++ .../cassettes/latest/btx/attachments.yaml | 48 +++--- .../latest/btx/reasoning_completions.yaml | 78 +++++++++ 10 files changed, 476 insertions(+), 369 deletions(-) create mode 100644 py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/reasoning_completions.yaml create mode 100644 py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/reasoning_completions.yaml create mode 100644 py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/reasoning_completions.yaml create mode 100644 py/src/braintrust/integrations/openai/cassettes/latest/btx/reasoning_completions.yaml diff --git a/py/src/braintrust/btx/span_validator.py b/py/src/braintrust/btx/span_validator.py index d8dd78a45..68a49f854 100644 --- a/py/src/braintrust/btx/span_validator.py +++ b/py/src/braintrust/btx/span_validator.py @@ -35,6 +35,10 @@ def _is_non_negative_number(value: Any) -> bool: return isinstance(value, (int, float)) and not isinstance(value, bool) and value >= 0 +def _is_positive_number(value: Any) -> bool: + return isinstance(value, (int, float)) and not isinstance(value, bool) and value > 0 + + def _is_non_empty_string(value: Any) -> bool: return isinstance(value, str) and len(value) > 0 @@ -58,6 +62,7 @@ def _is_reasoning_message(value: Any) -> bool: _NAMED_MATCHERS: dict[str, Any] = { "is_non_negative_number": _is_non_negative_number, + "is_positive_number": _is_positive_number, "is_non_empty_string": _is_non_empty_string, "is_reasoning_message": _is_reasoning_message, } diff --git a/py/src/braintrust/btx/spec-ref.txt b/py/src/braintrust/btx/spec-ref.txt index 45c7a584f..51bbb66dc 100644 --- a/py/src/braintrust/btx/spec-ref.txt +++ b/py/src/braintrust/btx/spec-ref.txt @@ -1 +1 @@ -v0.0.1 +v0.0.10 diff --git a/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/attachments.yaml b/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/attachments.yaml index 0f58768a0..a7a938890 100644 --- a/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/attachments.yaml +++ b/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/attachments.yaml @@ -1,155 +1,83 @@ interactions: - request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' + body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"Briefly + describe these attachments"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}},{"type":"file","file":{"filename":"blank.pdf","file_data":"data:application/pdf;base64,JVBERi0xLjAKMSAwIG9iago8PCAvVHlwZSAvQ2F0YWxvZyAvUGFnZXMgMiAwIFIgPj4KZW5kb2JqCjIgMCBvYmoKPDwgL1R5cGUgL1BhZ2VzIC9LaWRzIFszIDAgUl0gL0NvdW50IDEgPj4KZW5kb2JqCjMgMCBvYmoKPDwgL1R5cGUgL1BhZ2UgL1BhcmVudCAyIDAgUiAvTWVkaWFCb3ggWzAgMCA2MTIgNzkyXSA+PgplbmRvYmoKeHJlZgowIDQKMDAwMDAwMDAwMCA2NTUzNSBmIAowMDAwMDAwMDA5IDAwMDAwIG4gCjAwMDAwMDAwNTggMDAwMDAgbiAKMDAwMDAwMDExNSAwMDAwMCBuIAp0cmFpbGVyCjw8IC9TaXplIDQgL1Jvb3QgMSAwIFIgPj4Kc3RhcnR4cmVmCjE5MAolJUVPRgo="}}]}],"model":"gpt-4o","temperature":0.0}' headers: - Accept: + accept: - application/json - Accept-Encoding: + accept-encoding: - gzip, deflate - Connection: + connection: - keep-alive - Content-Length: - - '353' - Content-Type: + content-length: + - '888' + content-type: - application/json - Host: + host: - api.openai.com method: POST uri: https://api.openai.com/v1/chat/completions response: body: - string: "{\n \"id\": \"chatcmpl-DYJCnaJpluKcRLAhJ6IFEPYlb25km\",\n \"object\": - \"chat.completion\",\n \"created\": 1777069349,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n + string: "{\n \"id\": \"chatcmpl-ECrtQIzXCewzHrgripHO0lB2egzRQ\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735808,\n \"model\": \"gpt-4o-2024-08-06\",\n \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + \"assistant\",\n \"content\": \"The first attachment is a solid red + square, likely an image file with no additional content or context.\\n\\nThe + second attachment, \\\"blank.pdf,\\\" appears to be a PDF document with no + readable content or visible images.\",\n \"refusal\": null,\n \"annotations\": + []\n },\n \"logprobs\": null,\n \"finish_reason\": \"stop\"\n + \ }\n ],\n \"usage\": {\n \"prompt_tokens\": 495,\n \"completion_tokens\": + 42,\n \"total_tokens\": 537,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_a7190374f3\"\n}\n" + \"default\",\n \"system_fingerprint\": \"fp_684acb85fd\"\n}\n" headers: - Connection: - - keep-alive - Content-Type: - - application/json - Date: - - Fri, 24 Apr 2026 22:22:29 GMT - Server: - - cloudflare - Strict-Transport-Security: - - max-age=31536000; includeSubDomains; preload - Transfer-Encoding: - - chunked - X-Content-Type-Options: - - nosniff access-control-expose-headers: - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive content-length: - - '827' + - '1021' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:30:09 GMT openai-processing-ms: - - '374' + - '1020' openai-version: - '2020-10-01' - x-openai-proxy-wasm: - - v0.1 - x-ratelimit-limit-input-images: - - '50000' - x-ratelimit-limit-requests: - - '30000' - x-ratelimit-limit-tokens: - - '150000000' - x-ratelimit-remaining-input-images: - - '49999' - x-ratelimit-remaining-requests: - - '29999' - x-ratelimit-remaining-tokens: - - '149999220' - x-ratelimit-reset-input-images: - - 1ms - x-ratelimit-reset-requests: - - 2ms - x-ratelimit-reset-tokens: - - 0s - status: - code: 200 - message: OK -- request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '353' - Content-Type: - - application/json - Host: - - api.openai.com - method: POST - uri: https://api.openai.com/v1/chat/completions - response: - body: - string: "{\n \"id\": \"chatcmpl-DYJIoOeeAgj8TR5Pa2eURAXaOgFj1\",\n \"object\": - \"chat.completion\",\n \"created\": 1777069722,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n - \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": - {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": - 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_a7190374f3\"\n}\n" - headers: - Connection: - - keep-alive - Content-Type: - - application/json - Date: - - Fri, 24 Apr 2026 22:28:42 GMT - Server: + server: - cloudflare - Strict-Transport-Security: + strict-transport-security: - max-age=31536000; includeSubDomains; preload - Transfer-Encoding: + transfer-encoding: - chunked - X-Content-Type-Options: + x-content-type-options: - nosniff - access-control-expose-headers: - - X-Request-ID - content-length: - - '827' - openai-processing-ms: - - '395' - openai-version: - - '2020-10-01' x-openai-proxy-wasm: - v0.1 x-ratelimit-limit-input-images: - - '50000' + - '250000' x-ratelimit-limit-requests: - - '30000' + - '10000' x-ratelimit-limit-tokens: - - '150000000' + - '30000000' x-ratelimit-remaining-input-images: - - '49999' + - '249999' x-ratelimit-remaining-requests: - - '29999' + - '9999' x-ratelimit-remaining-tokens: - - '149999217' + - '29998451' x-ratelimit-reset-input-images: - - 1ms + - 0s x-ratelimit-reset-requests: - - 2ms + - 6ms x-ratelimit-reset-tokens: - - 0s + - 3ms status: code: 200 message: OK diff --git a/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/reasoning_completions.yaml b/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/reasoning_completions.yaml new file mode 100644 index 000000000..b279047b9 --- /dev/null +++ b/py/src/braintrust/integrations/openai/cassettes/1.71.0/btx/reasoning_completions.yaml @@ -0,0 +1,82 @@ +interactions: +- request: + body: '{"messages":[{"role":"user","content":"Look at this sequence: 2, 6, 12, + 20, 30. What is the pattern and what would be the formula for the nth term?\n"}],"model":"o4-mini","reasoning_effort":"medium"}' + headers: + accept: + - application/json + accept-encoding: + - gzip, deflate + connection: + - keep-alive + content-length: + - '199' + content-type: + - application/json + host: + - api.openai.com + method: POST + uri: https://api.openai.com/v1/chat/completions + response: + body: + string: "{\n \"id\": \"chatcmpl-ECrtSDJsX8y8zz1RLupVS9AJ6Kbq7\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735810,\n \"model\": \"o4-mini-2025-04-16\",\n + \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": + \"assistant\",\n \"content\": \"The five terms are \\r\\n 2, 6, 12, + 20, 30 \\r\\nTheir successive differences are \\r\\n 6\u22122=4, 12\u22126=6, + 20\u221212=8, 30\u221220=10 \\r\\nso the differences go up by 2 each time. + \ Hence it\u2019s a quadratic sequence. In fact one checks \\r\\n \\r\\n + a\u2099 = n\xB2 + n \\r\\n \\r\\ngives \\r\\n a\u2081 = 1 + 1 = 2 \\r\\n + a\u2082 = 4 + 2 = 6 \\r\\n a\u2083 = 9 + 3 = 12 \\r\\n a\u2084 = 16 + 4 + = 20 \\r\\n a\u2085 = 25 + 5 = 30 \\r\\n \\r\\nEquivalently, these are + the \u201Cpronic\u201D numbers n(n + 1).\",\n \"refusal\": null,\n + \ \"annotations\": []\n },\n \"finish_reason\": \"stop\"\n + \ }\n ],\n \"usage\": {\n \"prompt_tokens\": 41,\n \"completion_tokens\": + 642,\n \"total_tokens\": 683,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + {\n \"reasoning_tokens\": 448,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": + 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": + \"default\",\n \"system_fingerprint\": null\n}\n" + headers: + access-control-expose-headers: + - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive + content-length: + - '1234' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:30:16 GMT + openai-processing-ms: + - '5857' + openai-version: + - '2020-10-01' + server: + - cloudflare + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + transfer-encoding: + - chunked + x-content-type-options: + - nosniff + x-openai-proxy-wasm: + - v0.1 + x-ratelimit-limit-requests: + - '30000' + x-ratelimit-limit-tokens: + - '150000000' + x-ratelimit-remaining-requests: + - '29999' + x-ratelimit-remaining-tokens: + - '149999970' + x-ratelimit-reset-requests: + - 2ms + x-ratelimit-reset-tokens: + - 0s + status: + code: 200 + message: OK +version: 1 diff --git a/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/attachments.yaml b/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/attachments.yaml index cd292ccfd..591d4bbe2 100644 --- a/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/attachments.yaml +++ b/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/attachments.yaml @@ -1,155 +1,82 @@ interactions: - request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' + body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"Briefly + describe these attachments"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}},{"type":"file","file":{"filename":"blank.pdf","file_data":"data:application/pdf;base64,JVBERi0xLjAKMSAwIG9iago8PCAvVHlwZSAvQ2F0YWxvZyAvUGFnZXMgMiAwIFIgPj4KZW5kb2JqCjIgMCBvYmoKPDwgL1R5cGUgL1BhZ2VzIC9LaWRzIFszIDAgUl0gL0NvdW50IDEgPj4KZW5kb2JqCjMgMCBvYmoKPDwgL1R5cGUgL1BhZ2UgL1BhcmVudCAyIDAgUiAvTWVkaWFCb3ggWzAgMCA2MTIgNzkyXSA+PgplbmRvYmoKeHJlZgowIDQKMDAwMDAwMDAwMCA2NTUzNSBmIAowMDAwMDAwMDA5IDAwMDAwIG4gCjAwMDAwMDAwNTggMDAwMDAgbiAKMDAwMDAwMDExNSAwMDAwMCBuIAp0cmFpbGVyCjw8IC9TaXplIDQgL1Jvb3QgMSAwIFIgPj4Kc3RhcnR4cmVmCjE5MAolJUVPRgo="}}]}],"model":"gpt-4o","temperature":0.0}' headers: - Accept: + accept: - application/json - Accept-Encoding: + accept-encoding: - gzip, deflate - Connection: + connection: - keep-alive - Content-Length: - - '353' - Content-Type: + content-length: + - '888' + content-type: - application/json - Host: + host: - api.openai.com method: POST uri: https://api.openai.com/v1/chat/completions response: body: - string: "{\n \"id\": \"chatcmpl-DYJDAwb3iQUmh10cGiChqhDrcE9w3\",\n \"object\": - \"chat.completion\",\n \"created\": 1777069372,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n + string: "{\n \"id\": \"chatcmpl-ECrtC6p5r231hX1SognW6WQdvpMrJ\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735794,\n \"model\": \"gpt-4o-2024-08-06\",\n \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + \"assistant\",\n \"content\": \"The first attachment is a solid red + square image. The second attachment, \\\"blank.pdf,\\\" contains no readable + content or images.\",\n \"refusal\": null,\n \"annotations\": + []\n },\n \"logprobs\": null,\n \"finish_reason\": \"stop\"\n + \ }\n ],\n \"usage\": {\n \"prompt_tokens\": 495,\n \"completion_tokens\": + 25,\n \"total_tokens\": 520,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_a7190374f3\"\n}\n" + \"default\",\n \"system_fingerprint\": \"fp_684acb85fd\"\n}\n" headers: - Connection: - - keep-alive - Content-Type: - - application/json - Date: - - Fri, 24 Apr 2026 22:22:52 GMT - Server: - - cloudflare - Strict-Transport-Security: - - max-age=31536000; includeSubDomains; preload - Transfer-Encoding: - - chunked - X-Content-Type-Options: - - nosniff access-control-expose-headers: - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive content-length: - - '827' + - '931' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:29:55 GMT openai-processing-ms: - - '366' + - '780' openai-version: - '2020-10-01' - x-openai-proxy-wasm: - - v0.1 - x-ratelimit-limit-input-images: - - '50000' - x-ratelimit-limit-requests: - - '30000' - x-ratelimit-limit-tokens: - - '150000000' - x-ratelimit-remaining-input-images: - - '49999' - x-ratelimit-remaining-requests: - - '29999' - x-ratelimit-remaining-tokens: - - '149999220' - x-ratelimit-reset-input-images: - - 1ms - x-ratelimit-reset-requests: - - 2ms - x-ratelimit-reset-tokens: - - 0s - status: - code: 200 - message: OK -- request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '353' - Content-Type: - - application/json - Host: - - api.openai.com - method: POST - uri: https://api.openai.com/v1/chat/completions - response: - body: - string: "{\n \"id\": \"chatcmpl-DYJJ7VRAlgnQxGyeNNbl1mzwnfdft\",\n \"object\": - \"chat.completion\",\n \"created\": 1777069741,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n - \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": - {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": - 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_a7190374f3\"\n}\n" - headers: - Connection: - - keep-alive - Content-Type: - - application/json - Date: - - Fri, 24 Apr 2026 22:29:01 GMT - Server: + server: - cloudflare - Strict-Transport-Security: + strict-transport-security: - max-age=31536000; includeSubDomains; preload - Transfer-Encoding: + transfer-encoding: - chunked - X-Content-Type-Options: + x-content-type-options: - nosniff - access-control-expose-headers: - - X-Request-ID - content-length: - - '827' - openai-processing-ms: - - '555' - openai-version: - - '2020-10-01' x-openai-proxy-wasm: - v0.1 x-ratelimit-limit-input-images: - - '50000' + - '250000' x-ratelimit-limit-requests: - - '30000' + - '10000' x-ratelimit-limit-tokens: - - '150000000' + - '30000000' x-ratelimit-remaining-input-images: - - '49999' + - '249999' x-ratelimit-remaining-requests: - - '29999' + - '9999' x-ratelimit-remaining-tokens: - - '149999220' + - '29998451' x-ratelimit-reset-input-images: - - 1ms + - 0s x-ratelimit-reset-requests: - - 2ms + - 6ms x-ratelimit-reset-tokens: - - 0s + - 3ms status: code: 200 message: OK diff --git a/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/reasoning_completions.yaml b/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/reasoning_completions.yaml new file mode 100644 index 000000000..7332e2a20 --- /dev/null +++ b/py/src/braintrust/integrations/openai/cassettes/1.77.0/btx/reasoning_completions.yaml @@ -0,0 +1,80 @@ +interactions: +- request: + body: '{"messages":[{"role":"user","content":"Look at this sequence: 2, 6, 12, + 20, 30. What is the pattern and what would be the formula for the nth term?\n"}],"model":"o4-mini","reasoning_effort":"medium"}' + headers: + accept: + - application/json + accept-encoding: + - gzip, deflate + connection: + - keep-alive + content-length: + - '199' + content-type: + - application/json + host: + - api.openai.com + method: POST + uri: https://api.openai.com/v1/chat/completions + response: + body: + string: "{\n \"id\": \"chatcmpl-ECrtDoEsWx1AcgF0pI6EYTSr6m3U3\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735795,\n \"model\": \"o4-mini-2025-04-16\",\n + \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": + \"assistant\",\n \"content\": \"The terms 2, 6, 12, 20, 30,\u2026 are + the so-called \u201Cpronic\u201D or \u201Coblong\u201D numbers, i.e. \\n1\xB72, + 2\xB73, 3\xB74, 4\xB75, 5\xB76, \u2026 \\n\\nEquivalently the differences + go 4, 6, 8, 10,\u2026 = 2\xB72, 2\xB73, 2\xB74, 2\xB75,\u2026 so one shows + by induction that\\n\\n\u2003a\u2081 = 2, \\n\u2003a\u2099 = a\u2099\u208B\u2081 + + 2n \\n\\nand hence in closed\u2010form \\n\\n\u2003a\u2099 = n(n + 1).\",\n + \ \"refusal\": null,\n \"annotations\": []\n },\n \"finish_reason\": + \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": 41,\n \"completion_tokens\": + 876,\n \"total_tokens\": 917,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + {\n \"reasoning_tokens\": 704,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": + 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": + \"default\",\n \"system_fingerprint\": null\n}\n" + headers: + access-control-expose-headers: + - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive + content-length: + - '1115' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:30:03 GMT + openai-processing-ms: + - '7870' + openai-version: + - '2020-10-01' + server: + - cloudflare + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + transfer-encoding: + - chunked + x-content-type-options: + - nosniff + x-openai-proxy-wasm: + - v0.1 + x-ratelimit-limit-requests: + - '30000' + x-ratelimit-limit-tokens: + - '150000000' + x-ratelimit-remaining-requests: + - '29999' + x-ratelimit-remaining-tokens: + - '149999970' + x-ratelimit-reset-requests: + - 2ms + x-ratelimit-reset-tokens: + - 0s + status: + code: 200 + message: OK +version: 1 diff --git a/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/attachments.yaml b/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/attachments.yaml index fcb10443c..0dea4fc1b 100644 --- a/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/attachments.yaml +++ b/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/attachments.yaml @@ -1,155 +1,82 @@ interactions: - request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' + body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"Briefly + describe these attachments"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}},{"type":"file","file":{"filename":"blank.pdf","file_data":"data:application/pdf;base64,JVBERi0xLjAKMSAwIG9iago8PCAvVHlwZSAvQ2F0YWxvZyAvUGFnZXMgMiAwIFIgPj4KZW5kb2JqCjIgMCBvYmoKPDwgL1R5cGUgL1BhZ2VzIC9LaWRzIFszIDAgUl0gL0NvdW50IDEgPj4KZW5kb2JqCjMgMCBvYmoKPDwgL1R5cGUgL1BhZ2UgL1BhcmVudCAyIDAgUiAvTWVkaWFCb3ggWzAgMCA2MTIgNzkyXSA+PgplbmRvYmoKeHJlZgowIDQKMDAwMDAwMDAwMCA2NTUzNSBmIAowMDAwMDAwMDA5IDAwMDAwIG4gCjAwMDAwMDAwNTggMDAwMDAgbiAKMDAwMDAwMDExNSAwMDAwMCBuIAp0cmFpbGVyCjw8IC9TaXplIDQgL1Jvb3QgMSAwIFIgPj4Kc3RhcnR4cmVmCjE5MAolJUVPRgo="}}]}],"model":"gpt-4o","temperature":0.0}' headers: - Accept: + accept: - application/json - Accept-Encoding: + accept-encoding: - gzip, deflate - Connection: + connection: - keep-alive - Content-Length: - - '353' - Content-Type: + content-length: + - '888' + content-type: - application/json - Host: + host: - api.openai.com method: POST uri: https://api.openai.com/v1/chat/completions response: body: - string: "{\n \"id\": \"chatcmpl-DYJDVbftlpCB9lBrVG8o9PHCg8S7i\",\n \"object\": - \"chat.completion\",\n \"created\": 1777069393,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n + string: "{\n \"id\": \"chatcmpl-ECrt0LcL1SVu9I4v9TCBBXnVVMoX6\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735782,\n \"model\": \"gpt-4o-2024-08-06\",\n \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + \"assistant\",\n \"content\": \"The first attachment is a solid red + square image. The second attachment, \\\"blank.pdf,\\\" contains no readable + content or images.\",\n \"refusal\": null,\n \"annotations\": + []\n },\n \"logprobs\": null,\n \"finish_reason\": \"stop\"\n + \ }\n ],\n \"usage\": {\n \"prompt_tokens\": 495,\n \"completion_tokens\": + 25,\n \"total_tokens\": 520,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_a7190374f3\"\n}\n" + \"default\",\n \"system_fingerprint\": \"fp_684acb85fd\"\n}\n" headers: - Connection: - - keep-alive - Content-Type: - - application/json - Date: - - Fri, 24 Apr 2026 22:23:13 GMT - Server: - - cloudflare - Strict-Transport-Security: - - max-age=31536000; includeSubDomains; preload - Transfer-Encoding: - - chunked - X-Content-Type-Options: - - nosniff access-control-expose-headers: - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive content-length: - - '827' + - '931' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:29:43 GMT openai-processing-ms: - - '421' + - '785' openai-version: - '2020-10-01' - x-openai-proxy-wasm: - - v0.1 - x-ratelimit-limit-input-images: - - '50000' - x-ratelimit-limit-requests: - - '30000' - x-ratelimit-limit-tokens: - - '150000000' - x-ratelimit-remaining-input-images: - - '49999' - x-ratelimit-remaining-requests: - - '29999' - x-ratelimit-remaining-tokens: - - '149999220' - x-ratelimit-reset-input-images: - - 1ms - x-ratelimit-reset-requests: - - 2ms - x-ratelimit-reset-tokens: - - 0s - status: - code: 200 - message: OK -- request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '353' - Content-Type: - - application/json - Host: - - api.openai.com - method: POST - uri: https://api.openai.com/v1/chat/completions - response: - body: - string: "{\n \"id\": \"chatcmpl-DYJJTXUBwXopBlkUivMWAMm1eWQ2u\",\n \"object\": - \"chat.completion\",\n \"created\": 1777069763,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n - \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": - {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": - 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_a7190374f3\"\n}\n" - headers: - Connection: - - keep-alive - Content-Type: - - application/json - Date: - - Fri, 24 Apr 2026 22:29:23 GMT - Server: + server: - cloudflare - Strict-Transport-Security: + strict-transport-security: - max-age=31536000; includeSubDomains; preload - Transfer-Encoding: + transfer-encoding: - chunked - X-Content-Type-Options: + x-content-type-options: - nosniff - access-control-expose-headers: - - X-Request-ID - content-length: - - '827' - openai-processing-ms: - - '589' - openai-version: - - '2020-10-01' x-openai-proxy-wasm: - v0.1 x-ratelimit-limit-input-images: - - '50000' + - '250000' x-ratelimit-limit-requests: - - '30000' + - '10000' x-ratelimit-limit-tokens: - - '150000000' + - '30000000' x-ratelimit-remaining-input-images: - - '49999' + - '249999' x-ratelimit-remaining-requests: - - '29999' + - '9999' x-ratelimit-remaining-tokens: - - '149999217' + - '29998450' x-ratelimit-reset-input-images: - - 1ms + - 0s x-ratelimit-reset-requests: - - 2ms + - 6ms x-ratelimit-reset-tokens: - - 0s + - 3ms status: code: 200 message: OK diff --git a/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/reasoning_completions.yaml b/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/reasoning_completions.yaml new file mode 100644 index 000000000..1bf6dff77 --- /dev/null +++ b/py/src/braintrust/integrations/openai/cassettes/1.92.0/btx/reasoning_completions.yaml @@ -0,0 +1,78 @@ +interactions: +- request: + body: '{"messages":[{"role":"user","content":"Look at this sequence: 2, 6, 12, + 20, 30. What is the pattern and what would be the formula for the nth term?\n"}],"model":"o4-mini","reasoning_effort":"medium"}' + headers: + accept: + - application/json + accept-encoding: + - gzip, deflate + connection: + - keep-alive + content-length: + - '199' + content-type: + - application/json + host: + - api.openai.com + method: POST + uri: https://api.openai.com/v1/chat/completions + response: + body: + string: "{\n \"id\": \"chatcmpl-ECrt1nHs6K3Li9SHoEj6fXW9doI7C\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735783,\n \"model\": \"o4-mini-2025-04-16\",\n + \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": + \"assistant\",\n \"content\": \"The terms are the \u201Cpronic\u201D + or \u201Coblong\u201D numbers: \\n2=1\xB72, 6=2\xB73, 12=3\xB74, 20=4\xB75, + 30=5\xB76,\u2026 \\n\\nIf you let n start at 1 (so a\u2081=2, a\u2082=6, + \u2026), then \\n\u2003a\u2099 = n\xB7(n+1) = n\xB2 + n.\",\n \"refusal\": + null,\n \"annotations\": []\n },\n \"finish_reason\": \"stop\"\n + \ }\n ],\n \"usage\": {\n \"prompt_tokens\": 41,\n \"completion_tokens\": + 816,\n \"total_tokens\": 857,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + {\n \"reasoning_tokens\": 704,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": + 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": + \"default\",\n \"system_fingerprint\": null\n}\n" + headers: + access-control-expose-headers: + - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive + content-length: + - '969' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:29:49 GMT + openai-processing-ms: + - '6002' + openai-version: + - '2020-10-01' + server: + - cloudflare + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + transfer-encoding: + - chunked + x-content-type-options: + - nosniff + x-openai-proxy-wasm: + - v0.1 + x-ratelimit-limit-requests: + - '30000' + x-ratelimit-limit-tokens: + - '150000000' + x-ratelimit-remaining-requests: + - '29999' + x-ratelimit-remaining-tokens: + - '149999970' + x-ratelimit-reset-requests: + - 2ms + x-ratelimit-reset-tokens: + - 0s + status: + code: 200 + message: OK +version: 1 diff --git a/py/src/braintrust/integrations/openai/cassettes/latest/btx/attachments.yaml b/py/src/braintrust/integrations/openai/cassettes/latest/btx/attachments.yaml index 213e6f1c8..ec8958022 100644 --- a/py/src/braintrust/integrations/openai/cassettes/latest/btx/attachments.yaml +++ b/py/src/braintrust/integrations/openai/cassettes/latest/btx/attachments.yaml @@ -1,7 +1,7 @@ interactions: - request: - body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"What - color is this image?"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}}]}],"model":"gpt-4o-mini","temperature":0.0}' + body: '{"messages":[{"role":"system","content":"you are a helpful assistant"},{"role":"user","content":[{"type":"text","text":"Briefly + describe these attachments"},{"type":"image_url","image_url":{"url":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DwHwAFBQIAX8jx0gAAAABJRU5ErkJggg=="}},{"type":"file","file":{"filename":"blank.pdf","file_data":"data:application/pdf;base64,JVBERi0xLjAKMSAwIG9iago8PCAvVHlwZSAvQ2F0YWxvZyAvUGFnZXMgMiAwIFIgPj4KZW5kb2JqCjIgMCBvYmoKPDwgL1R5cGUgL1BhZ2VzIC9LaWRzIFszIDAgUl0gL0NvdW50IDEgPj4KZW5kb2JqCjMgMCBvYmoKPDwgL1R5cGUgL1BhZ2UgL1BhcmVudCAyIDAgUiAvTWVkaWFCb3ggWzAgMCA2MTIgNzkyXSA+PgplbmRvYmoKeHJlZgowIDQKMDAwMDAwMDAwMCA2NTUzNSBmIAowMDAwMDAwMDA5IDAwMDAwIG4gCjAwMDAwMDAwNTggMDAwMDAgbiAKMDAwMDAwMDExNSAwMDAwMCBuIAp0cmFpbGVyCjw8IC9TaXplIDQgL1Jvb3QgMSAwIFIgPj4Kc3RhcnR4cmVmCjE5MAolJUVPRgo="}}]}],"model":"gpt-4o","temperature":0.0}' headers: accept: - application/json @@ -10,7 +10,7 @@ interactions: connection: - keep-alive content-length: - - '353' + - '888' content-type: - application/json host: @@ -19,17 +19,19 @@ interactions: uri: https://api.openai.com/v1/chat/completions response: body: - string: "{\n \"id\": \"chatcmpl-E9C57hpRZQvVHXZzjSoamjadJRubp\",\n \"object\": - \"chat.completion\",\n \"created\": 1785860101,\n \"model\": \"gpt-4o-mini-2024-07-18\",\n + string: "{\n \"id\": \"chatcmpl-ECrs5s1LzduSb4pAfTnW7GMMJdYfq\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735725,\n \"model\": \"gpt-4o-2024-08-06\",\n \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": - \"assistant\",\n \"content\": \"The image is red.\",\n \"refusal\": - null,\n \"annotations\": []\n },\n \"logprobs\": null,\n - \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": - 8522,\n \"completion_tokens\": 5,\n \"total_tokens\": 8527,\n \"prompt_tokens_details\": - {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + \"assistant\",\n \"content\": \"The first attachment is a solid red + square image. The second attachment, \\\"blank.pdf,\\\" contains no readable + content or images.\",\n \"refusal\": null,\n \"annotations\": + []\n },\n \"logprobs\": null,\n \"finish_reason\": \"stop\"\n + \ }\n ],\n \"usage\": {\n \"prompt_tokens\": 495,\n \"completion_tokens\": + 25,\n \"total_tokens\": 520,\n \"prompt_tokens_details\": {\n \"cached_tokens\": + 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": {\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": - \"default\",\n \"system_fingerprint\": \"fp_e7eb9f2bc2\"\n}\n" + \"default\",\n \"system_fingerprint\": \"fp_684acb85fd\"\n}\n" headers: access-control-expose-headers: - X-Request-ID @@ -38,13 +40,13 @@ interactions: connection: - keep-alive content-length: - - '827' + - '931' content-type: - application/json date: - - Tue, 04 Aug 2026 16:15:01 GMT + - Fri, 14 Aug 2026 19:28:46 GMT openai-processing-ms: - - '1244' + - '815' openai-version: - '2020-10-01' server: @@ -58,23 +60,23 @@ interactions: x-openai-proxy-wasm: - v0.1 x-ratelimit-limit-input-images: - - '50000' + - '250000' x-ratelimit-limit-requests: - - '30000' + - '10000' x-ratelimit-limit-tokens: - - '150000000' + - '30000000' x-ratelimit-remaining-input-images: - - '49999' + - '249999' x-ratelimit-remaining-requests: - - '29999' + - '9999' x-ratelimit-remaining-tokens: - - '149999217' + - '29998450' x-ratelimit-reset-input-images: - - 1ms + - 0s x-ratelimit-reset-requests: - - 2ms + - 6ms x-ratelimit-reset-tokens: - - 0s + - 3ms status: code: 200 message: OK diff --git a/py/src/braintrust/integrations/openai/cassettes/latest/btx/reasoning_completions.yaml b/py/src/braintrust/integrations/openai/cassettes/latest/btx/reasoning_completions.yaml new file mode 100644 index 000000000..6042fec06 --- /dev/null +++ b/py/src/braintrust/integrations/openai/cassettes/latest/btx/reasoning_completions.yaml @@ -0,0 +1,78 @@ +interactions: +- request: + body: '{"messages":[{"role":"user","content":"Look at this sequence: 2, 6, 12, + 20, 30. What is the pattern and what would be the formula for the nth term?\n"}],"model":"o4-mini","reasoning_effort":"medium"}' + headers: + accept: + - application/json + accept-encoding: + - gzip, deflate + connection: + - keep-alive + content-length: + - '199' + content-type: + - application/json + host: + - api.openai.com + method: POST + uri: https://api.openai.com/v1/chat/completions + response: + body: + string: "{\n \"id\": \"chatcmpl-ECrs6kqMBMp3PWZK6E2pPAARUXMAR\",\n \"object\": + \"chat.completion\",\n \"created\": 1786735726,\n \"model\": \"o4-mini-2025-04-16\",\n + \ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\": + \"assistant\",\n \"content\": \"Each term is the product of two consecutive + integers. In fact for n=1,2,3,\u2026 you get\\n\\na\u2081=1\xB72=2, \\na\u2082=2\xB73=6, + \ \\na\u2083=3\xB74=12, \\na\u2084=4\xB75=20, \\na\u2085=5\xB76=30,\u2026\\n\\nSo + the nth term is \\na\u2099 = n\xB7(n + 1) \\n\\nEquivalently, a\u2099 = + n\xB2 + n.\",\n \"refusal\": null,\n \"annotations\": []\n },\n + \ \"finish_reason\": \"stop\"\n }\n ],\n \"usage\": {\n \"prompt_tokens\": + 41,\n \"completion_tokens\": 449,\n \"total_tokens\": 490,\n \"prompt_tokens_details\": + {\n \"cached_tokens\": 0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\": + {\n \"reasoning_tokens\": 320,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\": + 0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\": + \"default\",\n \"system_fingerprint\": null\n}\n" + headers: + access-control-expose-headers: + - X-Request-ID + - CF-Ray + - CF-Ray + connection: + - keep-alive + content-length: + - '1022' + content-type: + - application/json + date: + - Fri, 14 Aug 2026 19:28:50 GMT + openai-processing-ms: + - '3441' + openai-version: + - '2020-10-01' + server: + - cloudflare + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + transfer-encoding: + - chunked + x-content-type-options: + - nosniff + x-openai-proxy-wasm: + - v0.1 + x-ratelimit-limit-requests: + - '30000' + x-ratelimit-limit-tokens: + - '150000000' + x-ratelimit-remaining-requests: + - '29999' + x-ratelimit-remaining-tokens: + - '149999972' + x-ratelimit-reset-requests: + - 2ms + x-ratelimit-reset-tokens: + - 0s + status: + code: 200 + message: OK +version: 1