UNPKG

bc-code-intelligence-mcp

Version:

BC Code Intelligence MCP Server - Complete Specialist Bundle with AI-driven expert consultation, seamless handoffs, and context-preserving workflows

109 lines 3.69 kB
/** * Configuration system types for BC Code Intelligence MCP server * Supports multi-source configuration with layer-based knowledge management */ export var LayerSourceType; (function (LayerSourceType) { LayerSourceType["EMBEDDED"] = "embedded"; LayerSourceType["GIT"] = "git"; LayerSourceType["LOCAL"] = "local"; LayerSourceType["HTTP"] = "http"; LayerSourceType["NPM"] = "npm"; // 🚧 Planned - NPM package knowledge sources })(LayerSourceType || (LayerSourceType = {})); export var AuthType; (function (AuthType) { AuthType["TOKEN"] = "token"; AuthType["SSH_KEY"] = "ssh"; AuthType["BASIC"] = "basic"; AuthType["OAUTH"] = "oauth"; AuthType["AZ_CLI"] = "az_cli"; })(AuthType || (AuthType = {})); // Default configuration template export const DEFAULT_BC_CODE_INTEL_CONFIG = { layers: [ { name: 'embedded', priority: 0, source: { type: LayerSourceType.EMBEDDED, path: 'embedded-knowledge' }, enabled: true }, { name: 'project', priority: 100, source: { type: LayerSourceType.LOCAL, path: './bc-code-intel-overrides' }, enabled: true, patterns: ['*'] } ], resolution: { strategy: 'best_match', conflict_resolution: 'priority_wins', enable_fallback: true, fallback_to_embedded: true }, cache: { strategy: 'moderate', ttl: { git: '1h', local: 'immediate', http: '30m', embedded: 'permanent', npm: '24h' }, max_size_mb: 100, clear_on_startup: false, background_refresh: true }, security: { validate_sources: true, allow_local_paths: true, allow_http_sources: false, trusted_domains: [], max_download_size_mb: 50, scan_for_malicious_content: true }, performance: { max_concurrent_loads: 5, load_timeout_ms: 30000, max_layers: 20, lazy_loading: true, preload_embedded: true, memory_limit_mb: 500 }, developer: { debug_layers: false, hot_reload: false, log_level: 'info', profile_performance: false, validate_on_startup: true, export_config_schema: false, enable_diagnostic_tools: false // Disabled by default to minimize token overhead } }; // Environment variable mappings export const ENV_VAR_MAPPINGS = { 'BC_CODE_INTEL_CONFIG_PATH': 'config_file_path', 'BC_CODE_INTEL_DEBUG_LAYERS': 'developer.debug_layers', 'BC_CODE_INTEL_ENABLE_DIAGNOSTICS': 'developer.enable_diagnostic_tools', 'BC_CODE_INTEL_HOT_RELOAD': 'developer.hot_reload', 'BC_CODE_INTEL_LOG_LEVEL': 'developer.log_level', 'BC_CODE_INTEL_CACHE_STRATEGY': 'cache.strategy', 'BC_CODE_INTEL_CACHE_TTL_GIT': 'cache.ttl.git', 'BC_CODE_INTEL_CACHE_TTL_LOCAL': 'cache.ttl.local', 'BC_CODE_INTEL_ALLOW_HTTP_SOURCES': 'security.allow_http_sources', 'BC_CODE_INTEL_MAX_LAYERS': 'performance.max_layers', 'BC_CODE_INTEL_MEMORY_LIMIT_MB': 'performance.memory_limit_mb', // Project overrides absolute path 'BC_CODE_INTEL_PROJECT_OVERRIDES_PATH': 'layers[project].source.path', // Quick git layer setup 'BC_CODE_INTEL_COMPANY_KNOWLEDGE_URL': 'layers[company].source.url', 'BC_CODE_INTEL_COMPANY_KNOWLEDGE_TOKEN': 'layers[company].auth.token', 'BC_CODE_INTEL_COMPANY_KNOWLEDGE_BRANCH': 'layers[company].source.branch' }; //# sourceMappingURL=config-types.js.map