# smolagents

> Minimal agent library where agents write their actions as Python code.

## Facts
- **Category:** [Agent Frameworks](https://agentsearchengine.app/category/agent-frameworks)
- **Type:** Framework
- **Pricing:** Open source
- **GitHub stars:** 29,450
- **License:** Apache-2.0
- **Last repo activity:** 28 days ago (Aug 25, 2026)
- **Official site:** https://huggingface.co/docs/smolagents
- **Source code:** https://github.com/huggingface/smolagents
- **Listing on Agent Search Engine:** https://agentsearchengine.app/agents/smolagents
- **Data verified:** September 2026

## Best for
Small code-writing agents you want to read end to end before trusting them.

## Avoid if
You need a large integration ecosystem or managed orchestration out of the box.

## About smolagents
Hugging Face's small agent library. Its CodeAgent writes actions as executable Python rather than JSON tool calls, with sandboxed execution options; a conventional tool-calling agent is also included. It is model-agnostic and deliberately small, favouring a readable core over a large feature surface.

## Alternatives
smolagents sits in agent frameworks. Related tools indexed here:
- [langchain](https://agentsearchengine.app/agents/langchain) — The agent engineering platform. · Open source · Framework · 146k★ · Python · MIT · active 9 days ago
- [ruflo](https://agentsearchengine.app/agents/ruflo) — The leading agent meta-harness. Deploy intelligent multi-player swarms, coordinate autonomous workflows, and build conversational AI systems. · Open source · Framework · 72k★ · TypeScript · MIT · active 8 days ago
- [autogen](https://agentsearchengine.app/agents/autogen) — A programming framework for agentic AI; upstream is in maintenance mode. · Open source · Framework · 61k★ · Python · CC-BY-4.0 · active 5 months ago
- [crewAI](https://agentsearchengine.app/agents/crewai) — Framework for orchestrating role-playing, autonomous AI agents. By fostering collaborative intelligence, CrewAI empowers agents to work together seamlessly, tackling complex tasks. · Open source · Framework · 58k★ · Python · MIT · active 8 days ago
- [LlamaIndex](https://agentsearchengine.app/agents/llamaindex) — Framework for connecting LLMs and agents to your own documents and data. · Open source · Framework · 52k★ · MIT · active today
- [pydantic-ai](https://agentsearchengine.app/agents/pydantic-ai) — AI Agent Framework, the Pydantic way · Open source · Framework · 20k★ · Python · MIT · active 8 days ago
- [eliza](https://agentsearchengine.app/agents/eliza) — Open source agentic operating system · Open source · Framework · 19k★ · TypeScript · MIT · active 8 days ago
- [SuperAGI](https://agentsearchengine.app/agents/superagi) — <> SuperAGI - A dev-first open source autonomous AI agent framework. Enabling developers to build, manage & run useful autonomous agents quickly and reliably. · Open source · Framework · 18k★ · Python · MIT · active 1 year ago

---
Source: [Agent Search Engine](https://agentsearchengine.app) — an independent, hand-curated index of AI agents, MCP servers, and frameworks. Rankings are never sold; sponsored placements are labeled and never numbered. Full directory: https://agentsearchengine.app/llms-full.txt
