UNPKG

mcp-adr-analysis-server

Version:

MCP server for analyzing Architectural Decision Records and project architecture

1,394 lines (1,393 loc) 81.7 kB
/** * Memory-Centric Entity System * * Core types and interfaces for the memory-centric architecture transformation. * These entities replace task-oriented structures with persistent memory objects * that maintain context, relationships, and evolution over time. */ import { z } from 'zod'; export declare const BaseMemoryEntitySchema: z.ZodObject<{ id: z.ZodString; type: z.ZodEnum<{ architectural_decision: "architectural_decision"; code_component: "code_component"; business_requirement: "business_requirement"; technical_constraint: "technical_constraint"; quality_concern: "quality_concern"; implementation_pattern: "implementation_pattern"; environmental_factor: "environmental_factor"; stakeholder_input: "stakeholder_input"; knowledge_artifact: "knowledge_artifact"; decision_context: "decision_context"; troubleshooting_session: "troubleshooting_session"; environment_snapshot: "environment_snapshot"; failure_pattern: "failure_pattern"; security_pattern: "security_pattern"; deployment_assessment: "deployment_assessment"; }>; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; }, z.core.$strip>; export type BaseMemoryEntity = z.infer<typeof BaseMemoryEntitySchema>; export declare const ArchitecturalDecisionMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"architectural_decision">; decisionData: z.ZodObject<{ status: z.ZodEnum<{ proposed: "proposed"; accepted: "accepted"; deprecated: "deprecated"; superseded: "superseded"; }>; context: z.ZodString; decision: z.ZodString; consequences: z.ZodObject<{ positive: z.ZodArray<z.ZodString>; negative: z.ZodArray<z.ZodString>; risks: z.ZodArray<z.ZodString>; }, z.core.$strip>; alternatives: z.ZodArray<z.ZodObject<{ name: z.ZodString; description: z.ZodString; tradeoffs: z.ZodString; }, z.core.$strip>>; implementationStatus: z.ZodEnum<{ completed: "completed"; in_progress: "in_progress"; not_started: "not_started"; on_hold: "on_hold"; }>; implementationTasks: z.ZodArray<z.ZodString>; reviewHistory: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; reviewer: z.ZodString; decision: z.ZodEnum<{ approve: "approve"; reject: "reject"; revise: "revise"; }>; comments: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; export declare const CodeComponentMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"code_component">; componentData: z.ZodObject<{ filePath: z.ZodString; componentType: z.ZodEnum<{ function: "function"; configuration: "configuration"; class: "class"; module: "module"; interface: "interface"; }>; language: z.ZodString; size: z.ZodObject<{ lines: z.ZodNumber; complexity: z.ZodNumber; dependencies: z.ZodNumber; }, z.core.$strip>; qualityMetrics: z.ZodObject<{ maintainability: z.ZodNumber; testCoverage: z.ZodNumber; performance: z.ZodNumber; security: z.ZodNumber; }, z.core.$strip>; architecturalRole: z.ZodString; businessValue: z.ZodString; technicalDebt: z.ZodArray<z.ZodObject<{ type: z.ZodString; severity: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; description: z.ZodString; estimatedEffort: z.ZodString; }, z.core.$strip>>; dependencies: z.ZodArray<z.ZodString>; publicInterface: z.ZodArray<z.ZodString>; changeFrequency: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; riskProfile: z.ZodObject<{ technicalRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; businessRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; changeRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; mitigationStrategies: z.ZodArray<z.ZodString>; }, z.core.$strip>; }, z.core.$strip>; }, z.core.$strip>; export declare const BusinessRequirementMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"business_requirement">; requirementData: z.ZodObject<{ priority: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; businessValue: z.ZodString; acceptanceCriteria: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; constraints: z.ZodArray<z.ZodString>; satisfactionLevel: z.ZodNumber; implementationApproach: z.ZodOptional<z.ZodString>; riskFactors: z.ZodArray<z.ZodObject<{ risk: z.ZodString; impact: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; likelihood: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; mitigation: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; export declare const KnowledgeArtifactMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"knowledge_artifact">; artifactData: z.ZodObject<{ artifactType: z.ZodEnum<{ pattern: "pattern"; documentation: "documentation"; research: "research"; analysis: "analysis"; guideline: "guideline"; }>; content: z.ZodString; format: z.ZodEnum<{ code: "code"; text: "text"; markdown: "markdown"; json: "json"; yaml: "yaml"; }>; sourceReliability: z.ZodNumber; applicabilityScope: z.ZodArray<z.ZodString>; lastValidated: z.ZodOptional<z.ZodString>; keyInsights: z.ZodArray<z.ZodString>; actionableItems: z.ZodArray<z.ZodObject<{ action: z.ZodString; priority: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; timeframe: z.ZodString; dependencies: z.ZodArray<z.ZodString>; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; export declare const TroubleshootingSessionMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"troubleshooting_session">; sessionData: z.ZodObject<{ failurePattern: z.ZodObject<{ failureType: z.ZodEnum<{ test_failure: "test_failure"; deployment_failure: "deployment_failure"; build_failure: "build_failure"; runtime_error: "runtime_error"; performance_issue: "performance_issue"; security_issue: "security_issue"; other: "other"; }>; errorSignature: z.ZodString; frequency: z.ZodNumber; environments: z.ZodArray<z.ZodString>; }, z.core.$strip>; failureDetails: z.ZodObject<{ command: z.ZodOptional<z.ZodString>; exitCode: z.ZodOptional<z.ZodNumber>; errorMessage: z.ZodString; stackTrace: z.ZodOptional<z.ZodString>; logOutput: z.ZodOptional<z.ZodString>; environment: z.ZodOptional<z.ZodString>; timestamp: z.ZodOptional<z.ZodString>; affectedFiles: z.ZodOptional<z.ZodArray<z.ZodString>>; }, z.core.$strip>; analysisSteps: z.ZodArray<z.ZodString>; solutionEffectiveness: z.ZodNumber; resolutionTimeMinutes: z.ZodOptional<z.ZodNumber>; preventionMeasures: z.ZodArray<z.ZodString>; relatedADRs: z.ZodArray<z.ZodString>; environmentContext: z.ZodRecord<z.ZodString, z.ZodAny>; followUpActions: z.ZodArray<z.ZodObject<{ action: z.ZodString; type: z.ZodEnum<{ adr_suggestion: "adr_suggestion"; research_generation: "research_generation"; process_improvement: "process_improvement"; }>; priority: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; triggered: z.ZodBoolean; reason: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; export declare const EnvironmentSnapshotMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"environment_snapshot">; environmentData: z.ZodObject<{ environmentType: z.ZodEnum<{ testing: "testing"; development: "development"; production: "production"; staging: "staging"; }>; configuration: z.ZodRecord<z.ZodString, z.ZodAny>; complianceStatus: z.ZodObject<{ adrAlignment: z.ZodNumber; securityPosture: z.ZodNumber; performanceMetrics: z.ZodRecord<z.ZodString, z.ZodNumber>; lastValidation: z.ZodString; complianceIssues: z.ZodOptional<z.ZodArray<z.ZodString>>; }, z.core.$strip>; infrastructureSpecs: z.ZodObject<{ containerization: z.ZodRecord<z.ZodString, z.ZodAny>; dependencies: z.ZodArray<z.ZodString>; resourceLimits: z.ZodRecord<z.ZodString, z.ZodNumber>; networkConfiguration: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>; storageConfiguration: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>; }, z.core.$strip>; changeHistory: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; changeType: z.ZodEnum<{ dependencies: "dependencies"; security: "security"; configuration: "configuration"; infrastructure: "infrastructure"; }>; description: z.ZodString; impact: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; author: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; export declare const FailurePatternMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"failure_pattern">; patternData: z.ZodObject<{ failureType: z.ZodEnum<{ test_failure: "test_failure"; deployment_failure: "deployment_failure"; build_failure: "build_failure"; runtime_error: "runtime_error"; performance_issue: "performance_issue"; security_issue: "security_issue"; other: "other"; }>; pattern: z.ZodString; frequency: z.ZodNumber; environments: z.ZodArray<z.ZodString>; commonCauses: z.ZodArray<z.ZodString>; solutions: z.ZodArray<z.ZodObject<{ solution: z.ZodString; effectiveness: z.ZodNumber; timesToResolution: z.ZodNumber; prerequisites: z.ZodOptional<z.ZodArray<z.ZodString>>; }, z.core.$strip>>; preventionMeasures: z.ZodArray<z.ZodString>; riskLevel: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; impactAreas: z.ZodArray<z.ZodString>; learningPoints: z.ZodOptional<z.ZodArray<z.ZodString>>; }, z.core.$strip>; }, z.core.$strip>; export declare const SecurityPatternMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"security_pattern">; securityData: z.ZodObject<{ contentType: z.ZodEnum<{ documentation: "documentation"; code: "code"; configuration: "configuration"; logs: "logs"; general: "general"; }>; detectedPatterns: z.ZodArray<z.ZodObject<{ patternType: z.ZodString; severity: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; description: z.ZodString; location: z.ZodOptional<z.ZodString>; recommendation: z.ZodString; }, z.core.$strip>>; maskingResults: z.ZodObject<{ effectiveness: z.ZodNumber; method: z.ZodString; preservedUtility: z.ZodNumber; falsePositives: z.ZodOptional<z.ZodNumber>; falseNegatives: z.ZodOptional<z.ZodNumber>; }, z.core.$strip>; riskAssessment: z.ZodObject<{ overallRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; specificRisks: z.ZodArray<z.ZodString>; mitigationStrategies: z.ZodArray<z.ZodString>; complianceImpact: z.ZodOptional<z.ZodString>; }, z.core.$strip>; evolutionTracking: z.ZodObject<{ patternChanges: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; change: z.ZodString; impact: z.ZodString; }, z.core.$strip>>; effectivenessHistory: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; effectiveness: z.ZodNumber; method: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>; }, z.core.$strip>; export declare const DeploymentAssessmentMemorySchema: z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"deployment_assessment">; assessmentData: z.ZodObject<{ environment: z.ZodEnum<{ testing: "testing"; development: "development"; production: "production"; staging: "staging"; }>; readinessScore: z.ZodNumber; validationResults: z.ZodObject<{ testResults: z.ZodObject<{ passed: z.ZodNumber; failed: z.ZodNumber; coverage: z.ZodNumber; criticalFailures: z.ZodArray<z.ZodString>; }, z.core.$strip>; securityValidation: z.ZodObject<{ vulnerabilities: z.ZodNumber; securityScore: z.ZodNumber; criticalIssues: z.ZodArray<z.ZodString>; }, z.core.$strip>; performanceValidation: z.ZodObject<{ performanceScore: z.ZodNumber; bottlenecks: z.ZodArray<z.ZodString>; resourceUtilization: z.ZodRecord<z.ZodString, z.ZodNumber>; }, z.core.$strip>; }, z.core.$strip>; blockingIssues: z.ZodArray<z.ZodObject<{ issue: z.ZodString; severity: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; category: z.ZodEnum<{ test: "test"; performance: "performance"; dependencies: "dependencies"; security: "security"; configuration: "configuration"; }>; resolution: z.ZodOptional<z.ZodString>; estimatedEffort: z.ZodOptional<z.ZodString>; }, z.core.$strip>>; deploymentStrategy: z.ZodObject<{ type: z.ZodEnum<{ blue_green: "blue_green"; rolling: "rolling"; canary: "canary"; recreate: "recreate"; }>; rollbackPlan: z.ZodString; monitoringPlan: z.ZodString; estimatedDowntime: z.ZodOptional<z.ZodString>; }, z.core.$strip>; complianceChecks: z.ZodObject<{ adrCompliance: z.ZodNumber; regulatoryCompliance: z.ZodArray<z.ZodString>; auditTrail: z.ZodArray<z.ZodString>; }, z.core.$strip>; }, z.core.$strip>; }, z.core.$strip>; export declare const MemoryEntitySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"architectural_decision">; decisionData: z.ZodObject<{ status: z.ZodEnum<{ proposed: "proposed"; accepted: "accepted"; deprecated: "deprecated"; superseded: "superseded"; }>; context: z.ZodString; decision: z.ZodString; consequences: z.ZodObject<{ positive: z.ZodArray<z.ZodString>; negative: z.ZodArray<z.ZodString>; risks: z.ZodArray<z.ZodString>; }, z.core.$strip>; alternatives: z.ZodArray<z.ZodObject<{ name: z.ZodString; description: z.ZodString; tradeoffs: z.ZodString; }, z.core.$strip>>; implementationStatus: z.ZodEnum<{ completed: "completed"; in_progress: "in_progress"; not_started: "not_started"; on_hold: "on_hold"; }>; implementationTasks: z.ZodArray<z.ZodString>; reviewHistory: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; reviewer: z.ZodString; decision: z.ZodEnum<{ approve: "approve"; reject: "reject"; revise: "revise"; }>; comments: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; }, z.core.$strip>, z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"code_component">; componentData: z.ZodObject<{ filePath: z.ZodString; componentType: z.ZodEnum<{ function: "function"; configuration: "configuration"; class: "class"; module: "module"; interface: "interface"; }>; language: z.ZodString; size: z.ZodObject<{ lines: z.ZodNumber; complexity: z.ZodNumber; dependencies: z.ZodNumber; }, z.core.$strip>; qualityMetrics: z.ZodObject<{ maintainability: z.ZodNumber; testCoverage: z.ZodNumber; performance: z.ZodNumber; security: z.ZodNumber; }, z.core.$strip>; architecturalRole: z.ZodString; businessValue: z.ZodString; technicalDebt: z.ZodArray<z.ZodObject<{ type: z.ZodString; severity: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; description: z.ZodString; estimatedEffort: z.ZodString; }, z.core.$strip>>; dependencies: z.ZodArray<z.ZodString>; publicInterface: z.ZodArray<z.ZodString>; changeFrequency: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; riskProfile: z.ZodObject<{ technicalRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; businessRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; changeRisk: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; }>; mitigationStrategies: z.ZodArray<z.ZodString>; }, z.core.$strip>; }, z.core.$strip>; }, z.core.$strip>, z.ZodObject<{ id: z.ZodString; created: z.ZodString; lastModified: z.ZodString; version: z.ZodNumber; confidence: z.ZodNumber; relevance: z.ZodNumber; title: z.ZodString; description: z.ZodString; tags: z.ZodArray<z.ZodString>; relationships: z.ZodArray<z.ZodObject<{ targetId: z.ZodString; type: z.ZodEnum<{ implements: "implements"; depends_on: "depends_on"; conflicts_with: "conflicts_with"; supersedes: "supersedes"; relates_to: "relates_to"; influences: "influences"; originated_from: "originated_from"; impacts: "impacts"; constrains: "constrains"; addresses: "addresses"; occurred_in: "occurred_in"; validates: "validates"; complies_with: "complies_with"; detects: "detects"; mitigates: "mitigates"; }>; strength: z.ZodNumber; context: z.ZodOptional<z.ZodString>; created: z.ZodString; }, z.core.$strip>>; context: z.ZodObject<{ projectPhase: z.ZodOptional<z.ZodString>; businessDomain: z.ZodOptional<z.ZodString>; technicalStack: z.ZodArray<z.ZodString>; environmentalFactors: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; }, z.core.$strip>; accessPattern: z.ZodObject<{ lastAccessed: z.ZodString; accessCount: z.ZodNumber; accessContext: z.ZodArray<z.ZodString>; }, z.core.$strip>; evolution: z.ZodObject<{ origin: z.ZodEnum<{ inferred: "inferred"; created: "created"; discovered: "discovered"; imported: "imported"; }>; transformations: z.ZodArray<z.ZodObject<{ timestamp: z.ZodString; type: z.ZodString; description: z.ZodString; agent: z.ZodString; }, z.core.$strip>>; }, z.core.$strip>; validation: z.ZodObject<{ isVerified: z.ZodBoolean; verificationMethod: z.ZodOptional<z.ZodString>; verificationTimestamp: z.ZodOptional<z.ZodString>; conflictResolution: z.ZodOptional<z.ZodString>; }, z.core.$strip>; type: z.ZodLiteral<"business_requirement">; requirementData: z.ZodObject<{ priority: z.ZodEnum<{ medium: "medium"; low: "low"; high: "high"; critical: "critical"; }>; businessValue: z.ZodString; acceptanceCriteria: z.ZodArray<z.ZodString>; stakeholders: z.ZodArray<z.ZodString>; constraints: z.ZodArray<z.ZodString>; satisfactionLevel: z.ZodNumber; implementationApproach: z.ZodOptional<z.ZodString>; riskFactors: z.ZodArray<z.ZodObject<{ risk: z.ZodString; impact: z.ZodEnum<{ medium: "medium"; low: "low";