Token导航 LogoToken导航TokenDH.com
待分类敏感数据github未标认证来源可访问许可证需确认审计提醒

alibabacloud-rds-copilotalibabacloud RDS GitHub Copilot 命令行

Agent Skill

alibabacloud-rds-copilot 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

2,677

周安装

115

GitHub Stars

79

下载量

938
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:alibabacloud-rds-copilot(alibabacloud RDS GitHub Copilot 命令行)
来源仓库:https://github.com/aliyun/alibabacloud-aiops-skills
仓库路径:skills/alibabacloud-rds-copilot
安装命令:
npx skills add https://github.com/aliyun/alibabacloud-aiops-skills --skill alibabacloud-rds-copilot
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/aliyun/alibabacloud-aiops-skills --skill alibabacloud-rds-copilot

简介

alibabacloud-rds-copilot 作为阿里云 RDS Copilot 的智能助手,提供自然语言驱动的数据库问答服务。

  • 适用于 SQL 优化、实例操作和问题排查等日常运维场景。
  • 直接调用 aliyun rdsai chat-messages 命令与 RDS Copilot 交互,实时获取解答。
  • 需配置阿里云 AK/SK 并确保 CLI 已安装 RDS AI 相关插件。
  • 支持中英文提问,自动解析错误日志并提供修复建议,提升响应效率。

SKILL.md

Alibaba Cloud RDS Copilot Intelligent Operations Assistant

This skill serves as an intelligent agent for Alibaba Cloud RDS Copilot in conversations, helping users with RDS-related intelligent Q&A, SQL optimization, instance operations, and troubleshooting.

Scenario Description

Architecture: Alibaba Cloud CLI + RdsAi OpenAPI

Main features:

  • Understand user's natural language requests (Chinese or English), identify if related to RDS Copilot
  • Directly call Alibaba Cloud CLI to execute aliyun rdsai chat-messages command for real-time RDS Copilot queries
  • When receiving results or user-pasted error messages, further explain, diagnose, and provide recommendations

Installation

Pre-check: Alibaba Cloud CLI must be installed This skill uses Alibaba Cloud CLI to call RdsAi OpenAPI. You need to install and configure Alibaba Cloud CLI first.

Pre-check: Aliyun CLI >= 3.3.3 required

Run aliyun version to verify >= 3.3.3. If not installed or version too low, run curl -fsSL https://aliyuncli.alicdn.com/setup.sh | bash to update, or see references/cli-installation-guide.md for installation instructions.

Pre-check: Aliyun CLI plugin update required

[MUST] run aliyun configure set --auto-plugin-install true to enable automatic plugin installation. [MUST] run aliyun plugin update to ensure that any existing plugins are always up-to-date.

[MUST] CLI User-Agent — Every aliyun CLI command invocation must include: --user-agent AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot

macOS Installation

# Option 1: Install via Homebrew (recommended)
brew install aliyun-cli

# Option 2: Install via PKG package
curl -O https://aliyuncli.alicdn.com/aliyun-cli-latest.pkg
sudo installer -pkg aliyun-cli-latest.pkg -target /

# Option 3: Install via one-click script
/bin/bash -c "$(curl -fsSL https://aliyuncli.alicdn.com/install.sh)"

Linux Installation

# Install via one-click script
/bin/bash -c "$(curl -fsSL https://aliyuncli.alicdn.com/install.sh)"

# Or download TGZ package for manual installation
curl https://aliyuncli.alicdn.com/aliyun-cli-linux-latest-amd64.tgz -o aliyun-cli.tgz
tar xzvf aliyun-cli.tgz
sudo mv aliyun /usr/local/bin/

Verify Installation

aliyun version

Credential Configuration

Option 1: Interactive Configuration (Recommended)

aliyun configure --profile rdsai

Follow the prompts to enter:

  • Access Key Id: Your AccessKey ID
  • Access Key Secret: Your AccessKey Secret
  • Default Region Id: cn-hangzhou (or other regions)

Option 2: Non-interactive Configuration

aliyun configure set \
  --profile rdsai \
  --mode AK \
  --access-key-id <yourAccessKeyID> \
  --access-key-secret <yourAccessKeySecret> \
  --region cn-hangzhou

Command Format

Basic Command Structure

aliyun rdsai chat-messages \
  --query '<query content>' \
  --inputs RegionId=<region ID> Language=<language> Timezone=<timezone> [CustomAgentId=<custom agent ID>] \
  --event-mode separate \
  --endpoint rdsai.aliyuncs.com \
  --user-agent 'AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot' \
  [--conversation-id '<conversation ID>']

Parameter Description

IMPORTANT: Parameter Confirmation — Before executing any command, Determine user intent: SQL writing/optimization, SQL diagnosis, instance parameter tuning, troubleshooting, performance analysis, query instance list, etc. Collect necessary parameters (use default values if not specified).
ParameterRequired/OptionalDescriptionDefault
--queryRequiredUser query content-
--inputs RegionId=OptionalAlibaba Cloud region IDcn-hangzhou
--inputs Language=OptionalLanguagezh-CN
--inputs Timezone=OptionalTimezoneAsia/Shanghai
--inputs CustomAgentId=OptionalCustom Agent IDNone
--event-modeOptionalEvent modeseparate
--endpointRequiredAPI endpointrdsai.aliyuncs.com
--conversation-idOptionalConversation ID for multi-turn dialogueNone
--regionOptionalRegion for API callCredential default region
--profileOptionalSpecify credential profile nameDefault profile
--user-agentRequiredCustom User-AgentAlibabaCloud-Agent-Skills/alibabacloud-rds-copilot

RAM Permissions

This skill requires the following RAM permissions. See references/ram-policies.md for details.

PermissionDescription
rdsai:ChatMessagesCall RDS AI Assistant API

Core Workflow

0. Enable AI-Mode (Before Executing Any CLI Command)

Before executing any aliyun CLI command, you must enable AI-Mode and set the User-Agent:

# [MUST] Enable AI-Mode before any CLI command execution
aliyun configure ai-mode enable

# [MUST] Set User-Agent for AI-Mode
aliyun configure ai-mode set-user-agent --user-agent "AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot"

1. Confirm Task Type and Parameters

Determine user intent: SQL writing/optimization, SQL diagnosis, instance parameter tuning, troubleshooting, performance analysis, query instance list, etc.

Collect necessary parameters (use default values if not specified):

  • RegionId: Region ID (default cn-hangzhou)
  • Language: Language (default zh-CN)
  • Timezone: Timezone (default Asia/Shanghai)
  • CustomAgentId: Custom Agent ID (optional)
  • --conversation-id: Conversation ID for multi-turn dialogue (optional)

2. Construct Command and Call CLI

# Basic query
aliyun rdsai chat-messages \
  --query 'List RDS MySQL instances in Hangzhou region' \
  --inputs RegionId=cn-hangzhou Language=zh-CN Timezone=Asia/Shanghai \
  --event-mode separate \
  --endpoint rdsai.aliyuncs.com \
  --user-agent 'AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot'

# Troubleshooting example
aliyun rdsai chat-messages \
  --query 'RDS instance rm-bp1xxx connection timeout, error Too many connections, please help troubleshoot. Instance is in Hangzhou region.' \
  --inputs RegionId=cn-hangzhou Language=zh-CN Timezone=Asia/Shanghai \
  --event-mode separate \
  --endpoint rdsai.aliyuncs.com \
  --user-agent 'AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot'

# Query with Beijing region
aliyun rdsai chat-messages \
  --query 'Optimize this SQL: SELECT * FROM users WHERE name LIKE "%test%"' \
  --inputs RegionId=cn-beijing Language=zh-CN Timezone=Asia/Shanghai \
  --event-mode separate \
  --endpoint rdsai.aliyuncs.com \
  --user-agent 'AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot'

# Multi-turn dialogue (using ConversationId from previous response)
aliyun rdsai chat-messages \
  --query 'Continue analyzing the above issue' \
  --conversation-id '<ConversationId from previous response>' \
  --inputs RegionId=cn-hangzhou Language=zh-CN Timezone=Asia/Shanghai \
  --event-mode separate \
  --endpoint rdsai.aliyuncs.com \
  --user-agent 'AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot'

# Using custom Agent
aliyun rdsai chat-messages \
  --query 'Analyze database performance' \
  --inputs RegionId=cn-hangzhou Language=zh-CN Timezone=Asia/Shanghai CustomAgentId=your-custom-agent-id \
  --event-mode separate \
  --endpoint rdsai.aliyuncs.com \
  --user-agent 'AlibabaCloud-Agent-Skills/alibabacloud-rds-copilot'

3. Parse Results and Follow-up Processing

  • Explain RDS Copilot's response to the user in natural language
  • If the response contains SQL or operational steps, assess risks and warn:

- Avoid executing high-risk statements directly in production (e.g., large table DELETE / UPDATE / schema changes) - Recommend validating in test environment or adding backup/condition restrictions

  • If continuing the conversation, record the ConversationId from the response for the next query

4. Disable AI-Mode (After Workflow Ends)

After the workflow is complete, you must disable AI-Mode:

# [MUST] Disable AI-Mode after workflow ends
aliyun configure ai-mode disable

Output Format

Alibaba Cloud CLI returns JSON format responses (streaming multiple JSON events):

{"data":{"ConversationId":"8227be22-xxxx-xxxx-xxxx-xxxxxxxxxxxx","Event":"workflow_started","MessageId":"a79c881c-xxxx-xxxx-xxxx-xxxxxxxxxxxx",...}}
{"data":{"Answer":"<partial answer content>","Event":"message",...}}
{"data":{"Event":"workflow_finished",...}}

Key fields:

  • ConversationId: Conversation ID (for multi-turn dialogue)
  • Answer: AI assistant's response content
  • Event: Event type (workflow_started, message, workflow_finished)

Success Verification

  1. CLI installation successful: aliyun version shows version number
  2. Credential configured correctly: aliyun configure list shows configured credentials
  3. API call successful: Response contains ConversationId and Answer in JSON format
  4. Response content valid: Answer is relevant to the query content

See references/verification-method.md for detailed verification steps.


Cleanup

This skill only performs read-only query operations, does not create any cloud resources, no cleanup required.


API and Command List

See references/related-apis.md for details.

ProductAPI ActionCLI CommandDescription
RdsAiChatMessagesaliyun rdsai chat-messagesRDS AI Assistant dialogue API

Best Practices

  1. Use multi-turn dialogue: For complex issues, use --conversation-id for context-aware multi-turn conversations
  2. Specify correct region: Set RegionId parameter based on the RDS instance's region
  3. Be cautious in production: SQL recommendations from RDS Copilot should be validated in test environment first
  4. Save conversation ID: Save the returned ConversationId if you need to follow up or continue analysis
  5. Use configuration file: Recommend using aliyun configure to configure credentials, avoid exposing sensitive information in command line
  6. Use --profile: You can configure multiple credential profiles and switch between accounts using --profile

Reference Links

Reference DocumentDescription
Alibaba Cloud CLI DocumentationAlibaba Cloud CLI User Guide
references/related-apis.mdAPI and Command List
references/ram-policies.mdRAM Policy Configuration
references/verification-method.mdVerification Methods
references/acceptance-criteria.mdAcceptance Criteria

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.03%
按下载量换算319

Claude

32.06%
按下载量换算301

Cursor

21.42%
按下载量换算201

Gemini CLI

9.81%
按下载量换算92

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills