Skip to content

examples: document Python requirements for structured outputs - #805

Open
cloudgpuapp wants to merge 1 commit into
ollama:mainfrom
cloudgpuapp:docs/structured-outputs-python-versions
Open

cloudgpuapp wants to merge 1 commit into
ollama:mainfrom
cloudgpuapp:docs/structured-outputs-python-versions

Conversation

@cloudgpuapp

Copy link
Copy Markdown

Summary

Document the minimum Python versions of the three structured-output examples. The text examples evaluate list[T] at class definition time, which requires Python 3.9. The image example also evaluates str | None, which requires Python 3.10. Both failures happen before a request is sent.

This keeps the modern annotations discussed in #373 and makes the requirements visible where the examples are listed.

Verification

Ran all three unchanged scripts with mocked HTTP responses. Python 3.8.20 failed before requesting a response in all three. Python 3.9.6 ran both text examples but failed to load the image example. Python 3.10.22 ran all three. The successful runs checked the generated JSON schema and parsed the mocked responses. No Ollama server or model was started.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-21T21:44:57.009599Z 05b3f4c PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

This branch has not been deployed

No deployments
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.

1 participant