customer-card-render

作者: microsoft

從設計思考的典型產出生成客戶卡片 PowerPoint 內容 YAML,並透過共用的 PowerPoint 技能管道進行建置——由…提供

npx skills add https://github.com/microsoft/hve-core --skill customer-card-render

Customer Card Render Skill

Converts canonical Design Thinking markdown artifacts into PowerPoint skill content.yaml slide definitions and builds the final deck through the shared PowerPoint build pipeline.

Overview

This skill is a sibling to the experimental powerpoint skill. It handles the Design Thinking-specific mapping layer: extracting sections from canonical markdown artifacts and filling template-driven content.yaml files. The PowerPoint skill then owns layout rendering, theming, export, and validation.

Keeping these concerns separate means:

  • Customer-card mapping logic stays independent from general PowerPoint capabilities.
  • The skill can be included in collections independently.
  • Layout primitives, Invoke-PptxPipeline.ps1, theming, and validation behavior are not reimplemented here.

For full PowerPoint pipeline documentation, see powerpoint/SKILL.md.

Prerequisites

  • Python 3.11+

  • uv package manager — install with one of:

    # macOS / Linux
    curl -LsSf https://astral.sh/uv/install.sh | sh
    
    # Windows
    powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
    
    # Via pip (fallback)
    pip install uv
    
  • The experimental powerpoint skill at .github/skills/experimental/powerpoint/ for the Invoke-PptxPipeline.ps1 build step

Directory Structure

.github/skills/experimental/customer-card-render/
├── SKILL.md
├── pyproject.toml
├── references/
│   └── mapping-spec.md
├── scripts/
│   └── generate_cards.py
├── templates/
│   ├── global-style.yaml
│   ├── persona.content.yaml
│   ├── problem.content.yaml
│   ├── scenario.content.yaml
│   ├── use-case-slide1.content.yaml
│   ├── use-case-slide2.content.yaml
│   ├── use-case-slide3.content.yaml
│   └── vision.content.yaml
└── tests/
    ├── fuzz_harness.py
    └── test_generate_cards.py

Supported Artifact Types

Artifact TypeSlide Layout
Vision StatementSingle slide
Problem StatementSingle slide
ScenarioSingle slide
Use Case4 slides (see below)
PersonaSingle slide

Use Case 3-Slide Layout

Each Use Case expands into 3 consecutive slides with distinct sections:

SlideContent
Slide 1Use Case Description, Use Case Overview, Business Value, Primary User
Slide 2Secondary User, Preconditions, Steps, Data Requirements
Slide 3Equipment Requirements, Operating Environment, Success Criteria, Pain Points, Evidence

Cards are ordered by artifact type (Vision → Problem → Scenario → Use Case → Persona), then alphabetically by title within each type. Use Cases appear with all 4 slides consecutive (Slide N, N+1, N+2, N+3).

Two-Command Flow

Step 1: Generate slide YAML from canonical markdown

python .github/skills/experimental/customer-card-render/scripts/generate_cards.py \
  --canonical-dir .copilot-tracking/dt/<project-slug>/canonical \
  --output-dir .copilot-tracking/dt/<project-slug>/render/content

generate_cards.py CLI Reference

FlagRequiredDefaultDescription
--canonical-dirNo<skill-root>/canonicalDirectory containing canonical DT markdown files
--output-dirNo<skill-root>/scripts/contentDirectory to write generated content.yaml files
-v, --verboseNoEnable debug-level logging

The script reads each markdown file in --canonical-dir, detects the artifact type from frontmatter, extracts required sections, and generates content.yaml files. Vision, Problem, Scenario, and Persona artifacts produce one slide each. Use Case artifacts produce 3 consecutive slides per use case.

For the section-to-field mapping contract and Use Case 3-slide layout details, see references/mapping-spec.md.

Step 2: Build PPTX using the PowerPoint skill pipeline

./.github/skills/experimental/powerpoint/scripts/Invoke-PptxPipeline.ps1 -Action Build `
  -ContentDir .copilot-tracking/dt/<project-slug>/render/content `
  -StylePath .copilot-tracking/dt/<project-slug>/render/content/global/style.yaml `
  -OutputPath .copilot-tracking/dt/<project-slug>/render/output/customer-cards.pptx

The PowerShell orchestrator manages virtual environment setup and dependency installation automatically via uv sync. See powerpoint/SKILL.md for the full Invoke-PptxPipeline.ps1 parameter reference, template usage, validation, and export options.

DT Coach Integration

The dt-canonical-deck prompt and the dt-coaching-foundation skill's canonical-deck reference provide opt-in workflow integration for the Design Thinking coaching agent. When a user opts in, the coaching agent offers to build customer cards at method exit points. The two-command flow above runs as part of that workflow with --canonical-dir and --output-dir resolved from the active DT project slug in .copilot-tracking/dt/.

Canonical artifacts are produced by the DT coach and live under .copilot-tracking/dt/<project-slug>/canonical/.

Running Tests

cd .github/skills/experimental/customer-card-render
uv sync --group dev
uv run pytest tests/

Tests cover parsing, template selection, YAML emission, and regressions. The tests/fuzz_harness.py file is an Atheris polyglot fuzz harness for OSSF Scorecard compliance.

Content Fidelity Note: Use Case Cards

Use Case cards are split across 3 opinionated slides, each with dedicated sections:

  • Slide 1: Introduces the use case with Description, Overview, Business Value, and Primary User
  • Slide 2: Details execution with Secondary User, Preconditions, Steps, and Data Requirements
  • Slide 3: Captures quality criteria with Equipment Requirements, Operating Environment, Success Criteria, Pain Points, and Evidence

This structure ensures all 16 Use Case sections fit legibly across 4 slides without compression. Each section appears in its own textbox with appropriate styling and heading.

For complete mapping details, see references/mapping-spec.md.

Troubleshooting

IssueCauseSolution
uv not founduv not installedRun curl -LsSf https://astral.sh/uv/install.sh | sh (macOS/Linux) or pip install uv
Python not found by uvNo Python 3.11+ on PATHRun uv python install 3.11
Template not found--canonical-dir contains unknown typeCheck frontmatter type: field against supported artifact types
Empty output directoryNo canonical markdown files foundConfirm --canonical-dir path and that files have --- frontmatter
PPTX build fails after generatePowerPoint skill missing or path incorrectConfirm powerpoint/ skill exists at .github/skills/experimental/powerpoint/

Brought to you by microsoft/hve-core

來自 microsoft 的更多技能

oss-growth
microsoft
開源增長駭客角色
official
microsoft-foundry
microsoft
端到端部署、評估與管理 Foundry 代理:Docker 建置、ACR 推送、託管/提示代理建立、容器啟動、批次評估、持續評估、提示最佳化工作流程、agent.yaml、從追蹤資料集整理。用途:將代理部署至 Foundry、託管代理、建立代理、調用代理、評估代理、執行批次評估、持續評估、持續監控、持續評估狀態、最佳化提示、改善提示、提示最佳化器、最佳化代理指令、改善代理...
officialdevelopmentdevops
azure-ai
microsoft
用於 Azure AI:搜尋、語音、OpenAI、文件智慧。協助搜尋、向量/混合搜尋、語音轉文字、文字轉語音、轉錄、OCR。適用情境:AI 搜尋、查詢搜尋、向量搜尋、混合搜尋、語意搜尋、語音轉文字、文字轉語音、轉錄、OCR、將文字轉換為語音。
officialdevelopmentapi
azure-deploy
microsoft
對已準備好的應用程式執行 Azure 部署,這些應用程式需具備現有的 .azure/deployment-plan.md 與基礎架構檔案。當使用者要求建立新應用程式時,請勿使用此技能——應改用 azure-prepare。此技能會執行 azd up、azd deploy、terraform apply 及 az deployment 命令,並內建錯誤復原機制。需具備來自 azure-prepare 的 .azure/deployment-plan.md,以及來自 azure-validate 的驗證狀態。適用時機:「執行 azd up」、「執行 azd deploy」、「執行部署」……
officialdevopsaws
azure-storage
microsoft
Azure Storage Services 包括 Blob 儲存體、檔案共用、佇列儲存體、表格儲存體和 Data Lake。回答關於儲存存取層(熱、冷、凍結、封存)、各層使用時機及層級比較的問題。提供物件儲存、SMB 檔案共用、非同步訊息、NoSQL 鍵值及大數據分析。包含生命週期管理。用於:blob 儲存體、檔案共用、佇列儲存體、表格儲存體、data lake、上傳檔案、下載 blob、儲存帳戶、存取層...
officialdevelopmentdatabase
azure-diagnostics
microsoft
在 Azure 上使用 AppLens、Azure Monitor、資源健康狀態和安全分類來偵錯 Azure 生產問題。適用時機:偵錯生產問題、疑難排解應用程式服務、應用程式服務高 CPU、應用程式服務部署失敗、疑難排解容器應用程式、疑難排解函數、疑難排解 AKS、kubectl 無法連線、kube-system/CoreDNS 失敗、Pod 擱置、CrashLoop、節點未就緒、升級失敗、分析記錄、KQL、深入解析、映像提取失敗、冷啟動問題、健康狀態探查失敗...
officialdevopsdevelopment
azure-prepare
microsoft
準備 Azure 應用程式以進行部署(基礎架構 Bicep/Terraform、azure.yaml、Dockerfile)。用於建立/現代化或建立+部署;不適用於跨雲端遷移(請使用 azure-cloud-migrate)。請勿用於:copilot-sdk 應用程式(請使用 azure-hosted-copilot-sdk)。適用時機:「建立應用程式」、「建置 Web 應用程式」、「建立 API」、「建立無伺服器 HTTP API」、「建立前端」、「建立後端」、「建置服務」、「現代化應用程式」、「更新應用程式」、「新增驗證」、「新增快取」、「託管於 Azure」、「建立並...」
officialdevelopmentdevops
azure-validate
microsoft
部署前驗證 Azure 就緒狀態。對設定、基礎架構(Bicep 或 Terraform)、RBAC 角色指派、受控身分權限及先決條件進行深度檢查,再進行部署。適用時機:驗證我的應用程式、檢查部署就緒狀態、執行預檢檢查、驗證設定、確認是否可部署、驗證 azure.yaml、驗證 Bicep、部署前測試、疑難排解部署錯誤、驗證 Azure Functions、驗證函式應用程式、驗證無伺服器...
officialdevopstesting