Impossibly is a lean Python library for building and orchestrating production AI agents. Declare tools as plain Python functions, keep a tiny dependency footprint, and skip the boilerplateโthe stable core ships with first-class multimodal support and built-in tracing so you can ship and debug impossibly fast.
- Stable core without surprise breakages.
- Ultra-lean footprint. No dependency bloat.
- Declare tools as plain Python functions.
- Multi-modal out of the box.
- Powerful agents without the boilerplate. It's time to build impossibly fast.
from impossibly import Agent, Graph, START, END
# Create an Impossibly agent
agent = Agent(
client=openai_client,
model="gpt-4o",
system_prompt="You are a helpful assistant",
tools=[web_search, calculator, database]
)
# Build a reasoning workflow
graph = Graph()
graph.add_edge(START, agent)
graph.add_edge(agent, END)
# Execute with autonomous reasoning
result = graph.invoke("Analyze current market trends and provide strategic recommendations")Define agents and the tools available to them in a single object instantiation:
- Native Multi-modal Support: Agents can work with both text and images straight out of the box
- Native Routing: Under-the-hood prompt-injection to ensure intelligent decision making and routing
- Custom Functions: Build functions simply with Python, then connect them as tools to your agents
Agents connected with a visual and intuitive workflow design:
- Conditional Logic: Route based on agent decisions
- Monitoring: Track agent performance and decisions
Seamless connection to external systems and data with native Python functions:
- User-Created Tools: Connect to any API, service, database and more with self-defined Python functions
- Own Your Tools: Core updates won't break your functionsโfull control and easy fixes
- Custom Tools: Build domain-specific capabilities with Python
Specialized agents working together on complex tasks:
- Role-Based Design: Each agent has a specific expertise
- Coordinated Workflows: Agents pass work between each other
- Quality Assurance: Multiple agents validate and improve results
- Scalable Architecture: Add agents as complexity grows
Explore practical implementations in the /examples directory:
- SQL Agent: Autonomous database analysis with iterative reasoning
- Research Agent: Multi-step research with source validation
- Conversational Agents: Context-aware dialogue systems
- Tool Agents: Specialized agents for specific tasks
- Mixture of Experts: Dynamic agent selection based on task requirements
# Base installation
pip install impossibly
# With specific LLM providers only
pip install "impossibly[openai]"
pip install "impossibly[anthropic]"
pip install "impossibly[all]"
# For development & contributions
pip install "impossibly[dev]"# Install with test dependencies
pip install -e ".[test]"
# Run test suite
impossibly run
# Run in Docker
impossibly run --dockerVisit impossibly.dev for:
- Complete API documentation
- Agentic AI tutorials and guides
- Framework comparisons (LangGraph, CrewAI, AutoGen)
- Real-world case studies
- Best practices for building reliable agents
- Discord: Join our community
- GitHub: Contribute to the project
- Documentation: Learn more at impossibly.dev
MIT License - see LICENSE for details.
Ready to build, orchestrate and scale AI agents impossibly fast? Start with the documentation and join the community pushing the boundaries of autonomous AI.
