powerbi-modeling by github/awesome-copilot
npx skills add https://github.com/github/awesome-copilot --skill powerbi-modeling指导用户遵循 Microsoft 最佳实践构建优化良好、文档完善的 Power BI 语义模型。
当用户询问以下内容时使用此技能:
触发短语: "create a measure", "add relationship", "star schema", "optimize model", "DAX formula", "RLS", "naming convention", "model documentation", "cardinality", "cross-filter"
在提供任何建模指导之前,始终先检查当前模型状态:
1. 列出连接:connection_operations(operation: "ListConnections")
2. 如果没有连接,检查本地实例:connection_operations(operation: "ListLocalInstances")
3. 连接到模型(Desktop 或 Fabric)
4. 获取模型概览:model_operations(operation: "Get")
5. 列出表:table_operations(operation: "List")
6. 列出关系:relationship_operations(operation: "List")
7. 列出度量值:measure_operations(operation: "List")
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
连接后,根据最佳实践评估模型:
基于分析,使用参考资料指导改进:
| 领域 | 最佳实践 |
|---|---|
| 表 | 清晰的维度与事实分类 |
| 命名 | 人类可读:Customer Name 而非 CUST_NM |
| 描述 | 所有表、列、度量值都有文档记录 |
| 度量值 | 业务指标使用显式 DAX 度量值 |
| 关系 | 从维度到事实的一对多关系 |
| 交叉筛选 | 单向筛选,除非特别需要 |
| 隐藏字段 | 在报表视图中隐藏技术键、ID |
| 日期表 | 专用的标记日期表 |
使用以下 Power BI Modeling MCP 操作:
| 操作类别 | 关键操作 |
|---|---|
connection_operations | Connect, ListConnections, ListLocalInstances, ConnectFabric |
model_operations | Get, GetStats, ExportTMDL |
table_operations | List, Get, Create, Update, GetSchema |
column_operations | List, Get, Create, Update (descriptions, hidden, format) |
measure_operations | List, Get, Create, Update, Move |
relationship_operations | List, Get, Create, Update, Activate, Deactivate |
dax_query_operations | Execute, Validate |
calculation_group_operations | List, Create, Update |
security_role_operations | List, Create, Update, GetEffectivePermissions |
measure_operations(
operation: "Create",
definitions: [{
name: "Total Sales",
tableName: "Sales",
expression: "SUM(Sales[Amount])",
formatString: "$#,##0",
description: "Sum of all sales amounts"
}]
)
column_operations(
operation: "Update",
definitions: [{
tableName: "Customer",
name: "CustomerKey",
description: "Unique identifier for customer dimension",
isHidden: true
}]
)
relationship_operations(
operation: "Create",
definitions: [{
fromTable: "Sales",
fromColumn: "CustomerKey",
toTable: "Customer",
toColumn: "CustomerKey",
crossFilteringBehavior: "OneDirection"
}]
)
使用 microsoft_docs_search 研究当前最佳实践,适用于:
每周安装量
7.6K
代码仓库
GitHub 星标数
26.7K
首次出现
Feb 4, 2026
安全审计
安装于
codex7.4K
gemini-cli7.4K
opencode7.4K
github-copilot7.4K
cursor7.4K
kimi-cli7.4K
Guide users in building optimized, well-documented Power BI semantic models following Microsoft best practices.
Use this skill when users ask about:
Trigger phrases: "create a measure", "add relationship", "star schema", "optimize model", "DAX formula", "RLS", "naming convention", "model documentation", "cardinality", "cross-filter"
Before providing any modeling guidance, always examine the current model state:
1. List connections: connection_operations(operation: "ListConnections")
2. If no connection, check for local instances: connection_operations(operation: "ListLocalInstances")
3. Connect to the model (Desktop or Fabric)
4. Get model overview: model_operations(operation: "Get")
5. List tables: table_operations(operation: "List")
6. List relationships: relationship_operations(operation: "List")
7. List measures: measure_operations(operation: "List")
After connecting, assess the model against best practices:
Based on analysis, guide improvements using references:
| Area | Best Practice |
|---|---|
| Tables | Clear dimension vs fact classification |
| Naming | Human-readable: Customer Name not CUST_NM |
| Descriptions | All tables, columns, measures documented |
| Measures | Explicit DAX measures for business metrics |
| Relationships | One-to-many from dimension to fact |
| Cross-filter | Single direction unless specifically needed |
| Hidden fields | Hide technical keys, IDs from report view |
| Date table | Dedicated marked date table |
Use these Power BI Modeling MCP operations:
| Operation Category | Key Operations |
|---|---|
connection_operations | Connect, ListConnections, ListLocalInstances, ConnectFabric |
model_operations | Get, GetStats, ExportTMDL |
table_operations | List, Get, Create, Update, GetSchema |
column_operations | List, Get, Create, Update (descriptions, hidden, format) |
measure_operations | List, Get, Create, Update, Move |
relationship_operations |
measure_operations(
operation: "Create",
definitions: [{
name: "Total Sales",
tableName: "Sales",
expression: "SUM(Sales[Amount])",
formatString: "$#,##0",
description: "Sum of all sales amounts"
}]
)
column_operations(
operation: "Update",
definitions: [{
tableName: "Customer",
name: "CustomerKey",
description: "Unique identifier for customer dimension",
isHidden: true
}]
)
relationship_operations(
operation: "Create",
definitions: [{
fromTable: "Sales",
fromColumn: "CustomerKey",
toTable: "Customer",
toColumn: "CustomerKey",
crossFilteringBehavior: "OneDirection"
}]
)
Research current best practices using microsoft_docs_search for:
Weekly Installs
7.6K
Repository
GitHub Stars
26.7K
First Seen
Feb 4, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
codex7.4K
gemini-cli7.4K
opencode7.4K
github-copilot7.4K
cursor7.4K
kimi-cli7.4K
48,100 周安装
| List, Get, Create, Update, Activate, Deactivate |
dax_query_operations | Execute, Validate |
calculation_group_operations | List, Create, Update |
security_role_operations | List, Create, Update, GetEffectivePermissions |