trading-platform-database/ddl/schemas/ml/00-enums.sql

69 lines
1.3 KiB
SQL

-- =====================================================
-- ML SCHEMA - ENUMS
-- =====================================================
-- Description: Enumerations for ML signals system
-- Schema: ml
-- Author: Database Agent
-- Date: 2025-12-06
-- =====================================================
-- Tipo de modelo ML
CREATE TYPE ml.model_type AS ENUM (
'classification',
'regression',
'time_series',
'clustering',
'anomaly_detection',
'reinforcement_learning'
);
-- Framework de ML
CREATE TYPE ml.framework AS ENUM (
'sklearn',
'tensorflow',
'pytorch',
'xgboost',
'lightgbm',
'prophet',
'custom'
);
-- Estado del modelo
CREATE TYPE ml.model_status AS ENUM (
'development',
'testing',
'staging',
'production',
'deprecated',
'archived'
);
-- Tipo de predicción
CREATE TYPE ml.prediction_type AS ENUM (
'price_direction', -- UP/DOWN/NEUTRAL
'price_target', -- Precio objetivo
'volatility', -- Alta/Media/Baja
'trend', -- Tendencia
'signal', -- BUY/SELL/HOLD
'risk_score' -- Score de riesgo
);
-- Resultado de predicción
CREATE TYPE ml.prediction_result AS ENUM (
'buy',
'sell',
'hold',
'up',
'down',
'neutral'
);
-- Estado de outcome
CREATE TYPE ml.outcome_status AS ENUM (
'pending',
'correct',
'incorrect',
'partially_correct',
'expired'
);