Releases: huggingface/smolagents
Releases · huggingface/smolagents
v1.9.2
Full Changelog: v1.9.1...v1.9.2
v1.9.1
Bug Fixes 🐛
- fix tool code generation in case of multiline descriptions by @sysradium in #613
- Fix prompt for toolcalling agent and slightly update doc by @aymeric-roucher in #650
Full Changelog: v1.9.0...v1.9.1
v1.9.0
What's Changed
- Bump dev version: v1.9.0.dev0 by @albertvillanova in #544
- Small update to 'Introduction to Agents' docs format by @sergiopaniego in #548
- Doc grammar fix by @juanqui in #556
- Minor grammar correction by @doomspork in #528
- Fix multiagents docs by @derekalia in #549
- Fix managed agent example by @keetrap in #562
- Add authorized_imports in importFrom errors by @CalOmnie in #506
- chore: fix some typos by @zoupingshi in #557
- Minor fix in the guilded_tour docs by @touseefahmed96 in #578
- Add small readme to open Deep Research by @aymeric-roucher in #581
- Fixed Readme that is missing run.py call by @jsmidt in #585
- Fix 429 Client Error: Too Many Requests in CI test by @albertvillanova in #599
- Remove unused import in guided_tour docs by @albertvillanova in #600
- Test evaluate_delete by @albertvillanova in #519
- Move check_module_authorized out of import_module for use in get_safe_module by @CalOmnie in #507
- Test agent call with provide_run_summary by @albertvillanova in #513
- Create PromptTemplates typed dict by @albertvillanova in #547
- Refactor and test final answer prompts by @albertvillanova in #595
- Make question arg required in Open DeepResearch example by @albertvillanova in #617
- Remove unused api-base arg from Open DeepResearch example by @albertvillanova in #616
- corrected typo in README.md by @blakkd in #609
- MLX model support by @g-eoj in #300
- Add support for non-bool comparison operators. by @kc9zyz in #612
- docs: add Langfuse OpenTelemetry guide by @jannikmaierhoefer in #601
- Remove --prompt argument of instance instruction in README.md by @leeivan1007 in #632
- Fix CI quality check by removing trailing whitespace by @albertvillanova in #628
- Change math.pow -> pow by @Bilokin in #624
- Move plan user prompt to YAML and test text of plan prompts by @albertvillanova in #591
- Fix installation instructions in Open-DeepResearch README by @albertvillanova in #633
- Remove ManagedAgent from doc by @aymeric-roucher in #563
- Refactor operations count state setting by @albertvillanova in #631
- LiteLLMModel - detect message flatenning based on model information by @sysradium in #553
- Contribute to the documentation by @seanxuu in #630
- Adding default parameter for max_new_tokens in TransformersModel by @matfrei in #604
- Test evaluate_condition by @albertvillanova in #634
- Allow Gradio share parameter passthrough by @sysradium in #490
- Fix issue #635. Corrected installation instructions for open_deep_research by @nishaddeokar in #636
- Share full agents by @aymeric-roucher in #533
- Fix PlanningPromptTemplate and its docstring by @albertvillanova in #648
- Fix evaluate_condition for non-bool result by @albertvillanova in #638
- Removed reference to deprecated single_step in documentation by @crumbly-blue-cheese in #608
- Update README.md by @aymeric-roucher in #642
- Fix reference to Transformers in docs by @sergiopaniego in #643
- Fix for MLX Model when stop sequence is followed by any chars by @g-eoj in #623
- Allow for last_input_token_count=None by @Strings-RH in #644
New Contributors
- @juanqui made their first contribution in #556
- @doomspork made their first contribution in #528
- @CalOmnie made their first contribution in #506
- @zoupingshi made their first contribution in #557
- @NeuroWhAI made their first contribution in #576
- @jsmidt made their first contribution in #585
- @blakkd made their first contribution in #609
- @g-eoj made their first contribution in #300
- @kc9zyz made their first contribution in #612
- @jannikmaierhoefer made their first contribution in #601
- @leeivan1007 made their first contribution in #632
- @Bilokin made their first contribution in #624
- @seanxuu made their first contribution in #630
- @matfrei made their first contribution in #604
- @nishaddeokar made their first contribution in #636
- @crumbly-blue-cheese made their first contribution in #608
- @Strings-RH made their first contribution in #644
Full Changelog: v1.8.1...v1.9.0
v1.8.1
Bug Fixes 🐛
- Restore missing user prompt for initial facts by @NeuroWhAI in #576
- Bugfix: problems with the prompt refactoring of the planning step by @IlyaGusev in #564
- Do not pass system prompt to update plan and test plan prompts by @albertvillanova in #586
Full Changelog: v1.8.0...v1.8.1
v1.8.0
New features ⭐️
- We added visualization method to display the agent' structure as a tree! 🌳 by @aymeric-roucher in #470

- We vastly simplified managed agents in #484
- We've removed the ManagedAgents class: directly provide
name
anddescription
attributes to your agent to make it work as a managed agent ! Check an example here.
- We've removed the ManagedAgents class: directly provide
- We released Open Deep Research in #317!
Fixes 🔧
- Bump dev version: v1.8.0.dev0 by @albertvillanova in #451
- Add ToC and CLI docs by @merveenoyan in #455
- Fix link to Helium repository in README.md by @dross20 in #471
- Remove default max_tokens for all models by @albertvillanova in #475
- Improve Readme: shorter intro, VLMs, MCP, etc by @aymeric-roucher in #459
- Fix SpeechToTextTool new instance by @albertvillanova in #478
- Allow flatten_messages_as_text to be pushed via LiteLLMModel to fix Ollama integration by @sysradium in #406
- Fixed demo typo in README.md by @hanteed in #481
- Added
HfApiModel
import toweb browser example
by @sergiopaniego in #461 - Minor Fix tool push_to_hub by @keetrap in #460
- Fix link in README.md by @vanrohan in #496
- Fix undefined
step_number
in single_step run by @taha-yassine in #495 - Bump litellm to 1.60.2 (fixes #34) by @taha-yassine in #488
- Initialize step_number attribute by @albertvillanova in #497
- Suppress terminal logging in CI tests by @albertvillanova in #504
- Fix link in README.md by @Ryanb58 in #492
- Test PrintContainer by @albertvillanova in #515
- Add missing default tools to reference docs by @touseefahmed96 in #516
- Refactor prompts by @aymeric-roucher in #502
- Fix Typo by @rehanzo in #529
- Test HfApiModel call with custom_role_conversions by @albertvillanova in #517
- Set MAX_WHILE_ITERATIONS as module variable by @albertvillanova in #520
- add self.logger = logger for e2b_executor by @femto in #537
- Create simpler example open-deep-research by @aymeric-roucher in #534
- Support disabling logging to terminal by @albertvillanova in #512
- Fix installation with data files by @albertvillanova in #536
- Pin openinference-instrumentation-smolagents >= 0.1.4 by @albertvillanova in #535
- Delete prompts_path argument and use prompt_templates by @albertvillanova in #541
- Fix deprecation warning from importlib.resources.read_text by @albertvillanova in #543
- Delete non-exisiting accelerate extra by @albertvillanova in #539
- Fix some doc examples by @aymeric-roucher in #542
- Test E2B Executor by @albertvillanova in #540
New Contributors
- @dross20 made their first contribution in #471
- @sysradium made their first contribution in #406
- @hanteed made their first contribution in #481
- @vanrohan made their first contribution in #496
- @taha-yassine made their first contribution in #495
- @Ryanb58 made their first contribution in #492
- @rehanzo made their first contribution in #529
- @femto made their first contribution in #537
Full Changelog: v1.7.0...v1.8.0
v1.7.0
Main changes
Added commands to directly run agents from CLI: smolagent
and webagent
✨
- Make web browser agent example a CLI script by @merveenoyan in #416
- Add CLI for smolagents by @aymeric-roucher in #431
- Now you can run
smolagent "Your task!"
from CLI to directly call a smolagent. Try it!webagent "Find me a cheap train from Paris to Torino before Thursday"
orsmolagent "Who's the current director of La French Tech?"
- Now you can run
Gave a memory
to agents! 🧠
- Untangling Logging by @clefourrier in #316
- Test memory by @albertvillanova in #428
- This added a specific
memory
attribute to the agent! - We used this change to introduce nice functions like an
agent.replay()
function that replays the last run (based on the memories stored, so no further LLM calls)
- This added a specific
Other big improvements 💪
-
Improve code execution logs in case of error by showing print outputs by @aymeric-roucher in #446
- This makes sure that code execution outputs are stored to memory even when an error was raised later on. It should slightly improve the performance of
CodeAgents
- This makes sure that code execution outputs are stored to memory even when an error was raised later on. It should slightly improve the performance of
-
Update benchmark with Hub datasets by @albertvillanova in #412
- This adds storing of benchmarking outputs directly to the Hub. Moving forward, we'll make benchmarking even easier!
Fixes and small improvements
- Bump dev version: v1.7.0.dev0 by @albertvillanova in #390
- Fix return type of generator function in
Agent._run()
by @abidlabs in #409 - Update minimum Gradio version by @abidlabs in #408
- Support third-party Inference providers in
HfApiModel
by @julien-c in #422 - Minor fix for agent_from_any_llm.py example by @RolandJAAI in #423
- Fix
vlm_web_browser.py
example by @abidlabs in #410 - Fix regressions, refactor logging and improve replay function by @aymeric-roucher in #419
- Fix installation instruction for GradioUI in error message by @jank in #418
- Fix import from deleted logger module by @albertvillanova in #433
- Add web search tool and make prompt positional arg by @aymeric-roucher in #435
- Remove explicit model arg in HfApiModel - which wouldn't run without Pro by @sanjeed5 in #373
- Fix MultiStepAgent.planning_step message content by @albertvillanova in #437
- Fix and test MemoryStep by @albertvillanova in #432
- Fix get safe module by @antoinejeannot in #405
- Remove duplicate final_memory_step creation by @albertvillanova in #444
- Remove unused ChatMessageToolCall raw argument by @albertvillanova in #445
- Fix TransformersModel docstring by @August-murr in #447
- Test get_clean_message_list by @albertvillanova in #448
- Add web browser example to doc by @aymeric-roucher in #439
- Fix minor issue in e2b by @keetrap in #436
New Contributors
- @abidlabs made their first contribution in #409
- @julien-c made their first contribution in #422
- @August-murr made their first contribution in #447
Full Changelog: v1.6.0...v1.7.0
v1.6.0
What's Changed
- Bump version to 1.6.0.dev by @albertvillanova in #348
- Use transformers as optional dependency by @albertvillanova in #360
- Add pip install datasets to RAG example by @sanjeed5 in #371
- Update issue templates by @aymeric-roucher in #377
- TransformersModel auto-detects VLMs by @aymeric-roucher in #378
- Separate tree for Model docs is added by @touseefahmed96 in #382
- add kwargs to gradio launch by @tocab in #367
- Minor Fix in the example docs by @touseefahmed96 in #383
- Fix Extra planning by @bvantuan in #362
- Gradio chatbot: step duration, number, token count, support nested thoughts by @yvrjsharma in #384
- Gradio Chatbot looks much nicer than before! See below:

- Add Chinese translations for text-to-sql example by @FanwangM in #366
- Add Chinese translations for RAG by @FanwangM in #363
Qwen-2VL
->Qwen2-VL
model name typo fixed by @sergiopaniego in #349- chore: Fix Typo by Calling is_torch_available() in AgentAudio Class by @hironow in #379
- Additional parameters for openai client by @touseefahmed96 in #385
- DuckDuckGoSearchTool: add ddgs_kwargs parameter to constructor by @onukura in #372
- Fix final_answer issue in e2b_executor by @keetrap in #319
- Docs: Text to sql example - minor naming / dedupe by @GrahamTheCoder in #376
- Test import without extras by @albertvillanova in #370
- Add tool saving test by @aymeric-roucher in #389
- Fix blocking of os in authorized imports by @aymeric-roucher in #386
- Add test for DDGS Tool kwargs by @aymeric-roucher in #387
New Contributors
- @tocab made their first contribution in #367
- @bvantuan made their first contribution in #362
- @sergiopaniego made their first contribution in #349
- @hironow made their first contribution in #379
- @onukura made their first contribution in #372
- @GrahamTheCoder made their first contribution in #376
Full Changelog: v1.5.1...v1.6.0
v1.5.1
Bug Fixes 🐛
- Use transformers as optional dependency by @albertvillanova in #360
Full Changelog: v1.5.0...v1.5.1
v1.5.0
What's Changed
New Features 🚀
- Add VLM support by @merveenoyan in #220
Fixes 🐛
- refactor: update model type to ChatMessage in agent classes by @jank in #263
- Fixes AttributeError: 'CodeAgent' object has no attribute 'logger' #258 by @joaopauloschuler in #259
- Improve tool call argument parsing by @aymeric-roucher in #267
- Remove unused and undocumented
test_mode
parameter by @Wauplin in #273 - Fix Bug in from_langchain in tools.py by @RolandJAAI in #268
- Python interpreter: improve suggestions for possible mappings by @aymeric-roucher in #266
- Improve python executor's error logging by @aymeric-roucher in #275
- The use of BASE_PYTHON_TOOLS enables the use of compile, exec and eval by @tandiapa in #274
- Try first dunder method in evaluate_augassign by @albertvillanova in #285
- Add cool GIF of agent run inspection using Phoenix by @aymeric-roucher in #277
- Remove pickle5 package from E2BExecutor by @albertvillanova in #295
- Fuse stream and direct run calls by @clefourrier in #296
- minor fix for console in AgentLogger by @nbroad1881 in #303
- Add Azure OpenAI support by @vladiliescu in #282
- Fix arg passing to AgentExecutionError by @albertvillanova in #309
- refactor(models): restructure model parameter handling by @kingdomad in #227
- Local interpreter security: prevent builtins functions from being used if they have not been added as tools by @tandiapa in #299
- Support any and none tool types by @aymeric-roucher in #280
- Minor fix: adding a 60 seconds timeout to the visit webpage tool by @Killian-pit in #308
- Fix: source code inspection in interactive shells by @antoinejeannot in #281
- Refactor evaluate_augassign and test all operators by @albertvillanova in #313
- Unset temperature in models by @aymeric-roucher in #315
- Fix tool calls with LiteLLM and tool optional types by @aymeric-roucher in #318
- Multiple tool example by @touseefahmed96 in #293
- RAG on your huggingface_doc data using chromadb and groq api by @touseefahmed96 in #235
- Improve static tools initialization safety by @kingdomad in #324
- Append unused error message to memory by @albertvillanova in #325
Documentation and examples 📚
- Fix code examples with additional_args and num_ctx examples also in zh docs by @RolandJAAI in #260
- Update building_good_agents.md by @derekalia in #283
- Update guided_tour.md by @sanjeed5 in #287
- Added Hindi docs for smolagents by @keetrap in #279
- Update README and documentation to clarify Hub integrations with Gradio Spaces by @davidberenstein1957 in #306
- Update README.md fix quick demo code import bug by @Deng-Xian-Sheng in #327
- Add args to MultiStepAgent docstring by @albertvillanova in #332
- Fix MultiStepAgent docstring by @albertvillanova in #336
- Fix docstrings of models by @albertvillanova in #344
- docstring args for ToolCallingAgent, CodeAgent and ManagedAgent by @touseefahmed96 in #335
- Corrected tool examples in ToolCallingAgent system prompts by @RolandJAAI in #341
- Improve inference choice examples by @aymeric-roucher in #311
Maintenance 🏗️
- Add linter rules + apply make style by @Wauplin in #255
- Fix CI quality issue by @albertvillanova in #272
- Bump version to 1.5.0.dev by @aymeric-roucher in #256
- Make import time faster (optional deps + delay imports) by @Wauplin in #253
- Fix CI quality by @albertvillanova in #286
- Add huggingface-hub as required dependency by @albertvillanova in #288
- Make e2b optional dependency by @albertvillanova in #292
- Remove package json files by @albertvillanova in #314
- Update README instructions to run tests by @albertvillanova in #328
- Move torchvision to the torch extra by @nonsleepr in #297
New Contributors
- @tandiapa made their first contribution in #274
- @keetrap made their first contribution in #279
- @sanjeed5 made their first contribution in #287
- @davidberenstein1957 made their first contribution in #306
- @clefourrier made their first contribution in #296
- @nbroad1881 made their first contribution in #303
- @vladiliescu made their first contribution in #282
- @Killian-pit made their first contribution in #308
- @antoinejeannot made their first contribution in #281
- @touseefahmed96 made their first contribution in #293
- @Deng-Xian-Sheng made their first contribution in #327
- @nonsleepr made their first contribution in #297
- @merveenoyan made their first contribution in #220
Full Changelog: v1.4.1...v1.5.0
v1.4.1
What's Changed
New features 🚀
- Add support for MCP Servers tools as
ToolCollection
by @grll in #232- This enables using Model Context Protocol (MCP) servers, thus makes many, many tools compatible with
smolagents
: find a list on glama.ai or smithery.ai ✨
- This enables using Model Context Protocol (MCP) servers, thus makes many, many tools compatible with
- Allow passing kwargs to all models by @aymeric-roucher in #222
- Add Chinese translations for multi-agent example by @FanwangM in #246
Fixes 🐛
- Fix subpackage import vulnerability by @aymeric-roucher in #238
- Fix typo in building_good_agents.md by @rug in #193
- Align data types in example benchmark by @albertvillanova in #205
- Rename the split of the benchmark dataset from train to test by @albertvillanova in #216
- Fix vanilla model answer in example benchmark by @albertvillanova in #219
- Fix additional args in stream_to_gradio by @aymeric-roucher in #221
- Return textboxes on Gradio file upload errors by @stackviolator in #214
- Docs Bug - fix tool example with additional args by @RolandJAAI in #228
- Dead Link to Duck Duck Go search tool by @matterattetatte in #233
- Fix missing python modules in CodeAgent system prompt by @edbeeching in #226
Adjustments 🔧
- Clean makefile, pyproject.toml and CI by @Wauplin in #229
- Add resizeable option to Gradio UI component for better usabilty by @jank in #234
- Add trust_remote_code arg to TransformersModel by @aymeric-roucher in #240
- Make openai dependency optional by @albertvillanova in #236
- Remove dependency on _is_package_available from transformers by @albertvillanova in #247
- Update README.md by @aymeric-roucher in #208
- Set ollama context length in example to 8192 to make it work by @RolandJAAI in #252
- chore: unset console width, utilize auto detect feature by @simpletrontdip in #196
- Max length of "print" outputs as a parameter of an agent by @IlyaGusev in #209
- Small fixes in docs by @MoritzLaurer in #245
- Fixes before release by @aymeric-roucher in #254
New Contributors
- @rug made their first contribution in #193
- @RolandJAAI made their first contribution in #228
- @matterattetatte made their first contribution in #233
- @jank made their first contribution in #234
- @edbeeching made their first contribution in #226
- @Wauplin made their first contribution in #229
- @FanwangM made their first contribution in #246
- @simpletrontdip made their first contribution in #196
- @MoritzLaurer made their first contribution in #245
- @grll made their first contribution in #232
Full Changelog: v1.3.0...v1.4.1