New Features ✨
- Structured Generation in CodeAgent: Add optional support for structured outputs in
CodeAgent
, enabling more reliable and consistent generation patterns- Adding optional structured generation to CodeAgent by @akseljoonas in #1346
- Support for Streamable HTTP MCP Servers: Expand compatibility with new server types to support streamable HTTP MCP implementations
- Support Streamable HTTP MCP servers by @albertvillanova in #1384
- Run Results from
Agent.run()
: TheAgent.run()
method can now return aRunResult
object, providing richer metadata on agent execution- Agent.run() can return RunResult object by @aymeric-roucher in #1337
Security Enhancements 🔒
- Safer LocalPythonExecutor: Prevent indirect submodule access via attribute resolution, mitigating potential security risks in user-defined code
- Prevent submodules through indirect attribute access in LocalPythonExecutor by @albertvillanova in #1375
Enhancements 🛠️
- LocalPythonExecutor Enhancements:
- Support annotated assignments within class definition in LocalPythonExecutor by @albertvillanova in #1355
- Fix evaluate_class_def for Assign Attribute target in LocalPythonExecutor by @albertvillanova in #1357
- Support 'pass' statement in class definition in LocalPythonExecutor by @albertvillanova in #1358
- Refactor tests of LocalPythonExecutor by @albertvillanova in #1356
- Improve LaTeX rendering in GradioUI with extended delimiter support by @albertvillanova in #1387
Bug Fixes 🐛
- Streaming fixes
- Fix live streaming when generating planning steps by @FlorianVal in #1348
- Stop streaming if LiteLLM provide a finish_reason by @FlorianVal in #1350
- add api_base and api_keys to preparation of kwargs for generate stream by @FlorianVal in #1344
- Fix WebSearchTool validation error by @albertvillanova in #1367
- Fix smolagents benchmark by @aymeric-roucher in #1377
Documentation Improvements 📚
- Add example docs about using OpenRouter models by @albertvillanova in #1364
- Fix Llama model name in docs example by @SaiDunoyer in #1379
- fix typo in docstring in mcp_client.py by @grll in #1380
- Document use_structured_outputs_internally with version added by @albertvillanova in #1388
- Fix rendering of version added in docs by @albertvillanova in #1389
- Fix broken link in agentic RAG examples page by @vksx in #1363
Maintenance 🏗️
- Bump dev version: v1.17.0.dev0 by @albertvillanova in #1336
- Remove deprecated from_hf_api methods by @albertvillanova in #1351
New Contributors
- @FlorianVal made their first contribution in #1344
- @vksx made their first contribution in #1363
- @akseljoonas made their first contribution in #1346
- @SaiDunoyer made their first contribution in #1379
Full Changelog: v1.16.1...v1.17.0