Chuyển đến nội dung chính

Bài đăng

Hiển thị các bài đăng có nhãn MCP

Agentic Hot Reload: khi coding agent tự reload app đang chạy

Vòng AI cũ: dán lỗi → agent sửa file → bạn tự bấm r trong terminal. Agentic Hot Reload bỏ bước cuối. Dart/Flutter MCP server giúp agent tìm và kết nối app đang chạy, rồi trigger reload sau khi sửa. Vòng mới flutter run (debug) với MCP server sẵn cho agent. Prompt: “làm nút login màu cyan và to hơn.” Agent sửa Dart, trigger reload, bạn nhìn pixel. Không cần script keo dán. Dependency search được siết để agent đọc source package không cần full pub-cache; tool definition được gộp để giảm token. Mẹo setup Một debug session cho mỗi device bạn quan tâm; agent attach vào session đang chạy. Prompt nhỏ theo scope UI — Agentic Hot Reload thưởng cho diff nhỏ. Ghép Agent Skills để agent theo kiến trúc của bạn thay vì bịa mới. Giới hạn Hot reload không phải hot restart . State và native channel vẫn cần restart. Nếu đổi không hiện, kiểm tra session còn kết nối và edit nằm trong library reloadable (không phải rearrange main() bắt buộc restart). Bài viết gốc đăng tại FlutterCook ...

Agent Skills cho Dart và Flutter: workflow agent rẻ và chuẩn hơn

Agent giỏi gõ phím nhưng kém gu. Agent Skills mã hóa gu Flutter/Dart thành hướng dẫn ngắn theo task mà agent load được: cách thêm integration test, setup localization, cấu trúc feature. Vì sao skill thắng system prompt khổng lồ Theo scope. Chỉ load việc đang cần. Version cùng hệ sinh thái. Skill ship kèm package và docs. Rẻ token. Mặt phẳng tool MCP cũng được gộp để agent dành budget cho code của bạn. Dùng hàng ngày Cài/cấu hình Dart & Flutter MCP server cho agent (Claude Code, Gemini CLI, Cursor…). Ưu tiên invoke skill chính thức hơn prompt tự do “viết màn login”. Giữ skill local cho luật nhà (folder layout, convention Riverpod, style test). Package skills Pub package có thể ship skill riêng để agent biết idioms của package đó , không phải Flutter chung chung. Nếu bạn maintain plugin phổ biến, skill đang thành một phần DX tốt — và giảm API bị bịa. Anti-pattern Một prompt vừa redesign kiến trúc, vừa add feature, vừa viết test. Hãy tách. Tắt skill để “tiết kiệ...

Agentic Hot Reload: when your coding agent reloads the running app

The old AI loop was: paste error → agent edits file → you manually r in the terminal. Agentic Hot Reload removes the last step. The Dart/Flutter MCP server helps agents find and connect to a running app, then trigger reload after an edit. The new loop flutter run (debug) with the MCP server available to your agent. Prompt: “make the login button cyan and larger.” Agent edits Dart, triggers reload, you judge the pixels. No extra glue scripts. Dependency search is hardened so agents can read package sources without full pub-cache access, and tool definitions were consolidated to cut token cost. Practical setup tips Keep one debug session per device you care about; agents attach to what is running. Prefer small UI-scoped prompts — Agentic Hot Reload rewards incremental diffs. Pair with Agent Skills so the agent follows your architecture instead of inventing a new one. Limits Hot reload is not hot restart . State and native-channel changes still need a restart. If the ag...

Dart and Flutter Agent Skills: cheaper, better agent workflows

Agents are good at typing and bad at taste. Agent Skills encode Flutter/Dart taste as short, task-oriented instructions your agent can load: how to add integration tests, how to set up localization, how to structure a feature. Why skills beat a giant system prompt Scoped. Load only what the task needs. Versioned with the ecosystem. Skills ship alongside packages and docs. Token-cheap. The MCP tool surface was also consolidated so the agent spends budget on your code, not on boilerplate tool schemas. How to use them day to day Install/configure the Dart & Flutter MCP server for your agent (Claude Code, Gemini CLI, Cursor, etc.). Prefer invoking an official skill over free-form “write me a login screen.” Keep project-local skills for house rules (folder layout, Riverpod conventions, test style). Package skills Pub packages can ship their own skills so an agent knows this package’s idioms, not generic Flutter. If you maintain a popular plugin, a skill is becoming p...