Conversation
BREAKING CHANGE: `ToolInputSchema::from_root_schema()` renamed to `from_schema()` and now accepts `&schemars::Schema` instead of `&schemars::schema::RootSchema`, which was removed in schemars 1.0. Schemars 1.x generates JSON Schema Draft 2020-12 by default (using `$defs` instead of `definitions`). All `#[derive(JsonSchema)]` usage across the workspace is compatible without changes. Bumps workspace version to 0.4.0.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6 +/- ##
=======================================
Coverage 88.61% 88.61%
=======================================
Files 101 101
Lines 23022 23019 -3
=======================================
- Hits 20401 20399 -2
+ Misses 2621 2620 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
Summary
schemarsfrom 0.8 to 1.2 (JSON Schema Draft 2020-12)ToolInputSchema::from_root_schema()tofrom_schema()accepting&schemars::Schema(theRootSchematype was removed in schemars 1.0)definitionskey (schemars 1.x only uses$defs)Breaking changes
ToolInputSchema::from_root_schema(&schemars::schema::RootSchema)→ToolInputSchema::from_schema(&schemars::Schema)(behindschemarsfeature flag inmixtape-anthropic-sdk)Test plan
cargo check --workspace --all-featurespassescargo test --workspace --all-features)#[derive(JsonSchema)]usage (87+ structs/enums) compiles without changesschema_for!()inmixtape-core::Tool::input_schema()works with new return type