Open Source AI Agent Frameworks Compared: Build on ERPNext
An open source AI agent uses a language model to plan and carry out tasks through tools, and its code is under a licence that lets you run, study, change and self-host it. Here are the leading frameworks as of 15 November 2026, and how we build agents directly on ERPNext.
- Open source agent frameworks compared (15 Nov 2026)
- 9
- AutoGen status per its repo: archived, not for production
- Archived
- Models FinByz AI can call through LiteLLM
- 100+
- Licence of our FinByz AI Frappe app
- GPL-3.0
The basics
What is an open source AI agent?
In short
An open source AI agent is software that uses a language model to plan and carry out tasks through tools, where the agent's code is published under a licence that lets you run, study, change and self-host it. For a business, that means you can put the agent on your own server, next to your ERP data, and decide exactly which model it calls and what it's allowed to do.
Every agent has four working parts. A framework is just the code that wires them together and runs the loop.
A model
Tools
Memory
Rules
"Open source" applies to that code. According to the Open Source Initiative, an open source licence must allow free redistribution, access to source code and the right to make derived works, with no discrimination against fields of use. That last point matters. A licence that bars you from running a hosted service or removing a logo is source-available, not open source, even if the code is on GitHub.
The model is a separate question. You can run an open source agent framework with a closed model such as GPT or Claude, or with open-weight models on your own hardware. In October 2024 the OSI published a separate Open Source AI Definition 1.0 for models, because "open weights" alone doesn't give you the training data information or code needed to rebuild a model.
Open source vs closed agent platforms
| Question | Open source framework, self-hosted | Closed, hosted agent platform |
|---|---|---|
| Where do prompts and ERP data go? | Your server, plus whichever model API you choose | The vendor's cloud |
| Can you swap the model? | Yes, usually by changing a setting | Only to models the vendor offers |
| Can you read the agent's code? | Yes | No |
| Who patches and upgrades it? | Your team or your partner | The vendor |
| Lock-in risk | Low, the code stays with you | High if workflows live only on the platform |
| Effort to start | Higher, you build and host it | Lower, sign up and configure |
Why open source
Why do businesses choose open source AI agents?
Licence cost is rarely the real reason. Control is. Finance, HR and operations data sits in the ERP, and most owners we talk to want to know exactly where a prompt containing customer balances or salaries ends up.
Control of your data
Audit you can show
Portability
Comparison
Which open source AI agent frameworks lead in 2026?
Here are the frameworks that come up most in our projects and in public comparisons. Licences and maintenance status are taken from each project's GitHub repository on 15 November 2026; star counts are rounded and change daily.
| Framework | Maintainer | Licence | Style | Good fit for | GitHub stars |
|---|---|---|---|---|---|
| LangGraph | LangChain | MIT | Graph of steps with saved state, pause and resume | Long-running business processes that need human approval mid-way | ~45k |
| CrewAI | CrewAI Inc. | MIT | Role-based “crews” of agents plus event-driven flows | Teams of specialised agents (researcher, writer, reviewer) | ~61k |
| Microsoft Agent Framework | Microsoft | MIT | Agents and multi-agent workflows in Python and .NET, MCP and A2A support | Microsoft-centred stacks; the successor to AutoGen | ~15k |
| OpenAI Agents SDK | OpenAI | MIT | Lightweight agents with handoffs, guardrails and tracing | Quick multi-agent prototypes; works with other providers too | ~31k |
| Google ADK | Apache-2.0 | Code-first toolkit for building, evaluating and deploying agents | Teams on Google Cloud and Gemini | ~22k | |
| Pydantic AI | Pydantic | MIT | Type-checked agents with structured outputs | Python teams who want validated, typed responses | ~21k |
| smolagents | Hugging Face | Apache-2.0 | Minimal agents that write and run code as their actions | Research, data tasks, open-weight models | ~30k |
| LlamaIndex | LlamaIndex | MIT | Agents built around document parsing and retrieval | Document-heavy work: contracts, invoices, policies | ~53k |
| Agno | Agno | Apache-2.0 | Agent runtime with memory, knowledge and a control plane | Teams wanting a ready runtime rather than a library | ~43k |
What happened to AutoGen?
Microsoft's AutoGen repository now says AutoGen is archived and no longer maintained, and it advises against production use. New projects are pointed to Microsoft Agent Framework, which has a 1.0 release and a migration guide from AutoGen. If an older proposal you've received is built on AutoGen, ask about the migration plan.
Platforms that look open source but aren't
Two popular tools often appear in "open source AI agent platform" lists. Both can be self-hosted and both are useful, but neither is open source in the OSI sense. Read the licence before you build a product on top of either.
Dify
Licensed under a modified Apache 2.0 that, among other conditions, needs a commercial licence to run it as a multi-tenant service.
n8n
Uses its own Sustainable Use License and calls itself fair-code. We build n8n AI agent workflows for clients too.
Selection
How do you choose the best AI agent framework?
Start from the business process, not the framework. We usually ask these questions, in this order.
- 1Where does the data live?If 80 percent of what the agent needs is in ERPNext, the agent should sit close to ERPNext and use its permissions, not copy data into a separate store.
- 2Does the process need a person to approve steps?Payments, credit notes and external emails do. Pick something that can pause, wait for a decision and resume. LangGraph and our own Workflow Builder are built for this.
- 3One agent or several?Most first projects need one agent with five or six tools. Multi-agent setups add cost and new ways to fail.
- 4Which models must it support?If data rules mean a local model, check that the framework works with an OpenAI-compatible endpoint or a router such as LiteLLM.
- 5Who will run it in two years?Check release activity, the licence and whether your team or partner knows the language. A framework with a quiet repository is a risk, as AutoGen users found out.
- 6How will you see what it did?You need traces of each model call and tool call, kept long enough for audit.
Our framework
How does FinByz build AI agents on ERPNext?
We built our agent framework as a Frappe app called FinByz AI. It's open source under GPL-3.0 and published on GitHub at github.com/finbyz/finbyzai, so it installs on any Frappe or ERPNext site with the usual bench get-app and install-app commands. We run it on our own ERP, which also serves the knowledge base behind the chatbot on this website.
Our design choice was simple: every part of an agent is a normal Frappe DocType. That means agents get ERPNext's roles, permissions, version history and REST API without extra work, and an administrator can see and change an agent from the Desk like any other record.
The building blocks
| DocType | What it holds | Why it matters |
|---|---|---|
| LLM Provider and LLM | Provider, model name, temperature, token limits; keys in encrypted password fields | Swap models without touching the agent. Requests go through LiteLLM, which supports 100+ models including local ones through Ollama |
| AI Agent | System message, agent type (ReAct, conversational, structured chat or a LangChain chain), linked LLM, tools, knowledge base, memory type, max iterations, output schema | One record defines one agent; change behaviour by editing a form |
| AI Tool | A Python function or provider built-in tool, its description and configuration schema, plus “requires confirmation” and “cost sensitive” flags | The agent can only call tools that are registered and enabled |
| Knowledge Base | Web links and sitemaps, uploaded PDF, DOCX or TXT files and text notes; chunked and embedded into a vector store | Answers are grounded in your own policies and documents |
| AI Conversation | Message history for each session | Context carries across turns and is kept for review |
Vector stores supported
- Pinecone
- Qdrant
- Supabase (pgvector)
- Chroma
Agents can also call other agents as tools, so a coordinator can pass a question to a finance agent or a document agent without a separate multi-agent framework. Under the hood the agent loop runs on LangChain and LangGraph, and traces can be sent to LangSmith for debugging.
Workflow Builder: where agents meet business rules
An agent that only chats isn't much use to an operations team. So the second half of FinByz AI is a Workflow Builder: a visual canvas at /workflow for record-based automations with triggers, conditions, actions and AI steps. Three parts of it do the safety work.
Human approval
Policy checks
Run history
A typical agent we set up
Take overdue receivables. The agent's ERPNext user has read access to Sales Invoice, Customer and Payment Entry, and nothing else. Its tools list overdue invoices for one customer, fetch the last three payment dates and draft a reminder in the customer's language. A workflow triggers it daily for invoices 15 days past due. The draft lands in an approval for the credit controller, who edits a line if needed and approves. Only then does the email go out.
What we see go wrong most often is the opposite: a single "run any query" tool with an admin login. It works in a demo and fails the first audit.
How-to
How do you build your first open source AI agent on ERPNext?
- 1Pick one processChoose one with clear inputs and a measurable result, such as reminder drafts, supplier invoice matching or answering staff questions about HR policy.
- 2Install the app on a test copyUse
bench get-appandbench --site <site> install-app finbyzaion a copy of your site, not production. - 3Set up an LLM Provider and LLMUse a cloud model to start, or point LiteLLM at a local model if data must stay on-premise.
- 4Create a dedicated ERPNext user and roleGive the agent the smallest set of DocType permissions it needs. Add User Permissions to limit it by company or territory.
- 5Register three to six narrow toolsAdd them as AI Tool records. Turn on “requires confirmation” for anything that writes.
- 6Add a Knowledge BaseOnly if the agent must follow your policies or SOPs.
- 7Create the AI AgentWrite a short system message, set max iterations and attach the tools.
- 8Wrap it in a workflow and run in shadow modeAdd an approval step, run it for two weeks and compare its drafts with what your team actually did.
- 9Go live on one teamReview a sample of runs every week, then widen access.
For the wider picture of governance and rollout, read our guide to enterprise AI agents and how to deploy them on ERP.
Limits
When should you not use an open source AI agent?
Agents aren't the right answer for every task, and open source adds work of its own.
- The rule is fixed. If the logic is "send a reminder at 15, 30 and 45 days", a normal ERPNext notification or dunning setup is cheaper and fully predictable.
- Nobody will own it. A self-hosted agent needs someone to patch dependencies, rotate keys and read the traces. If that person doesn't exist, a managed product may be safer.
- The data isn't clean. An agent working on duplicate customers and wrong ledger balances will produce confident, wrong drafts.
- The output can't be checked. If no one can tell whether the agent's answer is right, keep a person in the loop or don't automate it yet.
- Copyleft is a problem for you. FinByz AI and ERPNext are GPL-3.0. That's fine for running them in your business, but plan accordingly if you intend to distribute modified code as a product.
Security needs attention from day one. The OWASP Top 10 for Agentic Applications lists risks such as goal hijacking, tool misuse and privilege abuse, and emails or PDFs an agent reads can carry hidden instructions. Treat everything the agent reads as untrusted, and let permissions, not prompts, decide what it can do.
Next step
What should you do next?
Start small
List three processes where your team copies data between screens or writes the same email every day. Pick the one with the cleanest data and an obvious approver. That's your first agent.
FinByz has delivered 200+ projects in 15+ countries since 2016, and we build ERPNext AI agents with the same open source stack described here. Our AI consulting team can give you a second opinion on a framework choice, and our AI implementation service covers the first agent design and rollout.
Sources
- Open Source Initiative: The Open Source Definition
- Open Source Initiative: The Open Source AI Definition 1.0, October 2024
- LangGraph repository (MIT), Checked 15 November 2026
- CrewAI repository (MIT), Checked 15 November 2026
- OpenAI Agents SDK repository (MIT), Checked 15 November 2026
- Google ADK repository (Apache-2.0), Checked 15 November 2026
- Pydantic AI repository (MIT), Checked 15 November 2026
- smolagents repository (Apache-2.0), Checked 15 November 2026
- LlamaIndex repository (MIT), Checked 15 November 2026
- Agno repository (Apache-2.0), Checked 15 November 2026
- Microsoft Agent Framework repository (MIT), Checked 15 November 2026
- Microsoft AutoGen repository: archive notice
- Microsoft Learn: Migration guide from AutoGen to Microsoft Agent Framework
- Dify licence (modified Apache 2.0)
- n8n Sustainable Use License
- FinByz AI repository (GPL-3.0)
- LiteLLM documentation: supported providers
- Frappe Framework: REST API
- ERPNext: User Permissions
- OWASP GenAI Security Project: Top 10 for Agentic Applications for 2026



