-
Notifications
You must be signed in to change notification settings - Fork 1.9k
bug: Warn about Azure OpenAI completions file-incompatibility #4048
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 17 commits
e37b0bc
91808ff
7cdf685
e6d4f06
9e0a102
5c45e72
cb6aa6b
17c6c25
63d7e6d
91b8337
a20068c
098f5ec
584a99d
61e4324
67c8371
caec194
ee4a419
b663951
aff00f3
22d356d
a10f9f1
f882fe8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| /Users/david/projects/pydantic-ai-claude-tools/learnings | ||
dsfaccini marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🚩 Potential bypass of document support check when In (Refers to line 1245) Was this helpful? React with 👍 or 👎 to provide feedback.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. IMO the for future reference, if we found these inconsistencies, having a single dataclass that uses property to validate combinations would be a better approach than checking multiple flags, since adding a check branch here would bloat this out further |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,95 @@ | ||
| interactions: | ||
| - request: | ||
| headers: | ||
| accept: | ||
| - application/json | ||
| accept-encoding: | ||
| - gzip, deflate, br | ||
| connection: | ||
| - keep-alive | ||
| content-length: | ||
| - '279' | ||
| content-type: | ||
| - application/json | ||
| host: | ||
| - api.openai.com | ||
| method: POST | ||
| parsed_body: | ||
| messages: | ||
| - content: | ||
| - text: What does this YAML describe? | ||
| type: text | ||
| - text: |- | ||
| -----BEGIN FILE id="a5bdf9" type="application/x-yaml"----- | ||
| name: test | ||
| version: 1.0.0 | ||
| -----END FILE id="a5bdf9"----- | ||
| type: text | ||
| role: user | ||
| model: gpt-4o | ||
| stream: false | ||
| uri: https://api.openai.com/v1/chat/completions | ||
| response: | ||
| headers: | ||
| access-control-expose-headers: | ||
| - X-Request-ID | ||
| alt-svc: | ||
| - h3=":443"; ma=86400 | ||
| connection: | ||
| - keep-alive | ||
| content-length: | ||
| - '1880' | ||
| content-type: | ||
| - application/json | ||
| openai-organization: | ||
| - user-grnwlxd1653lxdzp921aoihz | ||
| openai-processing-ms: | ||
| - '4743' | ||
| openai-project: | ||
| - proj_FYsIItHHgnSPdHBVMzhNBWGa | ||
| openai-version: | ||
| - '2020-10-01' | ||
| strict-transport-security: | ||
| - max-age=31536000; includeSubDomains; preload | ||
| transfer-encoding: | ||
| - chunked | ||
| parsed_body: | ||
| choices: | ||
| - finish_reason: stop | ||
| index: 0 | ||
| logprobs: null | ||
| message: | ||
| annotations: [] | ||
| content: |- | ||
| The provided YAML snippet is a basic descriptor for something labeled with the name "test" and a version number "1.0.0". Without additional context or accompanying fields, it's difficult to definitively say what specific application or resource this is describing. In a general sense, such a YAML configuration could be used for various purposes, including but not limited to: | ||
|
|
||
| 1. **Software/Application:** It could describe a software application or component called "test" with version 1.0.0. | ||
| 2. **Configuration Management:** It might be a part of a configuration management system for managing different versions of a service or application. | ||
| 3. **Package Information:** If used in a package management context, it might represent metadata for a package or library. | ||
| 4. **Service Definition:** It could represent a service or microservice within a larger system. | ||
|
|
||
| Each of these interpretations would depend on the broader context in which this YAML file is used. Further fields in the YAML file would provide more specificity about its purpose and functionality. | ||
| refusal: null | ||
| role: assistant | ||
| created: 1769199521 | ||
| id: chatcmpl-D1Hu5C2mqc2CPw07SQa6U7Ki9PF7X | ||
| model: gpt-4o-2024-08-06 | ||
| object: chat.completion | ||
| service_tier: default | ||
| system_fingerprint: fp_deacdd5f6f | ||
| usage: | ||
| completion_tokens: 202 | ||
| completion_tokens_details: | ||
| accepted_prediction_tokens: 0 | ||
| audio_tokens: 0 | ||
| reasoning_tokens: 0 | ||
| rejected_prediction_tokens: 0 | ||
| prompt_tokens: 57 | ||
| prompt_tokens_details: | ||
| audio_tokens: 0 | ||
| cached_tokens: 0 | ||
| total_tokens: 259 | ||
| status: | ||
| code: 200 | ||
| message: OK | ||
| version: 1 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,92 @@ | ||
| interactions: | ||
| - request: | ||
| headers: | ||
| accept: | ||
| - application/json | ||
| accept-encoding: | ||
| - gzip, deflate, br | ||
| connection: | ||
| - keep-alive | ||
| content-length: | ||
| - '308' | ||
| content-type: | ||
| - application/json | ||
| host: | ||
| - api.openai.com | ||
| method: POST | ||
| parsed_body: | ||
| messages: | ||
| - content: | ||
| - text: What type of configuration is this? | ||
| type: text | ||
| - text: |- | ||
| -----BEGIN FILE id="45a391" type="application/yaml"----- | ||
| version: "3" | ||
| services: | ||
| web: | ||
| image: nginx | ||
| -----END FILE id="45a391"----- | ||
| type: text | ||
| role: user | ||
| model: gpt-4o | ||
| stream: false | ||
| uri: https://api.openai.com/v1/chat/completions | ||
| response: | ||
| headers: | ||
| access-control-expose-headers: | ||
| - X-Request-ID | ||
| alt-svc: | ||
| - h3=":443"; ma=86400 | ||
| connection: | ||
| - keep-alive | ||
| content-length: | ||
| - '1218' | ||
| content-type: | ||
| - application/json | ||
| openai-organization: | ||
| - user-grnwlxd1653lxdzp921aoihz | ||
| openai-processing-ms: | ||
| - '1676' | ||
| openai-project: | ||
| - proj_FYsIItHHgnSPdHBVMzhNBWGa | ||
| openai-version: | ||
| - '2020-10-01' | ||
| strict-transport-security: | ||
| - max-age=31536000; includeSubDomains; preload | ||
| transfer-encoding: | ||
| - chunked | ||
| parsed_body: | ||
| choices: | ||
| - finish_reason: stop | ||
| index: 0 | ||
| logprobs: null | ||
| message: | ||
| annotations: [] | ||
| content: The configuration you provided is a YAML file for Docker Compose. Docker Compose is a tool used for defining | ||
| and running multi-container Docker applications. In this specific configuration, the YAML file is specifying a | ||
| single service called `web`, which uses the `nginx` Docker image. The file starts with specifying the Compose | ||
| file version as "3", indicating the format version used for composing the services. | ||
| refusal: null | ||
| role: assistant | ||
| created: 1769190655 | ||
| id: chatcmpl-D1Fb52cAhS0I5T514KLWFLTvsJHYv | ||
| model: gpt-4o-2024-08-06 | ||
| object: chat.completion | ||
| service_tier: default | ||
| system_fingerprint: fp_a0e9480a2f | ||
| usage: | ||
| completion_tokens: 77 | ||
| completion_tokens_details: | ||
| accepted_prediction_tokens: 0 | ||
| audio_tokens: 0 | ||
| reasoning_tokens: 0 | ||
| rejected_prediction_tokens: 0 | ||
| prompt_tokens: 55 | ||
| prompt_tokens_details: | ||
| audio_tokens: 0 | ||
| cached_tokens: 0 | ||
| total_tokens: 132 | ||
| status: | ||
| code: 200 | ||
| message: OK | ||
| version: 1 |
Uh oh!
There was an error while loading. Please reload this page.