// tools/register-facilitator-tools.ts — Registers Facilitator tools (SPEC-037)
import { z } from 'zod';
import { handleFacilitate } from './facilitate.js';
/**
 * Registers the `facilitate` tool and related facilitator tools (SPEC-037).
 */
export function registerFacilitatorTools(server) {
    // facilitate — zero-knowledge entry point
    server.registerTool('facilitate', {
        description: 'Entry point for users unfamiliar with Planu. ' +
            'Detects scenario (new project / existing / problem), ' +
            'checks ambiguity before execution, tracks session focus, ' +
            'and adds expert observations to generated artifacts.',
        inputSchema: {
            description: z
                .string()
                .describe('Free-form description: what you want to build, your problem, or your request'),
            projectId: z
                .string()
                .optional()
                .describe('Project ID (optional — used for focus persistence)'),
            sessionId: z
                .string()
                .optional()
                .describe('Session ID (overrides projectId for focus tracking)'),
            scenario: z
                .enum(['new_project', 'existing_project', 'concrete_problem'])
                .optional()
                .describe('Override auto-detected scenario'),
            collectedInfo: z
                .record(z.string(), z.string())
                .optional()
                .describe('Answers collected in previous steps'),
            step: z
                .number()
                .int()
                .min(0)
                .max(2)
                .optional()
                .describe('Current step index for new_project flow (0–2)'),
            targetTool: z
                .string()
                .optional()
                .describe('Planu tool name to check ambiguity for before calling it'),
            checkFocus: z
                .boolean()
                .optional()
                .describe('Check whether this request is aligned with the current session focus'),
            changeFocus: z.string().optional().describe('Explicitly declare a new session objective'),
        },
        annotations: {
            readOnlyHint: false,
        },
    }, (args) => handleFacilitate(args));
}
//# sourceMappingURL=register-facilitator-tools.js.map