AA

ag2ai/ag2-skills

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

12 stars 质量 66 趋势 23Apache-2.0

Agent Skills for AG2 developers

概览

A collection of skills for AG2 — an async, protocol-driven Python agent framework (ag2). Skills are packaged instructions and optional helper scripts that extend an AI agent's capabilities. These skills document the (the ag2 namespace) only — not AG2 Classic (the autogen namespace). They are verified against a specific upstream AG2 commit, pinned in COMPATIBILITY.json (currently ). Install the whole collection with the skills CLI: Upload the corresponding .zip from skills/ in the project's Skills settings, or paste the contents of SKILL.md into the conversation. AG2's built-in Skills toolkit can load a local skills directory — see the ag2-use-builtin-tools skill for the wiring. Map of AG2 capabilities and which sibling skill to reach for. when the user mentions building with AG2 but the specific feature isn't yet clear. - "I want to build an AG2 agent" - "How do I use ag2?

README

以下为原文 README 节选,完整内容请查看原文。

AG2 Skills

A collection of skills for AG2 — an async, protocol-driven Python agent framework (ag2). Skills are packaged instructions and optional helper scripts that extend an AI agent’s capabilities.

Skills follow the Agent Skills format.

Compatibility

These skills document the AG2 API (the ag2 namespace) only — not AG2 Classic (the autogen namespace). They are verified against a specific upstream AG2 commit, pinned in COMPATIBILITY.json (currently ag2 1.0.0).

Installation

Install the whole collection with the skills CLI:

npx skills add ag2ai/ag2-skills

To install a single skill, append @:

npx skills add ag2ai/ag2-skills@ag2-quickstart

Manual install (Claude Code)

git clone https://github.com/ag2ai/ag2-skills.git
cp -r ag2-skills/skills/ag2-overview ~/.claude/skills/
cp -r ag2-skills/skills/ag2-quickstart ~/.claude/skills/
# ...repeat for the skills you need

claude.ai

Upload the corresponding .zip from skills/ in the project’s Skills settings, or paste the contents of SKILL.md into the conversation.

AG2 agents (programmatic)

AG2’s built-in Skills toolkit can load a local skills directory — see the ag2-use-builtin-tools skill for the wiring.

Available Skills

ag2-overview

Map of AG2 capabilities and which sibling skill to reach for. Load this first when the user mentions building with AG2 but the specific feature isn’t yet clear.

Use when:

  • “I want to build an AG2 agent”
  • “How do I use ag2?”
  • The task touches AG2 but spans multiple features

Topics covered:

  • Index of every sibling skill with a one-line summary
  • Three prerequisites for any AG2 build (provider extra, API key, env loading)

ag2-quickstart

Build a minimal AG2 Agent end to end — pick a model provider, set a prompt, call agent.ask(), then continue the conversation with reply.ask() (multi-turn).

Use when:

  • Starting a new AG2 project
  • No working Agent yet
  • Need the multi-turn chaining pattern

Topics covered:

  • OpenAIConfig, AnthropicConfig, GeminiConfig, OllamaConfig
  • Env-var fallback for API keys
  • Multi-turn reply.ask() pattern

ag2-add-custom-tool

Add a custom Python tool to an AG2 Agent using the @tool decorator.

Use when:

  • Giving an agent a new capability backed by Python (API calls, DB queries, computations, file ops)
  • Returning typed text / data / images / binary from a tool
  • Wiring dependency injection into tools

Topics covered:

  • Sync and async tools, parameter typing, Pydantic schema customisation
  • Returning Input / ToolResult (text / data / images / binary)
  • final=True early-exit
  • Dependency injection via Context / Inject / Variable / Depends

ag2-use-builtin-tools

在 GitHub 查看完整 README

推荐工具

换一个关键词,或者移除筛选条件。

安装

npx skillfish add ag2ai/ag2-skills
新手?先看 mcpskill.org 教程 →