Bỏ qua để đến nội dung

AI trong DataValue — từ Business Insight đến Reasoning & Agentic Action

Nhiều năm qua, Data & Analytics giúp doanh nghiệp trả lời “điều gì đang xảy ra?” — và BI/Dashboard làm rất tốt việc đó. Nhưng khi dashboard báo doanh thu giảm 15%, câu hỏi tiếp theo không còn là “doanh thu bao nhiêu?” mà là “tại sao giảm? cái gì gây ra? nên ưu tiên khách hàng/sản phẩm nào? nên làm gì tiếp theo?”.

Đó là nơi AI tạo ra lớp giá trị mới. Trong DataValue, AI không phải một chatbot gắn cạnh dashboard — nó là lớp Reasoning & Intelligence nằm giữa Business Insight và Business Action:

flowchart LR
  D["Data"] --> TD["Trusted Data"] --> BS["Business Semantics"] --> BI["Business Insight"] --> AI["AI Reasoning"] --> DEC["Decision"] --> ACT["Agentic Action"] --> OUT["Business Outcome"]

Đây là bước chuyển từ Business Intelligence sang Decision Intelligence.

BI cho biết “điều gì đang xảy ra” — nhưng “So what?”

Phần tiêu đề “BI cho biết “điều gì đang xảy ra” — nhưng “So what?””

Chuỗi Odoo → Airbyte → ClickHouse → dbt → Cube → Superset cho doanh nghiệp khả năng See the Business: Revenue ↓12%, Gross Margin ↓4%, Active Customers ↓8%. Thông tin quan trọng — nhưng vẫn còn câu hỏi “So what? nên làm gì với những con số này?”.

BI thấy Revenue ↓12%. AI reasoning tiếp: giảm chủ yếu ở miền Nam → 68% mức giảm đến từ nhóm Distributor → nhóm này giảm mua Product Category A → nguyên nhân khả năng liên quan thay đổi giá & thời gian giao hàng trong 60 ngày gần đây. AI không chỉ trả về con số — nó giúp người dùng reason over the business context (Revenue↓ → Which Region? → Which Segment? → Which Products? → What Changed? → Possible Causes).

Nguyên tắc kiến trúc quan trọng: đừng đưa AI hàng trăm bảng raw (sale_order, account_move_line, stock_move…) rồi bảo “tự tìm Revenue” — AI sẽ phải đoán join nào, field nào là revenue, trạng thái nào tính, Gross hay Net, currency ra sao. Rất nguy hiểm trong Enterprise AI. DataValue đi qua Raw → dbt → Trusted Model → Cube → Trusted Business Semantics → AI:

Hai loại context: Structured (Cube) + Unstructured (Knowledge/RAG)

Phần tiêu đề “Hai loại context: Structured (Cube) + Unstructured (Knowledge/RAG)”

Cube không chỉ phục vụ Superset — nó là Business Context Layer cho AI (Define Once — Use Everywhere). Nhưng structured data chưa đủ: phần lớn tri thức doanh nghiệp nằm trong Policies, SOPs, Contracts, Manuals, Guidelines. Khi AI thấy Customer A giảm mua 40%, để hiểu sâu nó có thể cần đọc hợp đồng, chính sách discount, lịch sử trao đổi. Vì vậy Enterprise AI cần hai loại context:

Cube → Structured Context

What the business data says — Revenue/Margin/Customer theo semantic model.

Knowledge / RAG → Unstructured Context

What the enterprise knows — documents/policies/contracts, xây bằng LlamaIndex (Knowledge/RAG).

AI Assistant truyền thống: User → Question → AI → Answer. Enterprise AI tiến tới Agent: Goal → Understand → Gather Context → Use Tools → Reason → Decide → Take/Request Action. Agent không chỉ trả lời — nó thực hiện một chuỗi công việc để hoàn thành business goal.

Ví dụ Sales Intelligence Agent với câu hỏi “tại sao doanh thu tháng này giảm và cần ưu tiên xử lý ở đâu?” — thay vì “Revenue giảm 12%”, agent trả về: “Phần lớn mức giảm ở nhóm Distributor miền Nam, đặc biệt Product Category A; 15 khách hàng đóng góp phần lớn mức giảm; nên ưu tiên kiểm tra 5 khách hàng giá trị cao nhất và xác minh tác động thay đổi chính sách thương mại gần đây.” Đây là bước chuyển từ Reporting sang Reasoning.

Một Agent thực tế không gọi LLM một lần — nó cần: hỏi Cube → đánh giá → cần thêm data? → truy vấn tiếp → lấy knowledge → reason → cần human input? → recommend action. Đó là lý do cần Agent Orchestration, trong DataValue dùng LangGraph: LLM cung cấp reasoning capability; LangGraph điều phối cách Agent reasoning & dùng tools (state, branching, tool calling, retries, human-in-the-loop, multi-step). AI không còn là một isolated prompt mà là một reasoning workflow.

Tool Calling cho agent tương tác thế giới ngoài: get_revenue(), get_customer(), search_policy(), find_contract(), create_followup()… kết nối tới Cube (metrics), Knowledge (documents), APIs (enterprise systems), n8n (workflows) — AI chuyển từ Know sang Do.

Ranh giới rất quan trọng: AI có thể reasoning “Customer A churn risk cao” và recommend “liên hệ trong 24h”, nhưng thực hiện (Create CRM Task, Assign, Notify, Track) là Business Action:

flowchart LR
  AI["AI Agent · Reason & Decide"] --> DEC["Decision"] --> N8N["n8n · Automate & Execute"] --> SYS["CRM · ERP · Email · APIs"]

Đừng để agent gọi thẳng mọi hệ thống. Nếu AI quyết định “tạo PO trị giá 2 tỷ”, không nên AI → ERP → Create PO mà AI Recommendation → Controlled Workflow → Validation → Approval → Authorized Action → ERP. n8n là Business Workflow & Action Layer — AI reasoning linh hoạt, action được kiểm soát.

Ví dụ hoàn chỉnh: Customer Retention Agent → Closed Learning Loop

Phần tiêu đề “Ví dụ hoàn chỉnh: Customer Retention Agent → Closed Learning Loop”

Odoo (Customer/Orders/Invoices) → Airbyte → ClickHouse → dbt → Cube (Customer Revenue, Purchase Frequency, Last Purchase…). Agent phát hiện Customer A: Revenue ↓42%, Frequency ↓55%, Last Purchase 48 ngày, lấy thêm Contract/Discount Policy/Service History, kết luận churn risk cao → qua n8n: Create CRM Task → Assign Owner → Priority High → Notify Manager. Salesperson liên hệ, kết quả (Contacted/Offer Sent/Returned/Order Created) quay lại Data Platform.

flowchart LR
  DATA["Data"] --> TM["Trusted Meaning"] --> INS["Insight"] --> R["AI Reasoning"] --> DEC["Decision"] --> A["Agentic Action"] --> O["Business Outcome"] --> NEW["New Data → Learning"] --> DATA

Khác với Traditional Analytics (Data → Dashboard → Human), DataValue khép kín vòng lặp: data không chỉ giúp nhìn lại quá khứ, mà tham gia trực tiếp vào cách doanh nghiệp ra quyết định và hành động.

AI cần Observability & Governance — ba lớp context

Phần tiêu đề “AI cần Observability & Governance — ba lớp context”

Với nhiều agent (Sales/Finance/Procurement/Inventory/Service), cần biết: agent nhận câu hỏi gì? gọi tool nào? LLM nào? mất bao lâu? lỗi ở đâu? chính xác không? chi phí bao nhiêu? phiên bản mới tốt hơn không? Đó là AI Observability & Evaluation — trong DataValue dùng Langfuse (Observe · Evaluate · Improve), rất quan trọng khi chuyển từ AI Prototype sang Production AI.

Và AI không nên dùng mọi dataset nó tìm thấy (sales_old / sales_temp / fact_sales) — cần biết cái nào certified/deprecated, owner, lineage, quality. Đó là OpenMetadata. Ba lớp context giúp AI reasoning đáng tin:

flowchart TB
  AI["AI AGENT"]
  AI --> CUBE["Cube → What the business data means"]
  AI --> KN["Knowledge/RAG → What the enterprise knows"]
  AI --> OM["OpenMetadata → What data exists & whether it can be trusted"]

Nguyên tắc quan trọng: DataValue không nên định nghĩa là “dùng model X”. Model landscape đổi rất nhanh; tùy khách hàng/deployment, AI Layer có thể dùng OpenAI, Claude, Gemini, Llama/OSS, hay enterprise AI service. Cái DataValue cần sở hữu là Business Context · Enterprise Knowledge · Agent Logic · Tools · Business Workflow · Outcome & Learning. Model là một phần của architecture, không phải toàn bộ.

Trusted Business Data → { Superset: Explore & Analyze · AI: Reason & Assist } — Superset hợp khi muốn nhìn toàn cảnh/theo dõi KPI/so sánh/drill-down; AI hợp khi muốn hỏi/giải thích/reasoning/tổng hợp context/recommendation. Hai bên không thay nhau, cùng dùng một Trusted Data Foundation. Và mục tiêu không phải Human → AI mà là Human + Trusted Data + AI Reasoning + Controlled Automation → Better Decision, Faster Action; ở quyết định quan trọng, con người vẫn review/approve/override/chịu trách nhiệm.

Sự tiến hóa: BI → Decision Intelligence → Agentic Intelligence

Phần tiêu đề “Sự tiến hóa: BI → Decision Intelligence → Agentic Intelligence”
Cấp độChuỗiCâu hỏi
Business IntelligenceData → Dashboard → InsightWhat happened?
AI-assisted AnalyticsData → Insight → AI → ExplanationWhy did it happen?
Decision IntelligenceData → Insight → Reasoning → RecommendationWhat should we do?
Agentic IntelligenceData → Insight → Reasoning → Decision → Action → OutcomeHow can the enterprise act on it?

DataValue không bắt đầu từ Chatbot (LLM → Chatbot → tìm use case) mà đi ngược: Business Data → Trusted Data → Semantics → Context → Business Problem → AI Reasoning → Decision → Action → Outcome. AI chỉ tạo giá trị khi được đặt trong business context — nó là một phần của Data-to-Action Value Chain, không phải tính năng đứng riêng.

flowchart TB
  U["User / Application"] --> AG["AI AGENT"] --> LG["LangGraph · Reason & Orchestrate"]
  LG --> CUBE["Cube · Semantics"] & LI["LlamaIndex · Knowledge/RAG"] & OM["OpenMetadata · Data Context"]
  LG --> LLM["LLM / Model"] --> DEC["Decision"] --> N8N["n8n · Automate & Execute"]
  N8N --> SYS["CRM · ERP · APIs"] --> ACT["Business Action → Outcome & Learning"]
  LF["Langfuse · Observe · Evaluate · Improve"] -. xuyên suốt .-> AG

Role map: Airbyte Ingest · ClickHouse Store & Process · dbt Transform & Model · Cube Define & Understand · Superset Explore & Analyze · LlamaIndex Know · LangGraph Reason & Orchestrate · n8n Automate & Act · OpenMetadata Discover/Govern/Trust · Langfuse Observe/Evaluate/Improve. Đây không phải architecture của một chatbot — mà của một Enterprise AI & Agentic Intelligence Layer.

LangGraph — Agent Orchestration

Điều phối agent suy luận nhiều bước: graph, state, tool calling, human-in-the-loop. Xem →

LlamaIndex & RAGFlow — Knowledge & RAG

Enterprise Knowledge cho AI: RAG pipeline, governed retrieval, provenance, freshness. Xem →

Langfuse — Observability & Eval

Trace, evaluation, experiments, prompt management, cost, decision-to-outcome. Xem →

Chọn LLM (Model & Runtime)

Model-neutral architecture: one platform — multiple models, 7 tiêu chí, model routing. Xem →

AI trong DataValue là lớp chuyển Business Insight → Reasoning → Decision → Action. Để hoạt động thực sự trong doanh nghiệp, phía sau nó cần: Trusted Data (dữ liệu đúng), Semantic Layer (hiểu đúng meaning), Enterprise Knowledge (context), Agent Orchestration (reasoning nhiều bước), Governance (biết data nào tin được), Observability (đánh giá & cải thiện), Workflow Automation (biến quyết định thành hành động có kiểm soát).

Vì vậy bước từ BI sang AI không phải Dashboard → Chatbot mà là Insight → Reasoning → Decision → Agentic Action → Outcome & Learning — chuyển DataValue từ một nền tảng giúp hiểu dữ liệu thành một nền tảng để dữ liệu tham gia trực tiếp vào ra quyết định và tạo hành động kinh doanh: Data → Trusted Meaning → Insight → Reasoning → Decision → Action → Outcome → Learning → Value.

Chia sẻ: