Bỏ qua để đến nội dung
AggregaAggrega
Chọn ngôn ngữ: Tiếng Việt
Trang này được dịch bằng máy. Đọc bản gốc tiếng Anh.

aggrega skills

Cài đặt skill Aggrega vào một trợ lý AI

Cú pháp

aggrega skills

Mô tả

Install the skill that teaches an AI assistant to install and use Aggrega.
A skill is a folder holding a SKILL.md file in the open Agent Skills format,
which many assistants read from a skill folder of their own. The Aggrega skill
tells an assistant how to install Aggrega, how to connect it to the aggrega MCP
server, how to start a workspace, and how to run the authoring loop — scaffold,
validate, build. It carries no copy of any schema: it sends the assistant to
this binary for every structural question and to the published documentation
for every conceptual one.
The skill is built into this binary, so the copy it installs matches the
version you have.

Lệnh con

LệnhMô tả
aggrega skills installGhi skill Aggrega vào thư mục skill của một trợ lý AI
aggrega skills listLiệt kê các skill mà tệp nhị phân này đi kèm và các trợ lý mà nó có thể cài chúng cho

Mô tả aggrega skills install

Write the Aggrega skill into the skill folder of each assistant named with
--agent, so the assistant knows how to install and use Aggrega.
By default the skill goes into the assistant's project skill folder at the root
of your workspace — the one found from the directory you run the command in, or
named with --workspace-root; a directory no workspace marks is its own root —
which is where a project's own skills are committed. With --global it goes
into the assistant's per-user skill folder in your home directory instead,
where the assistant reads it in every project.
Every folder and file a project installation writes is held to the workspace:
a skill folder reached through a link leading out of it is refused, and
nothing is written.
--agent may be given more than once. Where several of the named assistants read
the same folder, the skill is written there once.
With --global and no --agent, the skill is installed for the assistants found
on this machine: each one whose configuration folder is in your home directory
or whose command is on your PATH, as the table below names them. The command
prints each assistant it found and what found it. At a terminal it then asks
before writing: press Enter to install for those, or type the identifiers of
other assistants to add them. Where standard input is not a terminal it
installs for the assistants found without asking. Where it finds none and is
given none, it writes nothing and says so. A project installation is for the
assistants a project's people use rather than those on one machine, so it
always names them with --agent.
The skill is written as a folder named aggrega holding SKILL.md, and every file
written carries a comment line saying where it comes from. Running the command
again replaces a copy carrying that line, which is how a newer aggrega brings
the skill up to its own version. A file at the target that does not carry it
was not written by this command, so the command refuses, names the file and
writes nothing; move it aside or remove it, then run the command again. Every
target is checked before anything is written, so a refusal leaves every folder
as it was.
The assistants it installs for, the folders each one reads, and what finds each
on this machine — its configuration folder in your home directory, or its
command on your PATH:
--agent assistant project folder per-user folder found by
amp Amp .agents/skills ~/.config/amp/skills ~/.config/amp, amp
antigravity Antigravity .agents/skills ~/.gemini/config/skills ~/.gemini/antigravity, antigravity
antigravity-cli Antigravity CLI .agents/skills ~/.gemini/antigravity-cli/skills ~/.gemini/antigravity-cli
claude-code Claude Code .claude/skills ~/.claude/skills ~/.claude, claude
cline Cline .cline/skills ~/.cline/skills ~/.cline, cline
codex Codex .agents/skills ~/.agents/skills ~/.codex, codex
cursor Cursor .cursor/skills ~/.cursor/skills ~/.cursor, cursor
gemini-cli Gemini CLI .gemini/skills ~/.gemini/skills gemini
github-copilot GitHub Copilot .github/skills ~/.copilot/skills ~/.copilot, copilot
goose Goose .agents/skills ~/.agents/skills ~/.config/goose, goose
opencode OpenCode .opencode/skills ~/.config/opencode/skills ~/.config/opencode, opencode
windsurf Windsurf .devin/skills ~/.codeium/windsurf/skills ~/.codeium/windsurf, windsurf
zed Zed .agents/skills ~/.agents/skills ~/.config/zed, zed
An assistant that is not listed is refused by name. It can still use Aggrega
through its MCP server: connect it to "aggrega mcp" as
https://aggrega.ai/docs/install/ describes.

Cờ của aggrega skills install

CờMặc địnhMô tả
--agent[]Trợ lý cần cài skill, theo định danh (ví dụ claude-code, codex, cursor hoặc gemini-cli). Có thể lặp lại; phần trợ giúp liệt kê mọi định danh và thư mục mà mỗi định danh ghi vào. Bắt buộc khi không có —global; khi có —global và không chỉ định trợ lý nào, skill được cài cho các trợ lý tìm thấy trên máy này.
--globalfalseCài vào thư mục skill theo người dùng của từng trợ lý trong thư mục home của bạn, thư mục mà trợ lý đọc trong mọi dự án, thay vì thư mục skill dự án ở gốc workspace của bạn.

Mô tả aggrega skills list

List the skills built into this binary, and the assistants "aggrega skills
install" can write them for, with the project folder and the per-user folder
each assistant reads skills from. It writes nothing.

Chức năng

aggrega skills install ghi skill Aggrega vào thư mục skill của từng trợ lý AI mà bạn nêu bằng --agent, hoặc, khi có --global và không có --agent, của từng trợ lý mà nó tìm thấy trên máy này. Một skill là một thư mục chứa tệp SKILL.md theo định dạng mở Agent Skills: một khối frontmatter ngắn nêu tên skill và cho biết khi nào dùng nó, theo sau là các chỉ dẫn. Một trợ lý đọc skill sẽ nạp nó khi yêu cầu của bạn khớp, nhờ đó biết cách cài Aggrega, cách kết nối tới aggrega mcp, cách bắt đầu một workspace và cách chạy vòng lặp soạn thảo được mô tả trong Soạn thảo tệp Aggrega.

Skill không mang bản sao nào của schema hay hợp đồng thực thể. Nó bảo trợ lý hỏi tệp nhị phân mọi câu trả lời về cấu trúc — qua các công cụ MCP khi máy chủ được kết nối, nếu không thì qua dòng lệnh aggrega — và đọc tài liệu đã phát hành để biết ý nghĩa của mọi thứ. Skill được tích hợp sẵn trong tệp nhị phân, nên bản sao mà nó ghi khớp với phiên bản bạn đã cài.

Terminal window
aggrega skills install --agent claude-code
Installed the aggrega skill for Claude Code at /home/you/project/.claude/skills/aggrega

Skill được đặt ở đâu

Không có --global, skill được đặt vào thư mục skill dự án của trợ lý ở gốc workspace của bạn, nơi trợ lý tìm các skill của dự án và nơi bạn commit chúng. Workspace là workspace mà mọi lệnh tìm thấy — workspace mà --workspace-root nêu tên, hoặc workspace được tìm thấy từ thư mục bạn chạy lệnh, nên chạy từ một thư mục con vẫn cài ở gốc — và một thư mục không được workspace nào đánh dấu là gốc của chính nó. Với --global, skill được đặt vào thư mục skill theo người dùng của trợ lý trong thư mục home của bạn, thư mục mà trợ lý đọc trong mọi dự án. Bảng trong phần mô tả ở trên cho biết cả hai thư mục của mọi trợ lý; mỗi thư mục là thư mục mà tài liệu của chính trợ lý đó chỉ định, và ~ đại diện cho thư mục home của bạn.

Một số trợ lý đọc thư mục dùng chung .agents/skills. Nêu nhiều hơn một trợ lý trong số đó sẽ ghi skill vào đó một lần và nêu tên tất cả chúng trong một dòng báo cáo việc đó:

Terminal window
aggrega skills install --agent codex --agent zed --global
Installed the aggrega skill for Codex and Zed at /home/you/.agents/skills/aggrega

Các trợ lý trên máy này

Khi có --global và không có --agent, lệnh cài skill cho các trợ lý mà nó tìm thấy trên máy này. Một trợ lý được coi là đã tìm thấy khi thư mục cấu hình riêng của nó nằm trong thư mục home của bạn, hoặc lệnh của nó nằm trên PATH của bạn; cột found by của bảng trong phần mô tả ở trên nêu cả hai cho mọi trợ lý. Một thư mục hoặc lệnh chỉ được dùng khi nó chỉ thuộc về riêng trợ lý đó, nên việc tìm thấy nó không bao giờ đại diện cho một trợ lý khác: thư mục dùng chung .agents/skills không tìm thấy trợ lý nào, và .gemini, nơi cả Gemini CLI lẫn Antigravity đều lưu tệp, không tìm thấy trợ lý nào trong hai trợ lý đó — Gemini CLI được tìm thấy qua lệnh gemini của nó, và mỗi sản phẩm Antigravity qua thư mục riêng của nó bên dưới .gemini. Một trợ lý có cấu hình nằm ở nơi khác trên hệ thống của bạn được tìm thấy qua lệnh của nó, hoặc được nêu bằng --agent.

Lệnh in ra từng trợ lý mà nó tìm thấy và thứ đã giúp tìm thấy trợ lý đó, rồi cài đặt:

Terminal window
aggrega skills install --global
Found Claude Code (claude-code), from the folder /home/you/.claude
Found Codex (codex), from the command /usr/local/bin/codex
Installed the aggrega skill for Claude Code at /home/you/.claude/skills/aggrega
Installed the aggrega skill for Codex at /home/you/.agents/skills/aggrega

Tại một terminal, nó hỏi trước. Sau các dòng nêu những gì nó tìm thấy, nó yêu cầu bạn xác nhận: nhấn Enter để cài cho các trợ lý đó, hoặc gõ định danh của các trợ lý khác, phân tách bằng dấu cách hoặc dấu phẩy, để thêm chúng. Khi không tìm thấy trợ lý nào, nó hỏi định danh thay vào đó, và một câu trả lời trống không ghi gì cả. Khi đầu vào chuẩn không phải là terminal — một script, một trợ lý chạy lệnh thay cho bạn, hoặc công cụ riêng của trợ lý dành cho việc đó — nó không hỏi gì và cài cho các trợ lý mà nó tìm thấy. Khi không tìm thấy trợ lý nào và không được chỉ định trợ lý nào, nó không ghi gì, thông báo điều đó và thoát với mã khác không.

Nêu bất kỳ --agent nào sẽ bỏ qua việc tìm kiếm: lệnh chỉ cài cho các trợ lý bạn đã nêu và không cài cho trợ lý nào khác. Một lần cài đặt vào dự án, không có --global, luôn nêu tên chúng: nó dành cho các trợ lý mà những người trong dự án sử dụng, điều mà máy này không cho biết.

Cài lại, và những gì bị từ chối

Mọi tệp mà lệnh ghi đều mang một dòng chú thích, ngay sau frontmatter, cho biết tệp đến từ skill được tích hợp sẵn trong tệp nhị phân aggrega và việc cài lại sẽ thay thế nó. Dòng đó là cách lệnh phân biệt bản sao của chính nó với bản sao của bạn:

  • Một bản sao mang dòng đó sẽ bị thay thế. Chạy lại lệnh sau khi nâng cấp Aggrega sẽ đưa skill lên phiên bản mới, và dòng mà nó in ra ghi Replaced thay vì Installed.
  • Một tệp không có dòng đó sẽ bị từ chối. Một SKILL.md đã có sẵn tại đích mà lệnh không ghi là của bạn, nên lệnh nêu đường dẫn của nó, không ghi gì ở đâu cả và thoát với mã khác không. Hãy chuyển tệp sang chỗ khác hoặc xóa nó, rồi chạy lại lệnh. Để giữ các thay đổi của riêng bạn, hãy giữ chúng trong một skill có tên khác.
  • Một thư mục được tiếp cận qua một liên kết dẫn ra ngoài workspace sẽ bị từ chối. Không có --global, mọi thư mục và tệp mà lệnh sẽ ghi đều bị giới hạn trong workspace: khi thư mục skill của một trợ lý, hoặc một thư mục trên đường dẫn tới nó, là một liên kết dẫn ra ngoài workspace, lệnh nêu liên kết đó và nơi nó dẫn tới, không ghi gì ở đâu cả và thoát với mã khác không — điều kiện được mô tả trong A path the operation writes leads through a link out of the directory it must stay inside (Một đường dẫn mà thao tác ghi dẫn qua một liên kết ra ngoài thư mục mà nó phải ở bên trong). Một liên kết vẫn nằm trong workspace thì được ghi xuyên qua.

Mọi đích đến đều được kiểm tra trước khi ghi bất cứ thứ gì, nên một lần từ chối cho một trợ lý cũng để nguyên thư mục của mọi trợ lý khác. Các tệp trong thư mục của skill mà skill không ghi sẽ không bị đụng tới.

Các trợ lý mà lệnh không biết

--agent chỉ nhận các định danh trong bảng ở trên, mỗi định danh là định danh mà công cụ dòng lệnh skill mở dùng cho cùng trợ lý đó. Mọi định danh khác đều bị từ chối theo tên, kèm danh sách các định danh mà lệnh biết. Một trợ lý không được liệt kê vẫn có thể dùng Aggrega: hãy kết nối nó với máy chủ MCP như trang Kết nối máy chủ MCP mô tả, và nó sẽ tiếp cận cùng các công cụ và tài liệu tham khảo mà skill trỏ tới.

Ví dụ

Cài skill cho Claude Code trong dự án này:

Terminal window
aggrega skills install --agent claude-code

Cài nó cho Gemini CLI và Cursor trong mọi dự án của bạn:

Terminal window
aggrega skills install --agent gemini-cli --agent cursor --global

Cài nó vào mọi dự án của bạn cho các trợ lý trên máy này:

Terminal window
aggrega skills install --global

Đưa một bản sao đã cài lên phiên bản tệp nhị phân mà bạn vừa nâng cấp:

Terminal window
aggrega skills install --agent claude-code

Liệt kê những gì lệnh biết

aggrega skills list in các skill được tích hợp sẵn trong tệp nhị phân này cùng mô tả của chúng, rồi in mọi trợ lý mà aggrega skills install biết, cùng thư mục dự án và thư mục theo người dùng của nó. Lệnh không ghi gì.

Terminal window
aggrega skills list