feat: implement CI (Continuous Intelligence) autonomous engineering harness
Implements the full PRD for CI - a fully autonomous AI-driven software engineering harness derived from Learnship's architecture. Core components: - CI Orchestrator agent with autonomous pipeline (SPECIFY → CLARIFY → RESEARCH → PLAN → EXECUTE → VERIFY → COMPLETE) - Decision Engine with confidence thresholds (high/medium/low) - Clarify Phase with question budget and default acceptance - Escalation Protocol with timeout auto-proceed - Audit Trail system (.ci/audit/) for post-hoc review - Error Recovery with retry, plan revision, and rollback 18 agents (all Learnship agents + Orchestrator): - Autonomous behavioral modifications per PRD §7.1 - Agent registry with factory pattern 11 CLI commands: - ci init, ci run, ci quick, ci debug, ci verify - ci review, ci status, ci audit, ci clarify - ci rollback, ci ship 4-layer verification system: - Structural, Behavioral, Security, Code Quality 3 autonomy levels: full, supervised, guided Compatible with Learnship artifact schemas (.planning/)
This commit is contained in:
@@ -0,0 +1,105 @@
|
||||
export type AutonomyLevel = "full" | "supervised" | "guided";
|
||||
|
||||
export type ModelProfile = "quality" | "speed" | "balanced";
|
||||
|
||||
export type BranchingStrategy = "phase" | "feature" | "trunk";
|
||||
|
||||
export type PhaseName = "research" | "plan" | "execute" | "verify" | "complete";
|
||||
|
||||
export type AgentName =
|
||||
| "orchestrator"
|
||||
| "planner"
|
||||
| "executor"
|
||||
| "verifier"
|
||||
| "researcher"
|
||||
| "phase-researcher"
|
||||
| "challenger"
|
||||
| "security-auditor"
|
||||
| "debugger"
|
||||
| "doc-writer"
|
||||
| "doc-verifier"
|
||||
| "code-reviewer"
|
||||
| "ideation-agent"
|
||||
| "roadmapper"
|
||||
| "plan-checker"
|
||||
| "project-researcher"
|
||||
| "research-synthesizer"
|
||||
| "solution-writer";
|
||||
|
||||
export interface AutonomyConfig {
|
||||
level: AutonomyLevel;
|
||||
escalation_hooks: string[];
|
||||
clarify_budget: number;
|
||||
decision_confidence_threshold: number;
|
||||
max_revision_iterations: number;
|
||||
max_verification_retries: number;
|
||||
escalation_timeout_ms: number;
|
||||
}
|
||||
|
||||
export interface ParallelizationConfig {
|
||||
enabled: boolean;
|
||||
max_concurrent_agents: number;
|
||||
min_plans_for_parallel: number;
|
||||
}
|
||||
|
||||
export interface VerificationConfig {
|
||||
automated_only: boolean;
|
||||
escalate_visual: boolean;
|
||||
escalate_external_integration: boolean;
|
||||
test_first: boolean;
|
||||
}
|
||||
|
||||
export interface SecurityConfig {
|
||||
auto_accept_low_severity: boolean;
|
||||
auto_mitigate_medium_severity: boolean;
|
||||
escalate_high_severity: boolean;
|
||||
}
|
||||
|
||||
export interface GitConfig {
|
||||
branching_strategy: BranchingStrategy;
|
||||
auto_commit: boolean;
|
||||
auto_push: boolean;
|
||||
}
|
||||
|
||||
export interface CIConfig {
|
||||
autonomy: AutonomyConfig;
|
||||
model_profile: ModelProfile;
|
||||
parallelization: ParallelizationConfig;
|
||||
verification: VerificationConfig;
|
||||
security: SecurityConfig;
|
||||
git: GitConfig;
|
||||
}
|
||||
|
||||
export const DEFAULT_CI_CONFIG: CIConfig = {
|
||||
autonomy: {
|
||||
level: "full",
|
||||
escalation_hooks: ["deploy", "delete_data", "merge_to_main"],
|
||||
clarify_budget: 10,
|
||||
decision_confidence_threshold: 0.6,
|
||||
max_revision_iterations: 3,
|
||||
max_verification_retries: 2,
|
||||
escalation_timeout_ms: 300000,
|
||||
},
|
||||
model_profile: "quality",
|
||||
parallelization: {
|
||||
enabled: true,
|
||||
max_concurrent_agents: 5,
|
||||
min_plans_for_parallel: 2,
|
||||
},
|
||||
verification: {
|
||||
automated_only: true,
|
||||
escalate_visual: true,
|
||||
escalate_external_integration: true,
|
||||
test_first: false,
|
||||
},
|
||||
security: {
|
||||
auto_accept_low_severity: true,
|
||||
auto_mitigate_medium_severity: true,
|
||||
escalate_high_severity: true,
|
||||
},
|
||||
git: {
|
||||
branching_strategy: "phase",
|
||||
auto_commit: true,
|
||||
auto_push: false,
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user