motherduck-enable-self-serve-analytics

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Enable Self-Serve Analytics

启用自助分析

Use this skill when the user wants broad internal access to analytics with clear guardrails, trusted datasets, and a practical rollout path.
This is a use-case skill. It orchestrates
motherduck-explore
,
motherduck-query
,
motherduck-model-data
,
motherduck-create-dive
, and
motherduck-share-data
.
当用户希望为内部团队提供具备明确管控规则、可信数据集及实用推广路径的广泛分析访问权限时,可使用此skill。
这是一个场景化skill,它将
motherduck-explore
motherduck-query
motherduck-model-data
motherduck-create-dive
motherduck-share-data
进行编排。

Start Here: Is a MotherDuck Server Active?

第一步:是否有MotherDuck服务器处于活跃状态?

Always determine this first.
  • If a remote MotherDuck MCP server or local MotherDuck server is active, use it.
  • If the user has not named the target database, ask which database or workspace will power the rollout.
  • Explore the live data model before defining the rollout:
    • trusted source tables
    • candidate curated views
    • department-level dimensions
    • core KPIs
    • share boundaries
Use the actual data model to pick the first audience and first asset.
If no server is active, ask for a table list and target audience before drafting the rollout.
请始终首先确认这一点。
  • 如果远程MotherDuck MCP服务器本地MotherDuck服务器处于活跃状态,请直接使用。
  • 如果用户未指定目标数据库,请询问将为此次推广提供支持的数据库或工作区。
  • 在定义推广方案前,先探索实时数据模型:
    • 可信源表
    • 候选精选视图
    • 部门级维度
    • 核心KPI
    • 共享边界
借助实际数据模型选择首个受众和首个资产。
如果没有活跃服务器,请先获取表格列表和目标受众,再起草推广方案。

Use This Skill When

适用场景

  • The user wants internal teams to answer their own questions.
  • The user needs a first rollout plan for Dives, dashboards, or shares.
  • The user needs adoption plus governance, not just chart creation.
  • The audience is internal; for external users or embedded product analytics, use
    motherduck-build-cfa-app
    .
  • 用户希望内部团队能够自行解答问题。
  • 用户需要针对Dives、仪表板或共享内容制定首个推广计划。
  • 用户需要兼顾采用率与治理,而非仅创建图表。
  • 受众为内部用户;若面向外部用户或嵌入式产品分析,请使用
    motherduck-build-cfa-app

Rollout Defaults

推广默认规则

  • first audience first, not company-wide exposure
  • curated dataset before broad access
  • Dive or share boundary over raw table dumping
  • standard ownership for metric changes
  • lightweight metric definitions and owners before inviting more users
  • 优先覆盖首个受众,而非全公司范围推广
  • 先提供精选数据集,再开放广泛访问权限
  • 采用Dive或共享边界,而非直接导出原始表格
  • 为指标变更设定标准所有权机制
  • 在邀请更多用户前,先制定轻量化的指标定义并确定负责人

Workflow

工作流程

  1. Confirm whether live MotherDuck discovery is available.
  2. Inspect the data model that internal teams would use.
  3. Pick the first audience and first use case.
  4. Publish one trusted dataset.
  5. Document the metric owner, refresh expectation, and access boundary.
  6. Publish one Dive or one share.
  7. Expand only after the first workflow is stable.
When this skill produces a native DuckDB (
md:
) connection, watermark it with
custom_user_agent=agent-skills/2.2.0(harness-<harness>;llm-<llm>)
. If metadata is missing, fall back to
harness-unknown
and
llm-unknown
.
  1. 确认是否可进行实时MotherDuck发现。
  2. 检查内部团队将使用的数据模型。
  3. 选择首个受众和首个使用场景。
  4. 发布一个可信数据集。
  5. 记录指标负责人、刷新预期及访问边界。
  6. 发布一个Dive或一项共享内容。
  7. 仅在首个工作流程稳定后再进行扩展。
当此skill生成原生DuckDB(
md:
)连接时,请为其添加水印
custom_user_agent=agent-skills/2.2.0(harness-<harness>;llm-<llm>)
。若元数据缺失,则默认使用
harness-unknown
llm-unknown

Output

输出内容

The output of this skill should be:
  • the first audience
  • the first asset
  • the governing dataset
  • the ownership model
  • the rollout guardrails
If the caller explicitly asks for structured JSON, return raw JSON only with no Markdown fences or prose before/after it. This is mainly for automated tests, regression checks, or downstream tooling that needs a stable machine-readable shape. Normal human-facing use of the skill can stay in prose unless JSON is explicitly requested.
Use this exact top-level shape when JSON is requested:
json
{
  "summary": {},
  "assumptions": [],
  "implementation_plan": [],
  "validation_plan": [],
  "risks": []
}
此skill的输出应包含:
  • 首个受众
  • 首个资产
  • 受管控数据集
  • 所有权模型
  • 推广管控规则
若调用方明确要求结构化JSON,则仅返回原始JSON,无需添加Markdown围栏或前后说明文字。 这主要用于自动化测试、回归检查或需要稳定机器可读格式的下游工具。面向普通用户使用此skill时,除非明确要求JSON,否则可采用散文形式输出。
当请求JSON时,请使用以下精确的顶层结构:
json
{
  "summary": {},
  "assumptions": [],
  "implementation_plan": [],
  "validation_plan": [],
  "risks": []
}

References

参考资料

  • references/SELF_SERVE_ROLLOUT_GUIDE.md
    -- preserved detailed rollout guidance that used to live in this skill
  • references/SELF_SERVE_ROLLOUT_GUIDE.md
    —— 保留了原在此skill中的详细推广指南

Runnable Artifact

可运行制品

  • artifacts/self_serve_rollout_example.py
    -- MotherDuck-backed Python example that publishes a curated view and produces team KPI output for a first rollout asset
  • artifacts/self_serve_rollout_example.ts
    -- TypeScript companion artifact with the same rollout output contract
Run it with:
bash
uv run --with duckdb python skills/motherduck-enable-self-serve-analytics/artifacts/self_serve_rollout_example.py
Run the same artifact against a temporary MotherDuck database:
bash
MOTHERDUCK_ARTIFACT_USE_MOTHERDUCK=1 \
uv run --with duckdb python skills/motherduck-enable-self-serve-analytics/artifacts/self_serve_rollout_example.py
Validate the TypeScript companion artifact:
bash
uv run scripts/test_typescript_artifacts.py
  • artifacts/self_serve_rollout_example.py
    —— 基于MotherDuck的Python示例,用于发布精选视图并为首个推广资产生成团队KPI输出
  • artifacts/self_serve_rollout_example.ts
    —— TypeScript配套制品,具备相同的推广输出约定
运行方式:
bash
uv run --with duckdb python skills/motherduck-enable-self-serve-analytics/artifacts/self_serve_rollout_example.py
针对临时MotherDuck数据库运行同一制品:
bash
MOTHERDUCK_ARTIFACT_USE_MOTHERDUCK=1 \
uv run --with duckdb python skills/motherduck-enable-self-serve-analytics/artifacts/self_serve_rollout_example.py
验证TypeScript配套制品:
bash
uv run scripts/test_typescript_artifacts.py

Related Skills

相关Skills

  • motherduck-explore
    -- inspect the real workspace before rollout
  • motherduck-query
    -- validate KPI definitions
  • motherduck-model-data
    -- publish curated analytical views or tables
  • motherduck-create-dive
    -- build the first shareable answer surface
  • motherduck-share-data
    -- publish governed data access when users need SQL, not just a Dive
  • motherduck-explore
    —— 在推广前检查真实工作区
  • motherduck-query
    —— 验证KPI定义
  • motherduck-model-data
    —— 发布精选分析视图或表格
  • motherduck-create-dive
    —— 构建首个可共享的解答界面
  • motherduck-share-data
    —— 当用户需要SQL而非仅Dive时,发布受管控的数据访问权限