-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
152 lines (136 loc) · 6.45 KB
/
Copy pathindex.html
File metadata and controls
152 lines (136 loc) · 6.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>3D Cell Simulator</title>
<link rel="stylesheet" href="{{ url_for('static', filename='css/style.css') }}">
</head>
<body>
<div class="container">
<header>
<h1>AI-Powered 3D Cell Simulator</h1>
<p>Test cells with any chemical combination - AI predicts unseen conditions</p>
</header>
<div class="main-content">
<!-- 3D Visualization Area -->
<div class="visualization-panel">
<div id="canvas-container"></div>
<div class="view-controls">
<p>Drag to rotate • Scroll to zoom</p>
</div>
</div>
<!-- Control Panel (Right Side) -->
<div class="control-panel">
<h2>Environmental Controls</h2>
<!-- AI Mode Toggle -->
<div class="mode-selector">
<label class="mode-option">
<input type="radio" name="mode" value="simple" checked>
<span>Simple Mode</span>
</label>
<label class="mode-option">
<input type="radio" name="mode" value="ai">
<span>AI Mode</span>
</label>
</div>
<div class="control-group">
<label for="nutrients">
<span class="label-text">Nutrients</span>
<span class="value-display" id="nutrients-value">50</span>
</label>
<input type="range" id="nutrients" min="0" max="100" value="50" step="1">
<div class="range-info">
<span>Optimal: 40-70</span>
</div>
</div>
<div class="control-group">
<label for="proteins">
<span class="label-text">Proteins</span>
<span class="value-display" id="proteins-value">50</span>
</label>
<input type="range" id="proteins" min="0" max="100" value="50" step="1">
<div class="range-info">
<span>Optimal: 30-60</span>
</div>
</div>
<!-- Simple mode controls -->
<div id="simple-controls">
<div class="control-group">
<label for="chemicals">
<span class="label-text">Toxic Chemicals</span>
<span class="value-display" id="chemicals-value">0</span>
</label>
<input type="range" id="chemicals" min="0" max="100" value="0" step="1">
<div class="range-info">
<span>Safe: 0-10</span>
</div>
</div>
</div>
<!-- AI mode controls -->
<div id="ai-controls" style="display: none;">
<div class="ai-section">
<h3>Chemical Composition</h3>
<p class="ai-hint">Mix any chemicals - AI will predict effects!</p>
<div id="chemical-list"></div>
<div class="add-chemical">
<input type="text" id="chemical-name" placeholder="Enter chemical name..." list="known-chemicals">
<datalist id="known-chemicals"></datalist>
<input type="number" id="chemical-concentration" placeholder="Conc." min="0" max="100" value="50">
<button id="add-chemical-btn" class="btn-small">Add</button>
</div>
<div class="quick-presets">
<p><strong>Quick Presets:</strong></p>
<button class="preset-btn" data-preset="toxic">Toxic Mix</button>
<button class="preset-btn" data-preset="healthy">Healthy Mix</button>
<button class="preset-btn" data-preset="oxidative">Oxidative Stress</button>
<button class="preset-btn" data-preset="unknown">Unknown Chemicals</button>
</div>
</div>
</div>
<div class="button-group">
<button id="update-btn" class="btn btn-primary">Update Simulation</button>
<button id="reset-btn" class="btn btn-secondary">Reset</button>
</div>
<div class="legend">
<h3>Health Legend</h3>
<div class="legend-item">
<span class="color-box" style="background: #00ff00;"></span>
<span>Thriving (>80%)</span>
</div>
<div class="legend-item">
<span class="color-box" style="background: #ffff00;"></span>
<span>Stressed (40-80%)</span>
</div>
<div class="legend-item">
<span class="color-box" style="background: #ff8800;"></span>
<span>Struggling (20-40%)</span>
</div>
<div class="legend-item">
<span class="color-box" style="background: #ff0000;"></span>
<span>Critical (<20%)</span>
</div>
</div>
</div>
</div>
<!-- Full Width Stats Section at Bottom -->
<div class="stats-section">
<div class="stats-container">
<div class="info-panel">
<h3>Cell Status</h3>
<div id="cell-status"></div>
</div>
<!-- AI Analysis -->
<div id="ai-analysis" style="display: none;">
<h3>AI Analysis</h3>
<div id="ai-insights"></div>
</div>
</div>
</div>
</div>
<!-- Three.js Library -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js"></script>
<!-- Main Application Script -->
<script src="{{ url_for('static', filename='js/app.js') }}"></script>
</body>
</html>