CREATE TABLE transformation_logs (
id VARCHAR(50) NOT NULL,
stage JSON,
method JSON,
from_state VARCHAR(255),
to_state VARCHAR(255),
initial_confidence FLOAT,
final_confidence FLOAT,
confidence_degradation FLOAT,
reasoning VARCHAR(255),
rules_applied JSON,
inputs_considered JSON,
alternatives JSON,
model_name VARCHAR(255),
model_version VARCHAR(255),
temperature FLOAT,
max_tokens INTEGER,
hyperparameters JSON,
was_validated BOOLEAN,
human_reviewed BOOLEAN,
reviewer_id VARCHAR(255),
quality_notes VARCHAR(255),
source_entity_ids JSON,
dependency_log_ids JSON,
correlation_id VARCHAR(255),
processing_time_ms BIGINT,
memory_usage_bytes BIGINT,
cost_estimate FLOAT,
had_errors BOOLEAN,
error_messages JSON,
warning_messages JSON,
started_at JSON,
completed_at JSON,
tenant_id VARCHAR(50) NOT NULL,
metadata JSON,
PRIMARY KEY (id)
)