Source: Introducing smolagents (Hugging Face blog)

Launch post for smolagents, the successor to transformers.agents, arguing for code agents and showing open models competitive with closed ones on the authors' agent benchmark.

Contents

Summary

Introduces smolagents as a deliberately small library replacing transformers.agents. Explains the agency spectrum, why code is a better action format than JSON, and shows benchmark results where code agents outperform tool-calling agents and open models approach closed ones.

Key claims

  • smolagents replaces the deprecated transformers.agents.
  • Core logic is about a thousand lines; first-class code agents; E2B sandboxing; Hub sharing of tools; any model via HF, inference APIs or LiteLLM.
  • On the authors’ benchmark, code agents beat tool-calling agents, and open models are competitive with leading closed models.

Feeds

Suggest changes →