Repository navigation
feat(custom-models): add CustomModel.derived_capabilities; release 0.3.1 - #20
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Customers on 0.3.0 hit
capabilities.0 Input should be 'tool_calling', 'vision', 'embedding' or 'reasoning'on custom-model get/refresh/list for vision models, because graphn-cp started returning architecture-derived capabilities (image_input,video_input,thinking).That is fixed in the API (voltagepark/takao#3678, live in prod, OpenAPI 0.38.0):
capabilitiesstays within theCapabilityenum, and the full set moved to a new open field,derived_capabilities. Verified against prod with this repo's 0.3.0 on a Qwen2-VL model: get/refresh/list succeed, and the pre-fix response shape still raises the original error.This PR exposes the new field as a typed attribute and releases 0.3.1. No customer needs it to be unblocked.
What changes
CustomModel.derived_capabilities: list[str] | None(open-ended;Nonefrom control planes before 0.38.0).Capabilitystays aLiteral, matching the spec.asyncio_default_fixture_loop_scope = "function"in the pytest config. CI now installs pytest 9.2.0, where pytest-asyncio's "unset" warning plusfilterwarnings = erroraborted the run with an INTERNALERROR before any test ran;mainwould fail the same way.functionis the scope the tests already use.pyproject.tomland_version.py, plus the CHANGELOG section, so merging auto-tagsv0.3.1and publishes to PyPI.How to verify
ruff check src tests,ruff format --check src tests,pytest: 111 pass.derived_capabilities(older control plane) yieldsNone.Companion
derived_capabilities)