refactor: remove orchestration layer (#45)
* refactor: remove orchestration layer and simplify CLI Remove the complex orchestration layer including checkpoint management, rollback/recovery commands, and session management commands. This consolidates the execution logic directly in shannon.ts for a simpler fire-and-forget execution model. Changes: - Remove checkpoint-manager.ts and rollback functionality - Remove command-handler.ts and cli/prompts.ts - Simplify session-manager.ts to just agent definitions - Consolidate orchestration logic in shannon.ts - Update CLAUDE.md documentation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * refactor: move session lock logic to shannon.ts, simplify session-manager - Reduce session-manager.ts to only AGENTS, AGENT_ORDER, getParallelGroups() - Move Session interface and lock file functions to shannon.ts - Simplify Session to only: id, webUrl, repoPath, status, startedAt - Remove unused types/session.ts Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * refactor: use crypto.randomUUID() for session ID generation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -30,22 +30,12 @@ export class Timer {
|
||||
}
|
||||
}
|
||||
|
||||
interface TimingResultsPhases {
|
||||
[key: string]: number;
|
||||
}
|
||||
|
||||
interface TimingResultsCommands {
|
||||
[key: string]: number;
|
||||
}
|
||||
|
||||
interface TimingResultsAgents {
|
||||
[key: string]: number;
|
||||
}
|
||||
|
||||
interface TimingResults {
|
||||
total: Timer | null;
|
||||
phases: TimingResultsPhases;
|
||||
commands: TimingResultsCommands;
|
||||
agents: TimingResultsAgents;
|
||||
}
|
||||
|
||||
@@ -61,8 +51,6 @@ interface CostResults {
|
||||
// Global timing and cost tracker
|
||||
export const timingResults: TimingResults = {
|
||||
total: null,
|
||||
phases: {},
|
||||
commands: {},
|
||||
agents: {},
|
||||
};
|
||||
|
||||
@@ -87,44 +75,6 @@ export const displayTimingSummary = (): void => {
|
||||
console.log(chalk.cyan(`📊 Total Execution Time: ${formatDuration(totalDuration)}`));
|
||||
console.log();
|
||||
|
||||
// Phase breakdown
|
||||
if (Object.keys(timingResults.phases).length > 0) {
|
||||
console.log(chalk.yellow.bold('🔍 Phase Breakdown:'));
|
||||
let phaseTotal = 0;
|
||||
for (const [phase, duration] of Object.entries(timingResults.phases)) {
|
||||
const percentage = ((duration / totalDuration) * 100).toFixed(1);
|
||||
console.log(
|
||||
chalk.yellow(` ${phase.padEnd(20)} ${formatDuration(duration).padStart(8)} (${percentage}%)`)
|
||||
);
|
||||
phaseTotal += duration;
|
||||
}
|
||||
console.log(
|
||||
chalk.gray(
|
||||
` ${'Phases Total'.padEnd(20)} ${formatDuration(phaseTotal).padStart(8)} (${((phaseTotal / totalDuration) * 100).toFixed(1)}%)`
|
||||
)
|
||||
);
|
||||
console.log();
|
||||
}
|
||||
|
||||
// Command breakdown
|
||||
if (Object.keys(timingResults.commands).length > 0) {
|
||||
console.log(chalk.blue.bold('🖥️ Command Breakdown:'));
|
||||
let commandTotal = 0;
|
||||
for (const [command, duration] of Object.entries(timingResults.commands)) {
|
||||
const percentage = ((duration / totalDuration) * 100).toFixed(1);
|
||||
console.log(
|
||||
chalk.blue(` ${command.padEnd(20)} ${formatDuration(duration).padStart(8)} (${percentage}%)`)
|
||||
);
|
||||
commandTotal += duration;
|
||||
}
|
||||
console.log(
|
||||
chalk.gray(
|
||||
` ${'Commands Total'.padEnd(20)} ${formatDuration(commandTotal).padStart(8)} (${((commandTotal / totalDuration) * 100).toFixed(1)}%)`
|
||||
)
|
||||
);
|
||||
console.log();
|
||||
}
|
||||
|
||||
// Agent breakdown
|
||||
if (Object.keys(timingResults.agents).length > 0) {
|
||||
console.log(chalk.magenta.bold('🤖 Agent Breakdown:'));
|
||||
|
||||
Reference in New Issue
Block a user