feat: Add Protocol 13 adaptive optimization, Plotly charts, and dashboard improvements

## Protocol 13: Adaptive Multi-Objective Optimization
- Iterative FEA + Neural Network surrogate workflow
- Initial FEA sampling, NN training, NN-accelerated search
- FEA validation of top NN predictions, retraining loop
- adaptive_state.json tracks iteration history and best values
- M1 mirror study (V11) with 103 FEA, 3000 NN trials

## Dashboard Visualization Enhancements
- Added Plotly.js interactive charts (parallel coords, Pareto, convergence)
- Lazy loading with React.lazy() for performance
- Code splitting: plotly.js-basic-dist (~1MB vs 3.5MB)
- Chart library toggle (Recharts default, Plotly on-demand)
- ExpandableChart component for full-screen modal views
- ConsoleOutput component for real-time log viewing

## Documentation
- Protocol 13 detailed documentation
- Dashboard visualization guide
- Plotly components README
- Updated run-optimization skill with Mode 5 (adaptive)

## Bug Fixes
- Fixed TypeScript errors in dashboard components
- Fixed Card component to accept ReactNode title
- Removed unused imports across components

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Antoine
2025-12-04 07:41:54 -05:00
parent e74f1ccf36
commit 8cbdbcad78
270 changed files with 15471 additions and 517 deletions

View File

@@ -1,7 +1,7 @@
# Run Optimization Skill
**Last Updated**: November 25, 2025
**Version**: 1.0 - Optimization Execution and Monitoring
**Last Updated**: December 3, 2025
**Version**: 2.0 - Added Adaptive Multi-Objective (Protocol 13)
You are helping the user run and monitor Atomizer optimization studies.
@@ -97,6 +97,42 @@ python run_optimization.py --trials 30 --resume
```
**Use when**: Optimization was interrupted
### Mode 5: Adaptive Multi-Objective (Protocol 13)
```bash
cd studies/{study_name}
python run_optimization.py --start
```
**Use when**:
- FEA takes > 5 minutes per run
- Multi-objective optimization (2-4 objectives)
- Need to explore > 100 designs efficiently
**Workflow:**
1. Initial FEA trials (50-100) for NN training data
2. Train neural network surrogate
3. NN-accelerated search (1000+ trials in seconds)
4. Validate top NN predictions with FEA
5. Retrain NN with new data, repeat
**Configuration** (in optimization_config.json):
```json
{
"protocol": 13,
"adaptive_settings": {
"enabled": true,
"initial_fea_trials": 50,
"nn_trials_per_iteration": 1000,
"fea_validation_per_iteration": 5,
"max_iterations": 10
}
}
```
**Monitoring:**
- `adaptive_state.json`: Current iteration, best values, history
- Dashboard shows FEA (blue) vs NN (orange) trials
- Pareto front updates after each FEA validation
## Execution Steps
### Step 1: Validate Study
@@ -254,6 +290,12 @@ MONITORING OPTIONS
cd atomizer-dashboard/frontend && npm run dev
→ http://localhost:3003
Features:
- ALL extracted metrics displayed per trial (not just mass/frequency)
- Quick preview shows first 6 metrics with abbreviations
- Expanded view shows full metric names and values
- Multi-objective studies: Zernike RMS, coefficients, workload metrics
2. Optuna Dashboard:
python -c "import optuna; from optuna_dashboard import run_server; ..."
→ http://localhost:8081
@@ -263,6 +305,10 @@ MONITORING OPTIONS
Tail the log file
```
**IMPORTANT**: For multi-objective studies with custom metrics (Zernike, thermal, etc.),
the Atomizer Dashboard automatically displays ALL numeric metrics from user_attrs.
No configuration needed - metrics are discovered dynamically.
## Resource Management
### Before Running