// @generated by protoc-gen-es v2.11.0 with parameter "target=js+dts"
// @generated from file risk.proto (package risk, syntax proto3)
/* eslint-disable */

import type { GenEnum, GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
import type { Message } from "@bufbuild/protobuf";

/**
 * Describes the file risk.proto.
 */
export declare const file_risk: GenFile;

/**
 * @generated from message risk.StreamCircuitBreakerStatusRequest
 */
export declare type StreamCircuitBreakerStatusRequest = Message<"risk.StreamCircuitBreakerStatusRequest"> & {
  /**
   * Filter by symbol (all if not specified)
   *
   * @generated from field: optional string symbol = 1;
   */
  symbol?: string;

  /**
   * 0 = server default (2s)
   *
   * @generated from field: uint32 interval_seconds = 2;
   */
  intervalSeconds: number;
};

/**
 * Describes the message risk.StreamCircuitBreakerStatusRequest.
 * Use `create(StreamCircuitBreakerStatusRequestSchema)` to create a new message.
 */
export declare const StreamCircuitBreakerStatusRequestSchema: GenMessage<StreamCircuitBreakerStatusRequest>;

/**
 * @generated from message risk.StreamRiskMetricsRequest
 */
export declare type StreamRiskMetricsRequest = Message<"risk.StreamRiskMetricsRequest"> & {
  /**
   * Portfolio identifier (default if not specified)
   *
   * @generated from field: optional string portfolio_id = 1;
   */
  portfolioId?: string;

  /**
   * 0 = server default (3s)
   *
   * @generated from field: uint32 interval_seconds = 2;
   */
  intervalSeconds: number;
};

/**
 * Describes the message risk.StreamRiskMetricsRequest.
 * Use `create(StreamRiskMetricsRequestSchema)` to create a new message.
 */
export declare const StreamRiskMetricsRequestSchema: GenMessage<StreamRiskMetricsRequest>;

/**
 * Request to calculate portfolio VaR
 *
 * @generated from message risk.GetVaRRequest
 */
export declare type GetVaRRequest = Message<"risk.GetVaRRequest"> & {
  /**
   * Symbols to include in VaR calculation (empty = all positions)
   *
   * @generated from field: repeated string symbols = 1;
   */
  symbols: string[];

  /**
   * Confidence level (e.g., 0.95 for 95% VaR)
   *
   * @generated from field: double confidence_level = 2;
   */
  confidenceLevel: number;

  /**
   * Historical data period for calculation
   *
   * @generated from field: int32 lookback_days = 3;
   */
  lookbackDays: number;

  /**
   * VaR calculation method (historical, parametric, Monte Carlo)
   *
   * @generated from field: risk.VaRMethod method = 4;
   */
  method: VaRMethod;
};

/**
 * Describes the message risk.GetVaRRequest.
 * Use `create(GetVaRRequestSchema)` to create a new message.
 */
export declare const GetVaRRequestSchema: GenMessage<GetVaRRequest>;

/**
 * Response containing VaR calculation results
 *
 * @generated from message risk.GetVaRResponse
 */
export declare type GetVaRResponse = Message<"risk.GetVaRResponse"> & {
  /**
   * Total portfolio VaR value
   *
   * @generated from field: double portfolio_var = 1;
   */
  portfolioVar: number;

  /**
   * Individual symbol VaR contributions
   *
   * @generated from field: repeated risk.SymbolVaR symbol_vars = 2;
   */
  symbolVars: SymbolVaR[];

  /**
   * Confidence level used in calculation
   *
   * @generated from field: double confidence_level = 3;
   */
  confidenceLevel: number;

  /**
   * Historical period used
   *
   * @generated from field: int32 lookback_days = 4;
   */
  lookbackDays: number;

  /**
   * Calculation method used
   *
   * @generated from field: risk.VaRMethod method = 5;
   */
  method: VaRMethod;

  /**
   * Calculation timestamp (nanoseconds)
   *
   * @generated from field: int64 calculated_at = 6;
   */
  calculatedAt: bigint;
};

/**
 * Describes the message risk.GetVaRResponse.
 * Use `create(GetVaRResponseSchema)` to create a new message.
 */
export declare const GetVaRResponseSchema: GenMessage<GetVaRResponse>;

/**
 * Request to stream real-time VaR updates
 *
 * @generated from message risk.StreamVaRRequest
 */
export declare type StreamVaRRequest = Message<"risk.StreamVaRRequest"> & {
  /**
   * Confidence level for VaR calculation
   *
   * @generated from field: double confidence_level = 1;
   */
  confidenceLevel: number;

  /**
   * How often to send updates
   *
   * @generated from field: int32 update_frequency_seconds = 2;
   */
  updateFrequencySeconds: number;
};

/**
 * Describes the message risk.StreamVaRRequest.
 * Use `create(StreamVaRRequestSchema)` to create a new message.
 */
export declare const StreamVaRRequestSchema: GenMessage<StreamVaRRequest>;

/**
 * VaR contribution for a specific symbol
 *
 * @generated from message risk.SymbolVaR
 */
export declare type SymbolVaR = Message<"risk.SymbolVaR"> & {
  /**
   * Trading symbol
   *
   * @generated from field: string symbol = 1;
   */
  symbol: string;

  /**
   * VaR value for this symbol
   *
   * @generated from field: double var_value = 2;
   */
  varValue: number;

  /**
   * Current position size
   *
   * @generated from field: double position_size = 3;
   */
  positionSize: number;

  /**
   * Percentage contribution to total portfolio VaR
   *
   * @generated from field: double contribution_pct = 4;
   */
  contributionPct: number;
};

/**
 * Describes the message risk.SymbolVaR.
 * Use `create(SymbolVaRSchema)` to create a new message.
 */
export declare const SymbolVaRSchema: GenMessage<SymbolVaR>;

/**
 * Request for position risk analysis
 *
 * @generated from message risk.GetPositionRiskRequest
 */
export declare type GetPositionRiskRequest = Message<"risk.GetPositionRiskRequest"> & {
  /**
   * Filter by symbol (all symbols if not specified)
   *
   * @generated from field: optional string symbol = 1;
   */
  symbol?: string;

  /**
   * Filter by account (all accounts if not specified)
   *
   * @generated from field: optional string account_id = 2;
   */
  accountId?: string;
};

/**
 * Describes the message risk.GetPositionRiskRequest.
 * Use `create(GetPositionRiskRequestSchema)` to create a new message.
 */
export declare const GetPositionRiskRequestSchema: GenMessage<GetPositionRiskRequest>;

/**
 * Response containing position risk analysis
 *
 * @generated from message risk.GetPositionRiskResponse
 */
export declare type GetPositionRiskResponse = Message<"risk.GetPositionRiskResponse"> & {
  /**
   * Risk analysis for each position
   *
   * @generated from field: repeated risk.PositionRisk position_risks = 1;
   */
  positionRisks: PositionRisk[];

  /**
   * Overall portfolio risk score (0-100)
   *
   * @generated from field: double portfolio_risk_score = 2;
   */
  portfolioRiskScore: number;
};

/**
 * Describes the message risk.GetPositionRiskResponse.
 * Use `create(GetPositionRiskResponseSchema)` to create a new message.
 */
export declare const GetPositionRiskResponseSchema: GenMessage<GetPositionRiskResponse>;

/**
 * Request to validate order against risk limits
 *
 * @generated from message risk.ValidateOrderRequest
 */
export declare type ValidateOrderRequest = Message<"risk.ValidateOrderRequest"> & {
  /**
   * Trading symbol
   *
   * @generated from field: string symbol = 1;
   */
  symbol: string;

  /**
   * Order quantity
   *
   * @generated from field: double quantity = 2;
   */
  quantity: number;

  /**
   * Order price
   *
   * @generated from field: double price = 3;
   */
  price: number;

  /**
   * Buy or sell
   *
   * @generated from field: string side = 4;
   */
  side: string;

  /**
   * Trading account
   *
   * @generated from field: string account_id = 5;
   */
  accountId: string;
};

/**
 * Describes the message risk.ValidateOrderRequest.
 * Use `create(ValidateOrderRequestSchema)` to create a new message.
 */
export declare const ValidateOrderRequestSchema: GenMessage<ValidateOrderRequest>;

/**
 * Response containing order validation results
 *
 * @generated from message risk.ValidateOrderResponse
 */
export declare type ValidateOrderResponse = Message<"risk.ValidateOrderResponse"> & {
  /**
   * True if order passes all risk checks
   *
   * @generated from field: bool is_valid = 1;
   */
  isValid: boolean;

  /**
   * List of risk violations (if any)
   *
   * @generated from field: repeated risk.RiskViolation violations = 2;
   */
  violations: RiskViolation[];

  /**
   * Risk assessment for this order
   *
   * @generated from field: risk.RiskScore risk_score = 3;
   */
  riskScore?: RiskScore;

  /**
   * Human-readable validation message
   *
   * @generated from field: string message = 4;
   */
  message: string;
};

/**
 * Describes the message risk.ValidateOrderResponse.
 * Use `create(ValidateOrderResponseSchema)` to create a new message.
 */
export declare const ValidateOrderResponseSchema: GenMessage<ValidateOrderResponse>;

/**
 * Request for comprehensive risk metrics
 *
 * @generated from message risk.GetRiskMetricsRequest
 */
export declare type GetRiskMetricsRequest = Message<"risk.GetRiskMetricsRequest"> & {
  /**
   * Portfolio identifier (default portfolio if not specified)
   *
   * @generated from field: optional string portfolio_id = 1;
   */
  portfolioId?: string;
};

/**
 * Describes the message risk.GetRiskMetricsRequest.
 * Use `create(GetRiskMetricsRequestSchema)` to create a new message.
 */
export declare const GetRiskMetricsRequestSchema: GenMessage<GetRiskMetricsRequest>;

/**
 * Response containing comprehensive risk metrics
 *
 * @generated from message risk.GetRiskMetricsResponse
 */
export declare type GetRiskMetricsResponse = Message<"risk.GetRiskMetricsResponse"> & {
  /**
   * Complete risk metrics and statistics
   *
   * @generated from field: risk.RiskMetrics metrics = 1;
   */
  metrics?: RiskMetrics;

  /**
   * Metrics calculation timestamp (nanoseconds)
   *
   * @generated from field: int64 calculated_at = 2;
   */
  calculatedAt: bigint;
};

/**
 * Describes the message risk.GetRiskMetricsResponse.
 * Use `create(GetRiskMetricsResponseSchema)` to create a new message.
 */
export declare const GetRiskMetricsResponseSchema: GenMessage<GetRiskMetricsResponse>;

/**
 * Request to stream real-time risk alerts
 *
 * @generated from message risk.StreamRiskAlertsRequest
 */
export declare type StreamRiskAlertsRequest = Message<"risk.StreamRiskAlertsRequest"> & {
  /**
   * Minimum alert severity to receive
   *
   * @generated from field: risk.RiskAlertSeverity min_severity = 1;
   */
  minSeverity: RiskAlertSeverity;

  /**
   * Types of alerts to receive (empty = all types)
   *
   * @generated from field: repeated risk.RiskAlertType alert_types = 2;
   */
  alertTypes: RiskAlertType[];
};

/**
 * Describes the message risk.StreamRiskAlertsRequest.
 * Use `create(StreamRiskAlertsRequestSchema)` to create a new message.
 */
export declare const StreamRiskAlertsRequestSchema: GenMessage<StreamRiskAlertsRequest>;

/**
 * Request to trigger emergency stop
 *
 * @generated from message risk.EmergencyStopRequest
 */
export declare type EmergencyStopRequest = Message<"risk.EmergencyStopRequest"> & {
  /**
   * Type of emergency stop (all trading, symbol, account, etc.)
   *
   * @generated from field: risk.EmergencyStopType stop_type = 1;
   */
  stopType: EmergencyStopType;

  /**
   * Reason for emergency stop
   *
   * @generated from field: string reason = 2;
   */
  reason: string;

  /**
   * Symbol to stop (for symbol-specific stops)
   *
   * @generated from field: optional string symbol = 3;
   */
  symbol?: string;

  /**
   * Account to stop (for account-specific stops)
   *
   * @generated from field: optional string account_id = 4;
   */
  accountId?: string;
};

/**
 * Describes the message risk.EmergencyStopRequest.
 * Use `create(EmergencyStopRequestSchema)` to create a new message.
 */
export declare const EmergencyStopRequestSchema: GenMessage<EmergencyStopRequest>;

/**
 * Response after emergency stop execution
 *
 * @generated from message risk.EmergencyStopResponse
 */
export declare type EmergencyStopResponse = Message<"risk.EmergencyStopResponse"> & {
  /**
   * True if emergency stop was successful
   *
   * @generated from field: bool success = 1;
   */
  success: boolean;

  /**
   * Status message or error description
   *
   * @generated from field: string message = 2;
   */
  message: string;

  /**
   * Emergency stop timestamp (nanoseconds)
   *
   * @generated from field: int64 timestamp = 3;
   */
  timestamp: bigint;

  /**
   * List of order IDs affected by the stop
   *
   * @generated from field: repeated string affected_orders = 4;
   */
  affectedOrders: string[];
};

/**
 * Describes the message risk.EmergencyStopResponse.
 * Use `create(EmergencyStopResponseSchema)` to create a new message.
 */
export declare const EmergencyStopResponseSchema: GenMessage<EmergencyStopResponse>;

/**
 * Request for circuit breaker status
 *
 * @generated from message risk.GetCircuitBreakerStatusRequest
 */
export declare type GetCircuitBreakerStatusRequest = Message<"risk.GetCircuitBreakerStatusRequest"> & {
  /**
   * Filter by symbol (all symbols if not specified)
   *
   * @generated from field: optional string symbol = 1;
   */
  symbol?: string;
};

/**
 * Describes the message risk.GetCircuitBreakerStatusRequest.
 * Use `create(GetCircuitBreakerStatusRequestSchema)` to create a new message.
 */
export declare const GetCircuitBreakerStatusRequestSchema: GenMessage<GetCircuitBreakerStatusRequest>;

/**
 * Response containing circuit breaker status
 *
 * @generated from message risk.GetCircuitBreakerStatusResponse
 */
export declare type GetCircuitBreakerStatusResponse = Message<"risk.GetCircuitBreakerStatusResponse"> & {
  /**
   * Status of all circuit breakers
   *
   * @generated from field: repeated risk.CircuitBreakerStatus circuit_breakers = 1;
   */
  circuitBreakers: CircuitBreakerStatus[];
};

/**
 * Describes the message risk.GetCircuitBreakerStatusResponse.
 * Use `create(GetCircuitBreakerStatusResponseSchema)` to create a new message.
 */
export declare const GetCircuitBreakerStatusResponseSchema: GenMessage<GetCircuitBreakerStatusResponse>;

/**
 * Risk analysis for a specific position
 *
 * @generated from message risk.PositionRisk
 */
export declare type PositionRisk = Message<"risk.PositionRisk"> & {
  /**
   * Trading symbol
   *
   * @generated from field: string symbol = 1;
   */
  symbol: string;

  /**
   * Current position size
   *
   * @generated from field: double position_size = 2;
   */
  positionSize: number;

  /**
   * Market value of position
   *
   * @generated from field: double market_value = 3;
   */
  marketValue: number;

  /**
   * Contribution to portfolio VaR
   *
   * @generated from field: double var_contribution = 4;
   */
  varContribution: number;

  /**
   * Position concentration risk (0-100)
   *
   * @generated from field: double concentration_risk = 5;
   */
  concentrationRisk: number;

  /**
   * Liquidity risk score (0-100)
   *
   * @generated from field: double liquidity_risk = 6;
   */
  liquidityRisk: number;

  /**
   * Overall risk assessment
   *
   * @generated from field: risk.RiskScore overall_score = 7;
   */
  overallScore?: RiskScore;

  /**
   * Additional risk metrics
   *
   * @generated from field: repeated risk.RiskMetric metrics = 8;
   */
  metrics: RiskMetric[];
};

/**
 * Describes the message risk.PositionRisk.
 * Use `create(PositionRiskSchema)` to create a new message.
 */
export declare const PositionRiskSchema: GenMessage<PositionRisk>;

/**
 * @generated from message risk.RiskViolation
 */
export declare type RiskViolation = Message<"risk.RiskViolation"> & {
  /**
   * @generated from field: risk.RiskViolationType violation_type = 1;
   */
  violationType: RiskViolationType;

  /**
   * @generated from field: string description = 2;
   */
  description: string;

  /**
   * @generated from field: double current_value = 3;
   */
  currentValue: number;

  /**
   * @generated from field: double limit_value = 4;
   */
  limitValue: number;

  /**
   * @generated from field: risk.RiskAlertSeverity severity = 5;
   */
  severity: RiskAlertSeverity;
};

/**
 * Describes the message risk.RiskViolation.
 * Use `create(RiskViolationSchema)` to create a new message.
 */
export declare const RiskViolationSchema: GenMessage<RiskViolation>;

/**
 * @generated from message risk.RiskScore
 */
export declare type RiskScore = Message<"risk.RiskScore"> & {
  /**
   * @generated from field: double overall_score = 1;
   */
  overallScore: number;

  /**
   * @generated from field: double concentration_score = 2;
   */
  concentrationScore: number;

  /**
   * @generated from field: double liquidity_score = 3;
   */
  liquidityScore: number;

  /**
   * @generated from field: double volatility_score = 4;
   */
  volatilityScore: number;

  /**
   * @generated from field: double correlation_score = 5;
   */
  correlationScore: number;

  /**
   * @generated from field: risk.RiskLevel risk_level = 6;
   */
  riskLevel: RiskLevel;
};

/**
 * Describes the message risk.RiskScore.
 * Use `create(RiskScoreSchema)` to create a new message.
 */
export declare const RiskScoreSchema: GenMessage<RiskScore>;

/**
 * @generated from message risk.RiskMetrics
 */
export declare type RiskMetrics = Message<"risk.RiskMetrics"> & {
  /**
   * @generated from field: double portfolio_var_1d = 1;
   */
  portfolioVar1d: number;

  /**
   * @generated from field: double portfolio_var_5d = 2;
   */
  portfolioVar5d: number;

  /**
   * @generated from field: double portfolio_var_30d = 3;
   */
  portfolioVar30d: number;

  /**
   * @generated from field: double max_drawdown = 4;
   */
  maxDrawdown: number;

  /**
   * @generated from field: double current_drawdown = 5;
   */
  currentDrawdown: number;

  /**
   * @generated from field: double sharpe_ratio = 6;
   */
  sharpeRatio: number;

  /**
   * @generated from field: double sortino_ratio = 7;
   */
  sortinoRatio: number;

  /**
   * @generated from field: double beta = 8;
   */
  beta: number;

  /**
   * @generated from field: double alpha = 9;
   */
  alpha: number;

  /**
   * @generated from field: double volatility = 10;
   */
  volatility: number;

  /**
   * @generated from field: repeated risk.PositionRisk position_risks = 11;
   */
  positionRisks: PositionRisk[];
};

/**
 * Describes the message risk.RiskMetrics.
 * Use `create(RiskMetricsSchema)` to create a new message.
 */
export declare const RiskMetricsSchema: GenMessage<RiskMetrics>;

/**
 * @generated from message risk.RiskMetric
 */
export declare type RiskMetric = Message<"risk.RiskMetric"> & {
  /**
   * @generated from field: string name = 1;
   */
  name: string;

  /**
   * @generated from field: double value = 2;
   */
  value: number;

  /**
   * @generated from field: string unit = 3;
   */
  unit: string;

  /**
   * @generated from field: risk.RiskLevel risk_level = 4;
   */
  riskLevel: RiskLevel;
};

/**
 * Describes the message risk.RiskMetric.
 * Use `create(RiskMetricSchema)` to create a new message.
 */
export declare const RiskMetricSchema: GenMessage<RiskMetric>;

/**
 * @generated from message risk.CircuitBreakerStatus
 */
export declare type CircuitBreakerStatus = Message<"risk.CircuitBreakerStatus"> & {
  /**
   * @generated from field: string name = 1;
   */
  name: string;

  /**
   * @generated from field: bool is_triggered = 2;
   */
  isTriggered: boolean;

  /**
   * @generated from field: optional string trigger_reason = 3;
   */
  triggerReason?: string;

  /**
   * @generated from field: optional int64 triggered_at = 4;
   */
  triggeredAt?: bigint;

  /**
   * @generated from field: optional int64 reset_at = 5;
   */
  resetAt?: bigint;

  /**
   * @generated from field: risk.CircuitBreakerType breaker_type = 6;
   */
  breakerType: CircuitBreakerType;
};

/**
 * Describes the message risk.CircuitBreakerStatus.
 * Use `create(CircuitBreakerStatusSchema)` to create a new message.
 */
export declare const CircuitBreakerStatusSchema: GenMessage<CircuitBreakerStatus>;

/**
 * Event Messages
 *
 * @generated from message risk.VaREvent
 */
export declare type VaREvent = Message<"risk.VaREvent"> & {
  /**
   * @generated from field: double portfolio_var = 1;
   */
  portfolioVar: number;

  /**
   * @generated from field: repeated risk.SymbolVaR symbol_vars = 2;
   */
  symbolVars: SymbolVaR[];

  /**
   * @generated from field: risk.VaRChangeType change_type = 3;
   */
  changeType: VaRChangeType;

  /**
   * @generated from field: int64 timestamp = 4;
   */
  timestamp: bigint;
};

/**
 * Describes the message risk.VaREvent.
 * Use `create(VaREventSchema)` to create a new message.
 */
export declare const VaREventSchema: GenMessage<VaREvent>;

/**
 * @generated from message risk.RiskAlertEvent
 */
export declare type RiskAlertEvent = Message<"risk.RiskAlertEvent"> & {
  /**
   * @generated from field: string alert_id = 1;
   */
  alertId: string;

  /**
   * @generated from field: risk.RiskAlertType alert_type = 2;
   */
  alertType: RiskAlertType;

  /**
   * @generated from field: risk.RiskAlertSeverity severity = 3;
   */
  severity: RiskAlertSeverity;

  /**
   * @generated from field: string message = 4;
   */
  message: string;

  /**
   * @generated from field: optional string symbol = 5;
   */
  symbol?: string;

  /**
   * @generated from field: optional string account_id = 6;
   */
  accountId?: string;

  /**
   * @generated from field: map<string, string> metadata = 7;
   */
  metadata: { [key: string]: string };

  /**
   * @generated from field: int64 timestamp = 8;
   */
  timestamp: bigint;
};

/**
 * Describes the message risk.RiskAlertEvent.
 * Use `create(RiskAlertEventSchema)` to create a new message.
 */
export declare const RiskAlertEventSchema: GenMessage<RiskAlertEvent>;

/**
 * VaR calculation methodology
 *
 * @generated from enum risk.VaRMethod
 */
export enum VaRMethod {
  /**
   * Default/unknown method
   *
   * @generated from enum value: VAR_METHOD_UNSPECIFIED = 0;
   */
  VAR_METHOD_UNSPECIFIED = 0,

  /**
   * Historical simulation method
   *
   * @generated from enum value: VAR_METHOD_HISTORICAL = 1;
   */
  VAR_METHOD_HISTORICAL = 1,

  /**
   * Parametric (variance-covariance) method
   *
   * @generated from enum value: VAR_METHOD_PARAMETRIC = 2;
   */
  VAR_METHOD_PARAMETRIC = 2,

  /**
   * Monte Carlo simulation method
   *
   * @generated from enum value: VAR_METHOD_MONTE_CARLO = 3;
   */
  VAR_METHOD_MONTE_CARLO = 3,
}

/**
 * Describes the enum risk.VaRMethod.
 */
export declare const VaRMethodSchema: GenEnum<VaRMethod>;

/**
 * @generated from enum risk.RiskViolationType
 */
export enum RiskViolationType {
  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_UNSPECIFIED = 0;
   */
  UNSPECIFIED = 0,

  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_POSITION_LIMIT = 1;
   */
  POSITION_LIMIT = 1,

  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_CONCENTRATION = 2;
   */
  CONCENTRATION = 2,

  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_VAR_LIMIT = 3;
   */
  VAR_LIMIT = 3,

  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_DRAWDOWN = 4;
   */
  DRAWDOWN = 4,

  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_LIQUIDITY = 5;
   */
  LIQUIDITY = 5,

  /**
   * @generated from enum value: RISK_VIOLATION_TYPE_CORRELATION = 6;
   */
  CORRELATION = 6,
}

/**
 * Describes the enum risk.RiskViolationType.
 */
export declare const RiskViolationTypeSchema: GenEnum<RiskViolationType>;

/**
 * Risk assessment levels
 *
 * @generated from enum risk.RiskLevel
 */
export enum RiskLevel {
  /**
   * Default/unknown level
   *
   * @generated from enum value: RISK_LEVEL_UNSPECIFIED = 0;
   */
  UNSPECIFIED = 0,

  /**
   * Low risk (green)
   *
   * @generated from enum value: RISK_LEVEL_LOW = 1;
   */
  LOW = 1,

  /**
   * Medium risk (yellow)
   *
   * @generated from enum value: RISK_LEVEL_MEDIUM = 2;
   */
  MEDIUM = 2,

  /**
   * High risk (orange)
   *
   * @generated from enum value: RISK_LEVEL_HIGH = 3;
   */
  HIGH = 3,

  /**
   * Critical risk (red)
   *
   * @generated from enum value: RISK_LEVEL_CRITICAL = 4;
   */
  CRITICAL = 4,
}

/**
 * Describes the enum risk.RiskLevel.
 */
export declare const RiskLevelSchema: GenEnum<RiskLevel>;

/**
 * Severity levels for risk alerts
 *
 * @generated from enum risk.RiskAlertSeverity
 */
export enum RiskAlertSeverity {
  /**
   * Default/unknown severity
   *
   * @generated from enum value: RISK_ALERT_SEVERITY_UNSPECIFIED = 0;
   */
  UNSPECIFIED = 0,

  /**
   * Informational alert
   *
   * @generated from enum value: RISK_ALERT_SEVERITY_INFO = 1;
   */
  INFO = 1,

  /**
   * Warning alert
   *
   * @generated from enum value: RISK_ALERT_SEVERITY_WARNING = 2;
   */
  WARNING = 2,

  /**
   * Critical alert requiring attention
   *
   * @generated from enum value: RISK_ALERT_SEVERITY_CRITICAL = 3;
   */
  CRITICAL = 3,

  /**
   * Emergency alert requiring immediate action
   *
   * @generated from enum value: RISK_ALERT_SEVERITY_EMERGENCY = 4;
   */
  EMERGENCY = 4,
}

/**
 * Describes the enum risk.RiskAlertSeverity.
 */
export declare const RiskAlertSeveritySchema: GenEnum<RiskAlertSeverity>;

/**
 * Types of risk alerts
 *
 * @generated from enum risk.RiskAlertType
 */
export enum RiskAlertType {
  /**
   * Default/unknown type
   *
   * @generated from enum value: RISK_ALERT_TYPE_UNSPECIFIED = 0;
   */
  UNSPECIFIED = 0,

  /**
   * VaR limit breach
   *
   * @generated from enum value: RISK_ALERT_TYPE_VAR_BREACH = 1;
   */
  VAR_BREACH = 1,

  /**
   * Position size limit breach
   *
   * @generated from enum value: RISK_ALERT_TYPE_POSITION_LIMIT = 2;
   */
  POSITION_LIMIT = 2,

  /**
   * Drawdown limit breach
   *
   * @generated from enum value: RISK_ALERT_TYPE_DRAWDOWN = 3;
   */
  DRAWDOWN = 3,

  /**
   * Portfolio concentration risk
   *
   * @generated from enum value: RISK_ALERT_TYPE_CONCENTRATION = 4;
   */
  CONCENTRATION = 4,

  /**
   * Liquidity risk alert
   *
   * @generated from enum value: RISK_ALERT_TYPE_LIQUIDITY = 5;
   */
  LIQUIDITY = 5,

  /**
   * Correlation risk alert
   *
   * @generated from enum value: RISK_ALERT_TYPE_CORRELATION = 6;
   */
  CORRELATION = 6,
}

/**
 * Describes the enum risk.RiskAlertType.
 */
export declare const RiskAlertTypeSchema: GenEnum<RiskAlertType>;

/**
 * Types of emergency stops
 *
 * @generated from enum risk.EmergencyStopType
 */
export enum EmergencyStopType {
  /**
   * Default/unknown type
   *
   * @generated from enum value: EMERGENCY_STOP_TYPE_UNSPECIFIED = 0;
   */
  UNSPECIFIED = 0,

  /**
   * Stop all trading activity
   *
   * @generated from enum value: EMERGENCY_STOP_TYPE_ALL_TRADING = 1;
   */
  ALL_TRADING = 1,

  /**
   * Stop trading for specific symbol
   *
   * @generated from enum value: EMERGENCY_STOP_TYPE_SYMBOL = 2;
   */
  SYMBOL = 2,

  /**
   * Stop trading for specific account
   *
   * @generated from enum value: EMERGENCY_STOP_TYPE_ACCOUNT = 3;
   */
  ACCOUNT = 3,

  /**
   * Stop specific trading strategy
   *
   * @generated from enum value: EMERGENCY_STOP_TYPE_STRATEGY = 4;
   */
  STRATEGY = 4,
}

/**
 * Describes the enum risk.EmergencyStopType.
 */
export declare const EmergencyStopTypeSchema: GenEnum<EmergencyStopType>;

/**
 * @generated from enum risk.CircuitBreakerType
 */
export enum CircuitBreakerType {
  /**
   * @generated from enum value: CIRCUIT_BREAKER_TYPE_UNSPECIFIED = 0;
   */
  UNSPECIFIED = 0,

  /**
   * @generated from enum value: CIRCUIT_BREAKER_TYPE_PORTFOLIO_LOSS = 1;
   */
  PORTFOLIO_LOSS = 1,

  /**
   * @generated from enum value: CIRCUIT_BREAKER_TYPE_SYMBOL_VOLATILITY = 2;
   */
  SYMBOL_VOLATILITY = 2,

  /**
   * @generated from enum value: CIRCUIT_BREAKER_TYPE_POSITION_SIZE = 3;
   */
  POSITION_SIZE = 3,

  /**
   * @generated from enum value: CIRCUIT_BREAKER_TYPE_DRAWDOWN = 4;
   */
  DRAWDOWN = 4,
}

/**
 * Describes the enum risk.CircuitBreakerType.
 */
export declare const CircuitBreakerTypeSchema: GenEnum<CircuitBreakerType>;

/**
 * @generated from enum risk.VaRChangeType
 */
export enum VaRChangeType {
  /**
   * @generated from enum value: VAR_CHANGE_TYPE_UNSPECIFIED = 0;
   */
  VAR_CHANGE_TYPE_UNSPECIFIED = 0,

  /**
   * @generated from enum value: VAR_CHANGE_TYPE_INCREASED = 1;
   */
  VAR_CHANGE_TYPE_INCREASED = 1,

  /**
   * @generated from enum value: VAR_CHANGE_TYPE_DECREASED = 2;
   */
  VAR_CHANGE_TYPE_DECREASED = 2,

  /**
   * @generated from enum value: VAR_CHANGE_TYPE_BREACH = 3;
   */
  VAR_CHANGE_TYPE_BREACH = 3,
}

/**
 * Describes the enum risk.VaRChangeType.
 */
export declare const VaRChangeTypeSchema: GenEnum<VaRChangeType>;

/**
 * Risk Management Service provides comprehensive risk assessment, monitoring, and control capabilities
 * for high-frequency trading operations. This service integrates real-time VaR calculations,
 * position risk analysis, compliance monitoring, and emergency controls.
 *
 * @generated from service risk.RiskService
 */
export declare const RiskService: GenService<{
  /**
   * Value at Risk (VaR) Calculations
   * Calculate current portfolio VaR using specified method and parameters
   *
   * @generated from rpc risk.RiskService.GetVaR
   */
  getVaR: {
    methodKind: "unary";
    input: typeof GetVaRRequestSchema;
    output: typeof GetVaRResponseSchema;
  },
  /**
   * Stream real-time VaR updates as market conditions change
   *
   * @generated from rpc risk.RiskService.StreamVaRUpdates
   */
  streamVaRUpdates: {
    methodKind: "server_streaming";
    input: typeof StreamVaRRequestSchema;
    output: typeof VaREventSchema;
  },
  /**
   * Position Risk Analysis
   * Get comprehensive risk analysis for current positions
   *
   * @generated from rpc risk.RiskService.GetPositionRisk
   */
  getPositionRisk: {
    methodKind: "unary";
    input: typeof GetPositionRiskRequestSchema;
    output: typeof GetPositionRiskResponseSchema;
  },
  /**
   * Validate order against risk limits before execution
   *
   * @generated from rpc risk.RiskService.ValidateOrder
   */
  validateOrder: {
    methodKind: "unary";
    input: typeof ValidateOrderRequestSchema;
    output: typeof ValidateOrderResponseSchema;
  },
  /**
   * Risk Metrics and Monitoring
   * Get comprehensive portfolio risk metrics and statistics
   *
   * @generated from rpc risk.RiskService.GetRiskMetrics
   */
  getRiskMetrics: {
    methodKind: "unary";
    input: typeof GetRiskMetricsRequestSchema;
    output: typeof GetRiskMetricsResponseSchema;
  },
  /**
   * Stream real-time risk alerts and violations
   *
   * @generated from rpc risk.RiskService.StreamRiskAlerts
   */
  streamRiskAlerts: {
    methodKind: "server_streaming";
    input: typeof StreamRiskAlertsRequestSchema;
    output: typeof RiskAlertEventSchema;
  },
  /**
   * Emergency Controls and Circuit Breakers
   * Trigger emergency stop to halt trading activities
   *
   * @generated from rpc risk.RiskService.EmergencyStop
   */
  emergencyStop: {
    methodKind: "unary";
    input: typeof EmergencyStopRequestSchema;
    output: typeof EmergencyStopResponseSchema;
  },
  /**
   * Get status of all circuit breakers and safety mechanisms
   *
   * @generated from rpc risk.RiskService.GetCircuitBreakerStatus
   */
  getCircuitBreakerStatus: {
    methodKind: "unary";
    input: typeof GetCircuitBreakerStatusRequestSchema;
    output: typeof GetCircuitBreakerStatusResponseSchema;
  },
  /**
   * Server-streaming: polls GetCircuitBreakerStatus at gateway level
   *
   * @generated from rpc risk.RiskService.StreamCircuitBreakerStatus
   */
  streamCircuitBreakerStatus: {
    methodKind: "server_streaming";
    input: typeof StreamCircuitBreakerStatusRequestSchema;
    output: typeof GetCircuitBreakerStatusResponseSchema;
  },
  /**
   * Server-streaming: polls GetRiskMetrics at gateway level
   *
   * @generated from rpc risk.RiskService.StreamRiskMetrics
   */
  streamRiskMetrics: {
    methodKind: "server_streaming";
    input: typeof StreamRiskMetricsRequestSchema;
    output: typeof GetRiskMetricsResponseSchema;
  },
}>;

