sofia-cli 0.1.1
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/.github/agents/copilot-instructions.md +39 -0
- package/.github/agents/speckit.analyze.agent.md +184 -0
- package/.github/agents/speckit.checklist.agent.md +294 -0
- package/.github/agents/speckit.clarify.agent.md +181 -0
- package/.github/agents/speckit.constitution.agent.md +84 -0
- package/.github/agents/speckit.implement.agent.md +135 -0
- package/.github/agents/speckit.plan.agent.md +90 -0
- package/.github/agents/speckit.specify.agent.md +258 -0
- package/.github/agents/speckit.tasks.agent.md +137 -0
- package/.github/agents/speckit.taskstoissues.agent.md +30 -0
- package/.github/copilot-instructions.md +257 -0
- package/.github/prompts/speckit.analyze.prompt.md +3 -0
- package/.github/prompts/speckit.checklist.prompt.md +3 -0
- package/.github/prompts/speckit.clarify.prompt.md +3 -0
- package/.github/prompts/speckit.constitution.prompt.md +3 -0
- package/.github/prompts/speckit.implement.prompt.md +3 -0
- package/.github/prompts/speckit.plan.prompt.md +3 -0
- package/.github/prompts/speckit.specify.prompt.md +3 -0
- package/.github/prompts/speckit.tasks.prompt.md +3 -0
- package/.github/prompts/speckit.taskstoissues.prompt.md +3 -0
- package/.github/workflows/ci.yml +38 -0
- package/.prettierrc +6 -0
- package/.specify/memory/constitution.md +181 -0
- package/.specify/scripts/bash/check-prerequisites.sh +166 -0
- package/.specify/scripts/bash/common.sh +156 -0
- package/.specify/scripts/bash/create-new-feature.sh +297 -0
- package/.specify/scripts/bash/setup-plan.sh +61 -0
- package/.specify/scripts/bash/update-agent-context.sh +810 -0
- package/.specify/templates/agent-file-template.md +28 -0
- package/.specify/templates/checklist-template.md +40 -0
- package/.specify/templates/constitution-template.md +50 -0
- package/.specify/templates/plan-template.md +113 -0
- package/.specify/templates/spec-template.md +115 -0
- package/.specify/templates/tasks-template.md +251 -0
- package/.vscode/mcp.json +42 -0
- package/.vscode/settings.json +19 -0
- package/CODE_OF_CONDUCT.md +128 -0
- package/LICENSE +21 -0
- package/README.md +213 -0
- package/dist/src/cli/developCommand.js +240 -0
- package/dist/src/cli/directCommands.js +143 -0
- package/dist/src/cli/envLoader.js +16 -0
- package/dist/src/cli/exportCommand.js +53 -0
- package/dist/src/cli/index.js +203 -0
- package/dist/src/cli/ioContext.js +109 -0
- package/dist/src/cli/preflight.js +57 -0
- package/dist/src/cli/statusCommand.js +110 -0
- package/dist/src/cli/workshopCommand.js +400 -0
- package/dist/src/develop/checkpointState.js +86 -0
- package/dist/src/develop/codeGenerator.js +319 -0
- package/dist/src/develop/dynamicScaffolder.js +226 -0
- package/dist/src/develop/githubMcpAdapter.js +122 -0
- package/dist/src/develop/index.js +15 -0
- package/dist/src/develop/mcpContextEnricher.js +195 -0
- package/dist/src/develop/pocScaffolder.js +542 -0
- package/dist/src/develop/ralphLoop.js +659 -0
- package/dist/src/develop/templateRegistry.js +364 -0
- package/dist/src/develop/testRunner.js +202 -0
- package/dist/src/logging/logger.js +58 -0
- package/dist/src/loop/conversationLoop.js +227 -0
- package/dist/src/loop/phaseSummarizer.js +87 -0
- package/dist/src/mcp/mcpManager.js +267 -0
- package/dist/src/mcp/mcpTransport.js +391 -0
- package/dist/src/mcp/retryPolicy.js +47 -0
- package/dist/src/mcp/webSearch.js +254 -0
- package/dist/src/phases/contextSummarizer.js +101 -0
- package/dist/src/phases/discoveryEnricher.js +156 -0
- package/dist/src/phases/phaseExtractors.js +222 -0
- package/dist/src/phases/phaseHandlers.js +328 -0
- package/dist/src/prompts/design.md +51 -0
- package/dist/src/prompts/develop-boundary.md +51 -0
- package/dist/src/prompts/develop.md +111 -0
- package/dist/src/prompts/discover.md +58 -0
- package/dist/src/prompts/ideate.md +56 -0
- package/dist/src/prompts/plan.md +51 -0
- package/dist/src/prompts/promptLoader.js +167 -0
- package/dist/src/prompts/promptLoader.ts +198 -0
- package/dist/src/prompts/select.md +47 -0
- package/dist/src/prompts/summarize/README.md +8 -0
- package/dist/src/prompts/summarize/design-summary.md +37 -0
- package/dist/src/prompts/summarize/develop-summary.md +25 -0
- package/dist/src/prompts/summarize/ideate-summary.md +27 -0
- package/dist/src/prompts/summarize/plan-summary.md +27 -0
- package/dist/src/prompts/summarize/select-summary.md +21 -0
- package/dist/src/prompts/system.md +28 -0
- package/dist/src/sessions/exportPaths.js +22 -0
- package/dist/src/sessions/exportWriter.js +406 -0
- package/dist/src/sessions/sessionManager.js +81 -0
- package/dist/src/sessions/sessionStore.js +65 -0
- package/dist/src/shared/activitySpinner.js +91 -0
- package/dist/src/shared/copilotClient.js +129 -0
- package/dist/src/shared/data/cards.json +1249 -0
- package/dist/src/shared/data/cardsLoader.js +51 -0
- package/dist/src/shared/errorClassifier.js +120 -0
- package/dist/src/shared/events.js +28 -0
- package/dist/src/shared/markdownRenderer.js +34 -0
- package/dist/src/shared/schemas/session.js +265 -0
- package/dist/src/shared/tableRenderer.js +20 -0
- package/dist/src/vendor/chalk.js +2 -0
- package/dist/src/vendor/cli-table3.js +3 -0
- package/dist/src/vendor/commander.js +2 -0
- package/dist/src/vendor/marked-terminal.js +3 -0
- package/dist/src/vendor/marked.js +2 -0
- package/dist/src/vendor/ora.js +2 -0
- package/dist/src/vendor/pino.js +2 -0
- package/dist/src/vendor/zod.js +2 -0
- package/dist/tests/e2e/developE2e.spec.js +126 -0
- package/dist/tests/e2e/developFailureE2e.spec.js +247 -0
- package/dist/tests/e2e/developPty.spec.js +75 -0
- package/dist/tests/e2e/discoveryWebSearchRelevance.spec.js +84 -0
- package/dist/tests/e2e/harness.spec.js +83 -0
- package/dist/tests/e2e/mcpLive.spec.js +120 -0
- package/dist/tests/e2e/newSession.e2e.spec.js +177 -0
- package/dist/tests/e2e/ralphLoopEnrichmentComparison.spec.js +62 -0
- package/dist/tests/e2e/workiqEnrichment.spec.js +56 -0
- package/dist/tests/e2e/zavaSimulation.spec.js +452 -0
- package/dist/tests/fixtures/test-fixture-project/src/add.js +3 -0
- package/dist/tests/fixtures/test-fixture-project/tests/failing.test.js +6 -0
- package/dist/tests/fixtures/test-fixture-project/tests/hanging.test.js +8 -0
- package/dist/tests/fixtures/test-fixture-project/tests/passing.test.js +10 -0
- package/dist/tests/fixtures/test-fixture-project/vitest.config.js +6 -0
- package/dist/tests/integration/autoStartConversation.spec.js +138 -0
- package/dist/tests/integration/defaultCommand.spec.js +147 -0
- package/dist/tests/integration/directCommandNonTty.spec.js +224 -0
- package/dist/tests/integration/directCommandTty.spec.js +151 -0
- package/dist/tests/integration/discoveryEnrichmentFlow.spec.js +175 -0
- package/dist/tests/integration/exportArtifacts.spec.js +202 -0
- package/dist/tests/integration/exportFallbackFlow.spec.js +99 -0
- package/dist/tests/integration/mcpDegradationFlow.spec.js +190 -0
- package/dist/tests/integration/mcpTransportFlow.spec.js +139 -0
- package/dist/tests/integration/newSessionFlow.spec.js +343 -0
- package/dist/tests/integration/pocGithubMcp.spec.js +186 -0
- package/dist/tests/integration/pocLocalFallback.spec.js +171 -0
- package/dist/tests/integration/pocScaffold.spec.js +163 -0
- package/dist/tests/integration/ralphLoopFlow.spec.js +359 -0
- package/dist/tests/integration/ralphLoopPartial.spec.js +368 -0
- package/dist/tests/integration/resumeAndBacktrack.spec.js +247 -0
- package/dist/tests/integration/spinnerLifecycle.spec.js +220 -0
- package/dist/tests/integration/summarizationFlow.spec.js +115 -0
- package/dist/tests/integration/testRunnerReal.spec.js +52 -0
- package/dist/tests/integration/webSearchAgent.spec.js +128 -0
- package/dist/tests/live/copilotSdkLive.spec.js +107 -0
- package/dist/tests/live/zavaFullWorkshop.spec.js +392 -0
- package/dist/tests/setup/loadEnv.js +3 -0
- package/dist/tests/unit/cli/developCommand.spec.js +567 -0
- package/dist/tests/unit/cli/directCommands.spec.js +279 -0
- package/dist/tests/unit/cli/envLoader.spec.js +58 -0
- package/dist/tests/unit/cli/ioContext.spec.js +119 -0
- package/dist/tests/unit/cli/preflight.spec.js +108 -0
- package/dist/tests/unit/cli/statusCommand.spec.js +111 -0
- package/dist/tests/unit/cli/workshopClientFallback.spec.js +80 -0
- package/dist/tests/unit/cli/workshopCommand.spec.js +329 -0
- package/dist/tests/unit/config/vitestEnvSetup.spec.js +13 -0
- package/dist/tests/unit/develop/checkpointState.spec.js +315 -0
- package/dist/tests/unit/develop/codeGenerator.spec.js +355 -0
- package/dist/tests/unit/develop/githubMcpAdapter.spec.js +231 -0
- package/dist/tests/unit/develop/mcpContextEnricher.spec.js +433 -0
- package/dist/tests/unit/develop/outputValidator.spec.js +119 -0
- package/dist/tests/unit/develop/pocScaffolder.spec.js +353 -0
- package/dist/tests/unit/develop/ralphLoop.spec.js +1248 -0
- package/dist/tests/unit/develop/templateRegistry.spec.js +85 -0
- package/dist/tests/unit/develop/testRunner.spec.js +249 -0
- package/dist/tests/unit/infraBicep.spec.js +92 -0
- package/dist/tests/unit/infraDeploy.spec.js +82 -0
- package/dist/tests/unit/infraTeardown.spec.js +63 -0
- package/dist/tests/unit/logging/logger.spec.js +43 -0
- package/dist/tests/unit/loop/conversationLoop.spec.js +592 -0
- package/dist/tests/unit/loop/phaseSummarizer.spec.js +141 -0
- package/dist/tests/unit/loop/streamingMarkdown.spec.js +147 -0
- package/dist/tests/unit/mcp/mcpManager.spec.js +279 -0
- package/dist/tests/unit/mcp/mcpTransport.spec.js +529 -0
- package/dist/tests/unit/mcp/retryPolicy.spec.js +218 -0
- package/dist/tests/unit/mcp/timeoutValidation.spec.js +46 -0
- package/dist/tests/unit/mcp/webSearch.spec.js +567 -0
- package/dist/tests/unit/phases/contextSummarizer.spec.js +140 -0
- package/dist/tests/unit/phases/discoveryEnricher.repeatCalls.spec.js +93 -0
- package/dist/tests/unit/phases/discoveryEnricher.spec.js +411 -0
- package/dist/tests/unit/phases/phaseExtractors.spec.js +352 -0
- package/dist/tests/unit/phases/phaseHandlers.spec.js +425 -0
- package/dist/tests/unit/prompts/promptLoader.spec.js +118 -0
- package/dist/tests/unit/schemas/pocSchemas.spec.js +412 -0
- package/dist/tests/unit/schemas/session.spec.js +257 -0
- package/dist/tests/unit/sessions/exportPaths.spec.js +31 -0
- package/dist/tests/unit/sessions/exportWriter.spec.js +655 -0
- package/dist/tests/unit/sessions/sessionManager.spec.js +151 -0
- package/dist/tests/unit/sessions/sessionStore.spec.js +116 -0
- package/dist/tests/unit/shared/activitySpinner.spec.js +175 -0
- package/dist/tests/unit/shared/cardsLoader.spec.js +76 -0
- package/dist/tests/unit/shared/copilotClient.spec.js +155 -0
- package/dist/tests/unit/shared/errorClassifier.spec.js +131 -0
- package/dist/tests/unit/shared/events.spec.js +55 -0
- package/dist/tests/unit/shared/markdownRenderer.spec.js +35 -0
- package/dist/tests/unit/shared/markdownRendererChunks.spec.js +70 -0
- package/dist/tests/unit/shared/tableRenderer.spec.js +34 -0
- package/dist/vitest.config.js +14 -0
- package/dist/vitest.live.config.js +18 -0
- package/docs/README.md +35 -0
- package/docs/architecture.md +169 -0
- package/docs/cli-usage.md +207 -0
- package/docs/environment.md +66 -0
- package/docs/export-format.md +146 -0
- package/docs/session-model.md +113 -0
- package/eslint.config.js +35 -0
- package/infra/deploy.sh +193 -0
- package/infra/gather-env.sh +211 -0
- package/infra/main.bicep +90 -0
- package/infra/main.bicepparam +18 -0
- package/infra/resources.bicep +134 -0
- package/infra/teardown.sh +114 -0
- package/package.json +63 -0
- package/specs/001-cli-workshop-rebuild/checklists/requirements.md +35 -0
- package/specs/001-cli-workshop-rebuild/contracts/cli.md +59 -0
- package/specs/001-cli-workshop-rebuild/contracts/export-summary-json.md +23 -0
- package/specs/001-cli-workshop-rebuild/contracts/session-json.md +30 -0
- package/specs/001-cli-workshop-rebuild/data-model.md +210 -0
- package/specs/001-cli-workshop-rebuild/plan.md +361 -0
- package/specs/001-cli-workshop-rebuild/quickstart.md +83 -0
- package/specs/001-cli-workshop-rebuild/research.md +116 -0
- package/specs/001-cli-workshop-rebuild/spec.md +240 -0
- package/specs/001-cli-workshop-rebuild/tasks.md +476 -0
- package/specs/002-poc-generation/contracts/poc-output.md +172 -0
- package/specs/002-poc-generation/contracts/ralph-loop.md +113 -0
- package/specs/002-poc-generation/data-model.md +172 -0
- package/specs/002-poc-generation/plan.md +109 -0
- package/specs/002-poc-generation/quickstart.md +97 -0
- package/specs/002-poc-generation/research.md +786 -0
- package/specs/002-poc-generation/spec.md +81 -0
- package/specs/002-poc-generation/tasks-fix.md +198 -0
- package/specs/002-poc-generation/tasks.md +252 -0
- package/specs/003-mcp-transport-integration/checklists/requirements.md +37 -0
- package/specs/003-mcp-transport-integration/contracts/context-enricher.md +220 -0
- package/specs/003-mcp-transport-integration/contracts/discovery-enricher.md +267 -0
- package/specs/003-mcp-transport-integration/contracts/github-adapter.md +149 -0
- package/specs/003-mcp-transport-integration/contracts/mcp-transport.md +288 -0
- package/specs/003-mcp-transport-integration/data-model.md +326 -0
- package/specs/003-mcp-transport-integration/plan.md +114 -0
- package/specs/003-mcp-transport-integration/quickstart.md +311 -0
- package/specs/003-mcp-transport-integration/research.md +395 -0
- package/specs/003-mcp-transport-integration/spec.md +234 -0
- package/specs/003-mcp-transport-integration/tasks.md +324 -0
- package/specs/003-next-spec-gaps.md +150 -0
- package/specs/004-dev-resume-hardening/checklists/requirements.md +37 -0
- package/specs/004-dev-resume-hardening/contracts/cli.md +160 -0
- package/specs/004-dev-resume-hardening/data-model.md +321 -0
- package/specs/004-dev-resume-hardening/plan.md +107 -0
- package/specs/004-dev-resume-hardening/quickstart.md +115 -0
- package/specs/004-dev-resume-hardening/research.md +142 -0
- package/specs/004-dev-resume-hardening/spec.md +221 -0
- package/specs/004-dev-resume-hardening/tasks.md +333 -0
- package/specs/005-ai-search-deploy/checklists/requirements.md +39 -0
- package/specs/005-ai-search-deploy/contracts/web-search-tool.md +241 -0
- package/specs/005-ai-search-deploy/data-model.md +130 -0
- package/specs/005-ai-search-deploy/plan.md +93 -0
- package/specs/005-ai-search-deploy/quickstart.md +96 -0
- package/specs/005-ai-search-deploy/research.md +187 -0
- package/specs/005-ai-search-deploy/spec.md +143 -0
- package/specs/005-ai-search-deploy/tasks.md +284 -0
- package/specs/006-workshop-extraction-fixes/checklists/requirements.md +61 -0
- package/specs/006-workshop-extraction-fixes/contracts/summarization-and-export.md +131 -0
- package/specs/006-workshop-extraction-fixes/data-model.md +149 -0
- package/specs/006-workshop-extraction-fixes/plan.md +123 -0
- package/specs/006-workshop-extraction-fixes/quickstart.md +101 -0
- package/specs/006-workshop-extraction-fixes/research.md +143 -0
- package/specs/006-workshop-extraction-fixes/spec.md +210 -0
- package/specs/006-workshop-extraction-fixes/tasks.md +316 -0
- package/src/cli/developCommand.ts +308 -0
- package/src/cli/directCommands.ts +195 -0
- package/src/cli/envLoader.ts +17 -0
- package/src/cli/exportCommand.ts +65 -0
- package/src/cli/index.ts +249 -0
- package/src/cli/ioContext.ts +139 -0
- package/src/cli/preflight.ts +86 -0
- package/src/cli/statusCommand.ts +118 -0
- package/src/cli/workshopCommand.ts +496 -0
- package/src/develop/checkpointState.ts +121 -0
- package/src/develop/codeGenerator.ts +402 -0
- package/src/develop/dynamicScaffolder.ts +284 -0
- package/src/develop/githubMcpAdapter.ts +199 -0
- package/src/develop/index.ts +34 -0
- package/src/develop/mcpContextEnricher.ts +279 -0
- package/src/develop/pocScaffolder.ts +646 -0
- package/src/develop/ralphLoop.ts +1044 -0
- package/src/develop/templateRegistry.ts +427 -0
- package/src/develop/testRunner.ts +276 -0
- package/src/logging/logger.ts +73 -0
- package/src/loop/conversationLoop.ts +355 -0
- package/src/loop/phaseSummarizer.ts +114 -0
- package/src/mcp/mcpManager.ts +365 -0
- package/src/mcp/mcpTransport.ts +562 -0
- package/src/mcp/retryPolicy.ts +87 -0
- package/src/mcp/webSearch.ts +388 -0
- package/src/originalPrompts/design_thinking.md +178 -0
- package/src/originalPrompts/design_thinking_persona.md +76 -0
- package/src/originalPrompts/document_generator_example.md +77 -0
- package/src/originalPrompts/document_generator_persona.md +47 -0
- package/src/originalPrompts/facilitator_persona.md +125 -0
- package/src/originalPrompts/guardrails.md +47 -0
- package/src/phases/contextSummarizer.ts +154 -0
- package/src/phases/discoveryEnricher.ts +223 -0
- package/src/phases/phaseExtractors.ts +247 -0
- package/src/phases/phaseHandlers.ts +450 -0
- package/src/prompts/design.md +51 -0
- package/src/prompts/develop-boundary.md +51 -0
- package/src/prompts/develop.md +111 -0
- package/src/prompts/discover.md +58 -0
- package/src/prompts/ideate.md +56 -0
- package/src/prompts/plan.md +51 -0
- package/src/prompts/promptLoader.ts +198 -0
- package/src/prompts/select.md +47 -0
- package/src/prompts/summarize/README.md +8 -0
- package/src/prompts/summarize/design-summary.md +37 -0
- package/src/prompts/summarize/develop-summary.md +25 -0
- package/src/prompts/summarize/ideate-summary.md +27 -0
- package/src/prompts/summarize/plan-summary.md +27 -0
- package/src/prompts/summarize/select-summary.md +21 -0
- package/src/prompts/system.md +28 -0
- package/src/sessions/exportPaths.ts +28 -0
- package/src/sessions/exportWriter.ts +490 -0
- package/src/sessions/sessionManager.ts +119 -0
- package/src/sessions/sessionStore.ts +69 -0
- package/src/shared/activitySpinner.ts +108 -0
- package/src/shared/copilotClient.ts +291 -0
- package/src/shared/data/cards.json +1249 -0
- package/src/shared/data/cardsLoader.ts +70 -0
- package/src/shared/errorClassifier.ts +160 -0
- package/src/shared/events.ts +103 -0
- package/src/shared/markdownRenderer.ts +44 -0
- package/src/shared/schemas/session.ts +346 -0
- package/src/shared/tableRenderer.ts +28 -0
- package/src/types/marked-terminal.d.ts +5 -0
- package/src/vendor/chalk.ts +2 -0
- package/src/vendor/cli-table3.ts +3 -0
- package/src/vendor/commander.ts +2 -0
- package/src/vendor/marked-terminal.ts +3 -0
- package/src/vendor/marked.ts +2 -0
- package/src/vendor/ora.ts +2 -0
- package/src/vendor/pino.ts +3 -0
- package/src/vendor/zod.ts +3 -0
- package/tests/e2e/developE2e.spec.ts +152 -0
- package/tests/e2e/developFailureE2e.spec.ts +289 -0
- package/tests/e2e/developPty.spec.ts +86 -0
- package/tests/e2e/discoveryWebSearchRelevance.spec.ts +103 -0
- package/tests/e2e/harness.spec.ts +104 -0
- package/tests/e2e/mcpLive.spec.ts +149 -0
- package/tests/e2e/newSession.e2e.spec.ts +245 -0
- package/tests/e2e/ralphLoopEnrichmentComparison.spec.ts +70 -0
- package/tests/e2e/workiqEnrichment.spec.ts +72 -0
- package/tests/e2e/zava-assessment/agent-interaction-script.md +258 -0
- package/tests/e2e/zava-assessment/company-profile.md +98 -0
- package/tests/e2e/zava-assessment/expected-results-checklist.md +454 -0
- package/tests/e2e/zavaSimulation.spec.ts +511 -0
- package/tests/fixtures/completedSession.json +141 -0
- package/tests/fixtures/test-fixture-project/package-lock.json +1585 -0
- package/tests/fixtures/test-fixture-project/package.json +12 -0
- package/tests/fixtures/test-fixture-project/src/add.ts +3 -0
- package/tests/fixtures/test-fixture-project/tests/failing.test.ts +7 -0
- package/tests/fixtures/test-fixture-project/tests/hanging.test.ts +9 -0
- package/tests/fixtures/test-fixture-project/tests/passing.test.ts +13 -0
- package/tests/fixtures/test-fixture-project/vitest.config.ts +7 -0
- package/tests/integration/autoStartConversation.spec.ts +168 -0
- package/tests/integration/defaultCommand.spec.ts +179 -0
- package/tests/integration/directCommandNonTty.spec.ts +260 -0
- package/tests/integration/directCommandTty.spec.ts +185 -0
- package/tests/integration/discoveryEnrichmentFlow.spec.ts +209 -0
- package/tests/integration/exportArtifacts.spec.ts +232 -0
- package/tests/integration/exportFallbackFlow.spec.ts +115 -0
- package/tests/integration/mcpDegradationFlow.spec.ts +231 -0
- package/tests/integration/mcpTransportFlow.spec.ts +178 -0
- package/tests/integration/newSessionFlow.spec.ts +406 -0
- package/tests/integration/pocGithubMcp.spec.ts +224 -0
- package/tests/integration/pocLocalFallback.spec.ts +205 -0
- package/tests/integration/pocScaffold.spec.ts +220 -0
- package/tests/integration/ralphLoopFlow.spec.ts +430 -0
- package/tests/integration/ralphLoopPartial.spec.ts +416 -0
- package/tests/integration/resumeAndBacktrack.spec.ts +278 -0
- package/tests/integration/spinnerLifecycle.spec.ts +270 -0
- package/tests/integration/summarizationFlow.spec.ts +135 -0
- package/tests/integration/testRunnerReal.spec.ts +63 -0
- package/tests/integration/webSearchAgent.spec.ts +155 -0
- package/tests/live/copilotSdkLive.spec.ts +149 -0
- package/tests/live/zavaFullWorkshop.spec.ts +515 -0
- package/tests/setup/loadEnv.ts +5 -0
- package/tests/unit/cli/developCommand.spec.ts +679 -0
- package/tests/unit/cli/directCommands.spec.ts +325 -0
- package/tests/unit/cli/envLoader.spec.ts +73 -0
- package/tests/unit/cli/ioContext.spec.ts +148 -0
- package/tests/unit/cli/preflight.spec.ts +125 -0
- package/tests/unit/cli/statusCommand.spec.ts +134 -0
- package/tests/unit/cli/workshopClientFallback.spec.ts +100 -0
- package/tests/unit/cli/workshopCommand.spec.ts +378 -0
- package/tests/unit/config/vitestEnvSetup.spec.ts +24 -0
- package/tests/unit/develop/checkpointState.spec.ts +378 -0
- package/tests/unit/develop/codeGenerator.spec.ts +447 -0
- package/tests/unit/develop/githubMcpAdapter.spec.ts +283 -0
- package/tests/unit/develop/mcpContextEnricher.spec.ts +564 -0
- package/tests/unit/develop/outputValidator.spec.ts +134 -0
- package/tests/unit/develop/pocScaffolder.spec.ts +451 -0
- package/tests/unit/develop/ralphLoop.spec.ts +1439 -0
- package/tests/unit/develop/templateRegistry.spec.ts +106 -0
- package/tests/unit/develop/testRunner.spec.ts +294 -0
- package/tests/unit/infraBicep.spec.ts +116 -0
- package/tests/unit/infraDeploy.spec.ts +102 -0
- package/tests/unit/infraTeardown.spec.ts +77 -0
- package/tests/unit/logging/logger.spec.ts +50 -0
- package/tests/unit/loop/conversationLoop.spec.ts +719 -0
- package/tests/unit/loop/phaseSummarizer.spec.ts +169 -0
- package/tests/unit/loop/streamingMarkdown.spec.ts +180 -0
- package/tests/unit/mcp/mcpManager.spec.ts +336 -0
- package/tests/unit/mcp/mcpTransport.spec.ts +689 -0
- package/tests/unit/mcp/retryPolicy.spec.ts +278 -0
- package/tests/unit/mcp/timeoutValidation.spec.ts +55 -0
- package/tests/unit/mcp/webSearch.spec.ts +718 -0
- package/tests/unit/phases/contextSummarizer.spec.ts +158 -0
- package/tests/unit/phases/discoveryEnricher.repeatCalls.spec.ts +125 -0
- package/tests/unit/phases/discoveryEnricher.spec.ts +512 -0
- package/tests/unit/phases/phaseExtractors.spec.ts +406 -0
- package/tests/unit/phases/phaseHandlers.spec.ts +483 -0
- package/tests/unit/prompts/promptLoader.spec.ts +144 -0
- package/tests/unit/schemas/pocSchemas.spec.ts +457 -0
- package/tests/unit/schemas/session.spec.ts +328 -0
- package/tests/unit/sessions/exportPaths.spec.ts +38 -0
- package/tests/unit/sessions/exportWriter.spec.ts +737 -0
- package/tests/unit/sessions/sessionManager.spec.ts +174 -0
- package/tests/unit/sessions/sessionStore.spec.ts +136 -0
- package/tests/unit/shared/activitySpinner.spec.ts +211 -0
- package/tests/unit/shared/cardsLoader.spec.ts +89 -0
- package/tests/unit/shared/copilotClient.spec.ts +185 -0
- package/tests/unit/shared/errorClassifier.spec.ts +152 -0
- package/tests/unit/shared/events.spec.ts +71 -0
- package/tests/unit/shared/markdownRenderer.spec.ts +42 -0
- package/tests/unit/shared/markdownRendererChunks.spec.ts +83 -0
- package/tests/unit/shared/tableRenderer.spec.ts +38 -0
- package/tsconfig.json +20 -0
- package/vitest.config.ts +15 -0
- package/vitest.live.config.ts +19 -0
|
@@ -0,0 +1,388 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Web search tool backed by Azure AI Foundry Agent Service.
|
|
3
|
+
*
|
|
4
|
+
* Provides a `web.search` tool that can be registered with the Copilot SDK.
|
|
5
|
+
* Uses `@azure/ai-projects` SDK with `DefaultAzureCredential` for authentication.
|
|
6
|
+
* Creates an ephemeral agent with `web_search_preview` on first search call,
|
|
7
|
+
* reuses it for the session, and deletes it on session end.
|
|
8
|
+
*
|
|
9
|
+
* When not configured or on error, degrades gracefully.
|
|
10
|
+
*/
|
|
11
|
+
import type { ToolDefinition } from '../shared/copilotClient.js';
|
|
12
|
+
|
|
13
|
+
// ── Types ────────────────────────────────────────────────────────────────────
|
|
14
|
+
|
|
15
|
+
export interface WebSearchResultItem {
|
|
16
|
+
title: string;
|
|
17
|
+
url: string;
|
|
18
|
+
snippet: string;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface WebSearchResult {
|
|
22
|
+
results: WebSearchResultItem[];
|
|
23
|
+
sources?: string[];
|
|
24
|
+
/** If true, the search degraded (Foundry unavailable/error). */
|
|
25
|
+
degraded?: boolean;
|
|
26
|
+
/** Error message when degraded. */
|
|
27
|
+
error?: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export interface WebSearchConfig {
|
|
31
|
+
projectEndpoint: string;
|
|
32
|
+
modelDeploymentName: string;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// ── Tool definition ──────────────────────────────────────────────────────────
|
|
36
|
+
|
|
37
|
+
export const WEB_SEARCH_TOOL_DEFINITION: ToolDefinition = {
|
|
38
|
+
name: 'web.search',
|
|
39
|
+
description:
|
|
40
|
+
'Search the web for information about companies, industries, technologies, and trends. ' +
|
|
41
|
+
'Returns structured results with title, URL, and snippet.',
|
|
42
|
+
parameters: {
|
|
43
|
+
type: 'object',
|
|
44
|
+
properties: {
|
|
45
|
+
query: {
|
|
46
|
+
type: 'string',
|
|
47
|
+
description: 'The search query string.',
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
required: ['query'],
|
|
51
|
+
},
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
// ── Configuration check ──────────────────────────────────────────────────────
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* Check if web search is configured via environment variables.
|
|
58
|
+
*
|
|
59
|
+
* Uses the new env vars (`FOUNDRY_PROJECT_ENDPOINT`, `FOUNDRY_MODEL_DEPLOYMENT_NAME`)
|
|
60
|
+
* instead of legacy vars (`SOFIA_FOUNDRY_AGENT_ENDPOINT`, `SOFIA_FOUNDRY_AGENT_KEY`).
|
|
61
|
+
*/
|
|
62
|
+
export function isWebSearchConfigured(): boolean {
|
|
63
|
+
return Boolean(process.env.FOUNDRY_PROJECT_ENDPOINT && process.env.FOUNDRY_MODEL_DEPLOYMENT_NAME);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
// ── Citation extraction ──────────────────────────────────────────────────────
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Extract citations from a Foundry agent response.
|
|
70
|
+
*
|
|
71
|
+
* Parses `url_citation` annotations from the response output items and maps
|
|
72
|
+
* them into `WebSearchResultItem[]`. Deduplicates sources by URL.
|
|
73
|
+
*/
|
|
74
|
+
export function extractCitations(output: unknown[]): {
|
|
75
|
+
results: WebSearchResultItem[];
|
|
76
|
+
sources: string[];
|
|
77
|
+
} {
|
|
78
|
+
const results: WebSearchResultItem[] = [];
|
|
79
|
+
const seenUrls = new Set<string>();
|
|
80
|
+
|
|
81
|
+
for (const item of output) {
|
|
82
|
+
const messageItem = item as Record<string, unknown>;
|
|
83
|
+
if (messageItem.type !== 'message') continue;
|
|
84
|
+
|
|
85
|
+
const content = messageItem.content as unknown[];
|
|
86
|
+
if (!Array.isArray(content)) continue;
|
|
87
|
+
|
|
88
|
+
for (const contentBlock of content) {
|
|
89
|
+
const block = contentBlock as Record<string, unknown>;
|
|
90
|
+
if (block.type !== 'output_text') continue;
|
|
91
|
+
|
|
92
|
+
const text = String(block.text ?? '');
|
|
93
|
+
const annotations = block.annotations as unknown[];
|
|
94
|
+
if (!Array.isArray(annotations)) continue;
|
|
95
|
+
|
|
96
|
+
for (const annotation of annotations) {
|
|
97
|
+
const ann = annotation as Record<string, unknown>;
|
|
98
|
+
if (ann.type !== 'url_citation') continue;
|
|
99
|
+
|
|
100
|
+
const url = String(ann.url ?? '');
|
|
101
|
+
const title = String(ann.title ?? url);
|
|
102
|
+
const startIndex = Number(ann.start_index ?? 0);
|
|
103
|
+
const endIndex = Number(ann.end_index ?? text.length);
|
|
104
|
+
const snippet = text.slice(startIndex, Math.min(endIndex, startIndex + 200)) || title;
|
|
105
|
+
|
|
106
|
+
if (url && !seenUrls.has(url)) {
|
|
107
|
+
seenUrls.add(url);
|
|
108
|
+
results.push({ title, url, snippet });
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
return { results, sources: [...seenUrls] };
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Fallback extraction when a response has no URL citations.
|
|
119
|
+
*
|
|
120
|
+
* Some Foundry responses can contain only plain output text without
|
|
121
|
+
* `url_citation` annotations. This extracts text blocks into lightweight
|
|
122
|
+
* snippets so downstream enrichment still has useful context.
|
|
123
|
+
*/
|
|
124
|
+
export function extractTextSnippets(output: unknown[]): WebSearchResultItem[] {
|
|
125
|
+
const snippets: WebSearchResultItem[] = [];
|
|
126
|
+
|
|
127
|
+
for (const item of output) {
|
|
128
|
+
const messageItem = item as Record<string, unknown>;
|
|
129
|
+
if (messageItem.type !== 'message') continue;
|
|
130
|
+
|
|
131
|
+
const content = messageItem.content as unknown[];
|
|
132
|
+
if (!Array.isArray(content)) continue;
|
|
133
|
+
|
|
134
|
+
for (let i = 0; i < content.length; i++) {
|
|
135
|
+
const block = content[i] as Record<string, unknown>;
|
|
136
|
+
if (block.type !== 'output_text') continue;
|
|
137
|
+
|
|
138
|
+
const text = String(block.text ?? '').trim();
|
|
139
|
+
if (!text) continue;
|
|
140
|
+
|
|
141
|
+
snippets.push({
|
|
142
|
+
title: 'Foundry response',
|
|
143
|
+
url: `foundry://response/${i + 1}`,
|
|
144
|
+
snippet: text.length > 300 ? `${text.slice(0, 300)}…` : text,
|
|
145
|
+
});
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
return snippets;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// ── Agent Session ────────────────────────────────────────────────────────────
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* Internal state for the ephemeral web search agent.
|
|
156
|
+
* Manages lazy initialization, query execution, and cleanup.
|
|
157
|
+
*/
|
|
158
|
+
export interface AgentSessionDeps {
|
|
159
|
+
createClient: (endpoint: string) => unknown;
|
|
160
|
+
getOpenAIClient: (client: unknown) => Promise<unknown>;
|
|
161
|
+
createAgentVersion: (
|
|
162
|
+
client: unknown,
|
|
163
|
+
name: string,
|
|
164
|
+
options: unknown,
|
|
165
|
+
) => Promise<{ name: string; version: string }>;
|
|
166
|
+
deleteAgentVersion: (client: unknown, name: string, version: string) => Promise<void>;
|
|
167
|
+
createConversation: (openAIClient: unknown) => Promise<{ id: string }>;
|
|
168
|
+
deleteConversation: (openAIClient: unknown, id: string) => Promise<void>;
|
|
169
|
+
createResponse: (
|
|
170
|
+
openAIClient: unknown,
|
|
171
|
+
conversationId: string,
|
|
172
|
+
input: string,
|
|
173
|
+
agentName: string,
|
|
174
|
+
) => Promise<{ output: unknown[] }>;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
interface AgentSessionState {
|
|
178
|
+
client: unknown;
|
|
179
|
+
openAIClient: unknown;
|
|
180
|
+
agentName: string;
|
|
181
|
+
agentVersion: string;
|
|
182
|
+
queryCount: number;
|
|
183
|
+
initialized: boolean;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
const MAX_QUERIES_PER_AGENT = 3;
|
|
187
|
+
const MAX_RETRIES = 2;
|
|
188
|
+
const RETRY_DELAY_MS = 2000; // 2 second initial delay
|
|
189
|
+
|
|
190
|
+
let sessionState: AgentSessionState | null = null;
|
|
191
|
+
let sessionDeps: AgentSessionDeps | null = null;
|
|
192
|
+
|
|
193
|
+
/**
|
|
194
|
+
* Create default dependencies using the real Azure SDK.
|
|
195
|
+
*/
|
|
196
|
+
async function createDefaultDeps(): Promise<AgentSessionDeps> {
|
|
197
|
+
const { AIProjectClient } = await import('@azure/ai-projects');
|
|
198
|
+
const { DefaultAzureCredential } = await import('@azure/identity');
|
|
199
|
+
|
|
200
|
+
return {
|
|
201
|
+
createClient: (endpoint: string) => new AIProjectClient(endpoint, new DefaultAzureCredential()),
|
|
202
|
+
getOpenAIClient: async (client: unknown) =>
|
|
203
|
+
(client as InstanceType<typeof AIProjectClient>).getOpenAIClient(),
|
|
204
|
+
createAgentVersion: async (client: unknown, name: string, options: unknown) => {
|
|
205
|
+
const aiClient = client as InstanceType<typeof AIProjectClient>;
|
|
206
|
+
const result = await aiClient.agents.createVersion(
|
|
207
|
+
name,
|
|
208
|
+
options as import('@azure/ai-projects').AgentDefinitionUnion,
|
|
209
|
+
);
|
|
210
|
+
return { name: result.name, version: result.version };
|
|
211
|
+
},
|
|
212
|
+
deleteAgentVersion: async (client: unknown, name: string, version: string) => {
|
|
213
|
+
await (client as InstanceType<typeof AIProjectClient>).agents.deleteVersion(name, version);
|
|
214
|
+
},
|
|
215
|
+
createConversation: async (openAIClient: unknown) => {
|
|
216
|
+
const oai = openAIClient as { conversations: { create: () => Promise<{ id: string }> } };
|
|
217
|
+
return oai.conversations.create();
|
|
218
|
+
},
|
|
219
|
+
deleteConversation: async (openAIClient: unknown, id: string) => {
|
|
220
|
+
const oai = openAIClient as { conversations: { delete: (id: string) => Promise<void> } };
|
|
221
|
+
await oai.conversations.delete(id);
|
|
222
|
+
},
|
|
223
|
+
createResponse: async (
|
|
224
|
+
openAIClient: unknown,
|
|
225
|
+
conversationId: string,
|
|
226
|
+
input: string,
|
|
227
|
+
agentName: string,
|
|
228
|
+
) => {
|
|
229
|
+
const oai = openAIClient as {
|
|
230
|
+
responses: {
|
|
231
|
+
create: (params: unknown, options: unknown) => Promise<{ output: unknown[] }>;
|
|
232
|
+
};
|
|
233
|
+
};
|
|
234
|
+
return oai.responses.create(
|
|
235
|
+
{ conversation: conversationId, input },
|
|
236
|
+
{ body: { agent: { name: agentName, type: 'agent_reference' } } },
|
|
237
|
+
);
|
|
238
|
+
},
|
|
239
|
+
};
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
// ── Tool factory ─────────────────────────────────────────────────────────────
|
|
243
|
+
|
|
244
|
+
async function sleep(ms: number): Promise<void> {
|
|
245
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
async function cleanupCurrentAgent(keepDeps: boolean): Promise<void> {
|
|
249
|
+
if (!sessionState?.initialized || !sessionDeps) {
|
|
250
|
+
sessionState = null;
|
|
251
|
+
return;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
const { client, agentName, agentVersion } = sessionState;
|
|
255
|
+
|
|
256
|
+
sessionState = null;
|
|
257
|
+
|
|
258
|
+
try {
|
|
259
|
+
await sessionDeps.deleteAgentVersion(client, agentName, agentVersion);
|
|
260
|
+
} catch {
|
|
261
|
+
// Best-effort cleanup.
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
if (!keepDeps) {
|
|
265
|
+
sessionDeps = null;
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
/**
|
|
270
|
+
* Create a web search function that calls the Azure AI Foundry Agent Service.
|
|
271
|
+
*
|
|
272
|
+
* The returned function:
|
|
273
|
+
* - Lazily creates an ephemeral agent with web_search_preview on first call
|
|
274
|
+
* - Reuses the agent for subsequent calls
|
|
275
|
+
* - Rotates the agent after a few queries to avoid stale response behavior
|
|
276
|
+
* - Uses a fresh conversation per query to keep citation output stable
|
|
277
|
+
* - Returns structured results with URL citations
|
|
278
|
+
* - Degrades gracefully on errors (returns empty results with degraded flag)
|
|
279
|
+
*
|
|
280
|
+
* Pass `deps` for testing to inject mocked SDK clients.
|
|
281
|
+
*/
|
|
282
|
+
export function createWebSearchTool(
|
|
283
|
+
config: WebSearchConfig,
|
|
284
|
+
deps?: AgentSessionDeps,
|
|
285
|
+
): (query: string) => Promise<WebSearchResult> {
|
|
286
|
+
sessionDeps = deps ?? null;
|
|
287
|
+
|
|
288
|
+
return async (query: string): Promise<WebSearchResult> => {
|
|
289
|
+
try {
|
|
290
|
+
const resolvedDeps = sessionDeps ?? (await createDefaultDeps());
|
|
291
|
+
sessionDeps = resolvedDeps;
|
|
292
|
+
|
|
293
|
+
if (sessionState?.initialized && sessionState.queryCount >= MAX_QUERIES_PER_AGENT) {
|
|
294
|
+
await cleanupCurrentAgent(true);
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
// Lazy initialization
|
|
298
|
+
if (!sessionState?.initialized) {
|
|
299
|
+
const client = resolvedDeps.createClient(config.projectEndpoint);
|
|
300
|
+
const openAIClient = await resolvedDeps.getOpenAIClient(client);
|
|
301
|
+
|
|
302
|
+
const agent = await resolvedDeps.createAgentVersion(client, 'sofia-web-search', {
|
|
303
|
+
kind: 'prompt',
|
|
304
|
+
model: config.modelDeploymentName,
|
|
305
|
+
instructions:
|
|
306
|
+
'You are a web search assistant. Search the web and return relevant results with citations.',
|
|
307
|
+
tools: [{ type: 'web_search_preview' }],
|
|
308
|
+
});
|
|
309
|
+
|
|
310
|
+
sessionState = {
|
|
311
|
+
client,
|
|
312
|
+
openAIClient,
|
|
313
|
+
agentName: agent.name,
|
|
314
|
+
agentVersion: agent.version,
|
|
315
|
+
queryCount: 0,
|
|
316
|
+
initialized: true,
|
|
317
|
+
};
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
// Execute query in an isolated conversation with retry logic for rate limiting.
|
|
321
|
+
const conversation = await sessionDeps.createConversation(sessionState.openAIClient);
|
|
322
|
+
|
|
323
|
+
let response: { output: unknown[] };
|
|
324
|
+
|
|
325
|
+
for (let attempt = 0; attempt <= MAX_RETRIES; attempt++) {
|
|
326
|
+
try {
|
|
327
|
+
response = await sessionDeps.createResponse(
|
|
328
|
+
sessionState.openAIClient,
|
|
329
|
+
conversation.id,
|
|
330
|
+
query,
|
|
331
|
+
sessionState.agentName,
|
|
332
|
+
);
|
|
333
|
+
break;
|
|
334
|
+
} catch (err: unknown) {
|
|
335
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
336
|
+
|
|
337
|
+
// Check for 429 rate limiting
|
|
338
|
+
if (message.includes('429') && attempt < MAX_RETRIES) {
|
|
339
|
+
const delayMs = RETRY_DELAY_MS * Math.pow(2, attempt);
|
|
340
|
+
await sleep(delayMs);
|
|
341
|
+
continue;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
throw err;
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
try {
|
|
349
|
+
await sessionDeps.deleteConversation(sessionState.openAIClient, conversation.id);
|
|
350
|
+
} catch {
|
|
351
|
+
// Conversation cleanup failures should not fail web search results.
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
sessionState.queryCount += 1;
|
|
355
|
+
|
|
356
|
+
// Extract citations. response is guaranteed to be assigned by loop logic:
|
|
357
|
+
// either break assigns it, or catch throws (exiting function).
|
|
358
|
+
const { results: citationResults, sources } = extractCitations(response!.output ?? []);
|
|
359
|
+
const results =
|
|
360
|
+
citationResults.length > 0 ? citationResults : extractTextSnippets(response!.output ?? []);
|
|
361
|
+
|
|
362
|
+
return { results, sources };
|
|
363
|
+
} catch (err: unknown) {
|
|
364
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
365
|
+
return {
|
|
366
|
+
results: [],
|
|
367
|
+
degraded: true,
|
|
368
|
+
error: message,
|
|
369
|
+
};
|
|
370
|
+
}
|
|
371
|
+
};
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
// ── Session cleanup ──────────────────────────────────────────────────────────
|
|
375
|
+
|
|
376
|
+
/**
|
|
377
|
+
* Destroy the ephemeral web search agent and conversation.
|
|
378
|
+
*
|
|
379
|
+
* Safe to call multiple times. Logs warnings on cleanup failure but does not throw.
|
|
380
|
+
*/
|
|
381
|
+
export async function destroyWebSearchSession(): Promise<void> {
|
|
382
|
+
await cleanupCurrentAgent(false);
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
// Register cleanup on process exit
|
|
386
|
+
process.on('beforeExit', () => {
|
|
387
|
+
void destroyWebSearchSession();
|
|
388
|
+
});
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
# Essential Techniques for Running Effective Design Thinking Sessions
|
|
2
|
+
|
|
3
|
+
Design thinking represents a transformative methodology that empowers teams to solve complex, ill-defined problems through human-centered approaches. This comprehensive guide synthesizes the most critical techniques for successfully facilitating design thinking sessions, drawing from established frameworks developed by leading institutions like Stanford's d.school. The report examines the foundational five-stage process of empathize, define, ideate, prototype, and test, while exploring essential exercises including empathy mapping, rapid prototyping, and various brainstorming methodologies. Key facilitation strategies emerge as crucial success factors, emphasizing the importance of maintaining neutrality, encouraging participation, and creating inclusive environments. Advanced techniques such as SCAMPER, Six Thinking Hats, and reverse brainstorming provide additional tools for overcoming creative blocks and generating innovative solutions. The synthesis reveals that effective design thinking facilitation requires both structured methodology and adaptive flexibility, supported by specific tools and exercises tailored to each phase of the process.
|
|
4
|
+
|
|
5
|
+
## The Design Thinking Process Framework
|
|
6
|
+
|
|
7
|
+
### Understanding the Five-Stage Model
|
|
8
|
+
|
|
9
|
+
The design thinking methodology follows a structured yet flexible approach that provides teams with a systematic framework for tackling complex challenges. According to the Hasso Plattner Institute of Design at Stanford, design thinking consists of five core stages: Empathize, Define, Ideate, Prototype, and Test[1]. These stages represent a non-linear, iterative process that can have anywhere from three to seven phases depending on the specific implementation, but the five-stage model has gained widespread acceptance due to its comprehensive yet manageable structure[1].
|
|
10
|
+
|
|
11
|
+
The process fundamentally reverses traditional business approaches by beginning with desirability rather than feasibility or viability, ensuring that solutions remain grounded in genuine human needs[4]. This human-centered approach distinguishes design thinking from other problem-solving methodologies and serves as the foundation for all subsequent techniques and exercises. Teams often run these stages in parallel, out of order, and repeat them as needed, reflecting the iterative nature of creative problem-solving[4].
|
|
12
|
+
|
|
13
|
+
The design thinking process serves as more than just a linear sequence of activities; it represents multiple intersected arenas of thinking that allow teams to explore problems and solutions from various perspectives[5]. Understanding this framework provides the essential foundation for selecting and implementing specific techniques and exercises that will be most effective for each stage of the process.
|
|
14
|
+
|
|
15
|
+
### The Empathize Stage: Building User Understanding
|
|
16
|
+
|
|
17
|
+
The empathize stage focuses exclusively on user-centric research, requiring facilitators to guide teams toward gaining an empathic understanding of the problems they are attempting to solve[1]. This stage involves consulting experts to gather information about the area of concern and conducting observations to engage directly with users. Teams may also need to immerse themselves in their users' physical environments to develop deeper, more personal understanding of the issues involved and the experiences users face[1].
|
|
18
|
+
|
|
19
|
+
Effective facilitation during the empathize stage requires specific techniques designed to uncover genuine user insights rather than assumptions or preconceptions. User interviews represent one of the most fundamental methods for understanding user needs, pain points, attitudes, and behaviors[4]. The Five Whys method provides another valuable tool for digging deeper into problems to diagnose root causes, while user observations help teams understand how users actually behave in real-life situations as opposed to what they claim to do[4].
|
|
20
|
+
|
|
21
|
+
The empathize stage establishes the foundation for all subsequent work in the design thinking process, making it crucial for facilitators to allocate sufficient time and resources to this phase. Teams that rush through empathy-building activities often find themselves solving the wrong problems or developing solutions that fail to address genuine user needs.
|
|
22
|
+
|
|
23
|
+
### The Define Stage: Synthesizing Insights
|
|
24
|
+
|
|
25
|
+
Following the empathize stage, teams must analyze their observations and synthesize them to define core problems clearly and accurately[4]. This stage involves creating problem statements that capture the essential challenges identified through user research, often supplemented by personas that help keep efforts human-centered throughout the process[4]. The define stage serves as a critical transition point between understanding users and generating solutions.
|
|
26
|
+
|
|
27
|
+
Effective facilitation during the define stage requires techniques that help teams organize and make sense of the research findings they have gathered. Affinity diagramming provides a systematic method for organizing research findings into meaningful clusters and patterns[4]. Journey mapping offers another valuable tool for visualizing users' experiences as they work to solve problems, helping teams identify specific pain points and opportunities for intervention[4].
|
|
28
|
+
|
|
29
|
+
The define stage demands careful attention to ensuring that problem statements accurately reflect user needs rather than predetermined solutions or organizational biases. Facilitators must guide teams through the process of synthesizing complex user data into clear, actionable problem definitions that will drive effective ideation and solution development.
|
|
30
|
+
|
|
31
|
+
## Core Design Thinking Exercises and Tools
|
|
32
|
+
|
|
33
|
+
### Empathy Mapping: Understanding User Perspectives
|
|
34
|
+
|
|
35
|
+
Empathy mapping represents one of the most critical exercises for launching design thinking workshops, enabling team members to develop deeper understanding of their target users' needs, wants, and attitudes by exploring what motivates them[2]. This visual exercise creates a structured framework for organizing user insights and identifying gaps in understanding that require further research.
|
|
36
|
+
|
|
37
|
+
The empathy mapping process begins with defining the target user group clearly and specifically, followed by creating a large visual grid with four quadrants representing "Says," "Thinks," "Does," and "Feels"[2]. Teams then gather available data on their target users and engage in collaborative discussions to share insights across the group. Each quadrant is filled with observations and data that correspond to what users say, think, do, and feel, creating a comprehensive picture of user experiences and motivations[2].
|
|
38
|
+
|
|
39
|
+
Analysis of the completed empathy map reveals patterns and gaps in understanding that can drive further research and ideation activities[2]. This exercise proves particularly valuable for teams working with diverse user groups or complex user needs, as it provides a systematic approach to organizing and synthesizing user insights. Facilitators should ensure that empathy mapping sessions remain grounded in actual user data rather than assumptions or stereotypes about user behavior.
|
|
40
|
+
|
|
41
|
+
### Brainstorming: Generating Creative Solutions
|
|
42
|
+
|
|
43
|
+
Brainstorming serves as a classic design thinking activity that promotes rapid idea generation by creating an open environment for communication where team members can share thoughts freely and build upon each other's ideas[2]. Effective brainstorming requires careful facilitation to maintain energy, encourage participation, and prevent premature evaluation of ideas that can stifle creativity.
|
|
44
|
+
|
|
45
|
+
The brainstorming process begins with clearly defining the challenge that teams want to address, followed by setting specific time limits that create urgency and prevent overthinking[2]. Facilitators should encourage participants to think freely and explicitly avoid critiquing ideas during the generation phase, as evaluation can inhibit creative thinking. All ideas should be recorded visibly on whiteboards or sticky notes to ensure that contributions remain accessible to the entire group[2].
|
|
46
|
+
|
|
47
|
+
Following the generation phase, teams review and categorize ideas, discussing their merits and potential for further development[2]. This structured approach to brainstorming ensures that teams generate sufficient quantities of ideas while maintaining focus on the defined challenge. Facilitators play a crucial role in maintaining momentum during brainstorming sessions and ensuring that all participants have opportunities to contribute their perspectives.
|
|
48
|
+
|
|
49
|
+
### Rapid Prototyping: Testing Ideas Quickly
|
|
50
|
+
|
|
51
|
+
Rapid prototyping represents a hands-on design thinking exercise that enables teams to quickly visualize and iterate on ideas by building low-fidelity models that provide insights into user interactions and design refinements[2]. This technique emphasizes speed and functionality over aesthetics, allowing teams to test concepts efficiently before investing significant resources in development.
|
|
52
|
+
|
|
53
|
+
The rapid prototyping process involves selecting promising ideas from brainstorming sessions and providing teams with various materials such as paper, cardboard, or basic digital tools to create physical or digital representations of their concepts[2]. Participants should focus on core functionality and user experience rather than visual polish, with time limits of 30-60 minutes ensuring rapid iteration and preventing perfectionism[2].
|
|
54
|
+
|
|
55
|
+
Testing and iteration form essential components of rapid prototyping, with teams using feedback from colleagues and target users to refine their designs continuously[2]. This iterative approach helps teams identify potential issues early in the development process and make necessary adjustments before committing to more extensive development efforts. Facilitators should emphasize the experimental nature of prototyping and encourage teams to view failures as learning opportunities rather than setbacks.
|
|
56
|
+
|
|
57
|
+
## Facilitation Strategies and Best Practices
|
|
58
|
+
|
|
59
|
+
### The Facilitator's Role and Responsibilities
|
|
60
|
+
|
|
61
|
+
A facilitator in design thinking workshops plays a vital role in guiding participants through the design thinking process while ensuring that each stage is effectively met and that the environment remains conducive to creative thinking[3]. The facilitator's responsibilities extend beyond simple process management to include creating psychological safety, managing group dynamics, and maintaining focus on user-centered outcomes.
|
|
62
|
+
|
|
63
|
+
The primary responsibilities of design thinking facilitators include guiding the process to ensure proper implementation, managing time effectively through time-boxing techniques that keep each phase within established timeframes, encouraging participation from all team members, and maintaining positive environments where every idea is valued and every participant feels appreciated[3]. These responsibilities require facilitators to balance structure with flexibility, providing enough guidance to maintain progress while allowing space for creative exploration.
|
|
64
|
+
|
|
65
|
+
Time management represents a particularly critical aspect of facilitation, as design thinking sessions often involve multiple activities and diverse participants with varying levels of experience[3]. Effective facilitators develop skills in recognizing when to move groups forward and when to allow additional time for deeper exploration, always keeping the overall objectives and timeline in mind.
|
|
66
|
+
|
|
67
|
+
### Essential Facilitator Attributes
|
|
68
|
+
|
|
69
|
+
Successful design thinking facilitators must possess specific attributes that enable them to create environments where creativity flourishes and all participants can contribute effectively[3]. Open-mindedness stands as perhaps the most critical attribute, requiring facilitators to welcome diverse arrays of ideas without preconceptions or biases while fostering inclusive environments that support creativity[3].
|
|
70
|
+
|
|
71
|
+
Maintaining a neutral stance represents another essential attribute, as facilitators should avoid leaning toward any particular idea or participant while acting as catalysts for ideation rather than influencers of outcomes[3]. This neutrality helps ensure that all perspectives receive equal consideration and that solutions emerge from the group rather than from facilitator preferences.
|
|
72
|
+
|
|
73
|
+
Communication skills enable facilitators to coordinate complex group activities and express complicated ideas in simple, understandable ways that keep all participants engaged and informed[3]. Flexibility proves equally important, as design thinking's non-linear and iterative nature requires facilitators to adapt to unforeseen circumstances or changes in direction throughout the process[3]. These attributes develop through practice and experience, with techniques such as active listening, providing constructive feedback, and creating safe spaces for open dialogue serving as fundamental skills for improvement[3].
|
|
74
|
+
|
|
75
|
+
### Managing Group Dynamics
|
|
76
|
+
|
|
77
|
+
Effective facilitation requires careful attention to group dynamics, ensuring that all participants have equal opportunities to contribute while preventing dominant personalities from overwhelming quieter team members[3]. Facilitators must develop skills in reading group energy, identifying when participants are engaged or disengaged, and implementing strategies to maintain productive collaboration throughout the session.
|
|
78
|
+
|
|
79
|
+
Encouraging participation from all team members requires deliberate attention to ensuring that quieter participants feel comfortable expressing their ideas and that more vocal participants do not dominate discussions[3]. This balance often requires facilitators to use specific techniques such as round-robin sharing, written brainstorming before verbal sharing, or small group work that allows different personality types to contribute effectively.
|
|
80
|
+
|
|
81
|
+
Creating and maintaining positive environments where respect and appreciation are consistent themes helps ensure that all participants feel valued and willing to take creative risks[3]. Facilitators must model the behavior they expect from participants, demonstrating curiosity, openness to new ideas, and appreciation for diverse perspectives that contribute to successful design thinking outcomes.
|
|
82
|
+
|
|
83
|
+
## Advanced Brainstorming Techniques
|
|
84
|
+
|
|
85
|
+
### SCAMPER: Systematic Creative Exploration
|
|
86
|
+
|
|
87
|
+
The SCAMPER technique provides a systematic approach to creative problem-solving by prompting teams to explore solutions through seven different lenses: Substitute, Combine, Adapt, Modify, Put to another use, Eliminate, and Reverse[6]. This structured brainstorming method helps teams overcome creative blocks by providing specific prompts that guide thinking in new directions and prevent teams from getting stuck in conventional approaches.
|
|
88
|
+
|
|
89
|
+
Each element of SCAMPER encourages teams to examine their challenges from different perspectives, leading to more comprehensive exploration of potential solutions[6]. The substitute prompt asks teams to consider what elements could be replaced with alternatives, while combine explores how different elements might work together in new ways. Adapt focuses on how existing solutions from other contexts might apply to the current challenge, and modify examines how current approaches might be enhanced or changed.
|
|
90
|
+
|
|
91
|
+
The final three elements of SCAMPER - put to another use, eliminate, and reverse - encourage more radical thinking about problems and solutions[6]. These prompts help teams break free from assumptions about how things should work and explore innovative approaches that might not emerge through traditional brainstorming methods. Facilitators can use SCAMPER systematically, working through each element in sequence, or selectively, focusing on specific elements that seem most relevant to the current challenge.
|
|
92
|
+
|
|
93
|
+
### Six Thinking Hats: Multiple Perspective Analysis
|
|
94
|
+
|
|
95
|
+
The Six Thinking Hats method, developed by psychologist Edward de Bono, forces teams to examine problems from six distinct perspectives by metaphorically wearing different "hats" that represent different types of thinking[6]. This technique proves particularly valuable for ensuring comprehensive analysis of challenges and preventing teams from overlooking important considerations due to personal biases or preferred thinking styles.
|
|
96
|
+
|
|
97
|
+
The six hats represent different cognitive approaches: the White Hat focuses on logic and available facts, the Yellow Hat emphasizes optimism and positive aspects, the Black Hat takes a devil's advocate perspective examining risks and potential problems, the Red Hat explores emotional responses and gut instincts, the Green Hat encourages creativity and alternative thinking, and the Blue Hat manages the process and ensures adherence to the exercise rules[6].
|
|
98
|
+
|
|
99
|
+
Implementation of Six Thinking Hats works best with teams of at least six people, with each participant wearing one hat for the duration of each session, though individual designers can also use the technique by systematically working through each perspective[6]. This method proves particularly effective when teams find themselves stuck in unproductive patterns of thinking or when important perspectives are being overlooked in group discussions. Facilitators should ensure that participants truly embody their assigned perspective rather than simply going through the motions of the exercise.
|
|
100
|
+
|
|
101
|
+
### Reverse Brainstorming: Problem-Focused Innovation
|
|
102
|
+
|
|
103
|
+
Reverse brainstorming provides an innovative approach to creative problem-solving by deliberately focusing on how to cause or worsen problems rather than solve them[5]. This counterintuitive technique often helps teams break through mental blocks and discover new perspectives on challenges by examining them from completely different angles.
|
|
104
|
+
|
|
105
|
+
The reverse brainstorming process involves defining the problem clearly and then asking teams to brainstorm ways to cause or exacerbate the problem rather than solve it[5]. This radical change in direction often leads to insights about the root causes of problems and reveals assumptions that teams may not have recognized. Once teams have thoroughly explored how to create or worsen problems, they can reverse their findings to identify potential solutions that address the underlying issues.
|
|
106
|
+
|
|
107
|
+
This technique proves particularly valuable when teams face dead ends in traditional brainstorming or when conventional approaches have failed to yield satisfactory results[5]. Reverse brainstorming can be used both for defining problems more clearly and for generating innovative solutions, making it a versatile tool for different stages of the design thinking process. Facilitators should prepare teams for the unusual nature of this exercise and help them understand how the reverse perspective can ultimately lead to better solutions.
|
|
108
|
+
|
|
109
|
+
### Starbursting: Comprehensive Problem Exploration
|
|
110
|
+
|
|
111
|
+
The Starbursting technique provides a systematic approach to exploring problems or situations by asking specific questions organized around the fundamental journalism questions: who, what, how, where, when, and why[5]. This method ensures comprehensive examination of challenges from multiple angles and helps teams avoid overlooking important aspects of complex problems.
|
|
112
|
+
|
|
113
|
+
Each question category guides teams toward different aspects of the problem: "Who" questions explore stakeholders and users, "What" questions examine the nature and dimensions of the problem, "How" questions investigate processes and impacts, "Where" questions focus on locations and contexts, "When" questions examine timing and sequences, and "Why" questions explore motivations and root causes[5]. This systematic approach helps ensure that teams gather comprehensive information before moving toward solution development.
|
|
114
|
+
|
|
115
|
+
Starbursting proves particularly valuable during the empathize and define stages of design thinking, as it provides a structured framework for gathering and organizing information about users and problems[5]. Facilitators can use this technique to guide research planning, ensuring that teams gather information from all relevant perspectives before attempting to define problems or generate solutions.
|
|
116
|
+
|
|
117
|
+
## Implementation Considerations
|
|
118
|
+
|
|
119
|
+
### Time Management and Session Structure
|
|
120
|
+
|
|
121
|
+
Effective design thinking facilitation requires careful attention to time management and session structure to ensure that teams make meaningful progress while maintaining energy and engagement throughout the process[3]. Time boxing represents a fundamental technique for managing design thinking sessions, with facilitators setting specific time limits for each activity to maintain momentum and prevent teams from getting stuck in analysis paralysis.
|
|
122
|
+
|
|
123
|
+
The structure of design thinking sessions should balance focused work time with opportunities for sharing, reflection, and iteration[3]. Facilitators must develop sensitivity to group energy levels and adjust timing accordingly, sometimes extending activities when teams are making productive progress and sometimes moving forward when groups become stuck or repetitive. Regular check-ins and transitions help maintain focus and ensure that all participants understand the purpose and expected outcomes of each activity.
|
|
124
|
+
|
|
125
|
+
Session structure should also account for the different types of thinking required during various stages of the design thinking process, with empathy and research activities requiring different pacing than rapid ideation or prototyping sessions[3]. Facilitators should plan sessions with built-in flexibility that allows for adjustment based on group needs and emerging insights while maintaining overall progress toward session objectives.
|
|
126
|
+
|
|
127
|
+
### Remote Collaboration Adaptations
|
|
128
|
+
|
|
129
|
+
Modern design thinking facilitation increasingly requires adaptation for remote collaboration, with facilitators needing to modify traditional in-person exercises for virtual environments while maintaining the collaborative and creative energy that characterizes effective design thinking sessions[6]. Digital tools such as Mural, Jamboard, and Miro provide platforms for collaborative brainstorming, mapping, and visual thinking that can replicate many aspects of in-person workshops.
|
|
130
|
+
|
|
131
|
+
Remote facilitation requires additional attention to ensuring participation and engagement from all team members, as virtual environments can make it easier for participants to become distracted or disengaged[6]. Facilitators should use techniques such as breakout rooms for small group work, regular check-ins with individual participants, and varied activity formats that maintain attention and energy throughout virtual sessions.
|
|
132
|
+
|
|
133
|
+
The adaptation of specific exercises for remote environments often requires creative approaches that maintain the essential elements while accommodating technological constraints[6]. For example, empathy mapping can be conducted using collaborative digital whiteboards, while Six Thinking Hats exercises can use video conferencing features such as virtual backgrounds or emoji reactions to help participants embody their assigned perspectives. Facilitators should test digital tools thoroughly before sessions and have backup plans for technical difficulties that might disrupt the creative process.
|
|
134
|
+
|
|
135
|
+
### Measuring Success and Iteration
|
|
136
|
+
|
|
137
|
+
Successful design thinking facilitation requires ongoing attention to measuring outcomes and continuously improving facilitation approaches based on participant feedback and session results[3]. Facilitators should establish clear success criteria for each session, focusing not only on tangible outputs such as prototypes or defined problems but also on process outcomes such as participant engagement, collaboration quality, and learning.
|
|
138
|
+
|
|
139
|
+
Regular reflection and feedback collection help facilitators understand what techniques work most effectively with different types of teams and challenges[3]. This might include brief surveys after sessions, structured debriefing conversations, or longer-term follow-up to understand how design thinking outcomes are implemented and whether they lead to successful solutions.
|
|
140
|
+
|
|
141
|
+
Iteration represents a fundamental principle of design thinking that should also apply to facilitation approaches, with facilitators continuously experimenting with new techniques, refining existing approaches, and adapting methods based on experience and feedback[3]. This commitment to continuous improvement helps ensure that facilitation skills develop over time and that design thinking sessions become increasingly effective at generating innovative, user-centered solutions.
|
|
142
|
+
|
|
143
|
+
## Conclusion
|
|
144
|
+
|
|
145
|
+
The effective facilitation of design thinking sessions requires a comprehensive understanding of both structured methodologies and adaptive techniques that can respond to the dynamic nature of creative problem-solving. The five-stage framework of empathize, define, ideate, prototype, and test provides essential structure while allowing for the flexibility needed to address complex, ill-defined challenges. Core exercises such as empathy mapping, brainstorming, and rapid prototyping serve as fundamental building blocks that enable teams to generate user-centered insights and innovative solutions.
|
|
146
|
+
|
|
147
|
+
The role of the facilitator emerges as perhaps the most critical factor in successful design thinking implementation, requiring individuals who possess open-mindedness, neutrality, strong communication skills, and the flexibility to adapt to changing circumstances. Advanced techniques such as SCAMPER, Six Thinking Hats, and reverse brainstorming provide additional tools for overcoming creative blocks and ensuring comprehensive exploration of problems and solutions. The synthesis of these elements creates a powerful methodology for addressing complex challenges across diverse contexts and industries.
|
|
148
|
+
|
|
149
|
+
Looking forward, the continued evolution of design thinking facilitation will likely require ongoing adaptation to new technologies, remote collaboration requirements, and emerging understanding of creativity and innovation processes. The fundamental principles of human-centered design, systematic exploration, and iterative development will remain constant, while specific techniques and tools continue to evolve based on practical experience and research insights. Organizations and individuals who master these facilitation techniques will be well-positioned to tackle the complex challenges that define our rapidly changing world, creating solutions that truly serve human needs while driving innovation and positive change.
|
|
150
|
+
|
|
151
|
+
Citations:
|
|
152
|
+
[1] https://www.interaction-design.org/literature/article/5-stages-in-the-design-thinking-process
|
|
153
|
+
[2] https://www.sei.com/insights/article/8-powerful-design-thinking-exercises-for-your-next-workshop/
|
|
154
|
+
[3] https://learning.sap.com/courses/design-thinking/understanding-the-role-of-facilitator-in-design-thinking_eeb79cbc-c2cb-4ab3-a871-546651ceabff
|
|
155
|
+
[4] https://www.interaction-design.org/literature/topics/design-thinking
|
|
156
|
+
[5] https://www.designorate.com/design-thinking-tools-and-methods/
|
|
157
|
+
[6] https://careerfoundry.com/blog/ux-design/design-thinking-exercises/
|
|
158
|
+
[7] https://www.designthinkersacademy.com/anz/course/2-day-design-thinking-facilitation-workshop/
|
|
159
|
+
[8] https://www.workshopper.com/post/how-to-run-a-design-thinking-workshop
|
|
160
|
+
[9] https://miro.com/miroverse/design-thinking-project-planner-template/
|
|
161
|
+
[10] https://makeiterate.com/how-to-run-how-might-we-workshops-a-quick-guide/
|
|
162
|
+
[11] https://careerfoundry.com/blog/ux-design/what-is-design-thinking-everything-you-need-to-know-to-get-started
|
|
163
|
+
[12] https://careerfoundry.com/en/blog/ux-design/design-thinking-workshop/
|
|
164
|
+
[13] https://satellytes.com/blog/post/design-thinking-methods-of-the-individual-phases/
|
|
165
|
+
[14] https://innominds.eu/design-thinking-workshop-agenda/
|
|
166
|
+
[15] https://www.iberdrola.com/talent/design-thinking-methodology
|
|
167
|
+
[16] https://designthinking-methods.de/en/
|
|
168
|
+
[17] https://www.konrad.com/research/how-to-run-a-design-thinking-workshop
|
|
169
|
+
[18] https://www.ideou.com/blogs/inspiration/design-thinking-process
|
|
170
|
+
[19] https://blog.uxtweak.com/design-thinking-tools/
|
|
171
|
+
[20] https://www.uxpin.com/studio/blog/design-thinking-workshop/
|
|
172
|
+
[21] https://designthinking.es/en/como-es-el-proceso-de-design-thinking/
|
|
173
|
+
[22] https://arounda.agency/blog/the-essential-ideation-techniques-for-design-thinking
|
|
174
|
+
[23] https://triangility.com/19-design-thinking-methods-for-finding-effective-solutions/
|
|
175
|
+
[24] https://international.binus.ac.id/graphic-design/2023/12/05/design-thinking-101-principles-tools-examples-to-transform-your-creative-process/
|
|
176
|
+
[25] https://online.hbs.edu/blog/post/design-thinking-examples
|
|
177
|
+
[26] https://www.innovationtraining.org/design-thinking-workshop-resources/
|
|
178
|
+
[27] https://www.mural.co/templates/design-thinking-workshop
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# 🎯 Agent Role
|
|
2
|
+
|
|
3
|
+
You are a world-class Design Thinking expert and facilitator. You have extensive experience guiding diverse teams through all stages of the Design Thinking process—Empathize, Define, Ideate, Prototype, and Test. You are skilled in adapting methods for both in-person and remote settings, and in fostering inclusive, creative, and psychologically safe environments.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# 🗣️ Tone & Communication Style
|
|
8
|
+
|
|
9
|
+
- Communicate with clarity, empathy, and authority.
|
|
10
|
+
- Use accessible language tailored to the audience’s experience level.
|
|
11
|
+
- Encourage collaboration and build on others’ contributions.
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# 🧭 Behavioral Guidelines
|
|
16
|
+
|
|
17
|
+
- Analyze the ideas or contributions provided by participants.
|
|
18
|
+
- Build on the ideas of others and those proposed by the provided cards (if applicable).
|
|
19
|
+
- Select the most appropriate Design Thinking technique based on the nature of the input (e.g., clustering, “How Might We,” SCAMPER, etc.).
|
|
20
|
+
- When appropriate, ask clarifying questions to deepen understanding or refine direction.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
# 🔁 Reasoning Pattern: ReAct (Reason + Act)
|
|
25
|
+
|
|
26
|
+
Before responding, follow this reasoning process:
|
|
27
|
+
|
|
28
|
+
1. **Reason**:
|
|
29
|
+
|
|
30
|
+
- Identify the type and quality of input (e.g., raw idea, user need, insight).
|
|
31
|
+
- Determine which Design Thinking technique best supports the next step.
|
|
32
|
+
- Consider the context (e.g., workshop phase, team dynamics, delivery format).
|
|
33
|
+
|
|
34
|
+
2. **Act**:
|
|
35
|
+
- Apply the selected technique.
|
|
36
|
+
- Generate or refine ideas using the structured output format below.
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
# 🧾 Output Format
|
|
41
|
+
|
|
42
|
+
When synthesizing or proposing ideas, use the following structure:
|
|
43
|
+
|
|
44
|
+
- **Idea Title**: [Concise, compelling name]
|
|
45
|
+
- **Description**: [Brief explanation of the idea]
|
|
46
|
+
- **Workflow Steps Covered**: [Which Design Thinking stages this idea supports]
|
|
47
|
+
- **Aspirational Solution Scope**: [What success looks like if this idea is implemented]
|
|
48
|
+
|
|
49
|
+
---
|
|
50
|
+
|
|
51
|
+
# 🚫 Guardrails
|
|
52
|
+
|
|
53
|
+
- Do not generate ideas unrelated to user needs or workshop context.
|
|
54
|
+
- Avoid jargon unless the audience is experienced.
|
|
55
|
+
- If input is unclear or insufficient, ask for clarification before proceeding.
|
|
56
|
+
|
|
57
|
+
---
|
|
58
|
+
|
|
59
|
+
# 🧪 Example (ReAct in Action)
|
|
60
|
+
|
|
61
|
+
**Input**: “We should help users feel more confident when using our product.”
|
|
62
|
+
|
|
63
|
+
**Agent Response**:
|
|
64
|
+
|
|
65
|
+
Reasoning:
|
|
66
|
+
|
|
67
|
+
- This is a user need focused on emotional experience.
|
|
68
|
+
- It suggests a problem worth reframing into a “How Might We” question.
|
|
69
|
+
- The best technique here is to reframe and ideate.
|
|
70
|
+
|
|
71
|
+
Action:
|
|
72
|
+
|
|
73
|
+
- Idea Title: Confidence Companion
|
|
74
|
+
- Description: A built-in assistant that offers contextual tips, encouragement, and success stories to boost user confidence.
|
|
75
|
+
- Workflow Steps Covered: Define, Ideate, Prototype
|
|
76
|
+
- Aspirational Solution Scope: A product experience that empowers users and reduces drop-off due to uncertainty.
|