FPT IS
Tables (14)
ai_recommendation
- id — BIGINT — Primary key — NOT NULL
- currency_id — BIGINT — Foreign key → currency.id — NOT NULL
- recommendation — ENUM('EXCHANGE_NOW','WAIT','NEUTRAL') — NOT NULL
- rationale — TEXT — NOT NULL
- confidence_score — DECIMAL(4,3) — NOT NULL
- model_version — VARCHAR(50) — NOT NULL
- generated_at — DATETIME — NOT NULL
- expires_at — DATETIME — NOT NULL
ai_recommendation_signal
- id — BIGINT — Primary key — NOT NULL
- recommendation_id — BIGINT — Foreign key → ai_recommendation.id — NOT NULL
- signal_id — BIGINT — Foreign key → recommendation_signal.id — NOT NULL
backtest_result
- id — BIGINT — Primary key — NOT NULL
- currency_id — BIGINT — Foreign key → currency.id — NOT NULL
- strategy_type — ENUM('RULE_BASED','LLM_ORCHESTRATED') — NOT NULL
- period_start — DATE — NOT NULL
- period_end — DATE — NOT NULL
- total_signals — INT — NOT NULL
- correct_signals — INT — NOT NULL
- accuracy_rate — DECIMAL(5,2) — NOT NULL
- created_at — DATETIME — NOT NULL
branch
- id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(100) — NOT NULL
- address — VARCHAR(255) — NOT NULL
- phone — VARCHAR(30)
- created_at — DATETIME — NOT NULL
branch_currency_inventory
- id — BIGINT — Primary key — NOT NULL
- branch_id — BIGINT — Foreign key → branch.id — NOT NULL
- currency_id — BIGINT — Foreign key → currency.id — NOT NULL
- stock_amount — DECIMAL(18,2) — NOT NULL
- updated_at — DATETIME — NOT NULL
currency
- id — BIGINT — Primary key — NOT NULL
- code — VARCHAR(10) — NOT NULL
- country — VARCHAR(50) — NOT NULL
- buy_rate — DECIMAL(15,4) — NOT NULL
- sell_rate — DECIMAL(15,4) — NOT NULL
- updated_at — DATETIME — NOT NULL
exchange_rate_history
- id — BIGINT — Primary key — NOT NULL
- currency_id — BIGINT — Foreign key → currency.id — NOT NULL
- rate — DECIMAL(15,4) — NOT NULL
- recorded_at — DATETIME — NOT NULL
macro_indicator
- id — BIGINT — Primary key — NOT NULL
- country_code — VARCHAR(10) — NOT NULL
- indicator_type — VARCHAR(50) — NOT NULL
- value — DECIMAL(15,4) — NOT NULL
- recorded_at — DATE — NOT NULL
news_article
- id — BIGINT — Primary key — NOT NULL
- currency_code — VARCHAR(10) — NOT NULL
- title — VARCHAR(500) — NOT NULL
- source — VARCHAR(100)
- url — VARCHAR(500)
- published_at — DATETIME — NOT NULL
- sentiment_score — DECIMAL(4,3)
- collected_at — DATETIME — NOT NULL
notification
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- type — ENUM('RESERVATION_COMPLETED','RESERVATION_CANCELLED','PICKUP_REMINDER') — NOT NULL
- message — VARCHAR(255) — NOT NULL
- is_read — BOOLEAN — NOT NULL
- created_at — DATETIME — NOT NULL
recommendation_signal
- id — BIGINT — Primary key — NOT NULL
- currency_id — BIGINT — Foreign key → currency.id — NOT NULL
- signal_type — ENUM('MOVING_AVERAGE','VOLATILITY','ZSCORE') — NOT NULL
- window_days — INT — NOT NULL
- value — DECIMAL(15,6) — NOT NULL
- calculated_at — DATETIME — NOT NULL
reservation
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- currency_id — BIGINT — Foreign key → currency.id — NOT NULL
- branch_id — BIGINT — Foreign key → branch.id — NOT NULL
- amount — DECIMAL(18,2) — NOT NULL
- pickup_date — DATE — NOT NULL
- pickup_time — TIME — NOT NULL
- status — ENUM('RESERVED','COMPLETED','CANCELLED') — NOT NULL
- qr_code — VARCHAR(255) — NOT NULL
- created_at — DATETIME — NOT NULL
- updated_at — DATETIME — NOT NULL
tool_call_log
- id — BIGINT — Primary key — NOT NULL
- recommendation_id — BIGINT — Foreign key → ai_recommendation.id — NOT NULL
- tool_name — VARCHAR(100) — NOT NULL
- tool_input — JSON
- tool_output — JSON
- called_at — DATETIME — NOT NULL
user
- id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(100) — NOT NULL
- email — VARCHAR(150) — NOT NULL
- password — VARCHAR(255) — NOT NULL
- role — ENUM('USER','ADMIN') — NOT NULL
- created_at — DATETIME — NOT NULL
- updated_at — DATETIME — NOT NULL