/** SDK-owned platform module. This implementation is maintained in goodvibes-sdk. */
/**
 * JSON Schema definition for the `inspect` tool.
 *
 * The inspect tool performs static analysis of a project or file and returns
 * structured information about its structure, APIs, database schema, components,
 * layout, accessibility, or a scaffold plan.
 */
export const INSPECT_TOOL_SCHEMA = {
    type: 'object',
    properties: {
        mode: {
            type: 'string',
            enum: ['project', 'api', 'api_spec', 'api_validate', 'api_sync', 'database', 'components', 'layout', 'accessibility', 'scaffold', 'component_state', 'render_triggers', 'hooks', 'overflow', 'sizing', 'stacking', 'responsive', 'events', 'tailwind', 'client_boundary', 'error_boundary'],
            description: 'Analysis mode. project: detect project type and structure; api: scan route definitions;'
                + ' api_spec: generate OpenAPI 3.0 spec from discovered routes;'
                + ' api_validate: compare existing OpenAPI spec against discovered routes;'
                + ' api_sync: detect frontend/backend type drift via fetch() call analysis;'
                + ' database: parse schema models; components: extract React components;'
                + ' layout: analyze CSS/Tailwind layout; accessibility: detect a11y issues;'
                + ' scaffold: generate module skeleton;'
                + ' component_state: trace useState/useReducer/useContext; render_triggers: find re-render causes;'
                + ' hooks: analyze hook dependency arrays; overflow: find CSS overflow issues;'
                + ' sizing: analyze sizing strategy; stacking: z-index and stacking context;'
                + ' responsive: Tailwind breakpoint analysis; events: event handling analysis;'
                + ' tailwind: detect class conflicts; client_boundary: Next.js directive analysis;'
                + ' error_boundary: error boundary coverage.',
        },
        projectRoot: {
            type: 'string',
            description: 'Root directory for the analysis. Defaults to the current working directory.',
        },
        file: {
            type: 'string',
            description: 'Path to a specific file. Required for component, layout, and accessibility modes.',
        },
        framework: {
            type: 'string',
            enum: ['auto', 'nextjs', 'express', 'fastify', 'hono'],
            description: 'Web framework for api mode. auto detects from package.json. Default: auto.',
        },
        schemaPath: {
            type: 'string',
            description: 'Path to database schema file (Prisma/Drizzle). For database mode. '
                + 'Defaults to prisma/schema.prisma.',
        },
        moduleName: {
            type: 'string',
            description: 'Module name for scaffold mode. Used to name generated files.',
        },
        dryRun: {
            type: 'boolean',
            description: 'scaffold mode: return file plan without writing. Default true.',
        },
        output: {
            type: 'object',
            description: 'Output formatting options.',
            properties: {
                format: {
                    type: 'string',
                    enum: ['summary', 'detailed', 'json'],
                    description: 'summary: condensed overview; detailed: full analysis; json: raw JSON. Default: detailed.',
                },
                max_tokens: {
                    type: 'integer',
                    minimum: 1,
                    description: 'Hard token cap for the response.',
                },
            },
        },
    },
    required: ['mode'],
};
