const TOOL_REGISTRATION_PATTERNS = [
    /registerTool\s*\(/,
    /src\/tools\/[\w-]+\.ts/,
    /new MCP tool/i,
    /register.*Planu tool/i,
    /new tool/i,
];
export function detectsNewToolRegistration(specBody, technicalMd) {
    const combined = `${specBody}\n${technicalMd}`;
    for (const pattern of TOOL_REGISTRATION_PATTERNS) {
        if (pattern.test(combined)) {
            return true;
        }
    }
    const createSection = /###\s+Create[\s\S]*?(?:###|$)/.exec(combined);
    if (createSection?.[0].includes('src/tools/') === true) {
        return true;
    }
    return false;
}
export function buildToolRegistrationCriteria() {
    return [
        {
            text: 'license-plans.json must include the new tool name',
            source: 'impact-detector',
            autoResolvable: false,
        },
        {
            text: 'register-spec-tools.test.ts count assertion must be updated to N+1',
            source: 'impact-detector',
            autoResolvable: false,
        },
        {
            text: 'tests/api/tool-schemas.snapshot.test.ts snapshot must be regenerated',
            source: 'impact-detector',
            autoResolvable: false,
        },
        {
            text: 'scripts/sync-website-counts.sh --apply must be run and website/ committed',
            source: 'impact-detector',
            autoResolvable: false,
        },
    ];
}
//# sourceMappingURL=tool-registration.js.map