takt 0.42.0 → 0.43.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/README.md +1 -0
- package/builtins/en/config.yaml +9 -1
- package/builtins/en/facets/instructions/dual-team-leader-implement.md +7 -2
- package/builtins/en/facets/instructions/fix-maintenance.md +43 -0
- package/builtins/en/facets/instructions/implement-maintenance.md +72 -0
- package/builtins/en/facets/instructions/plan-maintenance.md +51 -0
- package/builtins/en/facets/instructions/review-coding.md +8 -0
- package/builtins/en/facets/instructions/supervise-maintenance.md +110 -0
- package/builtins/en/facets/instructions/team-leader-implement.md +6 -1
- package/builtins/en/facets/instructions/write-tests-maintenance.md +45 -0
- package/builtins/en/facets/knowledge/architecture.md +5 -0
- package/builtins/en/facets/knowledge/existing-system.md +70 -0
- package/builtins/en/facets/knowledge/frontend.md +12 -0
- package/builtins/en/facets/knowledge/react.md +35 -0
- package/builtins/en/facets/output-contracts/coding-review.md +41 -0
- package/builtins/en/facets/output-contracts/maintenance-scope.md +29 -0
- package/builtins/en/facets/personas/coding-reviewer.md +27 -0
- package/builtins/en/facets/personas/dual-supervisor.md +1 -1
- package/builtins/en/facets/policies/ai-antipattern.md +40 -0
- package/builtins/en/facets/policies/existing-system-respect.md +73 -0
- package/builtins/en/facets/policies/review.md +20 -9
- package/builtins/en/workflow-categories.yaml +1 -0
- package/builtins/en/workflows/default-peer-review.yaml +25 -3
- package/builtins/en/workflows/frontend-maintenance.yaml +499 -0
- package/builtins/en/workflows/peer-review.yaml +23 -1
- package/builtins/en/workflows/review-fix-takt-default.yaml +30 -2
- package/builtins/ja/config.yaml +9 -1
- package/builtins/ja/facets/instructions/dual-team-leader-implement.md +7 -2
- package/builtins/ja/facets/instructions/fix-maintenance.md +43 -0
- package/builtins/ja/facets/instructions/implement-maintenance.md +72 -0
- package/builtins/ja/facets/instructions/plan-maintenance.md +51 -0
- package/builtins/ja/facets/instructions/review-coding.md +8 -0
- package/builtins/ja/facets/instructions/supervise-maintenance.md +110 -0
- package/builtins/ja/facets/instructions/team-leader-implement.md +6 -1
- package/builtins/ja/facets/instructions/write-tests-maintenance.md +45 -0
- package/builtins/ja/facets/knowledge/architecture.md +5 -0
- package/builtins/ja/facets/knowledge/existing-system.md +70 -0
- package/builtins/ja/facets/knowledge/frontend.md +12 -0
- package/builtins/ja/facets/knowledge/react.md +35 -0
- package/builtins/ja/facets/output-contracts/coding-review.md +41 -0
- package/builtins/ja/facets/output-contracts/maintenance-scope.md +29 -0
- package/builtins/ja/facets/personas/coding-reviewer.md +27 -0
- package/builtins/ja/facets/personas/dual-supervisor.md +2 -2
- package/builtins/ja/facets/policies/ai-antipattern.md +40 -0
- package/builtins/ja/facets/policies/existing-system-respect.md +73 -0
- package/builtins/ja/facets/policies/review.md +20 -9
- package/builtins/ja/workflow-categories.yaml +1 -0
- package/builtins/ja/workflows/default-peer-review.yaml +25 -3
- package/builtins/ja/workflows/frontend-maintenance.yaml +499 -0
- package/builtins/ja/workflows/peer-review.yaml +23 -1
- package/builtins/ja/workflows/review-fix-takt-default.yaml +30 -2
- package/builtins/skill/references/yaml-schema.md +8 -3
- package/builtins/skill-codex/references/yaml-schema.md +8 -3
- package/dist/agents/team-leader-structured-output.d.ts.map +1 -1
- package/dist/agents/team-leader-structured-output.js +21 -0
- package/dist/agents/team-leader-structured-output.js.map +1 -1
- package/dist/app/cli/commands.js +7 -1
- package/dist/app/cli/commands.js.map +1 -1
- package/dist/app/cli/routing.d.ts.map +1 -1
- package/dist/app/cli/routing.js +8 -1
- package/dist/app/cli/routing.js.map +1 -1
- package/dist/core/models/config-schemas.d.ts +72 -9
- package/dist/core/models/config-schemas.d.ts.map +1 -1
- package/dist/core/models/config-schemas.js +4 -0
- package/dist/core/models/config-schemas.js.map +1 -1
- package/dist/core/models/config-types.d.ts +10 -3
- package/dist/core/models/config-types.d.ts.map +1 -1
- package/dist/core/models/index.d.ts +1 -1
- package/dist/core/models/index.d.ts.map +1 -1
- package/dist/core/models/index.js.map +1 -1
- package/dist/core/models/quality-gate-defaults.d.ts +2 -0
- package/dist/core/models/quality-gate-defaults.d.ts.map +1 -0
- package/dist/core/models/quality-gate-defaults.js +2 -0
- package/dist/core/models/quality-gate-defaults.js.map +1 -0
- package/dist/core/models/schema-base.d.ts +15 -3
- package/dist/core/models/schema-base.d.ts.map +1 -1
- package/dist/core/models/schema-base.js +45 -2
- package/dist/core/models/schema-base.js.map +1 -1
- package/dist/core/models/types.d.ts +1 -1
- package/dist/core/models/types.d.ts.map +1 -1
- package/dist/core/models/workflow-schemas.d.ts +91 -13
- package/dist/core/models/workflow-schemas.d.ts.map +1 -1
- package/dist/core/models/workflow-types.d.ts +11 -3
- package/dist/core/models/workflow-types.d.ts.map +1 -1
- package/dist/core/workflow/engine/ParallelRunner.d.ts +11 -0
- package/dist/core/workflow/engine/ParallelRunner.d.ts.map +1 -1
- package/dist/core/workflow/engine/ParallelRunner.js +139 -19
- package/dist/core/workflow/engine/ParallelRunner.js.map +1 -1
- package/dist/core/workflow/engine/TeamLeaderRunner.d.ts.map +1 -1
- package/dist/core/workflow/engine/TeamLeaderRunner.js +55 -23
- package/dist/core/workflow/engine/TeamLeaderRunner.js.map +1 -1
- package/dist/core/workflow/engine/WorkflowEngine.d.ts.map +1 -1
- package/dist/core/workflow/engine/WorkflowEngine.js +5 -0
- package/dist/core/workflow/engine/WorkflowEngine.js.map +1 -1
- package/dist/core/workflow/engine/WorkflowEngineSetup.d.ts.map +1 -1
- package/dist/core/workflow/engine/WorkflowEngineSetup.js +2 -0
- package/dist/core/workflow/engine/WorkflowEngineSetup.js.map +1 -1
- package/dist/core/workflow/engine/WorkflowRunLoop.d.ts +7 -0
- package/dist/core/workflow/engine/WorkflowRunLoop.d.ts.map +1 -1
- package/dist/core/workflow/engine/WorkflowRunLoop.js +52 -0
- package/dist/core/workflow/engine/WorkflowRunLoop.js.map +1 -1
- package/dist/core/workflow/engine/team-leader-execution.d.ts +1 -0
- package/dist/core/workflow/engine/team-leader-execution.d.ts.map +1 -1
- package/dist/core/workflow/engine/team-leader-execution.js +22 -0
- package/dist/core/workflow/engine/team-leader-execution.js.map +1 -1
- package/dist/core/workflow/engine/team-leader-timeout-fallback.d.ts +13 -0
- package/dist/core/workflow/engine/team-leader-timeout-fallback.d.ts.map +1 -0
- package/dist/core/workflow/engine/team-leader-timeout-fallback.js +125 -0
- package/dist/core/workflow/engine/team-leader-timeout-fallback.js.map +1 -0
- package/dist/core/workflow/instruction/InstructionBuilder.d.ts.map +1 -1
- package/dist/core/workflow/instruction/InstructionBuilder.js +4 -3
- package/dist/core/workflow/instruction/InstructionBuilder.js.map +1 -1
- package/dist/core/workflow/part-definition-validator.d.ts.map +1 -1
- package/dist/core/workflow/part-definition-validator.js +4 -0
- package/dist/core/workflow/part-definition-validator.js.map +1 -1
- package/dist/core/workflow/quality-gates/commandGateMessage.d.ts +4 -0
- package/dist/core/workflow/quality-gates/commandGateMessage.d.ts.map +1 -0
- package/dist/core/workflow/quality-gates/commandGateMessage.js +84 -0
- package/dist/core/workflow/quality-gates/commandGateMessage.js.map +1 -0
- package/dist/core/workflow/quality-gates/commandGateRunner.d.ts +3 -0
- package/dist/core/workflow/quality-gates/commandGateRunner.d.ts.map +1 -0
- package/dist/core/workflow/quality-gates/commandGateRunner.js +242 -0
- package/dist/core/workflow/quality-gates/commandGateRunner.js.map +1 -0
- package/dist/core/workflow/quality-gates/qualityGateRunner.d.ts +3 -0
- package/dist/core/workflow/quality-gates/qualityGateRunner.d.ts.map +1 -0
- package/dist/core/workflow/quality-gates/qualityGateRunner.js +29 -0
- package/dist/core/workflow/quality-gates/qualityGateRunner.js.map +1 -0
- package/dist/core/workflow/quality-gates/types.d.ts +41 -0
- package/dist/core/workflow/quality-gates/types.d.ts.map +1 -0
- package/dist/core/workflow/quality-gates/types.js +2 -0
- package/dist/core/workflow/quality-gates/types.js.map +1 -0
- package/dist/core/workflow/run/run-meta.d.ts +3 -1
- package/dist/core/workflow/run/run-meta.d.ts.map +1 -1
- package/dist/core/workflow/run/run-meta.js +2 -0
- package/dist/core/workflow/run/run-meta.js.map +1 -1
- package/dist/core/workflow/run/run-slug.d.ts +2 -0
- package/dist/core/workflow/run/run-slug.d.ts.map +1 -0
- package/dist/core/workflow/run/run-slug.js +19 -0
- package/dist/core/workflow/run/run-slug.js.map +1 -0
- package/dist/core/workflow/team-leader-continuation-ids.d.ts +3 -0
- package/dist/core/workflow/team-leader-continuation-ids.d.ts.map +1 -0
- package/dist/core/workflow/team-leader-continuation-ids.js +6 -0
- package/dist/core/workflow/team-leader-continuation-ids.js.map +1 -0
- package/dist/core/workflow/types.d.ts +4 -0
- package/dist/core/workflow/types.d.ts.map +1 -1
- package/dist/features/interactive/conversationLoop.d.ts.map +1 -1
- package/dist/features/interactive/conversationLoop.js +11 -9
- package/dist/features/interactive/conversationLoop.js.map +1 -1
- package/dist/features/interactive/imageAttachments.d.ts +20 -0
- package/dist/features/interactive/imageAttachments.d.ts.map +1 -0
- package/dist/features/interactive/imageAttachments.js +75 -0
- package/dist/features/interactive/imageAttachments.js.map +1 -0
- package/dist/features/interactive/index.d.ts +2 -1
- package/dist/features/interactive/index.d.ts.map +1 -1
- package/dist/features/interactive/index.js +1 -1
- package/dist/features/interactive/index.js.map +1 -1
- package/dist/features/interactive/inlineImagePaste.d.ts +21 -0
- package/dist/features/interactive/inlineImagePaste.d.ts.map +1 -0
- package/dist/features/interactive/inlineImagePaste.js +136 -0
- package/dist/features/interactive/inlineImagePaste.js.map +1 -0
- package/dist/features/interactive/instructModeTypes.d.ts +23 -0
- package/dist/features/interactive/instructModeTypes.d.ts.map +1 -0
- package/dist/features/interactive/instructModeTypes.js +2 -0
- package/dist/features/interactive/instructModeTypes.js.map +1 -0
- package/dist/features/interactive/interactive.d.ts +3 -0
- package/dist/features/interactive/interactive.d.ts.map +1 -1
- package/dist/features/interactive/interactive.js.map +1 -1
- package/dist/features/interactive/interactiveInput.d.ts +2 -1
- package/dist/features/interactive/interactiveInput.d.ts.map +1 -1
- package/dist/features/interactive/interactiveInput.js +5 -1
- package/dist/features/interactive/interactiveInput.js.map +1 -1
- package/dist/features/interactive/lineEditor.d.ts +2 -0
- package/dist/features/interactive/lineEditor.d.ts.map +1 -1
- package/dist/features/interactive/lineEditor.js +130 -9
- package/dist/features/interactive/lineEditor.js.map +1 -1
- package/dist/features/interactive/passthroughMode.d.ts.map +1 -1
- package/dist/features/interactive/passthroughMode.js +8 -4
- package/dist/features/interactive/passthroughMode.js.map +1 -1
- package/dist/features/interactive/quietMode.d.ts.map +1 -1
- package/dist/features/interactive/quietMode.js +12 -8
- package/dist/features/interactive/quietMode.js.map +1 -1
- package/dist/features/interactive/retryMode.d.ts +10 -13
- package/dist/features/interactive/retryMode.d.ts.map +1 -1
- package/dist/features/interactive/retryMode.js +42 -22
- package/dist/features/interactive/retryMode.js.map +1 -1
- package/dist/features/tasks/add/index.d.ts +4 -0
- package/dist/features/tasks/add/index.d.ts.map +1 -1
- package/dist/features/tasks/add/index.js +12 -29
- package/dist/features/tasks/add/index.js.map +1 -1
- package/dist/features/tasks/attachments.d.ts +19 -0
- package/dist/features/tasks/attachments.d.ts.map +1 -0
- package/dist/features/tasks/attachments.js +129 -0
- package/dist/features/tasks/attachments.js.map +1 -0
- package/dist/features/tasks/execute/resolveTask.d.ts.map +1 -1
- package/dist/features/tasks/execute/resolveTask.js +4 -3
- package/dist/features/tasks/execute/resolveTask.js.map +1 -1
- package/dist/features/tasks/execute/runMeta.d.ts +5 -1
- package/dist/features/tasks/execute/runMeta.d.ts.map +1 -1
- package/dist/features/tasks/execute/runMeta.js +10 -4
- package/dist/features/tasks/execute/runMeta.js.map +1 -1
- package/dist/features/tasks/execute/selectAndExecute.d.ts.map +1 -1
- package/dist/features/tasks/execute/selectAndExecute.js +48 -4
- package/dist/features/tasks/execute/selectAndExecute.js.map +1 -1
- package/dist/features/tasks/execute/taskSpecContext.d.ts +7 -2
- package/dist/features/tasks/execute/taskSpecContext.d.ts.map +1 -1
- package/dist/features/tasks/execute/taskSpecContext.js +23 -36
- package/dist/features/tasks/execute/taskSpecContext.js.map +1 -1
- package/dist/features/tasks/execute/taskWorkflowExecution.d.ts.map +1 -1
- package/dist/features/tasks/execute/taskWorkflowExecution.js +2 -1
- package/dist/features/tasks/execute/taskWorkflowExecution.js.map +1 -1
- package/dist/features/tasks/execute/traceReportRedaction.d.ts +0 -1
- package/dist/features/tasks/execute/traceReportRedaction.d.ts.map +1 -1
- package/dist/features/tasks/execute/traceReportRedaction.js +1 -9
- package/dist/features/tasks/execute/traceReportRedaction.js.map +1 -1
- package/dist/features/tasks/execute/types.d.ts +8 -0
- package/dist/features/tasks/execute/types.d.ts.map +1 -1
- package/dist/features/tasks/execute/workflowExecutionBootstrap.js +1 -1
- package/dist/features/tasks/execute/workflowExecutionBootstrap.js.map +1 -1
- package/dist/features/tasks/index.d.ts +1 -0
- package/dist/features/tasks/index.d.ts.map +1 -1
- package/dist/features/tasks/index.js +1 -0
- package/dist/features/tasks/index.js.map +1 -1
- package/dist/features/tasks/list/instructMode.d.ts +2 -20
- package/dist/features/tasks/list/instructMode.d.ts.map +1 -1
- package/dist/features/tasks/list/instructMode.js +15 -4
- package/dist/features/tasks/list/instructMode.js.map +1 -1
- package/dist/features/tasks/list/retryTaskSpecAttachments.d.ts +8 -0
- package/dist/features/tasks/list/retryTaskSpecAttachments.d.ts.map +1 -0
- package/dist/features/tasks/list/retryTaskSpecAttachments.js +87 -0
- package/dist/features/tasks/list/retryTaskSpecAttachments.js.map +1 -0
- package/dist/features/tasks/list/taskInstructionActions.d.ts.map +1 -1
- package/dist/features/tasks/list/taskInstructionActions.js +20 -2
- package/dist/features/tasks/list/taskInstructionActions.js.map +1 -1
- package/dist/features/tasks/list/taskRetryActions.d.ts.map +1 -1
- package/dist/features/tasks/list/taskRetryActions.js +24 -6
- package/dist/features/tasks/list/taskRetryActions.js.map +1 -1
- package/dist/features/tasks/resume/directInstructMode.d.ts +13 -0
- package/dist/features/tasks/resume/directInstructMode.d.ts.map +1 -0
- package/dist/features/tasks/resume/directInstructMode.js +67 -0
- package/dist/features/tasks/resume/directInstructMode.js.map +1 -0
- package/dist/features/tasks/resume/directRunFinder.d.ts +7 -0
- package/dist/features/tasks/resume/directRunFinder.d.ts.map +1 -0
- package/dist/features/tasks/resume/directRunFinder.js +43 -0
- package/dist/features/tasks/resume/directRunFinder.js.map +1 -0
- package/dist/features/tasks/resume/index.d.ts +3 -0
- package/dist/features/tasks/resume/index.d.ts.map +1 -0
- package/dist/features/tasks/resume/index.js +229 -0
- package/dist/features/tasks/resume/index.js.map +1 -0
- package/dist/features/tasks/taskSpecFile.d.ts +2 -0
- package/dist/features/tasks/taskSpecFile.d.ts.map +1 -0
- package/dist/features/tasks/taskSpecFile.js +38 -0
- package/dist/features/tasks/taskSpecFile.js.map +1 -0
- package/dist/infra/claude-terminal/tmux-backend.js +1 -1
- package/dist/infra/claude-terminal/tmux-backend.js.map +1 -1
- package/dist/infra/codex/CodexStreamHandler.d.ts +4 -2
- package/dist/infra/codex/CodexStreamHandler.d.ts.map +1 -1
- package/dist/infra/codex/CodexStreamHandler.js +55 -21
- package/dist/infra/codex/CodexStreamHandler.js.map +1 -1
- package/dist/infra/codex/client.d.ts +2 -0
- package/dist/infra/codex/client.d.ts.map +1 -1
- package/dist/infra/codex/client.js +42 -6
- package/dist/infra/codex/client.js.map +1 -1
- package/dist/infra/config/configNormalizers.d.ts +16 -15
- package/dist/infra/config/configNormalizers.d.ts.map +1 -1
- package/dist/infra/config/configNormalizers.js +38 -6
- package/dist/infra/config/configNormalizers.js.map +1 -1
- package/dist/infra/config/env/global-current-env-specs.d.ts.map +1 -1
- package/dist/infra/config/env/global-current-env-specs.js +2 -0
- package/dist/infra/config/env/global-current-env-specs.js.map +1 -1
- package/dist/infra/config/env/project-current-env-specs.d.ts.map +1 -1
- package/dist/infra/config/env/project-current-env-specs.js +2 -0
- package/dist/infra/config/env/project-current-env-specs.js.map +1 -1
- package/dist/infra/config/global/globalConfigCore.d.ts.map +1 -1
- package/dist/infra/config/global/globalConfigCore.js +3 -0
- package/dist/infra/config/global/globalConfigCore.js.map +1 -1
- package/dist/infra/config/global/globalConfigSerializer.d.ts.map +1 -1
- package/dist/infra/config/global/globalConfigSerializer.js +5 -0
- package/dist/infra/config/global/globalConfigSerializer.js.map +1 -1
- package/dist/infra/config/loaders/qualityGateOverrides.d.ts +3 -2
- package/dist/infra/config/loaders/qualityGateOverrides.d.ts.map +1 -1
- package/dist/infra/config/loaders/qualityGateOverrides.js +42 -3
- package/dist/infra/config/loaders/qualityGateOverrides.js.map +1 -1
- package/dist/infra/config/loaders/workflowFileLoader.d.ts.map +1 -1
- package/dist/infra/config/loaders/workflowFileLoader.js +2 -2
- package/dist/infra/config/loaders/workflowFileLoader.js.map +1 -1
- package/dist/infra/config/loaders/workflowNormalizationPolicies.d.ts +3 -1
- package/dist/infra/config/loaders/workflowNormalizationPolicies.d.ts.map +1 -1
- package/dist/infra/config/loaders/workflowNormalizationPolicies.js +28 -0
- package/dist/infra/config/loaders/workflowNormalizationPolicies.js.map +1 -1
- package/dist/infra/config/loaders/workflowParser.d.ts +2 -2
- package/dist/infra/config/loaders/workflowParser.d.ts.map +1 -1
- package/dist/infra/config/loaders/workflowParser.js +3 -2
- package/dist/infra/config/loaders/workflowParser.js.map +1 -1
- package/dist/infra/config/loaders/workflowStepNormalizer.d.ts.map +1 -1
- package/dist/infra/config/loaders/workflowStepNormalizer.js +2 -1
- package/dist/infra/config/loaders/workflowStepNormalizer.js.map +1 -1
- package/dist/infra/config/project/projectConfig.d.ts.map +1 -1
- package/dist/infra/config/project/projectConfig.js +4 -3
- package/dist/infra/config/project/projectConfig.js.map +1 -1
- package/dist/infra/config/project/projectConfigTransforms.d.ts +5 -1
- package/dist/infra/config/project/projectConfigTransforms.d.ts.map +1 -1
- package/dist/infra/config/project/projectConfigTransforms.js +8 -0
- package/dist/infra/config/project/projectConfigTransforms.js.map +1 -1
- package/dist/infra/config/traced/tracedConfigSchema.d.ts.map +1 -1
- package/dist/infra/config/traced/tracedConfigSchema.js +4 -0
- package/dist/infra/config/traced/tracedConfigSchema.js.map +1 -1
- package/dist/infra/task/clone.d.ts +1 -0
- package/dist/infra/task/clone.d.ts.map +1 -1
- package/dist/infra/task/clone.js +19 -2
- package/dist/infra/task/clone.js.map +1 -1
- package/dist/infra/task/projectLocalTaktSync.d.ts.map +1 -1
- package/dist/infra/task/projectLocalTaktSync.js +6 -2
- package/dist/infra/task/projectLocalTaktSync.js.map +1 -1
- package/dist/infra/task/runner.d.ts +2 -2
- package/dist/infra/task/runner.d.ts.map +1 -1
- package/dist/infra/task/runner.js +4 -4
- package/dist/infra/task/runner.js.map +1 -1
- package/dist/infra/task/taskRecordMutations.d.ts +1 -1
- package/dist/infra/task/taskRecordMutations.d.ts.map +1 -1
- package/dist/infra/task/taskRecordMutations.js +5 -1
- package/dist/infra/task/taskRecordMutations.js.map +1 -1
- package/dist/infra/task/taskRetryService.d.ts +2 -2
- package/dist/infra/task/taskRetryService.d.ts.map +1 -1
- package/dist/infra/task/taskRetryService.js +4 -4
- package/dist/infra/task/taskRetryService.js.map +1 -1
- package/dist/shared/prompts/en/score_direct_instruct_system_prompt.md +63 -0
- package/dist/shared/prompts/en/score_retry_system_prompt.md +2 -2
- package/dist/shared/prompts/ja/score_direct_instruct_system_prompt.md +63 -0
- package/dist/shared/prompts/ja/score_retry_system_prompt.md +2 -2
- package/dist/shared/utils/sensitiveText.d.ts +2 -0
- package/dist/shared/utils/sensitiveText.d.ts.map +1 -0
- package/dist/shared/utils/sensitiveText.js +40 -0
- package/dist/shared/utils/sensitiveText.js.map +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -279,6 +279,7 @@ See [External Integrations](./docs/external-integrations.md) for other community
|
|
|
279
279
|
|
|
280
280
|
| Document | Description |
|
|
281
281
|
|----------|-------------|
|
|
282
|
+
| [Tutorial](./docs/tutorial.md) | Improve one example over three phases while queuing, running, and inspecting tasks |
|
|
282
283
|
| [CLI Reference](./docs/cli-reference.md) | All commands and options |
|
|
283
284
|
| [Configuration](./docs/configuration.md) | Global and project settings |
|
|
284
285
|
| [Design Philosophy](./docs/design-philosophy.md) | Why TAKT is built around workflows, facets, feedback loops, and traceability |
|
package/builtins/en/config.yaml
CHANGED
|
@@ -91,10 +91,18 @@ language: en # UI language: en | ja
|
|
|
91
91
|
# runtime:
|
|
92
92
|
# prepare: [node, gradle, ./custom-script.sh]
|
|
93
93
|
|
|
94
|
+
# Workflow YAML command gate policy
|
|
95
|
+
# workflow_command_gates:
|
|
96
|
+
# custom_scripts: false
|
|
97
|
+
|
|
94
98
|
# Workflow-level overrides
|
|
95
99
|
# workflow_overrides:
|
|
96
100
|
# quality_gates:
|
|
97
|
-
# - "All tests pass"
|
|
101
|
+
# - "All tests pass" # AI completion directive
|
|
102
|
+
# - type: command # Machine-executed gate after step completion
|
|
103
|
+
# name: quality-check
|
|
104
|
+
# command: "./.takt/quality-gates/check.sh"
|
|
105
|
+
# timeout_ms: 300000
|
|
98
106
|
# quality_gates_edit_only: true
|
|
99
107
|
# steps:
|
|
100
108
|
# review:
|
|
@@ -6,10 +6,13 @@ Analyze the implementation task and, if decomposition is appropriate, split into
|
|
|
6
6
|
|
|
7
7
|
1. Assess whether decomposition is appropriate
|
|
8
8
|
- Identify files to change and check inter-file dependencies
|
|
9
|
-
-
|
|
9
|
+
- First look for parallelizable responsibility boundaries
|
|
10
|
+
- If cross-cutting concerns exist (shared types, IDs, events), consider staged work: foundation part -> consuming parts -> verification part
|
|
10
11
|
- If few files are involved, or the task is a rename/refactoring, implement in a single part
|
|
12
|
+
- When parts.length === 1, first consider whether verification separation or staged work is possible
|
|
13
|
+
- Avoid oversized single parts such as "implementation and verification"
|
|
11
14
|
|
|
12
|
-
2. If decomposing: prioritize splitting along frontend and backend boundaries
|
|
15
|
+
2. If decomposing: prioritize splitting along frontend and backend boundaries, or group files by layer/module when that split does not fit
|
|
13
16
|
- **If design references exist and backend changes are not explicitly required, do not decompose.** Visual structure, copy, spacing, and styling are tightly coupled, and splitting them increases design drift risk
|
|
14
17
|
- **If design references exist, keep all UI components of the same screen in the same part.** Do not split headers, filters, cards, banners, and modals of one screen across different parts
|
|
15
18
|
- Splitting between frontend (UI, components, styles) and backend (API, logic, data layer) is the most natural decomposition axis
|
|
@@ -19,6 +22,7 @@ Analyze the implementation task and, if decomposition is appropriate, split into
|
|
|
19
22
|
- If there are type or interface dependencies, keep both sides in the same group
|
|
20
23
|
- Never assign the same file to multiple parts
|
|
21
24
|
- Keep test files and implementation files in the same part
|
|
25
|
+
- Separate implementation parts from verification parts
|
|
22
26
|
|
|
23
27
|
3. Assign file ownership exclusively to each part
|
|
24
28
|
- Each part's instruction must clearly state:
|
|
@@ -32,6 +36,7 @@ Analyze the implementation task and, if decomposition is appropriate, split into
|
|
|
32
36
|
- If tests are already written, instruct parts to implement so existing tests pass
|
|
33
37
|
- Refer to Quality Gates and plan any required verification as a dedicated single verification part
|
|
34
38
|
- Do not make parallel implementation parts run duplicate full-build or full-test checks
|
|
39
|
+
- Do not duplicate npm test / npm run test:e2e:mock in each implementation part
|
|
35
40
|
|
|
36
41
|
**Constraints:**
|
|
37
42
|
- If tests or build verification are needed, run them as a dedicated single verification part after dependent implementation parts are complete
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
Use reports in the Report Directory and fix reviewer findings with the minimum diff that preserves existing contracts.
|
|
2
|
+
|
|
3
|
+
**Fix principles:**
|
|
4
|
+
- When a finding includes a "suggested fix", follow it rather than inventing your own workaround
|
|
5
|
+
- Fix the target code directly. Do not deflect findings by adding tests or documentation instead
|
|
6
|
+
- Classify findings as must-fix, verification-only, or out-of-scope
|
|
7
|
+
- Modify only must-fix findings
|
|
8
|
+
- Do not mix unrelated refactoring, renames, comment deletion, or test expectation changes
|
|
9
|
+
|
|
10
|
+
**Report reference policy:**
|
|
11
|
+
- Use the latest review reports in the Report Directory as primary evidence.
|
|
12
|
+
- Past iteration reports are saved as `{filename}.{timestamp}` in the same directory (e.g., `architect-review.md.20260304T123456Z`). For each report, run Glob with a `{report-name}.*` pattern, read up to 2 files in descending timestamp order, and understand persists / reopened trends before starting fixes.
|
|
13
|
+
|
|
14
|
+
**Completion criteria (all must be satisfied):**
|
|
15
|
+
- Must-fix findings in this iteration (new / reopened) have been fixed
|
|
16
|
+
- Potential occurrences of the same `family_tag` have been fixed simultaneously (no partial fixes that cause recurrence)
|
|
17
|
+
- At least one regression test per `family_tag` has been added (mandatory for config-contract and boundary-check findings)
|
|
18
|
+
- Findings with the same `family_tag` from multiple reviewers have been merged and addressed as one fix
|
|
19
|
+
- After fixing, the full diff has been inspected and changes unrelated to the findings or request have been reverted
|
|
20
|
+
|
|
21
|
+
**Important**: After fixing, run the build (type check) and tests.
|
|
22
|
+
|
|
23
|
+
**Required output (include headings)**
|
|
24
|
+
## Work Results
|
|
25
|
+
- {Summary of actions taken}
|
|
26
|
+
## Finding Responses
|
|
27
|
+
- {Classification and response for must-fix, verification-only, and out-of-scope findings}
|
|
28
|
+
## Changes Made
|
|
29
|
+
- {Summary of required and related changes}
|
|
30
|
+
## Reverted Unnecessary Changes
|
|
31
|
+
- {Changes reverted, or "none"}
|
|
32
|
+
## Build Results
|
|
33
|
+
- {Build execution results}
|
|
34
|
+
## Test Results
|
|
35
|
+
- {Test command executed and results}
|
|
36
|
+
## Convergence gate
|
|
37
|
+
| Metric | Count |
|
|
38
|
+
|--------|-------|
|
|
39
|
+
| new (fixed in this iteration) | {N} |
|
|
40
|
+
| reopened (recurrence fixed) | {N} |
|
|
41
|
+
| persists (carried over, not addressed this iteration) | {N} |
|
|
42
|
+
## Evidence
|
|
43
|
+
- {List key points from files checked/searches/diffs/logs}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
Implement according to the plan with the minimum diff while preserving existing contracts.
|
|
2
|
+
Refer only to files within the Report Directory shown in the Workflow Context. Do not search or reference other report directories.
|
|
3
|
+
Use reports in the Report Directory as the primary source of truth. If additional context is needed, you may consult Previous Response and conversation history as secondary sources (Previous Response may be unavailable). If information conflicts, prioritize reports in the Report Directory and actual file contents.
|
|
4
|
+
|
|
5
|
+
**Important**: Add unit tests alongside the implementation.
|
|
6
|
+
- Add unit tests for newly created classes and functions
|
|
7
|
+
- Update relevant tests when modifying existing code, but do not weaken existing expectations for implementation convenience
|
|
8
|
+
- Test file placement: follow the project's conventions
|
|
9
|
+
- Build verification is mandatory. After completing implementation, run the build (type check) and verify there are no type errors
|
|
10
|
+
- Running tests is mandatory. After build succeeds, always run tests and verify results
|
|
11
|
+
- When introducing new contract strings (file names, config key names, etc.), define them as constants in one place
|
|
12
|
+
|
|
13
|
+
**Additional maintenance constraints:**
|
|
14
|
+
- Before implementation, classify planned changes as required, related, or unnecessary
|
|
15
|
+
- Implement only required and related changes
|
|
16
|
+
- Do not use a touched file as a reason to make style improvements, renames, file moves, hook return shape changes, comment deletions, or test expectation changes
|
|
17
|
+
- If the existing structure can satisfy the request, do not restructure only to match common style
|
|
18
|
+
- After implementation, inspect the full diff and revert unnecessary changes
|
|
19
|
+
|
|
20
|
+
**Maintenance Scope output contract (create at the start of implementation):**
|
|
21
|
+
```markdown
|
|
22
|
+
# Maintenance Change Scope
|
|
23
|
+
|
|
24
|
+
## Task
|
|
25
|
+
{One-line task summary}
|
|
26
|
+
|
|
27
|
+
## Required Changes
|
|
28
|
+
| File | Reason | Requirement Mapping |
|
|
29
|
+
|------|--------|---------------------|
|
|
30
|
+
| {File} | {Reason} | {Mapped requirement} |
|
|
31
|
+
|
|
32
|
+
## Related Changes
|
|
33
|
+
| File | Reason | Relation to Required Change |
|
|
34
|
+
|------|--------|-----------------------------|
|
|
35
|
+
| {File} | {Reason} | {Relation} |
|
|
36
|
+
|
|
37
|
+
## Existing Contracts Preserved
|
|
38
|
+
| Contract | Target | Preservation |
|
|
39
|
+
|----------|--------|--------------|
|
|
40
|
+
| {Contract type} | {Target} | {What is preserved} |
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
**Decisions output contract (at implementation completion, only if decisions were made):**
|
|
44
|
+
```markdown
|
|
45
|
+
# Decision Log
|
|
46
|
+
|
|
47
|
+
## 1. {Decision}
|
|
48
|
+
- **Context**: {Why the decision was needed}
|
|
49
|
+
- **Options considered**: {List of options}
|
|
50
|
+
- **Rationale**: {Reason for the choice}
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
**Pre-completion self-check (required):**
|
|
54
|
+
|
|
55
|
+
Before running build and tests, audit your work against Policy with the following procedure.
|
|
56
|
+
|
|
57
|
+
1. Open the Policy Source path with the Read tool and obtain the full content
|
|
58
|
+
2. List every `##` section (do not cherry-pick)
|
|
59
|
+
3. Match the REJECT criteria in each listed section against your implementation
|
|
60
|
+
4. Inspect the full diff and check that no out-of-scope rename, move, comment deletion, UI copy change, accessible-name change, or test expectation change remains
|
|
61
|
+
|
|
62
|
+
**Required output (include headings)**
|
|
63
|
+
## Work Results
|
|
64
|
+
- {Summary of actions taken}
|
|
65
|
+
## Changes Made
|
|
66
|
+
- {Summary of required and related changes}
|
|
67
|
+
## Reverted Unnecessary Changes
|
|
68
|
+
- {Changes reverted, or "none"}
|
|
69
|
+
## Build Results
|
|
70
|
+
- {Build execution results}
|
|
71
|
+
## Test Results
|
|
72
|
+
- {Test command executed and results}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
Analyze the task as maintenance work for an existing frontend feature and produce a minimum-diff implementation plan that includes necessary design decisions.
|
|
2
|
+
|
|
3
|
+
**Note:** If Previous Response exists, treat it as a rework request and compare it with the current files before revising the plan.
|
|
4
|
+
|
|
5
|
+
**Small-task criteria:**
|
|
6
|
+
- Only 1-2 files change
|
|
7
|
+
- No design decision is needed
|
|
8
|
+
- No technology choice is needed
|
|
9
|
+
|
|
10
|
+
For small tasks, omit the design section. In maintenance work, do not omit existing-contract and unnecessary-change checks even for small tasks.
|
|
11
|
+
|
|
12
|
+
**Do:**
|
|
13
|
+
1. **Read reference materials first (required)**
|
|
14
|
+
- Actually open files or directories listed in the task's reference-materials section with Read/Glob
|
|
15
|
+
- If a directory is listed, enumerate it and identify the relevant files before reading
|
|
16
|
+
- If reference materials do not exist or cannot be found, report that and do not substitute guesses
|
|
17
|
+
- **Do not use files not listed in the task as substitutes for reference materials**
|
|
18
|
+
2. Understand the task requirements
|
|
19
|
+
- Compare reference materials with the current implementation to identify the delta
|
|
20
|
+
- **For each requirement, decide whether a change is needed. If no change is needed, cite the current code location (file:line). Do not say "already correct" without evidence**
|
|
21
|
+
- **Limit requirements to explicit requirements and directly implied requirements. Do not turn general best practices or future extensibility into requirements**
|
|
22
|
+
- **Break requirements down only to make them verifiable. Do not let decomposition create new requirements**
|
|
23
|
+
- **When using an implied requirement, identify the explicit requirement that supports it in the plan report**
|
|
24
|
+
3. Inspect code to resolve unknowns
|
|
25
|
+
4. Identify existing contracts that must be preserved
|
|
26
|
+
- Check existing structure, type names, hook return values, UI copy, accessible names, comments, and test expectations
|
|
27
|
+
- If an existing contract must change, document the reason and impact scope in the plan
|
|
28
|
+
5. Classify candidate changes as required, related, or unnecessary
|
|
29
|
+
- Same file, nearby responsibility, or common style is not enough to make a change related
|
|
30
|
+
- Do not assign unnecessary changes to the Coder
|
|
31
|
+
6. Decide file structure and design patterns when needed
|
|
32
|
+
- If the existing structure can satisfy the request, keep it even if it is not ideal
|
|
33
|
+
7. Decide the implementation approach
|
|
34
|
+
- Check that the approach does not violate Knowledge or Policy constraints
|
|
35
|
+
- For user-facing additions or changes, fix the reachability condition, entry point, and activation path
|
|
36
|
+
8. Include the following in the Coder guidance:
|
|
37
|
+
- Existing implementation patterns to follow (file:line). Always cite same-kind existing code when available
|
|
38
|
+
- Impact scope. Especially when adding a new parameter, list every call path that must be wired
|
|
39
|
+
- Relevant anti-patterns for this task, if any
|
|
40
|
+
- Existing contracts that must not change
|
|
41
|
+
- Candidate changes explicitly excluded as unnecessary
|
|
42
|
+
|
|
43
|
+
**Required output (include headings)**
|
|
44
|
+
## Work Results
|
|
45
|
+
- {Plan summary}
|
|
46
|
+
## Change Classification
|
|
47
|
+
- {Required, related, and unnecessary changes}
|
|
48
|
+
## Existing Contracts
|
|
49
|
+
- {Existing contracts to preserve}
|
|
50
|
+
## Implementation Plan
|
|
51
|
+
- {Minimum-diff plan}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
Review the code diff.
|
|
2
|
+
|
|
3
|
+
Procedure:
|
|
4
|
+
1. Review the task intent, plan, diff, and execution evidence
|
|
5
|
+
2. Look for implementation bugs, regressions in existing behavior, security risks, and missing tests
|
|
6
|
+
3. Include only issues caused by the current diff that the user should fix
|
|
7
|
+
4. For each finding, include location, impact, and fix direction
|
|
8
|
+
5. Do not report unsupported speculation, preference-only changes, or unrelated pre-existing issues
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
Review evidence from executed tests, builds, and manual verification, then make the final approval decision including whether any unnecessary maintenance diff remains.
|
|
2
|
+
|
|
3
|
+
Procedure:
|
|
4
|
+
1. Open the Knowledge and Policy Source paths with the Read tool and obtain the full content
|
|
5
|
+
2. List every `##` section from each source (do not cherry-pick)
|
|
6
|
+
3. Match the criteria from the listed sections against the diff, execution evidence, and reports
|
|
7
|
+
|
|
8
|
+
## Step-specific additional procedure
|
|
9
|
+
|
|
10
|
+
1. Extract each requirement from the task instructions one by one
|
|
11
|
+
- If one sentence contains multiple conditions or paths, split it into the smallest verifiable units
|
|
12
|
+
- Split parallel expressions by default
|
|
13
|
+
2. For each requirement, identify the implemented code (file:line)
|
|
14
|
+
3. Actually verify that the code satisfies the requirement by reading files and checking build/test evidence
|
|
15
|
+
- Do not mark a compound requirement ✅ after checking only one side
|
|
16
|
+
- Do not trust plan or requirements-review judgments without independent verification per requirement
|
|
17
|
+
- REJECT if any single requirement is unsatisfied
|
|
18
|
+
4. Validate the maintenance scope
|
|
19
|
+
- Check whether required, related, and unnecessary change classifications are valid
|
|
20
|
+
- Check that comments, type names, file placement, UI copy, accessible names, and test expectations did not change out of scope
|
|
21
|
+
- REJECT if any diff remains that is justified only by general quality improvement or style cleanup
|
|
22
|
+
5. Re-evaluate prior review findings
|
|
23
|
+
- If a finding does not hold in the code, record it as false_positive
|
|
24
|
+
- If a valid finding is outside the task purpose or over-generalized, record it as overreach
|
|
25
|
+
- Do not silently pass through false_positive or overreach findings
|
|
26
|
+
|
|
27
|
+
## Report priority (supervise-specific)
|
|
28
|
+
|
|
29
|
+
- Summary reports are not primary evidence. Primary evidence is execution-result reports, review reports with concrete checks, and actual code
|
|
30
|
+
- `Build Results` / `Test Results` inside execution-result reports may be treated as primary evidence
|
|
31
|
+
- In `architecture-review` / `qa-review` / `testing-review` / `security-review` / `requirements-review`, prioritize each report's verification-evidence section
|
|
32
|
+
- Treat a verification-evidence item as supporting evidence only when target, check content, and result are all present. Otherwise treat it as unverified
|
|
33
|
+
- When evidence conflicts, prefer `execution-result report > review report with concrete checks > summary report`
|
|
34
|
+
|
|
35
|
+
**Validation output contract:**
|
|
36
|
+
```markdown
|
|
37
|
+
# Final Validation Result
|
|
38
|
+
|
|
39
|
+
## Result: APPROVE / REJECT
|
|
40
|
+
|
|
41
|
+
## Requirement Satisfaction Check
|
|
42
|
+
|
|
43
|
+
Extract requirements from the task instructions and verify each requirement against actual code.
|
|
44
|
+
|
|
45
|
+
| # | Requirement (from task instructions) | Satisfied | Evidence (file:line) |
|
|
46
|
+
|---|--------------------------------------|-----------|----------------------|
|
|
47
|
+
| 1 | {Requirement 1} | ✅/❌ | `src/file.ts:42` |
|
|
48
|
+
| 2 | {Requirement 2} | ✅/❌ | `src/file.ts:55` |
|
|
49
|
+
|
|
50
|
+
- Any ❌ requires REJECT
|
|
51
|
+
- ✅ without evidence is invalid
|
|
52
|
+
- Do not mark ✅ when only part of a compound case was checked
|
|
53
|
+
- Do not trust the plan report without independent verification per requirement
|
|
54
|
+
|
|
55
|
+
## Maintenance Scope Check
|
|
56
|
+
|
|
57
|
+
| Check | Result | Evidence |
|
|
58
|
+
|-------|--------|----------|
|
|
59
|
+
| Only required changes remain | ✅/❌ | {Evidence} |
|
|
60
|
+
| Related changes have clear reasons | ✅/❌ | {Evidence} |
|
|
61
|
+
| No unnecessary changes remain | ✅/❌ | {Evidence} |
|
|
62
|
+
| No out-of-scope comment deletion occurred | ✅/❌ | {Evidence} |
|
|
63
|
+
| Type names, file placement, and public APIs did not change out of scope | ✅/❌ | {Evidence} |
|
|
64
|
+
| UI copy, accessible names, and test expectations did not change out of scope | ✅/❌ | {Evidence} |
|
|
65
|
+
|
|
66
|
+
## Prior Finding Re-evaluation
|
|
67
|
+
|
|
68
|
+
| finding_id | Prior status | Re-evaluation | Evidence |
|
|
69
|
+
|------------|--------------|---------------|----------|
|
|
70
|
+
| {id} | new / persists / resolved | valid / false_positive / overreach | `src/file.ts:42`, `reports/plan.md` |
|
|
71
|
+
|
|
72
|
+
- If final judgment differs from prior review conclusions, write the reason with evidence
|
|
73
|
+
- When marking false_positive / overreach, state whether it is inappropriate relative to the task or the plan
|
|
74
|
+
- If overturning requirements-review, provide evidence-backed reasoning
|
|
75
|
+
|
|
76
|
+
## Verification Summary
|
|
77
|
+
| Item | Status | Verification Method |
|
|
78
|
+
|------|--------|---------------------|
|
|
79
|
+
| Tests | ✅ / ⚠️ / ❌ | {Execution log, report, CI evidence} |
|
|
80
|
+
| Build | ✅ / ⚠️ / ❌ | {Execution log, report, CI evidence} |
|
|
81
|
+
| Manual verification | ✅ / ⚠️ / ❌ | {Evidence checked, or state not verified} |
|
|
82
|
+
|
|
83
|
+
## Artifacts
|
|
84
|
+
- Created: {Created files}
|
|
85
|
+
- Modified: {Modified files}
|
|
86
|
+
|
|
87
|
+
## Incomplete Items (for REJECT)
|
|
88
|
+
| # | Item | Reason |
|
|
89
|
+
|---|------|--------|
|
|
90
|
+
| 1 | {Item} | {Reason} |
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
**Summary output contract (APPROVE only):**
|
|
94
|
+
```markdown
|
|
95
|
+
# Task Completion Summary
|
|
96
|
+
|
|
97
|
+
## Task
|
|
98
|
+
{Original request in 1-2 sentences}
|
|
99
|
+
|
|
100
|
+
## Result
|
|
101
|
+
Complete
|
|
102
|
+
|
|
103
|
+
## Changes
|
|
104
|
+
| Type | File | Summary |
|
|
105
|
+
|------|------|---------|
|
|
106
|
+
| Created | `src/file.ts` | Summary |
|
|
107
|
+
|
|
108
|
+
## Verification Evidence
|
|
109
|
+
- {Test/build/manual verification evidence}
|
|
110
|
+
```
|
|
@@ -6,14 +6,18 @@ Analyze the implementation task and, if decomposition is appropriate, split into
|
|
|
6
6
|
|
|
7
7
|
1. Assess whether decomposition is appropriate
|
|
8
8
|
- Identify files to change and check inter-file dependencies
|
|
9
|
-
-
|
|
9
|
+
- First look for parallelizable responsibility boundaries
|
|
10
|
+
- If cross-cutting concerns exist (shared types, IDs, events), consider staged work: foundation part -> consuming parts -> verification part
|
|
10
11
|
- If few files are involved, or the task is a rename/refactoring, implement in a single part
|
|
12
|
+
- When parts.length === 1, first consider whether verification separation or staged work is possible
|
|
13
|
+
- Avoid oversized single parts such as "implementation and verification"
|
|
11
14
|
|
|
12
15
|
2. If decomposing: group files by layer/module
|
|
13
16
|
- Create groups based on high cohesion (e.g., Domain layer / Infrastructure layer / API layer)
|
|
14
17
|
- If there are type or interface dependencies, keep both sides in the same group
|
|
15
18
|
- Never assign the same file to multiple parts
|
|
16
19
|
- Keep test files and implementation files in the same part
|
|
20
|
+
- Separate implementation parts from verification parts
|
|
17
21
|
|
|
18
22
|
3. Assign file ownership exclusively to each part
|
|
19
23
|
- Each part's instruction must clearly state:
|
|
@@ -24,6 +28,7 @@ Analyze the implementation task and, if decomposition is appropriate, split into
|
|
|
24
28
|
- If tests are already written, instruct parts to implement so existing tests pass
|
|
25
29
|
- Refer to Quality Gates and plan any required verification as a dedicated single verification part
|
|
26
30
|
- Do not make parallel implementation parts run duplicate full-build or full-test checks
|
|
31
|
+
- Do not duplicate npm test / npm run test:e2e:mock in each implementation part
|
|
27
32
|
|
|
28
33
|
**Constraints:**
|
|
29
34
|
- If tests or build verification are needed, run them as a dedicated single verification part after dependent implementation parts are complete
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
Write tests based on the plan before implementing production code, while protecting existing behavior.
|
|
2
|
+
Refer only to files within the Report Directory shown in the Workflow Context. Do not search or reference other report directories.
|
|
3
|
+
|
|
4
|
+
**Important: Do NOT create or modify production code. Only test files may be created.**
|
|
5
|
+
|
|
6
|
+
**Actions:**
|
|
7
|
+
1. Review the plan report and separate behavior changed by the request from existing behavior that must not change
|
|
8
|
+
2. Examine existing code and tests to learn the project's test patterns
|
|
9
|
+
3. Add regression tests when existing contracts are not protected
|
|
10
|
+
4. Write unit tests for the planned feature or fix
|
|
11
|
+
5. Determine whether integration tests are needed and create them if so
|
|
12
|
+
- Does the data flow cross 3+ modules?
|
|
13
|
+
- Does a new status/state merge into an existing workflow?
|
|
14
|
+
- Does a new option propagate through a call chain to the endpoint?
|
|
15
|
+
- If any apply, create integration tests
|
|
16
|
+
|
|
17
|
+
**Test writing guidelines:**
|
|
18
|
+
- Follow the project's existing test patterns (naming conventions, directory structure, helpers)
|
|
19
|
+
- Write tests in Given-When-Then structure
|
|
20
|
+
- One concept per test. Do not mix multiple concerns in a single test
|
|
21
|
+
- Cover happy path, error cases, boundary values, and edge cases
|
|
22
|
+
- Do not weaken existing expectations for implementation convenience
|
|
23
|
+
- When an external contract exists, include tests that use the contract-defined input location
|
|
24
|
+
- Example: pass request bodies using the defined root shape as-is
|
|
25
|
+
- Example: keep query / path parameters in their defined location instead of moving them into the body
|
|
26
|
+
- Include tests that would catch implementations that incorrectly reuse a response envelope when reading requests
|
|
27
|
+
- Write tests that are expected to pass after implementation is complete (build errors and test failures are expected at this stage)
|
|
28
|
+
|
|
29
|
+
**Non-executable asset constraints:**
|
|
30
|
+
- Do not create tests that freeze prose, headings, or structure in explanations, guides, README files, or Markdown documentation
|
|
31
|
+
- For docs-only changes, do not add tests unless an explicit executable contract exists
|
|
32
|
+
- Tests are only needed when assets contain contracts tied to code behavior or machine processing, such as CLI examples, config examples, or generated artifacts
|
|
33
|
+
|
|
34
|
+
**Test execution:**
|
|
35
|
+
- Run tests after creating them to check results
|
|
36
|
+
- Test failures and import errors are expected before implementation (including imports of not-yet-implemented modules)
|
|
37
|
+
- Fix errors that will persist after implementation, such as wrong import paths for existing modules
|
|
38
|
+
|
|
39
|
+
**Required output (include headings)**
|
|
40
|
+
## Work Results
|
|
41
|
+
- {Summary of created or updated tests}
|
|
42
|
+
## Protected Existing Contracts
|
|
43
|
+
- {Existing behavior protected by tests}
|
|
44
|
+
## Test Results
|
|
45
|
+
- {Command and result if run, or reason if not run}
|
|
@@ -212,6 +212,7 @@ Detect comments that simply restate code behavior in natural language.
|
|
|
212
212
|
| REJECT | JSDoc that only paraphrases the function name without adding information |
|
|
213
213
|
| OK | Explains why a particular implementation was chosen |
|
|
214
214
|
| OK | Explains the reason behind seemingly unusual behavior |
|
|
215
|
+
| OK | Explains the calculation basis or components of a constant or magic number |
|
|
215
216
|
| Best | No comment needed — the code itself communicates intent |
|
|
216
217
|
|
|
217
218
|
```typescript
|
|
@@ -238,6 +239,10 @@ if (status === 'interrupted') {
|
|
|
238
239
|
// OK - Reason behind seemingly odd behavior
|
|
239
240
|
// stay can cause loops, but is only used when explicitly specified by the user
|
|
240
241
|
return step.name;
|
|
242
|
+
|
|
243
|
+
// OK - Calculation basis for a constant
|
|
244
|
+
// paddingTop + paddingBottom + button height
|
|
245
|
+
const footerHeight = 24 + 12 + 48;
|
|
241
246
|
```
|
|
242
247
|
|
|
243
248
|
**Direct State Mutation Detection Criteria:**
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# Existing System Knowledge
|
|
2
|
+
|
|
3
|
+
## Existing System Contracts
|
|
4
|
+
|
|
5
|
+
In an existing system, contracts are not limited to explicit APIs. Values and structures observed by users or developers also function as contracts. A small code change can affect production screens, tests, reviews, and maintenance workflows.
|
|
6
|
+
|
|
7
|
+
| Criteria | Judgment |
|
|
8
|
+
|----------|----------|
|
|
9
|
+
| User-visible copy or state changes | Contract change |
|
|
10
|
+
| A value asserted by tests changes | Contract change |
|
|
11
|
+
| Hook or component call shape changes | Contract change |
|
|
12
|
+
| Only file placement or type names change | May still be a maintenance contract change |
|
|
13
|
+
| Closed internal duplication is removed | Internal change if impact is contained |
|
|
14
|
+
|
|
15
|
+
## Diff Classification
|
|
16
|
+
|
|
17
|
+
Changes in existing systems are classified by causal relationship to the request. The question is whether the request requires the change, not whether the change is in a touched file.
|
|
18
|
+
|
|
19
|
+
| Classification | Decision criteria |
|
|
20
|
+
|----------------|-------------------|
|
|
21
|
+
| Required change | Directly required to satisfy the request |
|
|
22
|
+
| Related change | Required to wire, verify, or keep a required change consistent |
|
|
23
|
+
| Unnecessary change | The request still succeeds without it |
|
|
24
|
+
| Dangerous unnecessary change | The request still succeeds without it and it changes an existing contract |
|
|
25
|
+
|
|
26
|
+
### Boundary of Related Changes
|
|
27
|
+
|
|
28
|
+
A related change must have an explainable connection to a required change. Proximity, same file, or same responsibility is not enough.
|
|
29
|
+
|
|
30
|
+
| Example | Classification |
|
|
31
|
+
|---------|----------------|
|
|
32
|
+
| Updating callers after adding a required parameter | Related change |
|
|
33
|
+
| Deleting an old store after changing persistence boundary | Related change |
|
|
34
|
+
| Renaming a touched component's Props type by preference | Unnecessary change |
|
|
35
|
+
| Changing a hook return shape to a props object as cleanup | Dangerous unnecessary change |
|
|
36
|
+
|
|
37
|
+
## Conflicts With General Quality Criteria
|
|
38
|
+
|
|
39
|
+
In maintenance work, general design improvements and framework style are not always the highest priority. Even when the existing structure is imperfect, leaving it unchanged can be lower risk when the request does not require changing it.
|
|
40
|
+
|
|
41
|
+
| Situation | Judgment |
|
|
42
|
+
|-----------|----------|
|
|
43
|
+
| Component extraction would look cleaner but is unnecessary for this fix | Do not change |
|
|
44
|
+
| Renaming or relocating Props types only to match common style | Do not change |
|
|
45
|
+
| The existing structure cannot satisfy the request | Change the minimum necessary scope |
|
|
46
|
+
| The existing structure is the cause of the bug | Change it with reason and impact scope documented |
|
|
47
|
+
|
|
48
|
+
## Meaning of Comments and Tests
|
|
49
|
+
|
|
50
|
+
Comments and tests may preserve historical constraints or intent. Even comments that look explanatory can act like contracts when they document calculation rationale, platform constraints, or known workaround reasons.
|
|
51
|
+
|
|
52
|
+
| Target | Handling |
|
|
53
|
+
|--------|----------|
|
|
54
|
+
| Calculation rationale comments | Preserve |
|
|
55
|
+
| Constraint or workaround comments | Preserve |
|
|
56
|
+
| Comments contradicting code | Correct |
|
|
57
|
+
| Comments that only restate function names | May consider deleting |
|
|
58
|
+
| Existing test expectations | Treat as existing contracts |
|
|
59
|
+
|
|
60
|
+
## Maintenance Change Risk
|
|
61
|
+
|
|
62
|
+
For maintenance work, preserving existing behavior is more important than making new code look better. Even a technically good change increases review cost and regression risk when it is outside the request.
|
|
63
|
+
|
|
64
|
+
| Change | Risk |
|
|
65
|
+
|--------|------|
|
|
66
|
+
| Rename | Increases grep, history tracing, and review scope |
|
|
67
|
+
| File move | Changes ownership boundaries, imports, and history tracing |
|
|
68
|
+
| UI contract change | Changes user experience, assistive technology behavior, and tests |
|
|
69
|
+
| Test weakening | Reduces regression detection |
|
|
70
|
+
| Extra abstraction | Adds present understanding cost for future flexibility |
|
|
@@ -81,6 +81,18 @@ Third-party UI libraries such as data grids, date pickers, charts, and virtualiz
|
|
|
81
81
|
| The real component is rendered with representative props and verified not to crash at screen level | OK |
|
|
82
82
|
| Prop shapes are chosen by referencing existing in-project usage patterns and the installed version | OK |
|
|
83
83
|
|
|
84
|
+
### Accessibility Contracts
|
|
85
|
+
|
|
86
|
+
Accessible names, roles, and states are UI contracts consumed by assistive technologies and tests. Add appropriate accessibility attributes for new UI elements, but treat changes to existing accessibility contracts like other user-facing copy or behavior changes.
|
|
87
|
+
|
|
88
|
+
| Criteria | Judgment |
|
|
89
|
+
|----------|----------|
|
|
90
|
+
| A new interactive element has no accessible name | REJECT |
|
|
91
|
+
| Checked, expanded, disabled, or similar state is not exposed to assistive technologies | Warning |
|
|
92
|
+
| An existing accessible name is changed without being required by the task | REJECT |
|
|
93
|
+
| Existing accessible names are preserved while missing role/state is added | OK |
|
|
94
|
+
| The reason and impact scope for changing an existing contract are explicit | OK |
|
|
95
|
+
|
|
84
96
|
## State Management
|
|
85
97
|
|
|
86
98
|
Child components do not modify their own state. They bubble events to parent, and parent manipulates state.
|
|
@@ -120,6 +120,41 @@ When shared state is required, call the hook once in the nearest common parent a
|
|
|
120
120
|
| Multiple components call the same stateful hook independently when they need shared state | REJECT |
|
|
121
121
|
| A hook returns JSX | REJECT |
|
|
122
122
|
|
|
123
|
+
### Props Type Placement and Hook Boundaries
|
|
124
|
+
|
|
125
|
+
Props types that belong to a single component should generally live in the same file as that component. Separate type files are appropriate when the contract is shared by multiple components, is part of a public API, or has independent meaning as a domain model.
|
|
126
|
+
|
|
127
|
+
| Criteria | Judgment |
|
|
128
|
+
|----------|----------|
|
|
129
|
+
| A single component's private Props type is moved to a `types` file without a clear reason | Warning |
|
|
130
|
+
| Props are moved to a separate file only so a hook can import a component's Props type | REJECT |
|
|
131
|
+
| Shared Props/data contracts used by multiple components or public APIs live in a separate file | OK |
|
|
132
|
+
| A hook returns state, events, and derived values while a container maps them to component props | OK |
|
|
133
|
+
| Even when a hook returns a props-like object, the hook does not depend on the component's Props type | OK |
|
|
134
|
+
|
|
135
|
+
```tsx
|
|
136
|
+
// REJECT - the hook depends on a specific component's Props contract
|
|
137
|
+
import type { DialogProps } from './Dialog'
|
|
138
|
+
|
|
139
|
+
export function useDialog(): { dialogProps: DialogProps } {
|
|
140
|
+
return { dialogProps: { open, onOpenChange } }
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
// OK - component-local Props stay with the component
|
|
144
|
+
interface DialogProps {
|
|
145
|
+
open: boolean
|
|
146
|
+
onOpenChange: (open: boolean) => void
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
export function Dialog(props: DialogProps) {
|
|
150
|
+
return <Modal {...props} />
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
// OK - the hook returns UI state and operations, and the caller passes them to the component
|
|
154
|
+
const dialog = useDialog()
|
|
155
|
+
return <Dialog open={dialog.open} onOpenChange={dialog.setOpen} />
|
|
156
|
+
```
|
|
157
|
+
|
|
123
158
|
## Handling exhaustive-deps
|
|
124
159
|
|
|
125
160
|
`react-hooks/exhaustive-deps` is not a rule to satisfy mechanically. If adding dependencies changes a mount-only effect into a loop, keep the effect mount-only and document why the suppression exists.
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
```markdown
|
|
2
|
+
# Coding Review
|
|
3
|
+
|
|
4
|
+
## Result: APPROVE / REJECT
|
|
5
|
+
|
|
6
|
+
## Summary
|
|
7
|
+
{Summarize the review result in 1-2 sentences}
|
|
8
|
+
|
|
9
|
+
## Current Iteration Findings (new)
|
|
10
|
+
| # | finding_id | family_tag | Severity | Location | Issue | Impact | Fix Suggestion |
|
|
11
|
+
|---|------------|------------|----------|----------|-------|--------|----------------|
|
|
12
|
+
| 1 | CODE-NEW-src-file-L42 | bug | High / Medium / Low | `src/file.ts:42` | {Issue} | {Impact} | {Fix suggestion} |
|
|
13
|
+
|
|
14
|
+
## Carry-over Findings (persists)
|
|
15
|
+
| # | finding_id | family_tag | Previous Evidence | Current Evidence | Issue | Fix Suggestion |
|
|
16
|
+
|---|------------|------------|-------------------|------------------|-------|----------------|
|
|
17
|
+
| 1 | CODE-PERSIST-src-file-L77 | regression | `src/file.ts:77` | `src/file.ts:77` | {Unresolved issue} | {Fix suggestion} |
|
|
18
|
+
|
|
19
|
+
## Resolved Findings (resolved)
|
|
20
|
+
| finding_id | Resolution Evidence |
|
|
21
|
+
|------------|---------------------|
|
|
22
|
+
| CODE-RESOLVED-src-file-L10 | Resolved at `src/file.ts:10` |
|
|
23
|
+
|
|
24
|
+
## Reopened Findings (reopened)
|
|
25
|
+
| # | finding_id | family_tag | Prior Resolution Evidence | Recurrence Evidence | Issue | Fix Suggestion |
|
|
26
|
+
|---|------------|------------|--------------------------|---------------------|-------|----------------|
|
|
27
|
+
| 1 | CODE-REOPENED-src-file-L55 | bug | `Previously: src/file.ts:10` | `src/file.ts:55` | {Reopened issue} | {Fix suggestion} |
|
|
28
|
+
|
|
29
|
+
## Verification Evidence
|
|
30
|
+
- Diff review: {What was checked}
|
|
31
|
+
- Build: {Result, or state unverified}
|
|
32
|
+
- Tests: {Result, or state unverified}
|
|
33
|
+
|
|
34
|
+
## Rejection Gate
|
|
35
|
+
- REJECT only when at least one finding exists in `new`, `persists`, or `reopened`
|
|
36
|
+
- Findings without `finding_id` are invalid
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
**Cognitive load reduction rules:**
|
|
40
|
+
- APPROVE: Summary only (5 lines or fewer)
|
|
41
|
+
- REJECT: Include only relevant finding rows (30 lines or fewer)
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
```markdown
|
|
2
|
+
# Maintenance Change Scope
|
|
3
|
+
|
|
4
|
+
## Task
|
|
5
|
+
{One-line task summary}
|
|
6
|
+
|
|
7
|
+
## Required Changes
|
|
8
|
+
| File | Reason | Requirement Mapping |
|
|
9
|
+
|------|--------|---------------------|
|
|
10
|
+
| {File} | {Reason} | {Mapped requirement} |
|
|
11
|
+
|
|
12
|
+
## Related Changes
|
|
13
|
+
| File | Reason | Relation to Required Change |
|
|
14
|
+
|------|--------|-----------------------------|
|
|
15
|
+
| {File} | {Reason} | {Relation} |
|
|
16
|
+
|
|
17
|
+
## Existing Contracts Preserved
|
|
18
|
+
| Contract | Target | Preservation |
|
|
19
|
+
|----------|--------|--------------|
|
|
20
|
+
| {Contract type} | {Target} | {What is preserved} |
|
|
21
|
+
|
|
22
|
+
## Unnecessary Change Check
|
|
23
|
+
| Check Target | Result | Notes |
|
|
24
|
+
|--------------|--------|-------|
|
|
25
|
+
| Renames or moves | {Present/none} | {Notes} |
|
|
26
|
+
| UI copy or accessibility | {Present/none} | {Notes} |
|
|
27
|
+
| Comment deletion | {Present/none} | {Notes} |
|
|
28
|
+
| Test expectation changes | {Present/none} | {Notes} |
|
|
29
|
+
```
|