/** * Server instructions for postgres-mcp (PostgreSQL MCP Server). * * ⚠️ AUTO-GENERATED — DO NOT EDIT THIS FILE DIRECTLY * Edit src/constants/server-instructions/*.md instead, * then run: npm run generate:instructions * * Slim instructions are sent to MCP clients during initialization. * Detailed help is available on-demand via postgres://help resources. * Instructions are dynamically generated based on enabled tool groups * and instruction level for token efficiency. */ import type { ToolGroup } from '../types/index.js'; /** * Instruction detail level for token efficiency * - essential: ~150 tokens - Core quick access only (for token-constrained clients) * - standard: ~200-300 tokens - + dynamic help pointers for enabled groups * - full: ~350-400 tokens - + active groups summary */ export type InstructionLevel = 'essential' | 'standard' | 'full'; /** * Generate dynamic instructions based on enabled tool groups and instruction level. * * Sections are conditionally included based on which tool groups are enabled: * - Code Mode → only with `codemode` group * - Help group listing → `standard`+ level, only lists enabled groups * - Active tools summary → `full` level only * * @param enabledGroups - Set of enabled tool group names * @param level - Instruction detail level (default: 'standard') * @param enabledToolCount - Number of enabled tools (for full level summary) */ export declare function generateInstructions(enabledGroups: Set, level?: InstructionLevel, enabledToolCount?: number): string; /** * Static instructions for backward compatibility. * @deprecated Use generateInstructions() instead for dynamic content */ export declare const INSTRUCTIONS = "# postgres-mcp (PostgreSQL MCP Server)\n\n## Quick Access\n\n| Purpose | Action |\n| --------------- | ---------------------------- |\n| Health check | `pg_analyze_db_health` tool |\n| Server info | `pg_server_version` tool |\n| Database schema | `postgres://schema` resource |\n| Audit & Tokens | `postgres://audit` resource |\n| Tool help | `postgres://help` resource |\n\n## Built-in Tools\n\n`pg_read_query`, `pg_write_query`, `pg_list_tables` \u2014 always available.\n\n## Code Mode Sandbox (`pg_execute_code`)\n\nFor multi-step data pipelines, complex validations, or token-heavy reads (like vector dimension data or large raw string outputs), ALWAYS use Code Mode. It provides a secure JavaScript execution sandbox with native `pg.*` proxy access, drastically reducing LLM token consumption by up to ~90% for loop operations and eliminating MCP transport latency.\n\n## Tool Groups Showcase (200+ Tools)\n\nAll tools are grouped by namespace in Code Mode (e.g. `pg.stats.*`, `pg.vector.*`).\nSome highlights include:\n\n- **Core Operations**: `core`, `transactions`, `migration`, `schema`\n- **Data Types**: `jsonb`, `text`, `vector`, `postgis`, `citext`, `ltree`\n- **Introspection/Health**: `introspection`, `monitoring`, `performance`, `kcache`\n- **Access Control**: `security`, `roles`\n- **Scale/Maintenance**: `partitioning`, `partman`, `cron`, `backup`, `admin`\n- **Analytics**: `stats`, `pgcrypto`\n\nReview individual `server-instructions/{group}.md` for deep-dive examples and parameter aliases, or use `postgres://help` directly from the MCP."; /** * Help content keyed by group name. * 'gotchas' is the always-available help (postgres://help). * Other keys are tool groups (postgres://help/{group}). */ export declare const HELP_CONTENT: ReadonlyMap; //# sourceMappingURL=server-instructions.d.ts.map