async function handler(ctx) {
    const { projectPath, projectId, specId } = ctx;
    if (!projectPath) {
        return;
    }
    // Sub-task 1: generate execution plan (fire-and-forget)
    await import('../../../tools/generate-execution-plan.js')
        .then(({ handleGenerateExecutionPlan }) => handleGenerateExecutionPlan({ specId, projectId }))
        .catch(() => {
        /* best-effort */
    });
    // Sub-task 2: fire TDD scaffold via complete-loop (fire-and-forget)
    await import('../../../engine/autopilot/complete-loop.js')
        .then(({ fireAutoScaffoldTdd }) => {
        fireAutoScaffoldTdd(projectPath, projectId, specId);
    })
        .catch(() => {
        /* best-effort */
    });
}
export const implementingKickoffHook = {
    id: 'implementing-kickoff',
    triggers: ['implementing'],
    requiresProjectPath: true,
    label: 'Auto-kickoff on implementing — fire execution plan + TDD scaffold (SPEC-504)',
    handler,
};
//# sourceMappingURL=implementing-kickoff.hook.js.map