Imported from kensonantony-prog/QuanTexa-Financial-v2 (
.agents/AGENTS.md). Install upstream withnpx skills add kensonantony-prog/QuanTexa-Financial-v2 --skill .agents. Copyright stays with the author.
Financial Integrity Rules (Non-Negotiable)
- Minimize look-ahead bias: No indicator, signal, or regime label at time t may use data after t.
- Execution Timing: A signal generated from data through bar T executes at bar T+1. Never assume a fill at the same bar's close that produced the signal.
- Transaction Costs: Transaction costs must reduce cash and portfolio value on every fill.
- Position Sizing: Position size must control actual exposure, not just be a label.
- Simulation Accuracy: The backtester must simulate money (cash, shares, equity), not just draw buy/sell markers.
- Single Metric Implementation: ONE implementation of each metric in
src/risk/metrics.py. The strategy, benchmark, robustness, and regime modules all call it. Never re-implement Sharpe, volatility, drawdown, or return elsewhere. - No Over-Optimization Bias: Never label the highest-return parameter set as "best" or "optimal". Robustness output shows the distribution of results and warns about over-optimization.
- Visibility of Assumptions: All assumptions are visible in the UI and documented in
research/assumptions.md. - Determinism: Same data + same parameters + same strategy = identical results (deterministic; no unseeded randomness).
- Graceful Error Handling: Fail gracefully. Invalid input produces a clear message, never a crash.
QUANTEXA Design System Rules (Non-Negotiable)
- Dark-First Command Center: Dark graphite (
#05080D,#0A1018,#0E1621) with Electric Cyan (#19D3F3) accents. - No Playful SaaS Aesthetics: Avoid cartoon illustrations, bright rainbows, or soft consumer pill buttons everywhere.
- Restrained Color Usage: Use semantic colors (
#22C55ESuccess,#F59E0BWarning,#EF4444Danger) strictly for actual risk and status communication. - Medium-High Information Density: Present dense financial metrics with tabular numbers (
font-variant-numeric: tabular-nums). - Restrained Rounding: Card border-radius
10px, subtle 1px border (#1C2936), no heavy drop shadows. - Source of Truth: Follow tokens and principles in
DESIGN.md.