Agent Skills › datagallery-lab/datafoundry

datagallery-lab/datafoundry

GitHub

用于自然语言数据问答,涵盖指标查询、趋势分析、异常检测及报告生成。遵循理解需求、探索Schema、只读查询、结果验证及精准呈现的标准化工作流,确保数据准确与可复现。

2 skills 161

Install All Skills

npx skills add datagallery-lab/datafoundry --all -g -y
More Options

List skills in collection

npx skills add datagallery-lab/datafoundry --list

Skills in Collection (2)

用于自然语言数据问答,涵盖指标查询、趋势分析、异常检测及报告生成。遵循理解需求、探索Schema、只读查询、结果验证及精准呈现的标准化工作流,确保数据准确与可复现。
用户询问具体业务指标或数值 需要分析数据趋势或进行维度对比 请求生成数据分析报告 检查数据异常或质量问题
packages/skills/builtin/data-analysis/SKILL.md
npx skills add datagallery-lab/datafoundry --skill data-analysis -g -y
SKILL.md
Frontmatter
{
    "name": "data-analysis",
    "tags": [
        "data",
        "analysis",
        "sql",
        "report",
        "数据分析",
        "查数",
        "指标"
    ],
    "version": "1.0.0",
    "description": "Answer data questions from quick metric lookups to full investigations and stakeholder-ready reports.",
    "denied-tools": [],
    "allowed-tools": [
        "list_data_sources",
        "inspect_schema",
        "preview_table",
        "run_sql_readonly",
        "read_file",
        "write_file",
        "list_files"
    ],
    "user-invocable": true
}

Data Analysis

Use this skill for natural-language data questions, including metric lookups, trend investigations, segment comparisons, anomaly checks, quality reviews, and short reports.

Chinese search aliases: 数据分析, 查数, 指标查询, 报表, SQL 分析, 趋势分析, 维度, 度量, 异常检查, 数据质量.

This workflow is adapted for this workbench from public data-analysis skill patterns:

  • Classify the user's request before querying.
  • Explore schema before SQL.
  • Retrieve only the data needed for the current question.
  • Validate results before presenting them.
  • Match the output to the user's requested level of detail.

Workflow

1. Understand The Question

Classify the task:

  • Quick answer: one metric, a simple filter, or a factual lookup.
  • Full analysis: trends, drivers, comparisons, segmentation, or anomalies.
  • Report: a structured write-up with method, findings, caveats, and recommendations.

Identify the needed datasource, tables, metrics, dimensions, filters, time range, and output format. If a required business definition is missing, state the assumption or ask only when guessing would materially change the answer.

2. Explore Before Querying

Always inspect the relevant datasource before writing SQL unless a valid schema token is already available in the current run.

Use progressive disclosure:

  • Start broad with datasource and schema discovery.
  • Narrow to candidate tables and columns.
  • Inspect only the specific tables needed for the query.
  • Use preview_table sparingly to understand shape, examples, nulls, or category values.

Do not dump broad schemas into the answer. Keep schema exploration focused on the user's task.

3. Query Read-Only Data

Write precise SELECT or WITH SQL through run_sql_readonly.

Use exact inspected table and column names. If a query fails, inspect the schema or simplify the query before retrying. Do not guess alternate names blindly.

For multi-step analysis, break the problem into focused sub-questions. Prefer a small number of high-signal queries over many speculative queries.

4. Validate Results

Before presenting conclusions, perform checks appropriate to the task:

  • Row count sanity: does the result size make sense?
  • Null handling: could missing values skew the result?
  • Magnitude check: are values in a plausible range?
  • Aggregation check: do subtotals align with totals?
  • Trend continuity: are there unexpected gaps or date boundary issues?
  • Filter check: did the query apply the user's requested scope?

If validation raises concerns, investigate when possible and surface the caveat.

5. Present The Answer

For quick answers:

  • Lead with the direct answer.
  • Include the most relevant context or caveat.
  • Include SQL only when it helps reproducibility.

For full analyses:

  • Lead with the key finding.
  • Support it with compact tables, calculations, or charts when useful.
  • Explain method and caveats.
  • Suggest the next best follow-up only when it is actionable.

For reports:

  • Write a concise executive summary.
  • Include method, findings, evidence, caveats, and recommendations.
  • Save longer reports or reusable outputs as workspace files and publish them as artifacts.

Guardrails

  • Never invent schemas, rows, metric definitions, SQL results, or file contents.
  • Never use write SQL, DDL, multi-statement SQL, or direct database clients.
  • Never bypass the Data Gateway with command-line database clients.
  • Never hide tool failures; explain what failed and how you adapted.
  • Keep conclusions proportional to the data actually inspected.
用于执行上传和运行时冒烟测试的最小化技能,适用于用户请求简单上传测试或基础数据检查的场景。
用户要求进行简单的上传测试 用户需要进行基础数据检查
scripts/fixtures/test-skill/SKILL.md
npx skills add datagallery-lab/datafoundry --skill hello-test-skill -g -y
SKILL.md
Frontmatter
{
    "name": "hello-test-skill",
    "tags": [
        "test",
        "demo"
    ],
    "version": "1.0.0",
    "description": "A minimal skill for upload and runtime smoke testing.",
    "allowed-tools": [
        "inspect_schema",
        "run_sql_readonly",
        "preview_table"
    ],
    "user-invocable": true
}

Hello Test Skill

Use this skill when the user asks for a simple upload test or a basic data check.

Steps

  1. Greet the user and confirm this skill was loaded.
  2. If a datasource is available, call inspect_schema first.
  3. Run a small read-only query with run_sql_readonly or preview a table.
  4. Summarize results in plain language.

Notes

  • This is a test skill only. Keep responses short.
  • Do not invent schema or query results.

Accueil - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-13 14:40
浙ICP备14020137号-1 $Carte des visiteurs$