Alibabacloud Data Agent Skill
БесплатноЗапускает вложенные скриптыНе проверенInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for…
от sdk-team1 269 установок в других каталогахОб этом скилле
metadata: author: DataAgent Team version: "1.8.5"
Changelog
- v1.8.5 — Database listing migrated to
ListTagMetaAsset(dms-enterprise 2018-11-01); workspace auto-resolution (CLI--workspace-id> envDATA_AGENT_WORKSPACE_ID>InitDataAgentPersonalWorkspace);dbsubcommand relaxed--dms-instance-id/--instance-nameto optional. - v1.8.4: Document project Python virtualenv (
venv/) setup and activation; add end-to-end regression notes for ASK_DATA / ANALYSIS (async + attach) - v1.8.3:
dbandfilesubcommands now accept--session-mode CLAW - v1.8.2:
SendChatMessagenow supports per-messageMode=CLAW(injected viaSessionConfig.Mode); dynamic DMSUnit resolution viaGetActiveRouteUnit - v1.8.1: Emphasize
attach-based session reuse as the core interaction mechanism; add golden workflow, capability matrix, and usage rules - v1.8.0: Add workspace (collaborative space) support, add custom agent support
- v1.7.2: Use Alibaba Cloud default credential chain instead of explicit AK/SK, add User-Agent header, fix RAM policy wildcard issues
- v1.7.1: Fix CLI
lscommand API response parsing (support case-insensitive field names), optimize SKILL documentation structure, separate ANALYSIS mode specification document - v1.7.0: API_KEY authentication support, native async execution mode, session isolation, enhanced attach mode, optimized log output
Installation
Python Environment (venv) — MUST READ
🚨 Hard Requirement: Python ≥ 3.10
The macOS system
/usr/bin/python3is typically 3.8 or 3.9 and cannot run this project (it relies onmatch/case,TypeAlias,|union syntax, and other 3.10+ features).Verify your version first:
python3 --version. If below 3.10, install via Homebrew or pyenv:# Homebrew brew install [email protected] # Or pyenv pyenv install 3.12.4 && pyenv local 3.12.4
⚠️ You MUST use a venv virtual environment. Never install dependencies globally. Running
pip installagainst the system Python pollutes the environment and may fail due to permission issues.
Use Existing venv (Recommended)
The project ships a pre-built venv/ directory (all dependencies pre-installed). Use it whenever possible:
cd alibabacloud-data-agent-skill
# Option A (recommended): activate the venv
source venv/bin/activate
python3 scripts/data_agent_cli.py ls
# Option B: invoke the venv interpreter directly (no activation needed)
venv/bin/python3 scripts/data_agent_cli.py ls
Rebuild venv
If venv/ is missing or dependencies are corrupted, recreate with a 3.10+ Python:
python3.12 -m venv venv # explicitly use a 3.10+ interpreter
source venv/bin/activate
pip install -r scripts/requirements.txt
Tip: All examples in this document write
python3 scripts/data_agent_cli.py .... When venv is activated,python3resolves to the venv interpreter automatically; otherwise prefix withvenv/bin/python3.
Configure Credentials
This Skill uses Alibaba Cloud default credential chain (recommended) or API_KEY authentication.
Option 1: Default Credential Chain (Recommended)
The Skill uses Alibaba Cloud SDK's default credential chain to automatically obtain credentials, supporting environment variables, configuration files, instance roles, etc.
See Alibaba Cloud Credential Chain Documentation
Option 2: API_KEY Authentication (File Analysis Only)
export DATA_AGENT_API_KEY=your-api-key
export DATA_AGENT_REGION=cn-hangzhou
Get API_KEY: Data Agent Console
Permission Requirements
RAM users need AliyunDMSFullAccess or AliyunDMSDataAgentFullAccess permissions.
See RAM-POLICIES.md for detailed permission information.
Debug Mode
DATA_AGENT_DEBUG_API=1 python3 scripts/data_agent_cli.py file example.csv -q "analyze"
💡 Getting Started Tips
- Use the built-in demo database
internal_data_employees(DataAgent's built-in test database containing employee, department, and salary data) for first-time experience - Or use local file
assets/example_game_data.csvfor file analysis experience
Data Agent CLI — Unified Command-Line Data Analysis Tool
Overview
scripts/data_agent_cli.py helps users complete the full workflow from discover data → initiate analysis → track progress → get results.
Core Concepts
⚠️ Key Prerequisite: Data Agent can only analyze databases that have been imported into Data Agent Data Center.
- Data Center: Data Agent's data center, only databases here can be analyzed
- DMS: Alibaba Cloud Data Management Service, stores metadata of all databases
- Relationship: Databases registered in DMS ≠ Databases in Data Center
Usage Flow:
- First use
lsto check if the target database exists in Data Cent
Установить Alibabacloud Data Agent Skill в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл Alibabacloud Data Agent Skill?
Invoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
Как установить скилл Alibabacloud Data Agent Skill?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл Alibabacloud Data Agent Skill запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
от AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
от Anthropicxlsx
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
от Anthropicpptx
Use this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…
от Anthropic