AI agents এখন research demos থেকে production systems-এ চলে এসেছে। 2026 সালের মধ্যে 60%-এর বেশি enterprise AI applications-এ agentic components অন্তর্ভুক্ত হবে বলে আশা করা হচ্ছে। কিন্তু scratch থেকে agents তৈরি করা - tool loops, state, memory, error handling, এবং multi-agent coordination পরিচালনা করা - জটিল। এখানেই frameworks কাজে আসে।
2026 সালে চারটি framework প্রভাবশালী: LangGraph, CrewAI, OpenAI Agents SDK, এবং Claude Agent SDK। প্রতিটি একই সমস্যার জন্য মৌলিকভাবে ভিন্ন পদ্ধতি গ্রহণ করে: LLMs-কে reason, plan, tools ব্যবহার, এবং collaborate করার ক্ষমতা দেওয়া।
এক নজরে
| দিক | LangGraph | CrewAI | OpenAI Agents SDK | Claude Agent SDK |
|---|---|---|---|---|
| নির্মাতা | LangChain | CrewAI Inc. | OpenAI | Anthropic |
| Architecture | Graph-based | Role-based | Handoff-based | Autonomous loop |
| দর্শন | সর্বোচ্চ নিয়ন্ত্রণ | Team collaboration | ন্যূনতম abstraction | Agent-কে computer দিন |
| ভাষা | Python, TypeScript | Python | Python | Python, TypeScript |
| Model support | যেকোনো (OpenAI, Claude, local) | যেকোনো | যেকোনো (নাম সত্ত্বেও) | শুধু Claude |
| GitHub stars | ~29k | ~40k | ~21k | ~6k |
| সেরা | Complex stateful workflows | Multi-agent specialization | Routing এবং triage | Coding এবং file-heavy tasks |
LangGraph: The Graph Builder
LangGraph agent workflows-কে directed cyclic graphs হিসেবে model করে। আপনি nodes (functions যা কাজ করে) এবং edges (তাদের মধ্যে transitions, ঐচ্ছিকভাবে conditional) define করেন। State graph-এর মধ্য দিয়ে প্রবাহিত হয় এবং checkpointing-এর মাধ্যমে persist হয়।
এটি সবচেয়ে explicit এবং controllable framework - আপনি প্রতিটি step নিজে wire করেন।
মূল ধারণাসমূহ
- StateGraph: typed state সহ graph definition
- Nodes: Python functions যা state transform করে
- Edges: nodes-এর মধ্যে connections, conditional হতে পারে
- Checkpointing: long-running workflows-এর জন্য built-in persistence
Code Example
from langgraph.graph import StateGraph, MessagesState, START, END from langchain_openai import ChatOpenAI llm = ChatOpenAI(model="gpt-4o") def call_agent(state: MessagesState): response = llm.invoke(state["messages"]) return {"messages": [response]} def should_continue(state: MessagesState): last = state["messages"][-1] if last.tool_calls: return "tools" return END def call_tools(state: MessagesState): # Execute tool calls and return results results = [] for tool_call in state["messages"][-1].tool_calls: result = execute_tool(tool_call) results.append(result) return {"messages": results} graph = StateGraph(MessagesState) graph.add_node("agent", call_agent) graph.add_node("tools", call_tools) graph.add_edge(START, "agent") graph.add_conditional_edges("agent", should_continue, {"tools": "tools", END: END}) graph.add_edge("tools", "agent") app = graph.compile() result = app.invoke({"messages": [{"role": "user", "content": "What's the weather?"}]})
শক্তিসমূহ
- প্রতিটি step এবং transition-এ সূক্ষ্ম নিয়ন্ত্রণ
- Built-in checkpointing এবং human-in-the-loop
- সম্পূর্ণ TypeScript parity
- যেকোনো LLM provider-এর সাথে কাজ করে
- Conditional branching এবং loops সহ complex workflows-এর জন্য সেরা
দুর্বলতাসমূহ
- শেখার curve খাড়া - graph theory concepts বুঝতে হবে
- সাধারণ use cases-এর জন্য verbose - একটি basic agent-এর জন্য অন্যান্য frameworks-এর তুলনায় বেশি boilerplate প্রয়োজন
- LangSmith ছাড়া graph flows debug করা চ্যালেঞ্জিং হতে পারে
মূল্য নির্ধারণ
Open-source (MIT)। LangSmith (managed observability platform)-এ production monitoring-এর জন্য paid tiers আছে।
CrewAI: The Team Assembler
CrewAI একটি মানবিক রূপক ব্যবহার করে: আপনি বিশেষজ্ঞ agents-এর একটি crew তৈরি করেন, প্রতিটির একটি role, goal, এবং backstory থাকে। Agents tools ব্যবহার করে tasks-এ collaborate করে, একটি process (sequential, hierarchical, বা consensual) দ্বারা সমন্বিত।
এটিকে একটি team hire করার মতো ভাবুন যেখানে প্রতিটি সদস্যের একটি নির্দিষ্ট job title এবং specialty আছে।
মূল ধারণাসমূহ
- Agent: role, goal, backstory, এবং tools সহ একটি persona
- Task: description, expected output, এবং assigned agent সহ একটি assignment
- Crew: একসাথে কাজ করা agents-এর একটি দল
- Process: execution strategy (sequential, hierarchical, consensual)
- Flow: একাধিক crews সংযুক্ত করার জন্য event-driven orchestration layer
Code Example
from crewai import Agent, Task, Crew, Process researcher = Agent( role="Senior Research Analyst", goal="Find comprehensive data about the given topic", backstory="You have 10 years of experience in technology research. " "You are thorough and always verify facts from multiple sources.", tools=[web_search_tool], verbose=True, ) writer = Agent( role="Technical Writer", goal="Create clear, engaging technical content", backstory="You write for a developer audience. " "Your articles are practical and include code examples.", tools=[file_tool], verbose=True, ) research_task = Task( description="Research the latest developments in WebAssembly in 2026. " "Focus on WASI, Component Model, and production use cases.", expected_output="A structured research document with key findings and sources.", agent=researcher, ) writing_task = Task( description="Write a blog post based on the research. " "Include code examples and Mermaid diagrams.", expected_output="A complete blog post in Markdown format.", agent=writer, context=[research_task], # Writer receives researcher's output ) crew = Crew( agents=[researcher, writer], tasks=[research_task, writing_task], process=Process.sequential, verbose=True, ) result = crew.kickoff() print(result.raw)
শক্তিসমূহ
- স্বজ্ঞাত role-based abstraction - বুঝতে সহজ
- 100+ built-in tool integrations
- Agents জুড়ে shared memory (short-term, long-term, entity)
- সবচেয়ে বড় community (~40k GitHub stars)
- একটি "manager" agent সহ hierarchical process যা delegate এবং validate করে
দুর্বলতাসমূহ
- LangGraph-এর তুলনায় কম সূক্ষ্ম নিয়ন্ত্রণ - আপনি roles define করেন, exact execution paths নয়
- Agents দ্বিমত পোষণ করলে hierarchical process অনির্দেশ্য হতে পারে
- Multi-agent conversations debug করা single-agent flows-এর চেয়ে কঠিন
মূল্য নির্ধারণ
Open-source core (free)। CrewAI Platform: $99/month (Teams) থেকে $120k/year (Enterprise)। মূল্য live crews এবং monthly executions-এর উপর ভিত্তি করে।
OpenAI Agents SDK: The Router
OpenAI Agents SDK (Swarm-এর spiritual successor) handoffs-এ মনোযোগ দেয় - agents conversations অন্যান্য specialized agents-এ transfer করে। এটি সবচেয়ে minimal framework: agents, tools, handoffs, এবং guardrails। এটুকুই।
মূল ধারণাসমূহ
- Agent: model + instructions + tools + handoffs
- Handoff: অন্য agent-এ transfer (LLM যে tool call করতে পারে সেভাবে modeled)
- Guardrail: agent-এর সাথে parallel-এ চলা input/output validation
- Runner: agent loop execute করে
- Tracing: সমস্ত LLM calls, tool invocations, এবং handoffs-এর জন্য built-in observability
Code Example
from agents import Agent, Runner, handoff, InputGuardrail, GuardrailFunctionOutput from pydantic import BaseModel class SafetyCheck(BaseModel): is_safe: bool reason: str async def content_safety(ctx, agent, input_text): result = await Runner.run( Agent(name="Safety", instructions="Check if input is safe. No PII."), input_text, context=ctx, ) output = SafetyCheck.model_validate_json(result.final_output) return GuardrailFunctionOutput( output_info=output, tripwire_triggered=not output.is_safe ) billing_agent = Agent( name="Billing Agent", instructions="You handle billing inquiries. Be precise with numbers.", tools=[lookup_invoice, process_payment], ) refund_agent = Agent( name="Refund Agent", instructions="You process refund requests. Always verify the order first.", tools=[lookup_order, issue_refund], ) triage_agent = Agent( name="Triage Agent", instructions="Route the customer to the right specialist. " "Ask clarifying questions if needed.", handoffs=[billing_agent, refund_agent], input_guardrails=[InputGuardrail(guardrail_function=content_safety)], ) result = await Runner.run(triage_agent, "I need a refund for order #4521") print(result.final_output) # The triage agent routes to refund_agent, which processes the refund
শক্তিসমূহ
- Clean handoff pattern - routing/triage workflows-এর জন্য স্বাভাবিক
- Guardrails execution-এর সাথে parallel-এ চলে (fail-fast, blocking নয়)
- Debugging-এর জন্য built-in tracing dashboard
- নাম সত্ত্বেও, non-OpenAI models support করে
- Minimal abstraction - বুঝতে এবং extend করতে সহজ
দুর্বলতাসমূহ
- LangGraph-এর তুলনায় কম mature state management
- কোনো built-in persistence বা checkpointing নেই
- Third-party tools-এর ecosystem ছোট
- Handoff-centric design প্রতিটি architecture-এ নাও মানাতে পারে
মূল্য নির্ধারণ
Open-source (MIT)। আপনি যে model ব্যবহার করেন তার জন্য per-token পরিশোধ করুন।
Claude Agent SDK: The Developer
Claude Agent SDK একটি ভিন্ন পদ্ধতি নেয়: workflows বা roles define করার পরিবর্তে, আপনি agent-কে tools-এর একটি set দেন এবং task সম্পন্ন করার উপায় বের করতে দেন। এটি একই autonomous loop ব্যবহার করে যা Claude Code-কে power করে - read, act, verify, iterate।
মূল ধারণাসমূহ
- query(): agent loop শুরু করার main entry point
- Built-in tools: Read, Write, Edit, Bash, Glob, Grep, WebSearch, WebFetch
- MCP-র মাধ্যমে custom tools: in-process MCP servers হিসেবে tools define করুন
- Sub-agents: বিশেষজ্ঞ agents যাদের কাছে parent delegate করতে পারে
- Sessions: একাধিক interactions জুড়ে context বজায় রাখুন
Code Example
import { tool, createSdkMcpServer, query } from "@anthropic-ai/claude-agent-sdk"; import { z } from "zod"; const searchDocs = tool( "search_docs", "Search the internal documentation for relevant information", { query: z.string().describe("Search query") }, async ({ query }) => { const results = await vectorStore.similaritySearch(query, 5); return { content: [{ type: "text", text: results.map(r => r.pageContent).join("\n\n") }], }; } ); const docsServer = createSdkMcpServer({ name: "docs", version: "1.0.0", tools: [searchDocs], }); for await (const message of query({ prompt: "Find how authentication works in our system and write a summary", options: { mcpServers: { docs: docsServer }, allowedTools: ["Read", "Glob", "Grep", "mcp__docs__search_docs"], }, })) { if (message.type === "result" && message.subtype === "success") { console.log(message.result); } }
শক্তিসমূহ
- First-class MCP integration - যেকোনো MCP server ecosystem-এ সংযুক্ত হন
- File operations, terminal, এবং web access-এর জন্য built-in tools
- বড় codebases-এর জন্য automatic context compaction
- Complex tasks-এর জন্য sub-agent parallelism
- Claude Code-এর মতো একই engine - আসল development workflows-এ battle-tested
দুর্বলতাসমূহ
- শুধু Claude models - কোনো multi-provider support নেই
- ছোট community সহ নতুন framework
- Python SDK-র জন্যও Node.js runtime প্রয়োজন
- LangGraph-এর তুলনায় কম explicit workflow control
মূল্য নির্ধারণ
Open-source। Standard Claude API token rates। Managed Agents (hosted version): token costs ছাড়াও $0.08 per session-hour।
কখন কোনটি বেছে নেবেন
LangGraph বেছে নিন যদি:
- আপনার workflow-এর প্রতিটি step-এ সুনির্দিষ্ট নিয়ন্ত্রণ প্রয়োজন হয়
- আপনার use case-এ complex conditional logic এবং loops জড়িত
- আপনার built-in persistence এবং human-in-the-loop checkpoints দরকার
- আপনাকে একই workflow-এ একাধিক LLM providers ব্যবহার করতে হবে
CrewAI বেছে নিন যদি:
- আপনি একটি স্বজ্ঞাত, role-based abstraction চান
- আপনার task-এ আলাদা specialties সহ একাধিক agents জড়িত
- আপনার agents-এর collaborate করা এবং পরস্পরকে context pass করা দরকার
- আপনি সবচেয়ে বড় community এবং সবচেয়ে বেশি built-in integrations চান
OpenAI Agents SDK বেছে নিন যদি:
- আপনার প্রাথমিক pattern হল conversations specialists-এর কাছে route করা
- আপনার guardrails দরকার যা parallel-এ input/output validate করে
- আপনি ন্যূনতম boilerplate সহ সবচেয়ে সরল abstraction চান
- Built-in tracing এবং observability গুরুত্বপূর্ণ
Claude Agent SDK বেছে নিন যদি:
- আপনার agents-কে code read, write, এবং execute করতে হবে
- আপনি first-class MCP server integration চান
- আপনার autonomous agents দরকার যা iterate এবং self-correct করে
- আপনি ইতিমধ্যে Claude ব্যবহার করছেন এবং সবচেয়ে গভীর integration চান
আপনি কি Frameworks Combine করতে পারেন?
হ্যাঁ। একটি সাধারণ pattern হল orchestration-এর জন্য একটি framework এবং individual agents-এর জন্য আরেকটি:
- LangGraph সামগ্রিক workflow graph-এর জন্য
- CrewAI একটি নির্দিষ্ট node-এর জন্য যেখানে multi-agent collaboration প্রয়োজন
- Claude Agent SDK MCP-র মাধ্যমে coding-related sub-tasks-এর জন্য
- OpenAI Agents SDK customer-facing triage এবং routing-এর জন্য
এই frameworks পারস্পরিকভাবে বিচ্ছিন্ন নয়। আপনার system-এর প্রতিটি অংশের জন্য যা মানানসই তা ব্যবহার করুন।
উপসংহার
প্রতিটি framework একটি স্পষ্ট বাজি ধরে:
- LangGraph control-এর জন্য optimize করে - আপনি প্রতিটি transition ঠিক করেন
- CrewAI collaboration-এর জন্য optimize করে - agents একটি team হিসেবে কাজ করে
- OpenAI Agents SDK simplicity-র জন্য optimize করে - minimal abstraction, clean handoffs
- Claude Agent SDK autonomy-র জন্য optimize করে - tools দিন এবং কাজ করতে দিন
সঠিক পছন্দ আপনার workflow, আপনার team, এবং আপনার বিদ্যমান stack-এর উপর নির্ভর করে। যেটি আপনার primary use case-এর সাথে মেলে সেটি বেছে নিন, ভালোভাবে শিখুন, এবং তাদের sweet spot-এ পৌঁছালে অন্যগুলো টেনে আনুন।