"use strict";
// SPDX-License-Identifier: AGPL-3.0-or-later
// Copyright (C) 2024-2026 Gracker (Chris)
// This file is part of SmartPerfetto. See LICENSE for details.
Object.defineProperty(exports, "__esModule", { value: true });
exports.CircuitState = exports.StateEventType = exports.AgentPhase = void 0;
// =============================================================================
// State Machine Types (新架构)
// =============================================================================
/**
 * Agent execution phase enum
 *
 * Provides type-safe state values for the agent state machine.
 * @see STATE_TRANSITIONS in stateMachine.ts for valid transitions
 */
var AgentPhase;
(function (AgentPhase) {
    AgentPhase["IDLE"] = "idle";
    AgentPhase["PLANNING"] = "planning";
    AgentPhase["EXECUTING"] = "executing";
    AgentPhase["EVALUATING"] = "evaluating";
    AgentPhase["REFINING"] = "refining";
    AgentPhase["AWAITING_USER"] = "awaiting_user";
    AgentPhase["COMPLETED"] = "completed";
    AgentPhase["FAILED"] = "failed";
})(AgentPhase || (exports.AgentPhase = AgentPhase = {}));
/**
 * State machine event type enum
 *
 * Provides type-safe event names for state transitions.
 */
var StateEventType;
(function (StateEventType) {
    StateEventType["START_ANALYSIS"] = "START_ANALYSIS";
    StateEventType["INTENT_UNDERSTOOD"] = "INTENT_UNDERSTOOD";
    StateEventType["PLAN_CREATED"] = "PLAN_CREATED";
    StateEventType["STAGE_STARTED"] = "STAGE_STARTED";
    StateEventType["STAGE_COMPLETED"] = "STAGE_COMPLETED";
    StateEventType["EVALUATION_COMPLETE"] = "EVALUATION_COMPLETE";
    StateEventType["NEEDS_REFINEMENT"] = "NEEDS_REFINEMENT";
    StateEventType["CIRCUIT_TRIPPED"] = "CIRCUIT_TRIPPED";
    StateEventType["USER_RESPONDED"] = "USER_RESPONDED";
    StateEventType["ANALYSIS_COMPLETE"] = "ANALYSIS_COMPLETE";
    StateEventType["ERROR_OCCURRED"] = "ERROR_OCCURRED";
})(StateEventType || (exports.StateEventType = StateEventType = {}));
// =============================================================================
// Circuit Breaker Types (新架构)
// =============================================================================
/**
 * Circuit breaker state enum
 *
 * Provides type-safe state values for the circuit breaker pattern.
 * - CLOSED: Normal operation, requests pass through
 * - OPEN: Circuit tripped, requests are blocked
 * - HALF_OPEN: Testing recovery, limited requests allowed
 */
var CircuitState;
(function (CircuitState) {
    CircuitState["CLOSED"] = "closed";
    CircuitState["OPEN"] = "open";
    CircuitState["HALF_OPEN"] = "half-open";
})(CircuitState || (exports.CircuitState = CircuitState = {}));
//# sourceMappingURL=types.js.map