bi-superpowers 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +31 -0
- package/.claude-plugin/plugin.json +34 -0
- package/.claude-plugin/skill-manifest.json +79 -0
- package/.mcp.json +13 -0
- package/.plugin/plugin.json +14 -0
- package/LICENSE +21 -0
- package/README.md +849 -0
- package/bin/build-plugin.js +97 -0
- package/bin/cli.js +891 -0
- package/bin/commands/autoupdate.js +128 -0
- package/bin/commands/build-desktop.js +368 -0
- package/bin/commands/create-from-template.js +165 -0
- package/bin/commands/diff.js +435 -0
- package/bin/commands/install.js +542 -0
- package/bin/commands/lint.js +441 -0
- package/bin/commands/mcp-setup.js +255 -0
- package/bin/commands/session-update.js +204 -0
- package/bin/commands/smoke-test.js +20 -0
- package/bin/commands/uninstall.js +611 -0
- package/bin/commands/update-check.js +427 -0
- package/bin/commands/validate-cases.js +264 -0
- package/bin/commands/validate-projects.js +426 -0
- package/bin/commands/watch.js +251 -0
- package/bin/lib/agents.js +62 -0
- package/bin/lib/base-template-smoke.js +299 -0
- package/bin/lib/claude-hooks.js +160 -0
- package/bin/lib/generators/claude-plugin.js +529 -0
- package/bin/lib/generators/index.js +116 -0
- package/bin/lib/generators/shared.js +257 -0
- package/bin/lib/mcp-config.js +835 -0
- package/bin/lib/microsoft-mcp.js +206 -0
- package/bin/lib/powerbi-mcp-session.js +140 -0
- package/bin/lib/skills.js +164 -0
- package/bin/lib/template-scaffold.js +366 -0
- package/bin/mcp/powerbi-modeling-launcher.js +42 -0
- package/bin/postinstall.js +50 -0
- package/bin/utils/mcp-detect.js +346 -0
- package/bin/utils/tui.js +314 -0
- package/commands/bi-connect.md +520 -0
- package/commands/bi-dax.md +464 -0
- package/commands/bi-kickoff.md +550 -0
- package/commands/bi-modeling.md +485 -0
- package/commands/bi-performance.md +521 -0
- package/commands/bi-powerquery.md +229 -0
- package/commands/bi-refactor.md +249 -0
- package/commands/bi-scorecard.md +268 -0
- package/commands/bi-start.md +272 -0
- package/config.example.json +23 -0
- package/config.json +23 -0
- package/desktop-extension/manifest.json +30 -0
- package/desktop-extension/package.json +10 -0
- package/desktop-extension/server.js +137 -0
- package/package.json +94 -0
- package/skills/bi-connect/SKILL.md +522 -0
- package/skills/bi-connect/scripts/update-check.js +427 -0
- package/skills/bi-dax/SKILL.md +466 -0
- package/skills/bi-dax/scripts/update-check.js +427 -0
- package/skills/bi-kickoff/SKILL.md +552 -0
- package/skills/bi-kickoff/references/flow.html +78 -0
- package/skills/bi-kickoff/references/flow.md +62 -0
- package/skills/bi-kickoff/scripts/update-check.js +427 -0
- package/skills/bi-modeling/SKILL.md +487 -0
- package/skills/bi-modeling/scripts/update-check.js +427 -0
- package/skills/bi-performance/SKILL.md +523 -0
- package/skills/bi-performance/scripts/install-tabular-editor.ps1 +159 -0
- package/skills/bi-performance/scripts/run-bpa.ps1 +265 -0
- package/skills/bi-performance/scripts/update-check.js +427 -0
- package/skills/bi-powerquery/SKILL.md +231 -0
- package/skills/bi-powerquery/references/base-template-data-contract.md +323 -0
- package/skills/bi-powerquery/references/power-query-standards.md +74 -0
- package/skills/bi-powerquery/scripts/new-powerquery-staging.ps1 +371 -0
- package/skills/bi-powerquery/scripts/test-powerquery-contract.ps1 +225 -0
- package/skills/bi-powerquery/scripts/update-check.js +427 -0
- package/skills/bi-refactor/SKILL.md +251 -0
- package/skills/bi-refactor/references/flow.md +27 -0
- package/skills/bi-refactor/scripts/update-check.js +427 -0
- package/skills/bi-scorecard/SKILL.md +270 -0
- package/skills/bi-scorecard/examples/base-template-scorecard-overlay.json +82 -0
- package/skills/bi-scorecard/scripts/new-scorecard-blueprint-from-base-template.ps1 +124 -0
- package/skills/bi-scorecard/scripts/powerbi-goal-status-rules-api.ps1 +39 -0
- package/skills/bi-scorecard/scripts/powerbi-goal-values-api.ps1 +48 -0
- package/skills/bi-scorecard/scripts/powerbi-goals-api.ps1 +68 -0
- package/skills/bi-scorecard/scripts/powerbi-rest-common.ps1 +197 -0
- package/skills/bi-scorecard/scripts/powerbi-scorecards-api.ps1 +53 -0
- package/skills/bi-scorecard/scripts/update-check.js +427 -0
- package/skills/bi-start/SKILL.md +274 -0
- package/skills/bi-start/scripts/update-check.js +427 -0
- package/src/content/base.md +197 -0
- package/src/content/mcp-requirements.json +57 -0
- package/src/content/routing.md +201 -0
- package/src/content/skills/bi-connect.md +493 -0
- package/src/content/skills/bi-dax.md +437 -0
- package/src/content/skills/bi-kickoff/SKILL.md +523 -0
- package/src/content/skills/bi-kickoff/references/flow.html +78 -0
- package/src/content/skills/bi-kickoff/references/flow.md +62 -0
- package/src/content/skills/bi-modeling.md +458 -0
- package/src/content/skills/bi-performance/SKILL.md +494 -0
- package/src/content/skills/bi-performance/scripts/install-tabular-editor.ps1 +159 -0
- package/src/content/skills/bi-performance/scripts/run-bpa.ps1 +265 -0
- package/src/content/skills/bi-powerquery/SKILL.md +202 -0
- package/src/content/skills/bi-powerquery/references/base-template-data-contract.md +323 -0
- package/src/content/skills/bi-powerquery/references/power-query-standards.md +74 -0
- package/src/content/skills/bi-powerquery/scripts/new-powerquery-staging.ps1 +371 -0
- package/src/content/skills/bi-powerquery/scripts/test-powerquery-contract.ps1 +225 -0
- package/src/content/skills/bi-refactor/SKILL.md +222 -0
- package/src/content/skills/bi-refactor/references/flow.md +27 -0
- package/src/content/skills/bi-scorecard/SKILL.md +241 -0
- package/src/content/skills/bi-scorecard/examples/base-template-scorecard-blueprint.expected.json +105 -0
- package/src/content/skills/bi-scorecard/examples/base-template-scorecard-overlay.json +82 -0
- package/src/content/skills/bi-scorecard/scripts/new-scorecard-blueprint-from-base-template.ps1 +124 -0
- package/src/content/skills/bi-scorecard/scripts/powerbi-goal-status-rules-api.ps1 +39 -0
- package/src/content/skills/bi-scorecard/scripts/powerbi-goal-values-api.ps1 +48 -0
- package/src/content/skills/bi-scorecard/scripts/powerbi-goals-api.ps1 +68 -0
- package/src/content/skills/bi-scorecard/scripts/powerbi-rest-common.ps1 +197 -0
- package/src/content/skills/bi-scorecard/scripts/powerbi-scorecards-api.ps1 +53 -0
- package/src/content/skills/bi-start.md +266 -0
- package/templates/base-template/AGENTS.md +33 -0
- package/templates/base-template/base-template.Report/.platform +11 -0
- package/templates/base-template/base-template.Report/StaticResources/RegisteredResources/BISuperpowers.json +3888 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BaseThemes/CY18SU07.json +177 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BaseThemes/Fluent2-CY26SU03.json +4104 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/AccessibleCityPark.json +26 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/AccessibleDefault.json +26 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/AccessibleNeutral.json +26 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/AccessibleOrchid.json +26 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/AccessibleTidal.json +26 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Bloom.json +139 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/CityPark.json +40 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Classroom.json +40 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/ColorblindSafe.json +48 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/CopilotDefault.json +1861 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Divergent.json +127 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Electric.json +48 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Frontier.json +136 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/HighContrast.json +40 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Highrise.json +41 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Innovate.json +227 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/NewExecutive.json +41 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Solar.json +33 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Storm.json +25 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Sunset.json +48 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Temperature.json +33 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Tidal.json +100 -0
- package/templates/base-template/base-template.Report/StaticResources/SharedResources/BuiltInThemes/Twilight.json +40 -0
- package/templates/base-template/base-template.Report/definition/bookmarks/1d40d43c7ade66e8603c.bookmark.json +2297 -0
- package/templates/base-template/base-template.Report/definition/bookmarks/af068ff51c0ca3089ea7.bookmark.json +2300 -0
- package/templates/base-template/base-template.Report/definition/bookmarks/bookmarks.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/page.json +130 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/0352fd80d074693a65db/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/0352fd80d074693a65db/visual.json +669 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/1c5a14bf493697344b68/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/1c5a14bf493697344b68/visual.json +723 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/3486cf7624c5b109b4e5/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/3486cf7624c5b109b4e5/visual.json +333 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/4d8b989008edc0db28d1/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/4d8b989008edc0db28d1/visual.json +109 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/55e10ac7d76a1954f94f/mobile.json +31 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/55e10ac7d76a1954f94f/visual.json +378 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/57f52ecf4490f70e4da1/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/57f52ecf4490f70e4da1/visual.json +175 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/5f4d76bbc870118e9840/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/5f4d76bbc870118e9840/visual.json +468 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/73629e1abebb7a444b59/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/73629e1abebb7a444b59/visual.json +359 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/749cb1388c7e0a88161c/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/749cb1388c7e0a88161c/visual.json +690 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/90677f13cea5d1275990/visual.json +17 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/92cf92e3da10493adb78/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/92cf92e3da10493adb78/visual.json +468 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/9fe17b1971f68443fc15/mobile.json +10 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/9fe17b1971f68443fc15/visual.json +328 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/a30bd0950630ed94e8a3/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/a30bd0950630ed94e8a3/visual.json +578 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/a56e91d9400a835e4814/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/a56e91d9400a835e4814/visual.json +432 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/aded24cd205c0b528642/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/aded24cd205c0b528642/visual.json +801 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/af34b26f14a8a724c9a9/mobile.json +37 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/af34b26f14a8a724c9a9/visual.json +1318 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/b529688fe5a226643322/visual.json +209 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/c4c6f332d05e72e2eb06/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/c4c6f332d05e72e2eb06/visual.json +174 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/fa81f184e2cb0e8b087c/mobile.json +29 -0
- package/templates/base-template/base-template.Report/definition/pages/6a4808bb8bb9166f49ff/visuals/fa81f184e2cb0e8b087c/visual.json +241 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/page.json +130 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/07e9c4302e29029c5462/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/07e9c4302e29029c5462/visual.json +690 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/109ceede4bc015b0c006/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/109ceede4bc015b0c006/visual.json +468 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/118257e006d472277e10/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/118257e006d472277e10/visual.json +359 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/2caf02e0137c4a1280cc/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/2caf02e0137c4a1280cc/visual.json +669 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/311e76fe3c9edad68204/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/311e76fe3c9edad68204/visual.json +109 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/31c21f8cbeb3b208940a/visual.json +209 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/3ab72c25062437149b03/visual.json +17 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/5959867442abcb0ce2b3/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/5959867442abcb0ce2b3/visual.json +788 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/5b96e0f88d192b044a13/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/5b96e0f88d192b044a13/visual.json +592 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/64e749a63d0786000e22/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/64e749a63d0786000e22/visual.json +468 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/7ae1ca604edac6586ad0/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/7ae1ca604edac6586ad0/visual.json +1310 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/840300733885141a6603/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/840300733885141a6603/visual.json +175 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/a38448cdb203279273d2/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/a38448cdb203279273d2/visual.json +516 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/d1e86f213a3841d12e20/visual.json +328 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/d4a484c1bcc8ee3075e2/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/d4a484c1bcc8ee3075e2/visual.json +432 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/d87cb5cf06acca19bbb5/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/d87cb5cf06acca19bbb5/visual.json +241 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/e243da2677209ed69408/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/e243da2677209ed69408/visual.json +174 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/f3aaf24f5b22b67573b0/mobile.json +11 -0
- package/templates/base-template/base-template.Report/definition/pages/9a5b670b015cab882629/visuals/f3aaf24f5b22b67573b0/visual.json +333 -0
- package/templates/base-template/base-template.Report/definition/pages/pages.json +8 -0
- package/templates/base-template/base-template.Report/definition/report.json +89 -0
- package/templates/base-template/base-template.Report/definition/version.json +4 -0
- package/templates/base-template/base-template.Report/definition.pbir +9 -0
- package/templates/base-template/base-template.SemanticModel/.platform +11 -0
- package/templates/base-template/base-template.SemanticModel/definition/cultures/es-AR.tmdl +11185 -0
- package/templates/base-template/base-template.SemanticModel/definition/database.tmdl +3 -0
- package/templates/base-template/base-template.SemanticModel/definition/expressions.tmdl +234 -0
- package/templates/base-template/base-template.SemanticModel/definition/functions.tmdl +637 -0
- package/templates/base-template/base-template.SemanticModel/definition/model.tmdl +82 -0
- package/templates/base-template/base-template.SemanticModel/definition/relationships.tmdl +271 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Calendario.tmdl +200 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Campa/303/261as.tmdl +75 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Canales.tmdl +84 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Clientes.tmdl +143 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Devoluciones.tmdl +95 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Ejecuci/303/263n proyectos.tmdl" +130 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Entregas.tmdl +122 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Equipos m/303/251tricas.tmdl" +40 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Equipos.tmdl +73 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Horas.tmdl +122 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Interacciones clientes.tmdl +146 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Leads.tmdl +119 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Monedas.tmdl +44 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Movimientos financieros.tmdl +145 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/M/303/251tricas.tmdl +1294 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/N/303/263mina.tmdl +110 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Oportunidades.tmdl +135 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Presupuesto.tmdl +125 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Productos.tmdl +98 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Proyectos.tmdl +77 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Servicios.tmdl +75 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Tareas proyecto.tmdl +102 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Tipo de cambio.tmdl +67 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/Ventas.tmdl +180 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux An/303/241lisis dimensiones.tmdl" +38 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Comparaciones.tmdl +227 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Compatibilidad m/303/251trica-dimensi/303/263n.tmdl" +68 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Modelo configuraci/303/263n.tmdl" +44 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Modo fechas.tmdl +36 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux M/303/251trica-Equipo.tmdl" +102 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Overrides m/303/251trica-dimensi/303/263n.tmdl" +54 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Per/303/255odos.tmdl" +182 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Rango fechas modo.tmdl +36 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Rango fechas.tmdl +27 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_Aux Vista de calendario.tmdl +30 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_GC C/303/241lculo.tmdl" +70 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_GC Eje X.tmdl +63 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_GC M/303/251trica.tmdl" +374 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_GC Tipo c/303/241lculo.tmdl" +223 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_PC Dimensi/303/263n.tmdl" +98 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables/_PC Eje X.tmdl +68 -0
- package/templates/base-template/base-template.SemanticModel/definition/tables//303/223rdenes servicio.tmdl" +151 -0
- package/templates/base-template/base-template.SemanticModel/definition.pbism +5 -0
- package/templates/base-template/base-template.SemanticModel/diagramLayout.json +568 -0
- package/templates/base-template/base-template.pbip +14 -0
- package/templates/base-template/template.manifest.json +41 -0
- package/theme/BISuperpowers.json +3888 -0
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
# Power BI Refactor Skill
|
|
2
|
+
|
|
3
|
+
## Trigger
|
|
4
|
+
Activate this skill when the user mentions any of:
|
|
5
|
+
- "bi-refactor", "/bi-refactor", "refactor Power BI", "refactorizar Power BI"
|
|
6
|
+
- "modelo existente", "existing PBIP", "existing PBIX", "migrar PBIX"
|
|
7
|
+
- "limpiar modelo", "reparar modelo", "template upgrade", "actualizar template"
|
|
8
|
+
- "visual roto", "bindings rotos", "mantener bookmarks", "preservar reporte"
|
|
9
|
+
|
|
10
|
+
## Identity
|
|
11
|
+
You are **Power BI Refactor Engineer**. You improve existing Power BI projects without rebuilding the report. You preserve the user's file, report shell, bookmarks, mobile layout, and visual identities while cleaning the semantic model through Power BI Desktop MCP.
|
|
12
|
+
|
|
13
|
+
## Non-negotiables Before Work
|
|
14
|
+
|
|
15
|
+
- **REPORT TOPOLOGY LOCK.** Never delete, rename, move, or recreate report pages, visuals, mobile layouts, or bookmarks. Never create replacement visuals/pages to "fix" broken bindings. Do not rebuild a "minimal functional report". A/D/R under any `.Report` path is a hard stop: stop, explain the broken bindings in plain language, and hand off to Power BI Desktop.
|
|
16
|
+
- **Existing-visual dimension/measure binding changes are the only report-side exception.** They may happen in Power BI Desktop manually, or through a future dedicated rebind command that proves a binding-only diff with dry-run, backup, validation, and explicit source-to-target mapping. No safe report rebind command currently ships with this plugin, so if visuals point to old fields, do not patch PBIR JSON and do not improvise a report repair. Leave the report shell intact and guide the user through manual Desktop rebinding.
|
|
17
|
+
- **Model-ready is not report-ready.** A semantic model can be correct while visuals still need to be reconnected. Never call the refactor complete unless that status is explicit.
|
|
18
|
+
|
|
19
|
+
## Teaching Contract — sé un profesor, no una consola
|
|
20
|
+
|
|
21
|
+
This skill teaches a non-technical business user *while* it works. Follow this contract in every session:
|
|
22
|
+
|
|
23
|
+
1. **Say the WHY before each step, in one plain sentence** — what it achieves for the user's business, not how it works inside.
|
|
24
|
+
2. **Define every term the first time you use it**, using the Plain-language glossary below. If a technical word is unavoidable, gloss it inline: `término (en palabras simples: …)`. Never let unexplained jargon reach the user.
|
|
25
|
+
3. **Ask business questions, one at a time.** Lead with what the user wants to achieve, in their words; never present a technical intake form or stack questions. Capture the technical details silently.
|
|
26
|
+
4. **Default to educativo pero breve.** Explain enough for the user to learn what matters, but do not ask them to choose an explanation level. Expand only if the user asks.
|
|
27
|
+
5. **Report results as business impact** — what the user can now do, or what it prevents — not raw ms / MB / row counts / HTTP status codes.
|
|
28
|
+
6. **Keep internal vocabulary internal.** Operator terms and file paths are for you, not the user; translate before surfacing.
|
|
29
|
+
|
|
30
|
+
- **Ask the pain before diagnosing.** "Diagnose first" stays true for the *files*, but open with ONE business question to the user before silently diagnosing: *"¿Qué es lo que hoy no te funciona o no te cuadra en este reporte?"* Anchor the refactor in their pain, then wait for the answer.
|
|
31
|
+
- **Close with a "what I fixed and why it matters" recap.** End in plain business language, e.g. *"unifiqué 3 medidas para que los totales coincidan en todos los visuales; reparé una relación que dejaba ventas sin cliente"* — so the verified work also teaches.
|
|
32
|
+
|
|
33
|
+
## Plain-language glossary
|
|
34
|
+
|
|
35
|
+
- **refactorizar (refactor)** = mejorar cómo está armado el reporte por dentro sin cambiar lo que ves.
|
|
36
|
+
- **medida (measure)** = una fórmula reutilizable que calcula un número, como una fórmula de Excel.
|
|
37
|
+
- **relación (relationship)** = el vínculo que conecta dos tablas (por ejemplo, ventas con su cliente).
|
|
38
|
+
- **marcador (bookmark)** = una vista guardada del reporte, como un favorito del navegador.
|
|
39
|
+
- **casilla portadora (carrier)** = una casilla neutra que muestra la métrica que el usuario elija.
|
|
40
|
+
- **modelo semántico (semantic model)** = el "cerebro" de datos detrás del reporte: tablas, relaciones y medidas.
|
|
41
|
+
|
|
42
|
+
**Internal — never surface verbatim:** A/D/R, PBIR, TMDL, `prototypeQuery`, binding-only diff, report-topology-lock. Never expose these in user-facing text — describe them in business terms (e.g. A/D/R = agregar/borrar/recrear páginas o visuales).
|
|
43
|
+
|
|
44
|
+
**(Interno — no se lo muestres al usuario; traducí a lenguaje claro.)** Estos mismos términos (A/D/R, PBIR, TMDL, `.Report/**`, `.SemanticModel/**`, binding-only diff) también aparecen en MANDATORY RULES, Red Flags y Common Mistakes: ahí son contrato operativo tuyo, no texto para el usuario. Si necesitás explicarle al usuario por qué algo es un freno (por ejemplo, la Regla 6 REPORT TOPOLOGY LOCK), decilo en negocio: "no voy a tocar el diseño de tus páginas ni tus marcadores; reparo los datos por detrás y, si un visual quedó apuntando a algo viejo, te paso el paso exacto para reconectarlo en Power BI Desktop".
|
|
45
|
+
|
|
46
|
+
## Ejemplo guiado (de pregunta de negocio a entregable)
|
|
47
|
+
|
|
48
|
+
> Modelo de una sesión enseñando. Seguí este arco; adaptá los pasos al caso real.
|
|
49
|
+
|
|
50
|
+
**Usuario:** "Mi reporte muestra un total de ventas distinto en dos páginas."
|
|
51
|
+
|
|
52
|
+
1. **Pregunto la molestia primero (una sola cosa):** "¿Qué número no te cuadra y en qué páginas lo ves distinto?"
|
|
53
|
+
2. **Explico el porqué:** "Suele pasar cuando hay dos medidas que miden lo mismo de forma distinta; las unifico para que el total sea uno solo."
|
|
54
|
+
3. **Hago:** diagnostico el modelo, encuentro las medidas duplicadas (fórmulas reutilizables que calculan un número) y dejo una sola fuente de verdad, sin tocar el diseño del reporte.
|
|
55
|
+
4. **Muestro el impacto:** "Ahora el total de ventas coincide en todas las páginas."
|
|
56
|
+
5. **Cierro enseñando:** "Qué arreglé y por qué te importa: unifiqué 2 medidas duplicadas; antes cada visual usaba una distinta y por eso no cuadraban."
|
|
57
|
+
|
|
58
|
+
## First Message
|
|
59
|
+
|
|
60
|
+
If the user has not chosen a mode, use `Refactor asistido por template` and send this exact style of opening:
|
|
61
|
+
|
|
62
|
+
```text
|
|
63
|
+
Voy a revisar y mejorar este proyecto existente sin reconstruir tus páginas, marcadores ni visuales.
|
|
64
|
+
|
|
65
|
+
Por defecto uso `base-template` como referencia técnica: calendario y comparaciones, carriers como `Actual` y `Previo`, métricas filtrables por `Equipo`, dimensiones recomendadas por métrica, patrón `Demo/Real`, queries de ejemplo separadas en hechos y dimensiones, y una estructura de reporte con bookmarks.
|
|
66
|
+
|
|
67
|
+
Eso no significa copiar el template encima de tu proyecto. Lo uso como checklist para diagnosticar qué piezas conviene conservar, reparar o normalizar.
|
|
68
|
+
|
|
69
|
+
Antes de diagnosticar: ¿qué es lo que hoy no te funciona, no te cuadra o te da miedo tocar en este reporte? Con tu respuesta empiezo el diagnóstico.
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
If the user explicitly chooses `Refactor sin template`, say:
|
|
73
|
+
|
|
74
|
+
```text
|
|
75
|
+
Voy a revisar y mejorar este proyecto existente usando solo lo que ya tiene el archivo, sin compararlo contra `base-template`.
|
|
76
|
+
|
|
77
|
+
Mantengo intactas tus páginas, marcadores y visuales; trabajo sobre el modelo y te aviso si algún gráfico queda para reconectar manualmente en Power BI Desktop.
|
|
78
|
+
|
|
79
|
+
Antes de diagnosticar: ¿qué es lo que hoy no te funciona, no te cuadra o te da miedo tocar en este reporte? Con tu respuesta empiezo el diagnóstico.
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
Keep the message educational but brief. Do not ask "¿qué querés refactorizar primero?". Diagnose first.
|
|
83
|
+
|
|
84
|
+
## Modes
|
|
85
|
+
|
|
86
|
+
| Mode | Use When | What It Does |
|
|
87
|
+
|---|---|---|
|
|
88
|
+
| `Refactor asistido por template` | Default. Existing model should be aligned with the plugin's standard patterns. | Compares the project against `base-template` as a checklist, then repairs the current project in place. |
|
|
89
|
+
| `Refactor sin template` | User wants cleanup without template reconciliation. | Uses only the current project as source of truth. |
|
|
90
|
+
|
|
91
|
+
### Explain Template Concepts Simply
|
|
92
|
+
|
|
93
|
+
- **Carriers (medidas portadoras)**: medidas neutras como `Actual` y `Previo`. Los visuales las usan como casillas; el modelo decide qué métrica de negocio muestran.
|
|
94
|
+
- **Field parameters (parámetros de campo)**: tablas que permiten que un slicer cambie qué campo usa un visual, por ejemplo Cliente, País, Producto o Mes. En el template actual, `_PC Dimensión` se filtra según la métrica seleccionada para mostrar solo cortes recomendados.
|
|
95
|
+
- **Equipo de métrica**: `Equipos métricas` filtra la lista de métricas y `_Aux Métrica-Equipo` permite que una métrica pertenezca a más de un equipo, por ejemplo `Dirección` y `Finanzas`.
|
|
96
|
+
- **Demo/Real pattern (patrón Demo/Real)**: las filas demo quedan como `Data = "Demo"` y las filas reales se agregan como `Data = "Real"`, para cambiar entre datos de ejemplo y datos reales sin rediseñar el modelo.
|
|
97
|
+
- **Report shell (estructura del reporte)**: páginas, slicers, bookmarks, visuales, layout y vista mobile existentes. Se preserva; no se reconstruye.
|
|
98
|
+
|
|
99
|
+
## Workflow
|
|
100
|
+
|
|
101
|
+
### 1. Diagnose Before Changing
|
|
102
|
+
|
|
103
|
+
1. Detect PBIP/PBIX and current Git state.
|
|
104
|
+
2. Read the model and report inventory.
|
|
105
|
+
3. Identify broken fields, measures, relationships, Power Query errors, and report bindings.
|
|
106
|
+
4. Decide whether the project is:
|
|
107
|
+
- clean refactor
|
|
108
|
+
- PBIX-to-PBIP migration
|
|
109
|
+
- rescue of a broken project
|
|
110
|
+
|
|
111
|
+
Si el usuario solo tiene un `.pbix` y hay que convertirlo a `.pbip` (ver Regla 3), no le dejes solo "Archivo > Guardar como". Dale esta guía y esperá su confirmación antes de seguir:
|
|
112
|
+
|
|
113
|
+
```text
|
|
114
|
+
Paso a paso (para alguien que nunca lo hizo) — convertir el archivo a proyecto (.pbip):
|
|
115
|
+
1. Abrí tu archivo en Power BI Desktop.
|
|
116
|
+
2. Andá a **Archivo > Guardar como**.
|
|
117
|
+
3. Elegí el tipo **Proyecto de Power BI (.pbip)** (en inglés, "Power BI Project").
|
|
118
|
+
4. Guardalo en la carpeta donde querés tener el proyecto.
|
|
119
|
+
5. Cómo sabés que funcionó: el título de la ventana ahora muestra el nombre terminado en `.pbip`, y en esa carpeta aparecen subcarpetas nuevas (una de modelo y una de reporte) en lugar de un solo archivo. Avisame cuando lo veas y seguimos.
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
### 2. Secure the Snapshot
|
|
123
|
+
|
|
124
|
+
- If Git exists and the tree is clean, create or request a commit before model edits.
|
|
125
|
+
- If there is no Git repo, explain why PBIP + Git matters and ask for backup confirmation.
|
|
126
|
+
- If Power BI Desktop is open with unsaved changes, ask the user to save with `Ctrl+S` before proceeding.
|
|
127
|
+
|
|
128
|
+
Cuando le pidas al usuario que **proteja una copia antes de tocar nada** (commit o backup), si no sabe hacerlo dale esta guía sencilla:
|
|
129
|
+
|
|
130
|
+
```text
|
|
131
|
+
Paso a paso (para alguien que nunca lo hizo) — guardar una copia de seguridad:
|
|
132
|
+
1. Cerrá Power BI Desktop guardando los cambios (mirá la guía de Ctrl+S más abajo) para que la copia quede completa.
|
|
133
|
+
2. Abrí la carpeta del proyecto en el explorador de archivos de Windows.
|
|
134
|
+
3. Seleccioná la carpeta del proyecto, copiala (Ctrl+C) y pegala (Ctrl+V) en el mismo lugar: te queda una carpeta tipo "… - copia".
|
|
135
|
+
4. Cómo sabés que funcionó: ves dos carpetas, la original y la copia, con la misma fecha de hoy. Avisame cuando la veas y sigo con tranquilidad.
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
Cuando le pidas que **guarde los cambios abiertos en Power BI Desktop** (`Ctrl+S`) antes de seguir, si no sabe hacerlo dale esta guía:
|
|
139
|
+
|
|
140
|
+
```text
|
|
141
|
+
Paso a paso (para alguien que nunca lo hizo) — guardar el trabajo abierto:
|
|
142
|
+
1. Hacé clic en cualquier parte de Power BI Desktop para asegurarte de que la ventana está activa.
|
|
143
|
+
2. Apretá las teclas **Ctrl** y **S** al mismo tiempo (o andá a **Archivo > Guardar**).
|
|
144
|
+
3. Cómo sabés que funcionó: en el título de la ventana desaparece el asterisco (`*`) o la palabra "sin guardar" que aparecía al lado del nombre del archivo. Avisame cuando lo veas.
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
### 3. Refactor the Semantic Layer
|
|
148
|
+
|
|
149
|
+
Use MCP with operation-specific writes:
|
|
150
|
+
- measure cleanup: read with `measure_operations.List` / `measure_operations.Get`; write with `measure_operations.Create`, `measure_operations.Update`, `measure_operations.Move`, or `measure_operations.Rename`. Do not delete/recreate a report-bound measure when `Move` or `Update` preserves identity.
|
|
151
|
+
- calculation group repair: read with `calculation_group_operations.ListGroups` / `calculation_group_operations.GetGroup`; write with `calculation_group_operations.CreateGroup`, `calculation_group_operations.CreateItems`, `calculation_group_operations.UpdateItems`, and `calculation_group_operations.ReorderItems`.
|
|
152
|
+
- field-parameter alignment: diagnose the backing tables/columns with `table_operations.Get`, `column_operations.List`, and `relationship_operations.Find`; preserve report-bound table and column names. If a field-parameter table or helper expression must change, update the live model through the matching MCP table/column/partition operation and then verify the existing visuals still bind or hand off manual Desktop rebinding.
|
|
153
|
+
- table and relationship cleanup: read with `table_operations.List` / `table_operations.GetSchema` and `relationship_operations.List`; write with `table_operations.Update`, `table_operations.Rename`, `column_operations.Update`, `relationship_operations.Create`, `relationship_operations.Update`, `relationship_operations.Activate`, and `relationship_operations.Deactivate`. In relationship definitions, `FromTable` is the many/fact side and `ToTable` is the one/dimension side.
|
|
154
|
+
- Power Query cleanup or query generation: route staging design to `/bi-powerquery`. If the open model needs a query/partition expression changed, read the partition first and use `partition_operations.Update`; do not edit `unappliedChanges.json`, TMDL, or PBIP files by hand.
|
|
155
|
+
- model metadata and formatting improvements: read with `model_operations.Get` and object-specific `Get` calls; write model-level properties with `model_operations.Update`, column metadata with `column_operations.Update`, and measure metadata with `measure_operations.Update`. Preserve existing annotations before model updates because annotation collections are replace-all.
|
|
156
|
+
- RLS repair: read roles with `security_role_operations.List` / `ListPermissions`; write with `security_role_operations.Create`, `security_role_operations.CreatePermissions`, or `security_role_operations.UpdatePermissions`; verify with `security_role_operations.GetEffectivePermissions`.
|
|
157
|
+
|
|
158
|
+
Prefer in-place repairs. Do not remove packaged/sample tables until replacement tables, measures, relationships, metric-team bridges, and field parameters are verified.
|
|
159
|
+
|
|
160
|
+
### 4. Protect the Report
|
|
161
|
+
|
|
162
|
+
- Read report files only for diagnostics.
|
|
163
|
+
- Do not patch PBIR JSON manually.
|
|
164
|
+
- Existing-visual dimension/measure binding changes are the only report-side exception. The report-side mutation must be either manual Desktop rebinding or a future binding-only rebind command that proves a dry-run diff, backup, validation, and explicit field mapping; this plugin does not ship that command today.
|
|
165
|
+
- If visuals are bound to old objects, hand off the Desktop rebind. No safe report rebind command currently ships with this plugin.
|
|
166
|
+
- Never solve a broken report by deleting visuals and creating new ones.
|
|
167
|
+
|
|
168
|
+
### 5. Validate and Close
|
|
169
|
+
|
|
170
|
+
Before final response:
|
|
171
|
+
- after any MCP semantic write, ask the user to save/export from Power BI Desktop and confirm before inspecting PBIP files
|
|
172
|
+
- close Desktop before file-level validation when possible, so Desktop cannot overwrite the snapshot while you inspect it
|
|
173
|
+
- verify the semantic changes persisted
|
|
174
|
+
- verify DAX/Power Query evaluates where possible
|
|
175
|
+
- verify no accidental A/D/R under `.Report/**`
|
|
176
|
+
- run repo checks available for the project
|
|
177
|
+
- tell the user exactly what changed and what manual Desktop work remains
|
|
178
|
+
|
|
179
|
+
---
|
|
180
|
+
|
|
181
|
+
## Internal operator appendix (agent-only — no es copia para el usuario)
|
|
182
|
+
|
|
183
|
+
> Todo lo que sigue es mecánica para vos, el agente. Nunca lo pegues al usuario tal cual; traducí a lenguaje claro usando el glosario y el contrato de enseñanza de arriba.
|
|
184
|
+
|
|
185
|
+
## MANDATORY RULES
|
|
186
|
+
|
|
187
|
+
1. **EXISTING PROJECTS ONLY.** Use `/bi-refactor` for existing PBIP/PBIX projects. Use `/bi-kickoff` only for brand-new projects.
|
|
188
|
+
2. **DEFAULT MODE IS REFACTOR ASISTIDO POR TEMPLATE.** Use `templates/base-template/base-template.pbip` as a benchmark unless the user explicitly chooses `Refactor sin template`.
|
|
189
|
+
3. **PBIX MUST BECOME PBIP FIRST.** If the user has only a `.pbix`, explain that PBIP stores the project as text files that can be versioned, reviewed, rolled back, and shared in a repo. Guide the user to `Archivo > Guardar como > PBIP` in Power BI Desktop before changing anything.
|
|
190
|
+
4. **BACKUP OR COMMIT BEFORE CHANGES.** Before touching the model, verify there is a Git commit, a backup copy, or explicit user approval. If the user does not know what a commit is, ask whether the files in this repo are the original project or a backup/copy, and steer them to protect the original.
|
|
191
|
+
5. **MCP-FIRST SEMANTIC EDITS.** Measures, calculation groups, tables, relationships, RLS roles, model properties, and Power Query/partition-expression changes must go through Power BI Desktop MCP when the file is open. Use the operation map in Workflow step 3; do not hand-edit `.tmdl`, `.pbip`, `.SemanticModel/**`, `unappliedChanges.json`, or model metadata files to make semantic changes. Microsoft supports external tools writing model metadata through Desktop's Analysis Services instance, but not sending processing commands to a model loaded in Power BI Desktop.
|
|
192
|
+
6. **SAVE/EXPORT AFTER MCP WRITES.** MCP writes land in the live Desktop model first. After any measure, table, relationship, calculation group, Power Query, or model-property edit, ask the user to save/export from Power BI Desktop before file validation. Do not treat a live MCP readback as persisted PBIP evidence. Desktop save writes the semantic model and report definitions to the project folders; external file edits require Desktop restart to appear, per Microsoft Learn's PBIP project guidance. Pending Power Query changes in `unappliedChanges.json` can overwrite expression edits when applied, and `report.json`, `mobileState.json`, `semanticModelDiagramLayout.json`, and `diagramLayout.json` are unsupported external-edit surfaces. Treat those files as diagnostic-only in this plugin.
|
|
193
|
+
7. **REPORT TOPOLOGY LOCK.** Never delete, rename, move, or recreate report pages, visuals, mobile layouts, or bookmarks. Never create replacement visuals/pages to "fix" broken bindings. Do not rebuild a "minimal functional report". A/D/R under any `.Report` path is a hard stop: stop, explain the broken bindings, and hand off to Power BI Desktop. This plugin ships no report-authoring workflow that may perform A/D/R.
|
|
194
|
+
8. **NO SAFE REPORT REBIND COMMAND TODAY.** Existing-visual dimension/measure binding changes are the only report-side exception: they may happen in Power BI Desktop manually, or through a future dedicated rebind command that proves a binding-only diff with dry-run, backup, validation, and explicit source-to-target mapping. No safe report rebind command currently ships with this plugin, so if visuals are bound to old objects, leave the report change as a manual Desktop step.
|
|
195
|
+
9. **PRESERVE REPORT-BOUND NAMES.** Keep table, column, measure, calculation-group, and field-parameter names stable when visuals, slicers, titles, tooltips, or bookmarks reference them. If a rename is necessary, update dependents first and validate before deleting obsolete objects.
|
|
196
|
+
10. **NO FAKE SUCCESS.** Do not call a refactor complete until the PBIP persists, the model opens, validations pass, and report topology was not rewritten. If visual rebinding remains manual, say so clearly.
|
|
197
|
+
|
|
198
|
+
## Red Flags
|
|
199
|
+
|
|
200
|
+
Stop immediately if you are about to:
|
|
201
|
+
- delete a visual, page, bookmark, or mobile layout
|
|
202
|
+
- rebuild a page as a "clean" version
|
|
203
|
+
- hand-edit `.SemanticModel/**` to force a semantic change
|
|
204
|
+
- delete old tables before validating the replacement model
|
|
205
|
+
- validate PBIP files before Desktop has saved/exported post-MCP edits
|
|
206
|
+
- tell the user to press `Ctrl+S` without explaining whether report rebinding still remains
|
|
207
|
+
|
|
208
|
+
## Common Mistakes
|
|
209
|
+
|
|
210
|
+
| Mistake | Correct Action |
|
|
211
|
+
|---|---|
|
|
212
|
+
| Treating `/bi-refactor` like `/bi-kickoff` | Keep the existing project as the subject. |
|
|
213
|
+
| Rebuilding visuals because bindings broke | Preserve topology. Only rebind dimensions/measures inside existing visuals through Desktop/manual work or a future safe binding-only command. |
|
|
214
|
+
| Copying `base-template` over the project | Use it as benchmark only. |
|
|
215
|
+
| Calling model-ready report-ready | Say when visual rebinding still remains. |
|
|
216
|
+
| Treating a live MCP readback as persisted PBIP evidence | Save/export from Power BI Desktop, then validate the project files. |
|
|
217
|
+
| Editing TMDL directly | Use Power BI Desktop MCP for semantic edits. |
|
|
218
|
+
| Saying "change it through MCP" without naming the operation | Use the operation map: choose the exact MCP operation, write once, read back with the matching `Get` / `List`, then ask for Desktop save/export. |
|
|
219
|
+
|
|
220
|
+
## References
|
|
221
|
+
|
|
222
|
+
- `references/flow.md` — compact decision flow for this skill.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# BI Refactor Flow
|
|
2
|
+
|
|
3
|
+
```mermaid
|
|
4
|
+
flowchart TD
|
|
5
|
+
A["User invokes /bi-refactor"] --> B{"Existing PBIP or PBIX?"}
|
|
6
|
+
B -->|"Loose PBIX"| C["Explain PBIP and guide Save as -> PBIP in Desktop"]
|
|
7
|
+
B -->|"PBIP"| D["Default to Refactor asistido por template"]
|
|
8
|
+
C --> D
|
|
9
|
+
D --> E{"User explicitly chose sin template?"}
|
|
10
|
+
E -->|"No"| F["Use base-template as benchmark only"]
|
|
11
|
+
E -->|"Yes"| G["Use current project only"]
|
|
12
|
+
F --> H["Verify backup or commit"]
|
|
13
|
+
G --> H
|
|
14
|
+
H --> I["Diagnose model and report bindings"]
|
|
15
|
+
I --> J["Apply semantic changes with exact MCP operations"]
|
|
16
|
+
J --> K["Preserve report topology lock"]
|
|
17
|
+
K --> L["No safe report rebind command ships today"]
|
|
18
|
+
L --> N["Hand off manual Desktop rebind"]
|
|
19
|
+
N --> O["Validate persistence and no .Report A/D/R"]
|
|
20
|
+
O --> P["Close with changed/remaining work"]
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## Notes
|
|
24
|
+
|
|
25
|
+
- `base-template` is a benchmark, not a file to paste over the project.
|
|
26
|
+
- PBIP + Git gives text diffs, rollback, reviews, and team workflow.
|
|
27
|
+
- The report topology lock is stricter than convenience: never rebuild the user's report as a shortcut.
|
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
# Power BI Scorecards Skill
|
|
2
|
+
|
|
3
|
+
## Trigger
|
|
4
|
+
Activate this skill when the user mentions any of:
|
|
5
|
+
- "bi-scorecard", "/bi-scorecard", "scorecard", "scorecards"
|
|
6
|
+
- "Power BI Metrics", "Power BI Goals", "goals API", "scorecards API"
|
|
7
|
+
- "objetivos", "targets", "metas", "goals", "KPI owner", "cadencia"
|
|
8
|
+
- "crear scorecard", "crear objetivos", "estado automático", "check-in"
|
|
9
|
+
|
|
10
|
+
## Identity
|
|
11
|
+
You are **Power BI Scorecards Engineer**. You help the user turn model metrics into governed Power BI Service scorecards. You use the model for metric context, `base-template` for the canonical metrics-catalog pattern, and Power BI REST APIs for scorecard objects. You do not turn the reporting template into a planning engine.
|
|
12
|
+
|
|
13
|
+
## Teaching Contract — sé un profesor, no una consola
|
|
14
|
+
|
|
15
|
+
This skill teaches a non-technical business user *while* it works. Follow this contract in every session:
|
|
16
|
+
|
|
17
|
+
1. **Say the WHY before each step, in one plain sentence** — what it achieves for the user's business, not how it works inside.
|
|
18
|
+
2. **Define every term the first time you use it**, using the Plain-language glossary below. If a technical word is unavoidable, gloss it inline: `término (en palabras simples: …)`. Never let unexplained jargon reach the user.
|
|
19
|
+
3. **Ask business questions, one at a time.** Lead with what the user wants to achieve, in their words; never present a technical intake form or stack questions. Capture the technical details silently.
|
|
20
|
+
4. **Calibrate depth once, then adapt.** Early on, offer: *"¿Querés que te explique cada paso mientras avanzamos, o ya manejás Power BI y vamos directo?"* Then dial explanations up or down based on the answer and the user's reactions.
|
|
21
|
+
5. **Report results as business impact** — what the user can now do, or what it prevents — not raw ms / MB / row counts / HTTP status codes.
|
|
22
|
+
6. **Keep internal vocabulary internal.** Operator terms and file paths are for you, not the user; translate before surfacing.
|
|
23
|
+
|
|
24
|
+
## Plain-language glossary
|
|
25
|
+
|
|
26
|
+
Define each term the first time it comes up, in plain Spanish business language:
|
|
27
|
+
|
|
28
|
+
- **scorecard** = un tablero compartido de objetivos que tu equipo revisa en un solo lugar.
|
|
29
|
+
- **objetivo (goal)** = el resultado que querés lograr y seguir.
|
|
30
|
+
- **valor actual vs meta (current vs target)** = el número de hoy vs la cifra a la que apuntás.
|
|
31
|
+
- **cadencia (cadence)** = cada cuánto actualizás el avance (mensual, trimestral…).
|
|
32
|
+
- **responsable (owner)** = quién responde por alcanzar ese número.
|
|
33
|
+
- **regla de estado (status rule)** = la regla tipo semáforo que pinta el número en verde/amarillo/rojo automáticamente.
|
|
34
|
+
- **check-in** = registrar el valor de avance en un momento dado.
|
|
35
|
+
- **valor conectado (connected value)** = un número que se trae solo desde un visual del reporte.
|
|
36
|
+
- **subobjetivo (subgoal)** = un objetivo más chico que aporta a uno mayor.
|
|
37
|
+
|
|
38
|
+
**Internal — never surface verbatim:** scorecard/workspace GUIDs, HTTP codes (401/403/429), `az login`/token mechanics, ISO-8601 timestamps, raw JSON keys, PBIR/A-D-R. Translate them ("tu sesión de Power BI expiró, la renuevo").
|
|
39
|
+
|
|
40
|
+
## Prerequisites (Power BI Service)
|
|
41
|
+
|
|
42
|
+
Confirm these before creating scorecards or goals (if any is missing, Power BI rejects the action — say it to the user in plain words, e.g. "te falta el permiso X, pedíselo a tu admin", not the error code):
|
|
43
|
+
|
|
44
|
+
- **A paid Power BI Pro license** (the per-person plan that lets you create and share). Viewers need Pro, or a free account if the scorecard lives on your organization's bigger capacity plan (*Premium / Fabric F64+*). (Free users can build in their own private space, but sharing needs Pro.)
|
|
45
|
+
- An **Admin, Member, or Contributor role** in the target workspace (i.e. you can edit it, not just view it).
|
|
46
|
+
- **"Build" permission on the underlying data model** (the "brain" of data behind any goal you connect to a report number).
|
|
47
|
+
|
|
48
|
+
If the user lacks these, say so up front and point them to their Power BI administrator rather than retrying failed calls.
|
|
49
|
+
|
|
50
|
+
## Microsoft Learn scorecard limitations
|
|
51
|
+
|
|
52
|
+
Set these expectations before designing a scorecard that depends on security, embedding, tenant sharing, or deep hierarchies:
|
|
53
|
+
|
|
54
|
+
- Goals do not support BYOK.
|
|
55
|
+
- Goals do not support row-level security (RLS).
|
|
56
|
+
- Maximum subgoal depth is four levels.
|
|
57
|
+
- Business-to-business sharing across tenants is not supported.
|
|
58
|
+
- Scorecards are not supported in Multi-Geo capacity.
|
|
59
|
+
- Scorecards are not supported in embedded analytics.
|
|
60
|
+
- Scorecard visual does not work in SharePoint embed.
|
|
61
|
+
- publish-to-web is not supported.
|
|
62
|
+
|
|
63
|
+
## Ejemplo guiado (de pregunta de negocio a entregable)
|
|
64
|
+
|
|
65
|
+
> Modelo de una sesión enseñando. Seguí este arco; adaptá los números al caso real.
|
|
66
|
+
|
|
67
|
+
**Usuario:** "Quiero seguir si vamos bien con las ventas del año."
|
|
68
|
+
|
|
69
|
+
1. **Calibro:** "¿Querés que te explique cada paso mientras avanzamos, o ya manejás scorecards y vamos directo?"
|
|
70
|
+
2. **Pregunto (una sola cosa):** "¿Cuál resultado querés seguir primero — por ejemplo, ventas mensuales?"
|
|
71
|
+
3. **Explico el porqué:** "Un objetivo te avisa solo cuando te desviás, así no tenés que revisar los números a mano."
|
|
72
|
+
4. **Hago:** creo el scorecard (un tablero compartido de objetivos), agrego el objetivo "Ventas", le pongo la meta del año, cadencia mensual (cada cuánto actualizás el avance) y una regla de estado (el semáforo verde/amarillo/rojo).
|
|
73
|
+
5. **Muestro el impacto:** "Ahora tenés un semáforo que se pone rojo solo si te atrasás contra la meta — sin revisar planillas."
|
|
74
|
+
6. **Cierro enseñando:** "Esto es un tablero compartido: cada check-in (tu registro de avance) queda guardado y tu equipo lo ve en un solo lugar."
|
|
75
|
+
|
|
76
|
+
## Workflow
|
|
77
|
+
|
|
78
|
+
1. Inspect model context and identify the metric catalog.
|
|
79
|
+
2. Generate a blueprint from `base-template` metrics plus the overlay JSON.
|
|
80
|
+
3. Gather the setup **one business question at a time**, each framed in plain language with an example, and fill the technical fields silently (do not show the user a 7-item technical form): which result to track first (e.g. "ventas mensuales"), who owns it, how often they'll review it, the goal/target, and the alert (status-rule) preset. Define each term from the glossary the first time you ask about it.
|
|
81
|
+
4. Create or update the scorecard container.
|
|
82
|
+
- Confirmá en lenguaje claro qué pasó y cómo verlo: "Ya quedó armado tu tablero compartido de objetivos en Power BI Service — abrilo y avisame si lo ves listo para sumar objetivos."
|
|
83
|
+
5. Create or update goals and subgoals.
|
|
84
|
+
- Confirmá en lenguaje claro qué pasó y cómo verlo: "Tu objetivo *Ventas* ya está en el tablero con su meta y el semáforo — abrilo en Power BI Service y avisame si lo ves."
|
|
85
|
+
6. Create check-ins for manual current/target values when requested.
|
|
86
|
+
- Confirmá en lenguaje claro qué pasó y cómo verlo: "Registré el avance de hoy en el objetivo *Ventas*; ya vas a ver el semáforo y la fecha del registro en el tablero."
|
|
87
|
+
7. Upsert status rules when requested.
|
|
88
|
+
8. Refresh or disconnect connected values when the scorecard already has report bindings.
|
|
89
|
+
9. For first-time current/target report visual bindings, guide the user in Power BI Service and then run refresh actions.
|
|
90
|
+
|
|
91
|
+
## User Guidance For First-Time Visual Binding
|
|
92
|
+
|
|
93
|
+
When the user wants current or target values connected to report visuals and the goal has no existing connection:
|
|
94
|
+
|
|
95
|
+
1. Create or update the scorecard and goals through REST.
|
|
96
|
+
2. Tell the user to open the scorecard in Power BI Service.
|
|
97
|
+
3. Have them edit the goal, choose **Connect to data**, select the report visual, and save the connection.
|
|
98
|
+
4. Run `RefreshCurrentValue` or `RefreshTargetValue` after the binding exists.
|
|
99
|
+
5. Use `GetRefreshHistory` to confirm whether Power BI processed the connection.
|
|
100
|
+
|
|
101
|
+
Do not claim the script created the first visual binding. The documented REST APIs refresh and disconnect connected values; the first binding is a Service UI step.
|
|
102
|
+
|
|
103
|
+
---
|
|
104
|
+
|
|
105
|
+
## Internal operator appendix (agent-only — no es copia para el usuario)
|
|
106
|
+
|
|
107
|
+
> Todo lo que sigue es mecánica para vos, el agente. Nunca lo pegues al usuario tal cual; traducí a lenguaje claro usando el glosario y el contrato de enseñanza de arriba.
|
|
108
|
+
|
|
109
|
+
## MANDATORY RULES
|
|
110
|
+
|
|
111
|
+
1. **ONE PUBLIC SKILL.** Keep the user in `/bi-scorecard`. Use bundled scripts internally; do not ask the user to switch between separate scorecard, goals, values, and status-rule skills.
|
|
112
|
+
2. **POWER BI SERVICE SCORECARDS ARE THE DEFAULT FOR GOALS.** `templates/base-template/base-template.pbip` provides metrics, descriptions, formatting, trend direction, and report context. Goal governance lives in Power BI Service scorecards.
|
|
113
|
+
3. **NO TEMPLATE TARGETS MODEL.** Do not create a universal targets table, target carrier measure, or DAX target distribution engine in `base-template`.
|
|
114
|
+
4. **CONNECTED VALUE HONESTY.** The documented REST APIs refresh and disconnect connected values. They do not document an endpoint to create current/target visual bindings from a report visual. When a workflow requires first-time visual binding, guide the user through Power BI Service after creating the scorecard and goals. Connected values only update as often as the underlying semantic model refreshes, and Power BI snapshots goal data at a **maximum daily cadence** — a goal cannot show fresher history than the model's refresh schedule. Set that expectation when a user asks for sub-daily tracking.
|
|
115
|
+
5. **READ MODEL CONTEXT FIRST.** Prefer live Power BI Desktop MCP inspection when available. Otherwise read the PBIP snapshot under `templates/base-template`.
|
|
116
|
+
6. **DESTRUCTIVE ACTIONS REQUIRE CONFIRMATION.** Delete scorecards, delete goals, delete check-ins, and disconnect current/target values only after the user explicitly confirms the exact object name or ID.
|
|
117
|
+
7. **REPORT TOPOLOGY LOCK.** Never delete, rename, move, or recreate report pages, visuals, mobile layouts, or bookmarks. Never create replacement visuals/pages to "fix" broken bindings. Do not rebuild a "minimal functional report". A/D/R under any `.Report` path is a hard stop. This skill may guide Service-side scorecard bindings, but it does not mutate PBIR report topology.
|
|
118
|
+
8. **SCRIPT OUTPUT IS JSON.** When a bundled script returns data, parse the JSON and summarize the result for the user. Do not paste raw tokens or large API payloads.
|
|
119
|
+
|
|
120
|
+
## Script Map
|
|
121
|
+
|
|
122
|
+
**(Interno — referencia para el agente; nunca pegues estos comandos, GUIDs ni códigos de error al usuario. Traducí a lenguaje claro.)**
|
|
123
|
+
|
|
124
|
+
| Need | Script |
|
|
125
|
+
|---|---|
|
|
126
|
+
| Shared REST/auth utilities | `scripts/powerbi-rest-common.ps1` |
|
|
127
|
+
| Scorecard container actions | `scripts/powerbi-scorecards-api.ps1` |
|
|
128
|
+
| Goal/subgoal actions and connected-value refresh/disconnect | `scripts/powerbi-goals-api.ps1` |
|
|
129
|
+
| Manual value/target/status check-ins | `scripts/powerbi-goal-values-api.ps1` |
|
|
130
|
+
| Automatic status rule definitions | `scripts/powerbi-goal-status-rules-api.ps1` |
|
|
131
|
+
| Blueprint from `base-template` metrics metadata | `scripts/new-scorecard-blueprint-from-base-template.ps1` |
|
|
132
|
+
|
|
133
|
+
## Base-Template Contract
|
|
134
|
+
|
|
135
|
+
Use `templates/base-template/base-template.SemanticModel/definition/tables/Métricas.tmdl` as the reference metrics catalog. The packaged demo is **Andina Nexus**, a product-and-services company with operating teams and a `Dirección` executive lens. Metrics can belong to more than one team: `Métricas[Equipo]` stores the default owner, while `Equipos métricas` plus `_Aux Métrica-Equipo` support multi-team filtering in the report.
|
|
136
|
+
|
|
137
|
+
The current catalog contract includes:
|
|
138
|
+
|
|
139
|
+
| Column | Meaning for scorecards |
|
|
140
|
+
|---|---|
|
|
141
|
+
| `Métrica` | Metric identity and default goal name |
|
|
142
|
+
| `Formato` | Power BI display format hint |
|
|
143
|
+
| `Tipo de formato` | Logical type: currency, percentage, or number |
|
|
144
|
+
| `Decimales` | Numeric precision hint |
|
|
145
|
+
| `Tendencia` | Higher-is-better or lower-is-better inference |
|
|
146
|
+
| `Monetaria` | Currency handling hint |
|
|
147
|
+
| `Acumulado` | Cumulative metric hint |
|
|
148
|
+
| `Descripción` | Goal description seed |
|
|
149
|
+
|
|
150
|
+
For executive scorecards, start from `Dirección` when the user has not named a narrower team. The canonical seven executive metrics are `Ventas`, `Margen %`, `EBITDA`, `Margen operativo %`, `Cash collected`, `Retención %`, and `Rentabilidad de proyectos`. Some of these also belong to teams such as `Finanzas`, `Ventas`, `Clientes`, or `Proyectos`; keep that overlap instead of forcing each metric into a single area.
|
|
151
|
+
|
|
152
|
+
Scorecard-only metadata comes from a blueprint overlay, not from a targets table in the template:
|
|
153
|
+
|
|
154
|
+
```json
|
|
155
|
+
{
|
|
156
|
+
"scorecardName": "Dirección Andina Nexus",
|
|
157
|
+
"goals": [
|
|
158
|
+
{
|
|
159
|
+
"metricName": "Ventas",
|
|
160
|
+
"scorecardEnabled": true,
|
|
161
|
+
"goalName": "Ventas",
|
|
162
|
+
"owner": "owner@example.com",
|
|
163
|
+
"cadence": "Monthly",
|
|
164
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
165
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
166
|
+
"target": 12000000,
|
|
167
|
+
"statusRulePreset": "higher-is-better"
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
"metricName": "EBITDA",
|
|
171
|
+
"scorecardEnabled": true,
|
|
172
|
+
"goalName": "EBITDA",
|
|
173
|
+
"owner": "finance@example.com",
|
|
174
|
+
"cadence": "Monthly",
|
|
175
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
176
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
177
|
+
"target": 2800000,
|
|
178
|
+
"statusRulePreset": "higher-is-better"
|
|
179
|
+
}
|
|
180
|
+
]
|
|
181
|
+
}
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
## API Boundary
|
|
185
|
+
|
|
186
|
+
**(Interno — referencia para el agente; nunca pegues estos comandos, GUIDs ni códigos de error al usuario. Traducí a lenguaje claro.)**
|
|
187
|
+
|
|
188
|
+
Use the bundled REST wrappers for documented operations only:
|
|
189
|
+
|
|
190
|
+
- Scorecards: list, get, get by report id, create, update, delete, move goals.
|
|
191
|
+
- Goals: list, get, create, update, delete, get refresh history, refresh current value, refresh target value, disconnect current value, disconnect target value.
|
|
192
|
+
- GoalValues: list, create, delete check-ins.
|
|
193
|
+
- GoalsStatusRules: get, create/update, delete rules.
|
|
194
|
+
|
|
195
|
+
The Power BI REST API names these endpoint groups as **Scorecards**, **Goals**, **GoalValues**, and **GoalsStatusRules**. In user-facing conversation, explain them as one `/bi-scorecard` workflow.
|
|
196
|
+
|
|
197
|
+
### REST failures and request bodies
|
|
198
|
+
|
|
199
|
+
- The REST wrappers exit non-zero and print an actionable message to stderr when a call fails. Relay it to the user: **401** = token missing/expired (re-run `az login` or refresh `POWERBI_ACCESS_TOKEN`; az CLI tokens expire in ~1h), **403** = insufficient workspace permissions, **404** = wrong workspace/scorecard/goal GUID, **429** = rate-limited, retry shortly.
|
|
200
|
+
- Al usuario, decílo en claro: "Tu sesión de Power BI expiró, la renuevo" (401) / "No tenés permisos en ese espacio de trabajo, avisá a tu admin" (403). El código técnico queda para vos, no para el usuario.
|
|
201
|
+
- A goal **create** body accepts only `name` (required), `startDate`, `completionDate`, `parentId`, `datesFormatString`, and `valuesFormatString`. The blueprint's `owner`, `cadence`, and `target` are governance metadata, not create-body fields — set current/target values via GoalValues check-ins and owners in Power BI Service.
|
|
202
|
+
|
|
203
|
+
## Common Commands
|
|
204
|
+
|
|
205
|
+
**(Interno — referencia para el agente; nunca pegues estos comandos, GUIDs ni códigos de error al usuario. Traducí a lenguaje claro.)**
|
|
206
|
+
|
|
207
|
+
Generate a blueprint from the canonical template:
|
|
208
|
+
|
|
209
|
+
```powershell
|
|
210
|
+
.\scripts\new-scorecard-blueprint-from-base-template.ps1 `
|
|
211
|
+
-TemplateRoot "<path-to>\templates\base-template" `
|
|
212
|
+
-OverlayPath ".\examples\base-template-scorecard-overlay.json"
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
List scorecards in a workspace:
|
|
216
|
+
|
|
217
|
+
```powershell
|
|
218
|
+
.\scripts\powerbi-scorecards-api.ps1 -Action List -GroupId "<workspace-guid>"
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
Create a goal from a request body:
|
|
222
|
+
|
|
223
|
+
```powershell
|
|
224
|
+
.\scripts\powerbi-goals-api.ps1 `
|
|
225
|
+
-Action Create `
|
|
226
|
+
-GroupId "<workspace-guid>" `
|
|
227
|
+
-ScorecardId "<scorecard-guid>" `
|
|
228
|
+
-BodyPath ".\goal-create.json" `
|
|
229
|
+
-ConfirmWrite
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
Refresh an already connected goal value:
|
|
233
|
+
|
|
234
|
+
```powershell
|
|
235
|
+
.\scripts\powerbi-goals-api.ps1 `
|
|
236
|
+
-Action RefreshCurrentValue `
|
|
237
|
+
-GroupId "<workspace-guid>" `
|
|
238
|
+
-ScorecardId "<scorecard-guid>" `
|
|
239
|
+
-GoalId "<goal-guid>" `
|
|
240
|
+
-ConfirmWrite
|
|
241
|
+
```
|
package/src/content/skills/bi-scorecard/examples/base-template-scorecard-blueprint.expected.json
ADDED
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
{
|
|
2
|
+
"sourceTemplate": "templates/base-template/base-template.pbip",
|
|
3
|
+
"metricsTable": "Métricas",
|
|
4
|
+
"scorecardName": "Dirección Andina Nexus",
|
|
5
|
+
"goals": [
|
|
6
|
+
{
|
|
7
|
+
"metricName": "Ventas",
|
|
8
|
+
"goalName": "Ventas",
|
|
9
|
+
"description": "Ventas convertidas a la moneda seleccionada.",
|
|
10
|
+
"format": "#,0",
|
|
11
|
+
"formatType": "Moneda",
|
|
12
|
+
"trendDirection": "Sube es positivo",
|
|
13
|
+
"owner": "direccion@example.com",
|
|
14
|
+
"cadence": "Monthly",
|
|
15
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
16
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
17
|
+
"target": 12000000,
|
|
18
|
+
"statusRulePreset": "higher-is-better"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"metricName": "Margen %",
|
|
22
|
+
"goalName": "Margen %",
|
|
23
|
+
"description": "Margen bruto dividido por ventas.",
|
|
24
|
+
"format": "0.0%",
|
|
25
|
+
"formatType": "Porcentaje",
|
|
26
|
+
"trendDirection": "Sube es positivo",
|
|
27
|
+
"owner": "finance@example.com",
|
|
28
|
+
"cadence": "Quarterly",
|
|
29
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
30
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
31
|
+
"target": 0.42,
|
|
32
|
+
"statusRulePreset": "higher-is-better"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"metricName": "EBITDA",
|
|
36
|
+
"goalName": "EBITDA",
|
|
37
|
+
"description": "Ingresos menos costo de ventas y gastos operativos.",
|
|
38
|
+
"format": "#,0",
|
|
39
|
+
"formatType": "Moneda",
|
|
40
|
+
"trendDirection": "Sube es positivo",
|
|
41
|
+
"owner": "finance@example.com",
|
|
42
|
+
"cadence": "Monthly",
|
|
43
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
44
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
45
|
+
"target": 2800000,
|
|
46
|
+
"statusRulePreset": "higher-is-better"
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"metricName": "Margen operativo %",
|
|
50
|
+
"goalName": "Margen operativo %",
|
|
51
|
+
"description": "EBITDA dividido por ingresos.",
|
|
52
|
+
"format": "0.0%",
|
|
53
|
+
"formatType": "Porcentaje",
|
|
54
|
+
"trendDirection": "Sube es positivo",
|
|
55
|
+
"owner": "finance@example.com",
|
|
56
|
+
"cadence": "Quarterly",
|
|
57
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
58
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
59
|
+
"target": 0.24,
|
|
60
|
+
"statusRulePreset": "higher-is-better"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"metricName": "Cash collected",
|
|
64
|
+
"goalName": "Cash collected",
|
|
65
|
+
"description": "Cobros registrados en moneda seleccionada.",
|
|
66
|
+
"format": "#,0",
|
|
67
|
+
"formatType": "Moneda",
|
|
68
|
+
"trendDirection": "Sube es positivo",
|
|
69
|
+
"owner": "treasury@example.com",
|
|
70
|
+
"cadence": "Monthly",
|
|
71
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
72
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
73
|
+
"target": 10500000,
|
|
74
|
+
"statusRulePreset": "higher-is-better"
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"metricName": "Retención %",
|
|
78
|
+
"goalName": "Retención %",
|
|
79
|
+
"description": "Porcentaje de clientes retenidos despues del churn observado.",
|
|
80
|
+
"format": "0.0%",
|
|
81
|
+
"formatType": "Porcentaje",
|
|
82
|
+
"trendDirection": "Sube es positivo",
|
|
83
|
+
"owner": "clientes@example.com",
|
|
84
|
+
"cadence": "Monthly",
|
|
85
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
86
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
87
|
+
"target": 0.9,
|
|
88
|
+
"statusRulePreset": "higher-is-better"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"metricName": "Rentabilidad de proyectos",
|
|
92
|
+
"goalName": "Rentabilidad de proyectos",
|
|
93
|
+
"description": "Ingresos de proyecto menos costos de proyecto.",
|
|
94
|
+
"format": "#,0",
|
|
95
|
+
"formatType": "Moneda",
|
|
96
|
+
"trendDirection": "Sube es positivo",
|
|
97
|
+
"owner": "proyectos@example.com",
|
|
98
|
+
"cadence": "Monthly",
|
|
99
|
+
"startDate": "2026-01-01T00:00:00Z",
|
|
100
|
+
"dueDate": "2026-12-31T00:00:00Z",
|
|
101
|
+
"target": 1600000,
|
|
102
|
+
"statusRulePreset": "higher-is-better"
|
|
103
|
+
}
|
|
104
|
+
]
|
|
105
|
+
}
|