mcp-adr-analysis-server
Version:
MCP server for analyzing Architectural Decision Records and project architecture
224 lines • 6.9 kB
TypeScript
/**
* TypeScript interfaces for MCP tool arguments
* Defines proper types for all tool methods to replace Record<string, unknown>
*/
export interface GetWorkflowGuidanceArgs {
goal: string;
projectContext: string;
availableAssets?: string[];
timeframe?: string;
primaryConcerns?: string[];
}
export interface GetArchitecturalContextArgs {
projectPath?: string;
filePath?: string;
includeCompliance?: boolean;
analysisDepth?: string;
recursiveDepth?: string;
technologyFocus?: string[];
analysisScope?: string[];
includeEnvironment?: boolean;
}
export interface GetImplementationGuidanceArgs {
adrsToImplement: string[];
technologyStack?: string[];
teamContext?: string;
focusAreas?: string[];
}
export interface GetDevelopmentGuidanceArgs {
developmentPhase?: string;
adrsToImplement?: string[];
technologyStack?: string[];
currentProgress?: string;
teamContext?: {
size?: string;
experienceLevel?: string;
};
timeline?: string;
focusAreas?: string[];
}
export interface DecisionData {
title: string;
context: string;
decision: string;
consequences: string;
alternatives?: string[];
evidence?: string[];
}
export interface GenerateAdrFromDecisionArgs {
decisionData: DecisionData;
templateFormat?: 'custom' | 'nygard' | 'madr';
existingAdrs?: string[];
adrDirectory?: string;
}
export interface ActionArgs {
action: string;
details: string;
impact?: 'low' | 'medium' | 'high' | 'critical';
}
export interface RuleDefinition {
id: string;
name: string;
description: string;
pattern: string;
severity: string;
message: string;
}
export interface ValidateRulesArgs {
filePath?: string;
fileContent?: string;
fileName?: string;
rules: RuleDefinition[];
validationType?: 'file' | 'function' | 'component' | 'module';
reportFormat?: 'detailed' | 'summary' | 'json';
projectPath?: string;
findingThreshold?: string;
}
export interface CreateRuleSetArgs {
name: string;
description?: string;
adrRules?: any[];
patternRules?: any[];
rules?: any[];
outputFormat?: 'json' | 'yaml' | 'both';
author?: string;
}
export interface ProjectContext {
projectPath: string;
adrDirectory: string;
todoPath: string;
projectType?: string;
hasADRs?: boolean;
hasTODO?: boolean;
}
export interface FailureDetails {
failureType: 'build_failure' | 'test_failure' | 'deployment_failure' | 'runtime_error' | 'performance_issue' | 'security_issue' | 'other';
failureDetails: {
errorMessage: string;
timestamp?: string;
environment?: string;
command?: string;
exitCode?: number;
stackTrace?: string;
logOutput?: string;
affectedFiles?: string[];
};
context?: {
impact?: 'low' | 'medium' | 'high' | 'critical';
frequency?: string;
recentChanges?: string;
reproducible?: boolean;
};
}
export interface TodoManagementV2Args {
adrDirectory: string;
operation: 'full_workflow' | 'generate_test_plan' | 'analyze_failure';
todoPath: string;
projectPath?: string;
failure?: FailureDetails;
}
export interface Constraints {
maxSteps?: number;
timeLimit?: string;
excludeTools?: string[];
prioritizeSpeed?: boolean;
}
export interface ToolChainOrchestratorArgs {
projectContext: ProjectContext;
operation: 'generate_plan' | 'analyze_intent' | 'suggest_tools' | 'validate_plan' | 'reality_check' | 'session_guidance';
userRequest: string;
constraints?: Constraints;
customInstructions?: string[];
}
export interface ReadFileArgs {
filePath: string;
encoding?: string;
}
export interface WriteFileArgs {
filePath: string;
content: string;
encoding?: string;
}
export interface ListDirectoryArgs {
directoryPath: string;
recursive?: boolean;
}
export interface SmartGitPushArgs {
commitMessage?: string;
branch?: string;
force?: boolean;
}
export interface DeploymentReadinessArgs {
environment?: string;
checkType?: 'basic' | 'full' | 'security';
}
export interface EmptyArgs {
}
export interface AnalyzeContentSecurityArgs {
content: string;
contentType?: 'code' | 'documentation' | 'configuration' | 'logs' | 'general';
userDefinedPatterns?: string[];
knowledgeEnhancement?: boolean;
enhancedMode?: boolean;
enableMemoryIntegration?: boolean;
enableTreeSitterAnalysis?: boolean;
}
export interface DetectedItem {
type: string;
category?: string;
content: string;
startPosition: number;
endPosition: number;
confidence?: number;
reasoning?: string;
severity: string;
suggestedMask?: string;
}
export interface GenerateContentMaskingArgs {
content: string;
detectedItems: DetectedItem[];
contentType?: 'code' | 'documentation' | 'configuration' | 'general';
}
export interface ConfigureCustomPatternsArgs {
projectPath: string;
existingPatterns?: string[];
}
export interface ApplyBasicContentMaskingArgs {
content: string;
maskingStrategy?: 'full' | 'partial' | 'placeholder';
}
export interface ValidateContentMaskingArgs {
originalContent: string;
maskedContent: string;
}
export interface AnalyzeProjectEcosystemArgs {
projectPath?: string;
includePatterns?: string[];
enhancedMode?: boolean;
knowledgeEnhancement?: boolean;
learningEnabled?: boolean;
technologyFocus?: string[];
analysisDepth?: string;
includeEnvironment?: boolean;
recursiveDepth?: string;
analysisScope?: string[];
}
export type { ArchitecturalContext, ArchitecturalDomain, KnowledgeGenerationConfig, PromptObject, } from './knowledge-generation.js';
export type { ReflexionConfig, MemoryQuery } from './reflexion-framework.js';
export type GenerateArchitecturalKnowledgeFunction = (context: import('./knowledge-generation.js').ArchitecturalContext, config?: import('./knowledge-generation.js').KnowledgeGenerationConfig) => Promise<{
prompt: string;
instructions: string;
context: any;
}>;
export type ExecuteWithReflexionFunction = (basePrompt: import('./knowledge-generation.js').PromptObject, config?: Partial<import('./reflexion-framework.js').ReflexionConfig>) => Promise<{
prompt: string;
instructions: string;
context: any;
}>;
export type RetrieveRelevantMemoriesFunction = (taskType: string, context: any, query?: Partial<import('./reflexion-framework.js').MemoryQuery>) => Promise<{
prompt: string;
instructions: string;
context: any;
}>;
export type CreateToolReflexionConfigFunction = (toolName: string, customConfig?: Partial<import('./reflexion-framework.js').ReflexionConfig>) => import('./reflexion-framework.js').ReflexionConfig;
//# sourceMappingURL=tool-arguments.d.ts.map