This is an old revision of the document!
Table of Contents
AI CMS / Framework / Model
Tổng quan
Có. Trong AI cũng tồn tại khái niệm tương đương CMS / Framework / Library giống lập trình truyền thống, nhưng được chia thành nhiều tầng đóng gói khác nhau.
Mục tiêu trang này: Giải thích AI theo đúng tư duy OpenCart / Laravel / SDK để dev hiểu ngay. What it is: Trong AI, cũng tồn tại khái niệm tương đương CMS / Framework / Library giống lập trình truyền thống.
Key idea: AI không phải một khối duy nhất, mà được chia thành nhiều tầng đóng gói, từ “lấy về dùng ngay” đến “tự build từ lõi”.
—
1) Mapping trực tiếp: Lập trình truyền thống ↔ AI
| Traditional Programming | AI Equivalent | Meaning |
|---|---|---|
| CMS (OpenCart, WordPress) | AI CMS / Prebuilt AI App | Dùng ngay |
| Framework (Laravel, Django) | AI Framework / LLM Framework | Build AI app |
| Library / SDK | Model / Inference Library | Ghép từng phần |
| Custom low-level code | Train model from scratch | Đắt & hiếm |
—
2) Tầng AI CMS – Dùng ngay (No-code / Low-code)
What it is: Ứng dụng AI đã đóng gói sẵn UI + workflow + model integration.
Equivalent: OpenCart / WordPress
Examples
* AnythingLLM](https://anythingllm.com|AnythingLLM)
* Flowise](https://flowiseai.com|Flowise)
* Open](https://openwebui.com|Open) WebUI
Key Characteristics
* Có sẵn UI * Workflow dựng bằng form / node * Config bằng YAML / JSON * Gắn LLM là chạy
Use When
* Internal chatbot * Knowledge assistant * PoC nhanh * Team không có ML skill
Limitations
* Khó custom sâu * Performance không tối ưu * Governance yếu nếu không chỉnh
👉 Đây là AI CMS đúng nghĩa.
—
3) Tầng AI Framework – Giống Laravel / Django
What it is: Framework để lập trình ứng dụng AI bằng code.
Equivalent: Laravel / Django
Popular Frameworks
* LangChain](https://www.langchain.com|LangChain) ⭐
* LlamaIndex](https://www.llamaindex.ai|LlamaIndex)
* Haystack](https://haystack.deepset.ai|Haystack)
* Semantic](https://learn.microsoft.com/semantic-kernel|Semantic) Kernel
What They Do
* Prompt management * RAG (Retrieval Augmented Generation) * Tool calling * Memory & agent flow
Mapping
* Laravel ≈ LangChain * Django ≈ LlamaIndex
Use When
* Build AI product thực sự * Có backend team * Cần kiểm soát flow & test
—
4) Tầng Pretrained Model – Model train sẵn
What it is: Model AI đã được train sẵn trên dữ liệu lớn.
Equivalent: Database engine / Search engine
Examples
* LLaMA](https://ai.meta.com/llama|LLaMA) / LLaMA 3
* Mistral](https://mistral.ai|Mistral) / Mixtral
* Qwen](https://huggingface.co/Qwen|Qwen)
Characteristics
* Không có UI * Không có workflow * Có thể self-host * Có thể fine-tune
🚫 Không phải CMS – chỉ là “bộ não”.
—
5) Tầng AI Inference Engine
What it is: Runtime để chạy model hiệu quả.
Equivalent: JVM / PHP runtime / DB engine core
Examples
* vLLM](https://github.com/vllm-project/vllm|vLLM)
* llama.cpp](https://github.com/ggerganov/llama.cpp|llama.cpp)
* TensorRT-LLM](https://developer.nvidia.com/tensorrt-llm|TensorRT-LLM)
* TGI](https://github.com/huggingface/text-generation-inference|TGI)
Use When
* High throughput * Tối ưu cost * On-prem / air-gapped
—
6) Tầng Managed AI Platform (AI SaaS)
What it is: Nền tảng AI được vận hành hoàn toàn bởi vendor.
Equivalent: Shopify / Salesforce
Examples
* OpenAI](https://openai.com|OpenAI) / Azure OpenAI
* AWS](https://aws.amazon.com/bedrock|AWS) Bedrock
* Google](https://cloud.google.com/vertex-ai|Google) Vertex AI
Pros / Cons
* ✅ Nhanh, không lo infra * ❌ Chi phí cao, lock-in
—
7) Sơ đồ tổng thể các tầng
AI CMS (No-code) │ Flowise / AnythingLLM │ AI Framework (Code) │ LangChain / LlamaIndex │ Pretrained Model │ LLaMA / Mistral │ Inference Engine │ vLLM / llama.cpp │ Infrastructure │ Cloud / On-prem GPU
—
8) Chọn gì trong thực tế?
* “Giống OpenCart, kéo về chạy” → AnythingLLM / Flowise * “Giống Laravel” → LangChain / LlamaIndex * “Enterprise, kiểm soát data” → Open-source model + vLLM + RAG
—
Phân loại dịch vụ AI – Company & Use Case
Mục tiêu
Trang này phân loại các dịch vụ AI phổ biến hiện nay theo tư duy lập trình viên senior (CMS / Framework / Runtime), kèm:
* Công ty đứng sau * Công dụng thực tế * Vị trí trong kiến trúc hệ thống
—
Tổng quan phân tầng
AI không phải một khối duy nhất, mà gồm 6 tầng, từ “dùng ngay” đến “lõi hạ tầng”.
AI App / Tool ↓ AI Platform (API) ↓ AI Framework ↓ Pretrained Model ↓ Inference Engine ↓ Infrastructure (GPU)
—
1) AI App / AI Tool (Dùng ngay)
Tương đương: CMS (WordPress / OpenCart)
| Dịch vụ | Công ty | Công dụng chính |
|---|---|---|
| ChatGPT | OpenAI | Trợ lý đa năng, hỏi đáp, code, viết spec |
| Claude Chat | Anthropic | Phân tích tài liệu dài, reasoning |
| GitHub Copilot | GitHub / Microsoft | Code completion, pair programming |
| AnythingLLM | Mintplex Labs | Chatbot nội bộ theo tài liệu |
| Flowise | FlowiseAI (OSS) | Dựng workflow AI nhanh |
| Open WebUI | Open-source | UI chat cho model self-host |
| Botpress | Botpress Inc. | Chatbot CSKH |
| Rasa | Rasa Technologies | Conversation engine |
Dùng khi: PoC nhanh, nội bộ, team nhỏ
—
2) AI Platform / AI SaaS
Tương đương: Shopify / Firebase
| Nền tảng | Công ty | Công dụng chính |
|---|---|---|
| OpenAI API | OpenAI | LLM API: chat, embedding, tool calling |
| Azure OpenAI | Microsoft | OpenAI + enterprise security |
| AWS Bedrock | Amazon | Multi-model AI cho enterprise |
| Google Vertex AI | End-to-end AI platform | |
| IBM watsonx | IBM | AI + data governance |
Dùng khi: Gọi AI qua API, không muốn quản GPU
—
3) AI Framework (Build AI Logic)
Tương đương: Laravel / Django
| Framework | Công ty / Tổ chức | Công dụng chính |
|---|---|---|
| LangChain | LangChain Inc. | Orchestrate prompt, agent, tool |
| LlamaIndex | LlamaIndex Inc. | RAG (document → answer) |
| Haystack | deepset | Search + QA pipeline |
| Semantic Kernel | Microsoft | AI orchestration enterprise |
| CrewAI | CrewAI Inc. | Multi-agent workflow |
| AutoGen | Microsoft Research | Agent collaboration |
Dùng khi: Build AI feature thật, cần test & CI/CD
—
4) Pretrained Model (Bộ não AI)
Tương đương: Database / Search Engine
| Model | Công ty | Công dụng chính |
|---|---|---|
| GPT-4 / GPT-5 | OpenAI | Reasoning, general-purpose |
| Claude 3 / 4 | Anthropic | Long context, safety |
| Gemini | Multimodal | |
| LLaMA 3 | Meta | Open-source, self-host |
| Mistral / Mixtral | Mistral AI | Nhẹ, nhanh, cost thấp |
| Qwen | Alibaba | Multilingual |
| DeepSeek | DeepSeek AI | Reasoning, open |
Lưu ý: Model không có UI, không có workflow
—
5) Inference Engine (Runtime)
Tương đương: JVM / PHP-FPM
| Engine | Công ty / Tổ chức | Công dụng chính |
|---|---|---|
| vLLM | UC Berkeley | High-throughput LLM serving |
| llama.cpp | Open-source | Chạy LLM trên CPU / edge |
| TensorRT-LLM | NVIDIA | Tối ưu GPU, latency thấp |
| TGI | Hugging Face | Production LLM endpoint |
| ONNX Runtime | Microsoft | Cross-platform inference |
Dùng khi: Self-host model, traffic lớn, tối ưu cost
—
6) Infrastructure (GPU / Cloud)
Tương đương: Server / Datacenter
| Infra | Công ty | Công dụng chính |
|---|---|---|
| AWS GPU | Amazon | AI cloud |
| Azure GPU | Microsoft | AI cloud |
| GCP GPU | AI cloud | |
| NVIDIA A100 / H100 | NVIDIA | Training / inference lớn |
| On-prem GPU | Doanh nghiệp | Privacy tuyệt đối |
—
===== Ví dụ kiến trúc thực tế =====
React / Vue ↓ Laravel / Go API ↓ LangChain / LlamaIndex ↓ OpenAI API hoặc LLaMA ↓ (vLLM nếu self-host)
—
Ghi chú quan trọng
⚠️ AI không deterministic như code truyền thống.
Luôn cần:
* Guardrail * Evaluation * Human review
