Commit f7f5af0
chore (ai/mcp): add
<!--
Welcome to contributing to AI SDK! We're excited to see your changes.
We suggest you read the following contributing guide we've created
before submitting:
https://github.com/vercel/ai/blob/main/CONTRIBUTING.md
-->
## Background
Splits up #5972 into package changes
and updates to examples.
## Summary
Moves capabilities validation downstream to the request level instead of
the method level.
This PR adds a new private `assertCapability` method called at the
request level. This means our custom, lightweight client defaults strict
mode to true for tool listing and tool calling.
## Verification
<!--
For features & bugfixes.
Please explain how you *manually* verified that the change works
end-to-end as expected (independent of automated tests).
Remove the section if it's not needed (e.g. for docs).
-->
## Tasks
<!--
This task list is intended to help you keep track of what you need to
do.
Feel free to add tasks and remove unnecessary tasks as needed.
Please check if the PR fulfills the following requirements:
-->
- [x] Tests have been added / updated (for bug fixes / features)
- [ ] Documentation has been added / updated (for bug fixes / features)
- [x] A _patch_ changeset for relevant packages has been added (for bug
fixes / features - run `pnpm changeset` in the project root)
- [x] Formatting issues have been fixed (run `pnpm prettier-fix` in the
project root)
## Future Work
<!--
Feel free to mention things not covered by this PR that can be done in
future PRs.
Remove the section if it's not needed.
-->
## Related Issues
<!--
List related issues here, e.g. "Fixes #1234".
Remove the section if it's not needed.
-->assertCapability method to experimental MCP client (#6047)1 parent 28ad69e commit f7f5af0
File tree
3 files changed
+42
-13
lines changed- .changeset
- packages/ai/core/tool/mcp
3 files changed
+42
-13
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| 64 | + | |
| 65 | + | |
64 | 66 | | |
65 | 67 | | |
66 | 68 | | |
| 69 | + | |
| 70 | + | |
67 | 71 | | |
68 | 72 | | |
69 | 73 | | |
| |||
163 | 167 | | |
164 | 168 | | |
165 | 169 | | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
166 | 189 | | |
167 | 190 | | |
168 | 191 | | |
| |||
181 | 204 | | |
182 | 205 | | |
183 | 206 | | |
| 207 | + | |
| 208 | + | |
184 | 209 | | |
185 | 210 | | |
186 | 211 | | |
| |||
214 | 239 | | |
215 | 240 | | |
216 | 241 | | |
217 | | - | |
| 242 | + | |
218 | 243 | | |
219 | 244 | | |
220 | 245 | | |
| |||
235 | 260 | | |
236 | 261 | | |
237 | 262 | | |
238 | | - | |
239 | | - | |
240 | | - | |
241 | | - | |
242 | | - | |
243 | | - | |
244 | 263 | | |
245 | 264 | | |
246 | 265 | | |
| |||
261 | 280 | | |
262 | 281 | | |
263 | 282 | | |
264 | | - | |
265 | | - | |
266 | | - | |
267 | | - | |
268 | | - | |
269 | | - | |
270 | 283 | | |
271 | 284 | | |
272 | 285 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
85 | 96 | | |
86 | 97 | | |
87 | 98 | | |
| |||
0 commit comments