PolarDB-X Distributed Database AI Assistant This skill provides intelligent O&M capabilities for Alibaba Cloud PolarDB-X distributed database , powered by the DAS (Database Autonomy Service) API via the aliyun CLI DAS plugin. Architecture : - - - PolarDB-X Intelligent Diagnostics Supported Capabilities | Capability | Description | |------------|-------------| | Instance Information | Instance details, cluster configuration, version info | | Topology Inspection | CN/DN node distribution, shard topology, data node status | | Storage Information | Disk usage, storage capacity, space growth trend…

\\r'}\"\n [[ -z \"$line\" ]] && continue\n\n # Detect response format on first line\n if [[ \"$format_detected\" == false ]]; then\n if [[ \"$line\" =~ ^data: ]]; then\n is_sse=true\n debug_log \"Detected SSE format response\"\n elif echo \"$line\" | jq -e '.data' &>/dev/null 2>&1; then\n is_json_stream=true\n debug_log \"Detected streaming JSON format response (DAS plugin)\"\n else\n # Might be error response or plain JSON, buffer first\n error_buffer=\"$line\"\n # Check if error response\n local error_code\n error_code=$(echo \"$line\" | jq -r '.Code // empty' 2>/dev/null) || true\n if [[ -n \"$error_code\" ]]; then\n local error_msg\n error_msg=$(echo \"$line\" | jq -r '.Message // empty' 2>/dev/null) || true\n echo \"Error: ${error_msg:-Unknown error} (${error_code})\" >&2\n if [[ \"$error_code\" == *\"Throttling\"* ]] || [[ \"$error_code\" == *\"ConcurrentLimit\"* ]]; then\n echo \"Max 2 concurrent sessions per account. Please wait for previous query to complete.\" >&2\n return 2\n fi\n return 1\n fi\n # Try to handle as plain JSON response\n local content\n content=$(echo \"$line\" | jq -r '.Content // .Data // empty' 2>/dev/null) || true\n if [[ -n \"$content\" ]]; then\n printf \"%s\" \"$content\"\n session_id=$(echo \"$line\" | jq -r '.SessionId // empty' 2>/dev/null) || true\n else\n # Cannot parse, output as-is\n echo \"$line\"\n fi\n format_detected=true\n continue\n fi\n format_detected=true\n fi\n\n # Process SSE format\n if [[ \"$is_sse\" == true ]]; then\n if [[ \"$line\" =~ ^data:\\ ?(.*) ]]; then\n local data=\"${BASH_REMATCH[1]}\"\n [[ \"$data\" == \"[DONE]\" || -z \"$data\" ]] && continue\n\n local chunk_content\n chunk_content=$(echo \"$data\" | jq -r '.Content // empty' 2>/dev/null) || true\n [[ -n \"$chunk_content\" ]] && printf \"%s\" \"$chunk_content\"\n\n local chunk_session\n chunk_session=$(echo \"$data\" | jq -r '.SessionId // empty' 2>/dev/null) || true\n [[ -n \"$chunk_session\" ]] && session_id=\"$chunk_session\"\n\n if [[ \"$DEBUG\" == \"true\" ]]; then\n local reasoning\n reasoning=$(echo \"$data\" | jq -r '.ReasoningContent // empty' 2>/dev/null) || true\n [[ -n \"$reasoning\" ]] && debug_log \"Reasoning: $reasoning\"\n fi\n fi\n fi\n\n # Process streaming JSON format\n if [[ \"$is_json_stream\" == true ]]; then\n local chunk_content\n chunk_content=$(echo \"$line\" | jq -r '.data.Content // empty' 2>/dev/null) || true\n [[ -n \"$chunk_content\" ]] && printf \"%s\" \"$chunk_content\"\n\n local chunk_session\n chunk_session=$(echo \"$line\" | jq -r '.data.SessionId // empty' 2>/dev/null) || true\n [[ -n \"$chunk_session\" ]] && session_id=\"$chunk_session\"\n\n if [[ \"$DEBUG\" == \"true\" ]]; then\n local reasoning\n reasoning=$(echo \"$line\" | jq -r '.data.ReasoningContent // empty' 2>/dev/null) || true\n [[ -n \"$reasoning\" ]] && debug_log \"Reasoning: $reasoning\"\n fi\n fi\n done\n\n # Output newline (end of content)\n echo \"\"\n\n # Output session ID (to stderr for multi-turn conversation)\n if [[ -n \"$session_id\" ]]; then\n echo \"\" >&2\n echo \"[SessionID] $session_id\" >&2\n fi\n}\n\n# --- Argument parsing ---\nwhile [[ $# -gt 0 ]]; do\n case \"$1\" in\n --session-id)\n SESSION_ID=\"$2\"\n shift 2\n ;;\n --profile)\n PROFILE=\"$2\"\n shift 2\n ;;\n --debug|-d)\n DEBUG=true\n shift\n ;;\n --help|-h)\n usage\n exit 0\n ;;\n -)\n QUERY=$(cat)\n shift\n ;;\n -*)\n echo \"Unknown option: $1\" >&2\n usage\n exit 1\n ;;\n *)\n QUERY=\"$1\"\n shift\n ;;\n esac\ndone\n\n# --- Input Validation ---\n# All agent inputs are treated as untrusted; validate type, format, and boundaries.\n\nif [[ -z \"$QUERY\" ]]; then\n usage\n exit 1\nfi\n\n# QUERY: enforce maximum length (8192 characters)\nMAX_QUERY_LENGTH=8192\nif [[ ${#QUERY} -gt $MAX_QUERY_LENGTH ]]; then\n echo \"Error: Query too long (${#QUERY} chars). Maximum allowed: $MAX_QUERY_LENGTH characters.\" >&2\n exit 1\nfi\n\n# SESSION_ID: if provided, must match expected format (alphanumeric, hyphens, underscores, dots, 1-128 chars)\nif [[ -n \"$SESSION_ID\" ]]; then\n if [[ ${#SESSION_ID} -gt 128 ]]; then\n echo \"Error: Session ID too long (${#SESSION_ID} chars). Maximum allowed: 128 characters.\" >&2\n exit 1\n fi\n if [[ ! \"$SESSION_ID\" =~ ^[a-zA-Z0-9._-]+$ ]]; then\n echo \"Error: Session ID contains invalid characters. Only alphanumeric, hyphen, underscore, and dot are allowed.\" >&2\n exit 1\n fi\nfi\n\n# PROFILE: if provided, must match safe character whitelist (alphanumeric, hyphens, underscores, 1-64 chars)\nif [[ -n \"$PROFILE\" ]]; then\n if [[ ${#PROFILE} -gt 64 ]]; then\n echo \"Error: Profile name too long (${#PROFILE} chars). Maximum allowed: 64 characters.\" >&2\n exit 1\n fi\n if [[ ! \"$PROFILE\" =~ ^[a-zA-Z0-9_-]+$ ]]; then\n echo \"Error: Profile name contains invalid characters. Only alphanumeric, hyphen, and underscore are allowed.\" >&2\n exit 1\n fi\nfi\n\ncheck_dependencies\n\n# --- Build CLI command arguments ---\n# Use DAS plugin's kebab-case command, supports Signature V3\ncli_args=(das get-yao-chi-agent\n --query \"$QUERY\"\n --source \"$SOURCE\"\n --endpoint \"$ENDPOINT\"\n --read-timeout \"$READ_TIMEOUT\"\n --connect-timeout \"$CONNECT_TIMEOUT\"\n --user-agent AlibabaCloud-Agent-Skills/alibabacloud-polardbx-ai-assistant\n)\n\nif [[ -n \"$SESSION_ID\" ]]; then\n cli_args+=(--session-id \"$SESSION_ID\")\nfi\n\nif [[ -n \"$PROFILE\" ]]; then\n cli_args+=(--profile \"$PROFILE\")\nfi\n\n# --- Output query info ---\necho \"[Query] $QUERY\" >&2\nif [[ -n \"$SESSION_ID\" ]]; then\n echo \"[SessionID] $SESSION_ID\" >&2\nfi\necho \"============================================================\" >&2\necho \"[YaoChi Agent Response]\" >&2\n\ndebug_log \"Executing: aliyun ${cli_args[*]}\"\n\n# --- Execute and stream parse (with throttling retry) ---\nfor (( attempt=1; attempt\u003c=THROTTLE_RETRY_MAX; attempt++ )); do\n debug_log \"Attempt $attempt/$THROTTLE_RETRY_MAX: aliyun ${cli_args[*]}\"\n\n set +e\n aliyun \"${cli_args[@]}\" 2>&1 | parse_sse_streaming\n parse_exit=${PIPESTATUS[1]}\n set -e\n\n # Exit code 2 = throttling error, retry after waiting\n if [[ $parse_exit -eq 2 ]]; then\n if [[ $attempt -lt $THROTTLE_RETRY_MAX ]]; then\n echo \"[Retry] Throttling detected, waiting ${THROTTLE_RETRY_INTERVAL}s before retry ($attempt/$THROTTLE_RETRY_MAX)...\" >&2\n sleep \"$THROTTLE_RETRY_INTERVAL\"\n continue\n else\n echo \"[Retry] Throttling persists after $THROTTLE_RETRY_MAX attempts, giving up.\" >&2\n exit 1\n fi\n fi\n\n # Any other result (success or non-throttling error), stop retrying\n break\ndone\n","content_type":"application/x-sh; charset=utf-8","language":"bash","size":11074,"content_sha256":"dbd3aed53a24504937e323c3cda49c2a8489c15e4bb107b198346f1581c9b894"}],"content_json":{"type":"doc","content":[{"type":"heading","attrs":{"level":1},"content":[{"text":"PolarDB-X Distributed Database AI Assistant","type":"text"}]},{"type":"paragraph","content":[{"text":"This skill provides intelligent O&M capabilities for ","type":"text"},{"text":"Alibaba Cloud PolarDB-X distributed database","type":"text","marks":[{"type":"strong"}]},{"text":", powered by the DAS (Database Autonomy Service) ","type":"text"},{"text":"get-yao-chi-agent","type":"text","marks":[{"type":"code_inline"}]},{"text":" API via the aliyun CLI DAS plugin.","type":"text"}]},{"type":"paragraph","content":[{"text":"Architecture","type":"text","marks":[{"type":"strong"}]},{"text":": ","type":"text"},{"text":"Aliyun CLI","type":"text","marks":[{"type":"code_inline"}]},{"text":" -> ","type":"text"},{"text":"DAS Plugin (Signature V3)","type":"text","marks":[{"type":"code_inline"}]},{"text":" -> ","type":"text"},{"text":"get-yao-chi-agent API","type":"text","marks":[{"type":"code_inline"}]},{"text":" -> PolarDB-X Intelligent Diagnostics","type":"text"}]},{"type":"heading","attrs":{"level":3},"content":[{"text":"Supported Capabilities","type":"text"}]},{"type":"table","attrs":{"layout":null},"content":[{"type":"tr","content":[{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Capability","type":"text"}]}]},{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Description","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Instance Information","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Instance details, cluster configuration, version info","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Topology Inspection","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"CN/DN node distribution, shard topology, data node status","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Storage Information","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Disk usage, storage capacity, space growth trends","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"SQL Optimization","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Slow SQL analysis, distributed execution plan interpretation, index suggestions, cross-shard query optimization","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Cluster Performance Monitoring","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"QPS/TPS/connections/throughput and other core metrics analysis","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Connection & Session Analysis","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Connection count monitoring, session troubleshooting, connection pool optimization","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Security Audit","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Whitelist, SSL, security policy audit","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Backup Status Check","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Backup completeness, retention policy, point-in-time recovery","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Instance Health Check","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Instance health status, running state verification","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Log Diagnostics","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Error log analysis, slow log troubleshooting","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Data Distribution Analysis","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Shard data skew detection, hotspot shard diagnostics","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Elastic Scaling Diagnostics","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Scale-out/in status, data migration progress, node load balancing","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Parameter Tuning","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Kernel parameter interpretation, change impact assessment, configuration recommendations","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"High Availability & DR","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"HA configuration assessment, disaster recovery architecture diagnostics, primary-standby status","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Expiring Instance Query","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Subscription instance expiration reminders, renewal status","type":"text"}]}]}]}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Installation","type":"text"}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"Pre-check: Aliyun CLI >= 3.3.3 required","type":"text","marks":[{"type":"strong"}]},{"text":" Run ","type":"text"},{"text":"aliyun version","type":"text","marks":[{"type":"code_inline"}]},{"text":" to verify >= 3.3.3. If not installed or version too low, run ","type":"text"},{"text":"curl -fsSL https://aliyuncli.alicdn.com/setup.sh | bash","type":"text","marks":[{"type":"code_inline"}]},{"text":" to install/update, or see ","type":"text"},{"text":"references/cli-installation-guide.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/cli-installation-guide.md","title":null}}]},{"text":" for installation instructions.","type":"text"}]}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"Pre-check: Aliyun CLI plugin update required","type":"text","marks":[{"type":"strong"}]},{"text":" ","type":"text"},{"text":"[MUST]","type":"text","marks":[{"type":"strong"}]},{"text":" run ","type":"text"},{"text":"aliyun configure set --auto-plugin-install true","type":"text","marks":[{"type":"code_inline"}]},{"text":" to enable automatic plugin installation. ","type":"text"},{"text":"[MUST]","type":"text","marks":[{"type":"strong"}]},{"text":" run ","type":"text"},{"text":"aliyun plugin update","type":"text","marks":[{"type":"code_inline"}]},{"text":" to ensure that any existing plugins on your local machine are always up-to-date.","type":"text"}]}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"[MUST] CLI User-Agent","type":"text","marks":[{"type":"strong"}]},{"text":" — Every ","type":"text"},{"text":"aliyun","type":"text","marks":[{"type":"code_inline"}]},{"text":" CLI command invocation must include: ","type":"text"},{"text":"--user-agent AlibabaCloud-Agent-Skills/alibabacloud-polardbx-ai-assistant","type":"text","marks":[{"type":"code_inline"}]}]}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"[MUST] Enable AI-Mode","type":"text","marks":[{"type":"strong"}]},{"text":" — AI-mode is required for Agent Skill execution. Run the following commands before any CLI invocation:","type":"text"}]},{"type":"code_block","attrs":{"wrap":false,"language":"bash"},"content":[{"text":"aliyun configure ai-mode enable\naliyun configure ai-mode set-user-agent --user-agent \"AlibabaCloud-Agent-Skills/alibabacloud-polardbx-ai-assistant\"","type":"text"}]}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"[MUST] Disable AI-Mode at EVERY exit point","type":"text","marks":[{"type":"strong"}]},{"text":" — Before delivering the final response for ANY reason, always disable AI-mode first. This applies to ALL exit paths: workflow success, workflow failure, error/exception, user cancellation, session end, or any other scenario where no further CLI commands will be executed. AI-mode is only used for Agent Skill invocation scenarios and MUST NOT remain enabled after the skill stops running.","type":"text"}]},{"type":"code_block","attrs":{"wrap":false,"language":"bash"},"content":[{"text":"aliyun configure ai-mode disable","type":"text"}]}]},{"type":"code_block","attrs":{"wrap":false,"language":"bash"},"content":[{"text":"# Install aliyun CLI\ncurl -fsSL https://aliyuncli.alicdn.com/install.sh | bash\naliyun version # Verify >= 3.3.3\n\n# Enable automatic plugin installation\naliyun configure set --auto-plugin-install true\n\n# Install DAS plugin (get-yao-chi-agent requires plugin for Signature V3 support)\naliyun plugin install --names aliyun-cli-das\n\n# Install jq (for JSON response parsing)\n# macOS:\nbrew install jq\n# Ubuntu/Debian:\n# sudo apt-get install jq","type":"text"}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Environment Variables","type":"text"}]},{"type":"paragraph","content":[{"text":"No additional environment variables are required. This skill relies entirely on the aliyun CLI's existing credential configuration.","type":"text"}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Authentication","type":"text"}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"Pre-check: Alibaba Cloud Credentials Required","type":"text","marks":[{"type":"strong"}]}]},{"type":"paragraph","content":[{"text":"Security Rules:","type":"text","marks":[{"type":"strong"}]}]},{"type":"bullet_list","content":[{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"NEVER","type":"text","marks":[{"type":"strong"}]},{"text":" read, echo, or print AK/SK values (e.g., ","type":"text"},{"text":"echo $ALIBABA_CLOUD_ACCESS_KEY_ID","type":"text","marks":[{"type":"code_inline"}]},{"text":" is FORBIDDEN)","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"NEVER","type":"text","marks":[{"type":"strong"}]},{"text":" ask the user to input AK/SK directly in the conversation or command line","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"NEVER","type":"text","marks":[{"type":"strong"}]},{"text":" use ","type":"text"},{"text":"aliyun configure set","type":"text","marks":[{"type":"code_inline"}]},{"text":" with literal credential values","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"ONLY","type":"text","marks":[{"type":"strong"}]},{"text":" use ","type":"text"},{"text":"aliyun configure list","type":"text","marks":[{"type":"code_inline"}]},{"text":" to check credential status","type":"text"}]}]}]},{"type":"code_block","attrs":{"wrap":false,"language":"bash"},"content":[{"text":"aliyun configure list","type":"text"}]},{"type":"paragraph","content":[{"text":"Check the output for a valid profile (AK, STS, or OAuth identity).","type":"text"}]},{"type":"paragraph","content":[{"text":"If no valid profile exists, STOP here.","type":"text","marks":[{"type":"strong"}]}]},{"type":"ordered_list","attrs":{"order":1,"listStyle":"number"},"content":[{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Obtain credentials from ","type":"text"},{"text":"Alibaba Cloud Console","type":"text","marks":[{"type":"link","attrs":{"href":"https://ram.console.aliyun.com/manage/ak","title":null}}]}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Configure credentials ","type":"text"},{"text":"outside of this session","type":"text","marks":[{"type":"strong"}]},{"text":" (via ","type":"text"},{"text":"aliyun configure","type":"text","marks":[{"type":"code_inline"}]},{"text":" in terminal or environment variables in shell profile)","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Return and re-run after ","type":"text"},{"text":"aliyun configure list","type":"text","marks":[{"type":"code_inline"}]},{"text":" shows a valid profile","type":"text"}]}]}]}]},{"type":"paragraph","content":[{"text":"Credentials are managed through aliyun CLI configuration — ","type":"text"},{"text":"no additional AK/SK setup is needed","type":"text","marks":[{"type":"strong"}]},{"text":":","type":"text"}]},{"type":"code_block","attrs":{"wrap":false,"language":"bash"},"content":[{"text":"# Recommended: OAuth mode\naliyun configure --mode OAuth\n\n# Alternative: AK mode (configure outside of agent session)\naliyun configure set \\\n --mode AK \\\n --access-key-id \u003cyour-access-key-id> \\\n --access-key-secret \u003cyour-access-key-secret> \\\n --region cn-hangzhou\n\n# Cross-account access: RamRoleArn mode\naliyun configure set \\\n --mode RamRoleArn \\\n --access-key-id \u003cyour-access-key-id> \\\n --access-key-secret \u003cyour-access-key-secret> \\\n --ram-role-arn acs:ram::\u003caccount-id>:role/\u003crole-name> \\\n --role-session-name yaochi-agent-session \\\n --region cn-hangzhou","type":"text"}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"RAM Policy","type":"text"}]},{"type":"paragraph","content":[{"text":"See ","type":"text"},{"text":"references/ram-policies.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/ram-policies.md","title":null}}]},{"text":" for the full list of required permissions.","type":"text"}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"[MUST] Permission Failure Handling:","type":"text","marks":[{"type":"strong"}]},{"text":" When any command or API call fails due to permission errors at any point during execution, follow this process:","type":"text"}]},{"type":"ordered_list","attrs":{"order":1,"listStyle":"number"},"content":[{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Read ","type":"text"},{"text":"references/ram-policies.md","type":"text","marks":[{"type":"code_inline"}]},{"text":" to get the full list of permissions required by this SKILL","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Use ","type":"text"},{"text":"ram-permission-diagnose","type":"text","marks":[{"type":"code_inline"}]},{"text":" skill to guide the user through requesting the necessary permissions","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Pause and wait until the user confirms that the required permissions have been granted","type":"text"}]}]}]}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Parameter Confirmation","type":"text"}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"IMPORTANT: Parameter Confirmation","type":"text","marks":[{"type":"strong"}]},{"text":" — Before executing any command or API call, ALL user-customizable parameters (e.g., RegionId, instance names, CIDR blocks, passwords, domain names, resource specifications, etc.) MUST be confirmed with the user. Do NOT assume or use default values without explicit user approval.","type":"text"}]}]},{"type":"table","attrs":{"layout":null},"content":[{"type":"tr","content":[{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Parameter","type":"text"}]}]},{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Required/Optional","type":"text"}]}]},{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Description","type":"text"}]}]},{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Default Value","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"query","type":"text","marks":[{"type":"code_inline"}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Required","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Natural language query content (including region, instance info, etc.)","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"-","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"--session-id","type":"text","marks":[{"type":"code_inline"}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Optional","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Session ID for multi-turn conversation context","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"-","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"--profile","type":"text","marks":[{"type":"code_inline"}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Optional","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"aliyun CLI profile name","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"default","type":"text"}]}]}]}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Core Workflow","type":"text"}]},{"type":"paragraph","content":[{"text":"All intelligent O&M operations ","type":"text"},{"text":"MUST","type":"text","marks":[{"type":"strong"}]},{"text":" be invoked through ","type":"text"},{"text":"scripts/call_yaochi_agent.sh","type":"text","marks":[{"type":"code_inline"}]},{"text":", which wraps the ","type":"text"},{"text":"aliyun das get-yao-chi-agent","type":"text","marks":[{"type":"code_inline"}]},{"text":" (DAS plugin kebab-case command, supporting Signature V3) with streaming response parsing.","type":"text"}]},{"type":"blockquote","content":[{"type":"paragraph","content":[{"text":"⚠️ CRITICAL RESTRICTION:","type":"text","marks":[{"type":"strong"}]}]},{"type":"bullet_list","content":[{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"DO NOT","type":"text","marks":[{"type":"strong"}]},{"text":" use direct ","type":"text"},{"text":"aliyun polardbx","type":"text","marks":[{"type":"code_inline"}]},{"text":" or ","type":"text"},{"text":"aliyun rds","type":"text","marks":[{"type":"code_inline"}]},{"text":" CLI commands for diagnostics, topology, or security audits.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"DO NOT","type":"text","marks":[{"type":"strong"}]},{"text":" attempt to query instance details using ","type":"text"},{"text":"DescribeDBInstances","type":"text","marks":[{"type":"code_inline"}]},{"text":" or similar APIs directly.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"ONLY","type":"text","marks":[{"type":"strong"}]},{"text":" use the DAS plugin command: ","type":"text"},{"text":"aliyun das get-yao-chi-agent","type":"text","marks":[{"type":"code_inline"}]},{"text":" (wrapped by ","type":"text"},{"text":"call_yaochi_agent.sh","type":"text","marks":[{"type":"code_inline"}]},{"text":").","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"If the script fails, check permissions via ","type":"text"},{"text":"ram-permission-diagnose","type":"text","marks":[{"type":"code_inline"}]},{"text":" skill, ","type":"text"},{"text":"DO NOT","type":"text","marks":[{"type":"strong"}]},{"text":" fallback to other product APIs.","type":"text"}]}]}]}]},{"type":"code_block","attrs":{"wrap":false,"language":"bash"},"content":[{"text":"# Cluster Management\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"List PolarDB-X instances in Hangzhou region\"\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show detailed configuration of instance pxc-xxx\"\n\n# Topology Inspection\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show CN/DN node distribution of instance pxc-xxx\"\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show shard topology of instance pxc-xxx\"\n\n# Performance Diagnostics\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Analyze performance of instance pxc-xxx in the last hour\"\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show slow SQL of instance pxc-xxx\"\n\n# SQL Optimization\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Optimize execution plan of this SQL on instance pxc-xxx\"\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Which cross-shard queries on instance pxc-xxx need optimization\"\n\n# Data Distribution\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Check whether data distribution of instance pxc-xxx is even\"\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Are there any hotspot shards on instance pxc-xxx\"\n\n# Elastic Scaling\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show scale-out status of instance pxc-xxx\"\n\n# Parameter Tuning\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"How to tune CONN_POOL_MAX_POOL_SIZE parameter on instance pxc-xxx\"\n\n# Connection & Session\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"How to troubleshoot high connection count on instance pxc-xxx\"\n\n# Backup & Restore\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show backup status of instance pxc-xxx\"\n\n# Security Audit\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Check security configuration of instance pxc-xxx\"\n\n# High Availability & DR\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Show HA configuration of instance pxc-xxx\"\n\n# Multi-turn Conversation (use session ID returned from previous call)\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"Continue analysis\" --session-id \"\u003csession-id>\"\n\n# Specify profile\nbash $SKILL_DIR/scripts/call_yaochi_agent.sh \"List instances\" --profile myprofile\n\n# Read from stdin\necho \"List instances\" | bash $SKILL_DIR/scripts/call_yaochi_agent.sh -","type":"text"}]},{"type":"heading","attrs":{"level":3},"content":[{"text":"Typical Query Examples","type":"text"}]},{"type":"table","attrs":{"layout":null},"content":[{"type":"tr","content":[{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Scenario","type":"text"}]}]},{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Example Query","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Cluster Management","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Show node list of instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Topology","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"How many CN and DN nodes does instance pxc-xxx have","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Performance Diagnostics","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"How to troubleshoot high CPU usage on instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Slow SQL Analysis","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Show slow SQL of instance pxc-xxx in the last hour","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"SQL Optimization","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Why is this SELECT statement slow on instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Data Distribution","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Is there data skew in shards of instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Elastic Scaling","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"What is the scale-out progress of instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Parameter Tuning","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"How to optimize connection pool parameters on instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Backup & Restore","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"When was the latest backup of instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Storage Optimization","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"What to do about rapid storage growth on instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Connection Troubleshooting","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Instance pxc-xxx connection count is maxed out","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Security Audit","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Check security configuration of instance pxc-xxx","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"High Availability","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Is the DR architecture of instance pxc-xxx reasonable","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Expiration Reminder","type":"text"}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Which PolarDB-X instances are about to expire","type":"text"}]}]}]}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Success Verification","type":"text"}]},{"type":"paragraph","content":[{"text":"See ","type":"text"},{"text":"references/verification-method.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/verification-method.md","title":null}}]},{"text":" for detailed verification steps.","type":"text"}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Cleanup","type":"text"}]},{"type":"paragraph","content":[{"text":"This skill focuses on ","type":"text"},{"text":"query and diagnostics","type":"text","marks":[{"type":"strong"}]},{"text":" capabilities only. It does not create any resources, so no cleanup is needed.","type":"text"}]},{"type":"paragraph","content":[{"text":"The following operations are ","type":"text"},{"text":"out of scope","type":"text","marks":[{"type":"strong"}]},{"text":" for this skill:","type":"text"}]},{"type":"bullet_list","content":[{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Creating/deleting PolarDB-X instances","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Changing instance specifications","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Purchasing/renewing instances","type":"text"}]}]}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Command Tables","type":"text"}]},{"type":"paragraph","content":[{"text":"See ","type":"text"},{"text":"references/related-apis.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/related-apis.md","title":null}}]},{"text":" for the full list of APIs and CLI commands.","type":"text"}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Best Practices","type":"text"}]},{"type":"ordered_list","attrs":{"order":1,"listStyle":"number"},"content":[{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Instance ID Format","type":"text","marks":[{"type":"strong"}]},{"text":": PolarDB-X instance IDs start with ","type":"text"},{"text":"pxc-","type":"text","marks":[{"type":"code_inline"}]},{"text":". Always include the full instance ID in queries.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Region Specification","type":"text","marks":[{"type":"strong"}]},{"text":": Explicitly specify the region in natural language queries (e.g., \"Hangzhou region\", \"Beijing region\") to improve query accuracy.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Multi-turn Conversation","type":"text","marks":[{"type":"strong"}]},{"text":": Use ","type":"text"},{"text":"--session-id","type":"text","marks":[{"type":"code_inline"}]},{"text":" to maintain context continuity in complex diagnostic scenarios.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Concurrency Limit","type":"text","marks":[{"type":"strong"}]},{"text":": Maximum 2 concurrent sessions per account. Avoid launching multiple parallel calls.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Distributed Characteristics","type":"text","marks":[{"type":"strong"}]},{"text":": When troubleshooting issues, distinguish between CN (Compute Node) and DN (Data Node) layers.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Throttling Handling","type":"text","marks":[{"type":"strong"}]},{"text":": If you encounter a ","type":"text"},{"text":"Throttling.UserConcurrentLimit","type":"text","marks":[{"type":"code_inline"}]},{"text":" error, wait for the previous query to complete before retrying.","type":"text"}]}]},{"type":"list_item","content":[{"type":"paragraph","content":[{"text":"Credential Security","type":"text","marks":[{"type":"strong"}]},{"text":": Use ","type":"text"},{"text":"aliyun configure","type":"text","marks":[{"type":"code_inline"}]},{"text":" to manage credentials. Never hardcode AK/SK in scripts.","type":"text"}]}]}]},{"type":"heading","attrs":{"level":2},"content":[{"text":"Reference Links","type":"text"}]},{"type":"table","attrs":{"layout":null},"content":[{"type":"tr","content":[{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Reference","type":"text"}]}]},{"type":"th","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Description","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"references/cli-installation-guide.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/cli-installation-guide.md","title":null}}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Aliyun CLI installation and configuration guide","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"references/related-apis.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/related-apis.md","title":null}}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Related APIs and CLI command list","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"references/ram-policies.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/ram-policies.md","title":null}}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"RAM permission policy list","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"references/verification-method.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/verification-method.md","title":null}}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Success verification methods","type":"text"}]}]}]},{"type":"tr","content":[{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"references/acceptance-criteria.md","type":"text","marks":[{"type":"link","attrs":{"href":"references/acceptance-criteria.md","title":null}}]}]}]},{"type":"td","attrs":{"colspan":1,"rowspan":1,"colwidth":null,"alignment":""},"content":[{"type":"paragraph","content":[{"text":"Acceptance criteria","type":"text"}]}]}]}]},{"type":"hr","attrs":{"markup":"---"}}]},"metadata":{"date":"2026-06-05","name":"alibabacloud-polardbx-ai-assistant","author":"@skillopedia","source":{"stars":133,"repo_name":"alibabacloud-aiops-skills","origin_url":"https://github.com/aliyun/alibabacloud-aiops-skills/blob/HEAD/skills/database/drds/alibabacloud-polardbx-ai-assistant/SKILL.md","repo_owner":"aliyun","body_sha256":"94874fbff95b89b0df0f85da4f63b551d4bbe45c5087fa400ac0a645f228c385","cluster_key":"84c9be33a150ec829e38758941087157de4e69a617e82584ad2de4b0f42c1eb9","clean_bundle":{"format":"clean-skill-bundle-v1","source":"aliyun/alibabacloud-aiops-skills/skills/database/drds/alibabacloud-polardbx-ai-assistant/SKILL.md","attachments":[{"id":"8c63826e-13e6-5c1a-9616-0c4e8ac5cb7b","key":"uploads/10433ee7-ad12-4ae0-b34e-97553e46c6c8/8c63826e-13e6-5c1a-9616-0c4e8ac5cb7b/attachment.md","path":"references/acceptance-criteria.md","size":5945,"sha256":"b82b868238751ee3e86a5f4782aeda926639bfce6d88ad48f448b791890ea848","contentType":"text/markdown; charset=utf-8"},{"id":"d6e7fa35-afa8-5fdb-a581-1a60dee61834","key":"uploads/10433ee7-ad12-4ae0-b34e-97553e46c6c8/d6e7fa35-afa8-5fdb-a581-1a60dee61834/attachment.md","path":"references/cli-installation-guide.md","size":11622,"sha256":"93abdd4f4a067822cca6894aa890855a50e723a6f6243f208887f171d6635170","contentType":"text/markdown; charset=utf-8"},{"id":"f22f8661-54b7-52b0-97bf-491b42addc5e","key":"uploads/10433ee7-ad12-4ae0-b34e-97553e46c6c8/f22f8661-54b7-52b0-97bf-491b42addc5e/attachment.md","path":"references/ram-policies.md","size":1547,"sha256":"bc480136778f4e5c1b4491f01ca9f982cad0a609d82b4c6bf6f3439a6cb7d537","contentType":"text/markdown; charset=utf-8"},{"id":"5b2e14ac-acf9-544f-843a-ddb221454580","key":"uploads/10433ee7-ad12-4ae0-b34e-97553e46c6c8/5b2e14ac-acf9-544f-843a-ddb221454580/attachment.md","path":"references/related-apis.md","size":2095,"sha256":"9aabc480a27a58b41e9e938a58af5b0bc039394ccdd3816034d932c72fd9eb84","contentType":"text/markdown; charset=utf-8"},{"id":"d83c2ce0-ca03-5d79-ae27-ec7e46775624","key":"uploads/10433ee7-ad12-4ae0-b34e-97553e46c6c8/d83c2ce0-ca03-5d79-ae27-ec7e46775624/attachment.md","path":"references/verification-method.md","size":2385,"sha256":"ceeee17e405b10853b93b149ed6077d1c83ff7651fa5e0b7990cbef23a36c36f","contentType":"text/markdown; charset=utf-8"},{"id":"7fabeba1-b99e-5ee5-829b-830711a366aa","key":"uploads/10433ee7-ad12-4ae0-b34e-97553e46c6c8/7fabeba1-b99e-5ee5-829b-830711a366aa/attachment.sh","path":"scripts/call_yaochi_agent.sh","size":11074,"sha256":"dbd3aed53a24504937e323c3cda49c2a8489c15e4bb107b198346f1581c9b894","contentType":"application/x-sh; charset=utf-8"}],"bundle_sha256":"dcba45ae53058c2869e6b37206026a662c8f4b65e73d3aeaeb4da2d70f1cfbd9","attachment_count":6,"text_attachments":6,"attachment_storage":"skillopedia-attachments-v1","binary_attachments":0,"excluded_attachments":[]},"cluster_size":1,"skill_md_path":"skills/database/drds/alibabacloud-polardbx-ai-assistant/SKILL.md","import_metadata":{"date":"2026-06-05","author":"@skillopedia","version":"v1","category":"security","category_label":"Security"},"exact_dupes_collapsed_into_this":0},"version":"v1","category":"security","import_tag":"clean-skills-v1","description":"Alibaba Cloud PolarDB-X Distributed Database AI Assistant. Use for PolarDB-X cluster management,\ntopology inspection, performance diagnostics, SQL optimization, data distribution analysis,\nelastic scaling diagnostics, connection/session analysis, security audit, backup/restore,\nparameter tuning, and other O&M operations.\nTriggers: \"PolarDB-X\", \"distributed database\", \"pxc-\", \"DN/CN nodes\", \"data sharding\",\n\"PolarDB-X diagnostics\", \"PolarDB-X performance\", \"PolarDB-X slow SQL\", \"YaoChi Agent\",\n\"PolarDB-X topology\", \"PolarDB-X backup\", \"PolarDB-X security audit\", \"PolarDB-X scaling\"\n"}},"renderedAt":1782982004492}

PolarDB-X Distributed Database AI Assistant This skill provides intelligent O&M capabilities for Alibaba Cloud PolarDB-X distributed database , powered by the DAS (Database Autonomy Service) API via the aliyun CLI DAS plugin. Architecture : - - - PolarDB-X Intelligent Diagnostics Supported Capabilities | Capability | Description | |------------|-------------| | Instance Information | Instance details, cluster configuration, version info | | Topology Inspection | CN/DN node distribution, shard topology, data node status | | Storage Information | Disk usage, storage capacity, space growth trend…