/** * SLOP Agent Types * * Types for SLOP-native multi-agent communication */ export interface SLOPInfo { name: string; version: string; description: string; tools: SLOPTool[]; capabilities?: string[]; status?: 'ready' | 'busy' | 'error'; } export interface SLOPTool { name: string; description: string; parameters?: Record; } export interface SLOPParameter { type: 'string' | 'number' | 'boolean' | 'object' | 'array'; description: string; required?: boolean; default?: unknown; } export interface SLOPToolCall { tool: string; arguments: Record; } export interface SLOPToolResult { result?: unknown; error?: string; } export interface SLOPMemoryEntry { key: string; value: unknown; timestamp: number; agent?: string; } export interface AgentMessage { id: string; from: string; to: string; type: 'request' | 'response' | 'broadcast'; tool?: string; arguments?: Record; result?: unknown; error?: string; timestamp: number; } export interface Finding { id: string; type: string; severity: 'critical' | 'high' | 'medium' | 'low'; title: string; description: string; file?: string; line?: number; package?: string; version?: string; cve?: string; cwe?: string; rule?: string; scanner?: string; message?: string; metadata?: Record; } export interface ExternalFinding { id?: string; type: string; severity?: 'critical' | 'high' | 'medium' | 'low'; title?: string; description?: string; message?: string; file?: string; line?: number; package?: string; version?: string; cve?: string; cwe?: string; rule?: string; scanner?: string; metadata?: Record; } export declare function normalizeFinding(f: ExternalFinding): Finding; export interface TriageResult { finding: Finding; validated: boolean; adjustedSeverity?: 'critical' | 'high' | 'medium' | 'low'; falsePositive: boolean; reason: string; recommendFix: boolean; confidence: number; } export interface FixSuggestion { finding: Finding; strategy: 'version-bump' | 'code-change' | 'config-change' | 'manual'; description: string; diff?: string; commands?: string[]; confidence: number; } export type FixStrategy = 'version-bump' | 'code-change' | 'config-change' | 'env-var' | 'remove' | 'manual'; export interface FixResult { findingId: string; finding: Finding; fixable: boolean; strategy: FixStrategy; package?: string; currentVersion?: string; fixedVersion?: string; description: string; explanation: string; commands: string[]; diff?: string; confidence: number; breakingChangeRisk: 'none' | 'low' | 'medium' | 'high'; testRequired: boolean; autoFixSafe: boolean; } export interface FixBatchResult { total: number; fixable: number; unfixable: number; fixes: FixResult[]; summary: { versionBumps: number; codeChanges: number; configChanges: number; manual: number; }; allCommands: string[]; } export interface ApplyFixResult { findingId: string; success: boolean; applied: boolean; output?: string; error?: string; } export interface PRResult { findingId?: string; success: boolean; prUrl?: string; prNumber?: number; branch?: string; error?: string; } export interface SLOPAgentConfig { id: string; name: string; port: number; description: string; peers?: { id: string; url: string; }[]; coordinatorUrl?: string; } export interface PipelineStage { agent: string; tool: string; dependsOn?: string[]; } export interface PipelineResult { stages: { agent: string; tool: string; result: unknown; duration: number; }[]; totalDuration: number; success: boolean; error?: string; }