Back to Skills

analyzing-data

verified

Queries data warehouse and answers business questions about data. Handles questions requiring database/warehouse queries including "who uses X", "how many Y", "show me Z", "find customers", "what is the count", data lookups, metrics, trends, or SQL analysis.

View on GitHub

Marketplace

astronomer

astronomer/agents

Plugin

data

Repository
Verified Org

astronomer/agents
8stars

skills/analyzing-data/SKILL.md

Last Verified

January 24, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/astronomer/agents/blob/main/skills/analyzing-data/SKILL.md -a claude-code --skill analyzing-data

Installation paths:

Claude
.claude/skills/analyzing-data/
Powered by add-skill CLI

Instructions

# Data Analysis

Answer business questions by querying the data warehouse. The kernel starts automatically on first use.

## Prerequisites

**uv must be installed:**
```bash
curl -LsSf https://astral.sh/uv/install.sh | sh
```

Scripts are located relative to this skill file.

## MANDATORY FIRST STEP

**Before any other action, check for cached patterns:**

```bash
uv run scripts/cli.py pattern lookup "<user's question>"
```

This is NON-NEGOTIABLE. Patterns contain proven strategies that save time and avoid failed queries.

---

## Workflow

```
Analysis Progress:
- [ ] Step 1: pattern lookup (check for cached strategy)
- [ ] Step 2: concept lookup (check for known tables)
- [ ] Step 3: Search codebase for table definitions (Grep)
- [ ] Step 4: Read SQL file to get table/column names
- [ ] Step 5: Execute query via kernel (run_sql)
- [ ] Step 6: learn_concept (ALWAYS before presenting results)
- [ ] Step 7: learn_pattern (ALWAYS if discovery required)
- [ ] Step 8: record_pattern_outcome (if you used a pattern in Step 1)
- [ ] Step 9: Present findings to user
```

---

## CLI Commands

### Kernel Management

```bash
uv run scripts/cli.py start           # Start kernel with Snowflake
uv run scripts/cli.py exec "..."      # Execute Python code
uv run scripts/cli.py status          # Check kernel status
uv run scripts/cli.py restart         # Restart kernel
uv run scripts/cli.py stop            # Stop kernel
uv run scripts/cli.py install plotly  # Install additional packages
```

### Concept Cache (concept -> table mappings)

```bash
# Look up a concept
uv run scripts/cli.py concept lookup customers

# Learn a new concept
uv run scripts/cli.py concept learn customers HQ.MART_CUST.CURRENT_ASTRO_CUSTS -k ACCT_ID

# List all concepts
uv run scripts/cli.py concept list

# Import concepts from warehouse.md
uv run scripts/cli.py concept import -p /path/to/warehouse.md
```

### Pattern Cache (query strategies)

```bash
# Look up patterns for a question
uv run scripts/cli.py p

Validation Details

Front Matter
Required Fields
Valid Name Format
Valid Description
Has Sections
Allowed Tools
Instruction Length:
5250 chars