ml-adoption-playbook
Skill này làm gì
Hướng dẫn này giúp bạn thêm trí tuệ nhân tạo (AI) vào một chương trình máy tính chưa có AI. Nó chỉ cách lên kế hoạch, chuẩn bị dữ liệu, tích hợp AI vào code hiện có và tạo một mô hình đơn giản đầu tiên.
Khi nào nên dùng
- ✓Khi bạn muốn thêm AI vào một chương trình.
- ✓Khi lên kế hoạch cho cách một mô hình AI mới (như hệ thống gợi ý) sẽ hoạt động trong ứng dụng.
- ✓Khi tổ chức công việc xây dựng, huấn luyện và sử dụng một thành phần AI.
Liên kết skill
https://github.com/affaan-m/ECC/blob/main/pi/core/skills/ml-adoption-playbook/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Làm sao để thêm một mô hình gợi ý sản phẩm vào website của tôi?”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Đầu tiên, AI hiểu vấn đề và kiểm tra xem một giải pháp đơn giản hơn có đủ dùng không. Sau đó, nó tổ chức dữ liệu cần thiết và lên kế hoạch cách AI giao tiếp với phần còn lại của chương trình mà không làm mọi thứ bị rối. Cuối cùng, nó tạo một mô hình cơ bản và hướng dẫn cách cải thiện.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
ML Adoption Playbook
This skill provides an adaptive methodology for implementing machine learning models into existing software engineering projects. It bridges the gap between traditional SWE and MLOps by structuring how ML should be researched, decoupled, trained, and integrated.
When to Activate
- A user asks to "add ML" or "add an algorithm" to their existing codebase.
- Planning the integration of a new model (e.g., recommendation, classification, forecasting) into a non-ML application.
- Structuring a workflow for an agent to build, train, and deploy an ML component adaptively.
Phase 1: Problem Framing & Feasibility
Before writing model code, establish the "why" and "how".
- Heuristic Check: Ask the user if a simple heuristic (e.g., regex, rule-based sorting) could solve the problem faster. If yes, start there.
- Metric Definition: Define what business metric the ML model is trying to improve (e.g., click-through rate, reduced latency).
- Mistake Budget: Define what a "bad" prediction looks like and how the system should handle it.
Phase 2: Data Readiness
ML is useless without clean, accessible data.
- Audit Data Sources: Identify where the training data lives. Is it a live database, a static CSV, or an API?
- Data Contract: Establish a schema for the input data. What features are required? What happens if a feature is missing?
- Leakage Prevention: Ensure the user's proposed data split does not accidentally leak future information into the training set (e.g., chronological splitting for time-series data).
Phase 3: Architectural Integration & Decoupling
Do not tightly couple model inference to core business logic.
- API Boundary: Suggest placing the model behind an API endpoint (e.g., using
fastapi-patternsordjango-patterns) or a dedicated service class. - Fallback Mechanisms: Design a default state. If the model takes too long to respond or throws an error, the system must gracefully fall back to a hardcoded rule.
- Feature Flags: Wrap the new ML inference call in a feature flag so it can be rolled out (or rolled back) safely.
Phase 4: Model Implementation & Training
Structure the code for reproducibility and iteration.
- Start Simple: Build a baseline model first (e.g., a simple scikit-learn Logistic Regression or a barebones PyTorch linear layer).
- Reproducibility: Apply
pytorch-patternsor similar best practices: fix random seeds, make code device-agnostic, and explicitly document tensor/array shapes. - Automated Evidence: Require tests for the data transforms and inference schema. Do not accept a model without an evaluation script comparing it against the baseline.
Phase 5: Handoff to MLOps
Once the baseline model is integrated, shift focus to continuous operations.
- Refer to
mle-workflow: Guide the user toward setting up experiment tracking, model registries, and drift detection. - CI/CD: Add the model evaluation step to the existing CI pipeline to ensure future commits do not degrade model performance.
Iterative Agent Workflow
When assisting a user via this playbook, agents should:
- Ask clarifying questions to complete Phase 1 before proposing architectures.
- Draft a data contract in Phase 2 for user approval.
- Write the decoupling interface (API/Service) in Phase 3 before writing the training loop.
- Deliver a reproducible script in Phase 4 that trains the model and saves the artifact.
Câu hỏi thường gặp
'Heuristic' là gì?
Đây là một giải pháp đơn giản, nhanh cho một vấn đề, chẳng hạn một quy tắc cơ bản, có thể dễ dùng và hiệu quả hơn một AI phức tạp.
'Architectural decoupling' là gì?
Nghĩa là tách AI khỏi phần còn lại của chương trình để thay đổi ở phần này không dễ dàng ảnh hưởng đến phần kia, giúp mọi thứ gọn gàng và ổn định hơn.
'Baseline model' là gì?
Đây là mô hình AI đơn giản đầu tiên bạn tạo để có thứ gì đó hoạt động. Nó là điểm xuất phát để so sánh và cải thiện sau này.
Chi tiết
Mô tả gốc của tác giả
End-to-end methodology for AI agents and software engineers to add machine learning algorithms to existing non-ML codebases. Covers problem framing, data readiness, architectural decoupling, and baseline model integration. Use when adding a machine learning capability to a codebase that has none, from problem framing through a baseline model.
repo: affaan-m/ECC
Độ phổ biến
- Sao GitHub
- 280k
- Vị trí xếp hạng
- #208
- Giấy phép
- MIT
- Cập nhật
- 15/10/2026
Bình luận
- …
Thêm skill từ kho mã này
accessibility
280kGiúp agent của bạn tạo giao diện mà ai cũng dùng được, đảm bảo website và app hoạt động tốt với người khuyết tật như người mù hoặc khó vận động.
agent-architecture-audit
280kGiúp agent của bạn kiểm tra xem mọi thứ có hoạt động đúng không, đồng thời tìm và sửa các lỗi trong hệ thống AI để chúng chạy như mong đợi.
agent-eval
280kGiúp agent của bạn so sánh các công cụ lập trình AI khác nhau, đo xem công cụ nào nhanh hơn, rẻ hơn và đáng tin cậy hơn cho từng tác vụ.
agent-harness-construction
280kGiúp agent của bạn hiểu rõ hơn cách thực hiện tác vụ, tối ưu các công cụ và chỉ dẫn mà agent dùng để tăng khả năng thành công.
Skill tương tự
add-model-provider
394kGiúp agent của bạn kết nối nhà cung cấp mô hình AI mới với OpenClaw bằng lệnh an toàn, giữ API key khỏi văn bản thuần và chạy thử.
acp-router
394kGiúp agent của bạn gửi một tác vụ đến trợ lý lập trình như Claude Code hoặc Cursor qua OpenClaw, để công việc chạy ngay trong công cụ đó.
browser-automation
394kHướng dẫn agent của bạn điều khiển trang web từng bước, gồm đăng nhập, tab và cách khôi phục khi trang ngừng phản hồi.