dotsagent.io
Ngôn ngữ:Tiếng Việt
Framework · LlamaIndex

Tổng quan về LlamaIndex

LlamaIndex kết hợp các công cụ phân tích cú pháp và truy xuất tài liệu với Agent Workflows hướng sự kiện bằng Python và TypeScript. Workflows có thể tạm dừng để chờ dữ liệu từ con người, lưu state và chạy dưới dạng MCP server hoặc được triển khai lên LlamaCloud.

Phù hợp nhất với: Agent tập trung vào truy xuất, xử lý nhiều tài liệu để phân tích cú pháp, trích xuất và tìm kiếm trước khi hành động.

Thông tin chính

Đơn vị duy trì
LlamaIndex
Ngôn ngữ
Python, TypeScript
Giấy phép
MIT
Phiên bản mới nhất
llama-index 0.14.25 / llama-index-workflows 2.25.0 · 25 tháng 9, 2026
Repository
run-llama/llama_index · 52.380 sao
Tùy chọn chạy trên nền tảng lưu trữ
LlamaCloud via LlamaAgents (llamactl deploy)
Triển khai bằng llamactl; sau đó workflows được cung cấp tại api.cloud.llamaindex.ai.

Bắt đầu nhanh

Cài package, thiết lập thông tin xác thực, rồi chạy agent đơn giản nhất theo tài liệu chính thức. ID model sử dụng trong tài liệu có thể chưa được bật cho tài khoản của bạn.

Cài đặt
pip install llama-index-core llama-index-llms-openai  (from search summary of the starter tutorial; not copied verbatim)

Cần OPENAI_API_KEY

Python
import asyncio
from llama_index.core.agent.workflow import FunctionAgent
from llama_index.llms.openai import OpenAI

# Define a simple calculator tool
def multiply(a: float, b: float) -> float:
    """Useful for multiplying two numbers."""
    return a * b

# Create an agent workflow with our calculator tool
agent = FunctionAgent(
    tools=[multiply],
    llm=OpenAI(model="gpt-4o-mini"),
    system_prompt="You are a helpful assistant that can multiply two numbers.",
)

async def main():
    # Run the agent
    response = await agent.run("What is 1234 * 4567?")
    print(str(response))

# Run the agent
if __name__ == "__main__":
    asyncio.run(main())

Nguồn hướng dẫn bắt đầu nhanh

Tính năng

Mọi modelCóDùng FunctionAgent cho model hỗ trợ gọi hàm; dùng ReActAgent cho các model khác
MCP clientCóget_tools_from_mcp_url trong llama-index-tools-mcp
MCP serverCóworkflow_as_mcp cung cấp workflow qua FastMCP
Đa agentCóAgentWorkflow điều phối nhiều agent
Lượt chạy bền vữngCóWorkflows lưu state khi đã kết nối backend điều phối
Phê duyệt của con ngườiCóInputRequiredEvent và HumanResponseEvent tạm dừng workflow
TracingChưa xác nhận
EvalsChưa xác nhận

Các thay đổi gần đây

  • Repo workflows đã được đổi tên thành run-llama/llama-agents (LlamaAgents); package trên PyPI vẫn là llama-index-workflows.
  • llamactl hiện có thể chạy và triển khai workflows.

Các lựa chọn thay thế cùng ngôn ngữ

Nguồn

  1. developers.llamaindex.ai/python/framework/getting_started/starter_example/
  2. developers.llamaindex.ai/python/framework/module_guides/deploying/agents/
  3. developers.llamaindex.ai/python/examples/agent/agent_workflow_basic/
  4. developers.llamaindex.ai/python/examples/tools/mcp/
  5. developers.llamaindex.ai/python/llamaagents/workflows/human_in_the_loop/
  6. developers.llamaindex.ai/python/llamaagents/llamactl/workflow-api/
  7. github.com/run-llama/llama-agents
  8. pypi.org/pypi/llama-index/json
  9. api.github.com/repos/run-llama/llama_index