File size: 12,789 Bytes
7706ff4 |
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 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Codette Quantum Simulation Interface</title>
<style>
body {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
background: linear-gradient(135deg, #0f0f23 0%, #1a1a3e 100%);
color: white;
margin: 0;
padding: 2rem;
min-height: 100vh;
}
.container {
max-width: 1200px;
margin: 0 auto;
}
.header {
text-align: center;
margin-bottom: 2rem;
}
.header h1 {
font-size: 2.5rem;
background: linear-gradient(45deg, #00f5ff, #a8e6cf);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}
.nav-bar {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
border-radius: 8px;
padding: 1rem;
margin-bottom: 2rem;
text-align: center;
}
.nav-bar a {
color: white;
text-decoration: none;
padding: 0.5rem 1rem;
margin: 0 0.5rem;
border-radius: 4px;
transition: background 0.3s ease;
}
.nav-bar a:hover {
background: rgba(255, 255, 255, 0.2);
}
.simulation-controls {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
border-radius: 16px;
padding: 2rem;
margin-bottom: 2rem;
border: 1px solid rgba(255, 255, 255, 0.2);
}
.control-group {
margin-bottom: 1.5rem;
}
.control-group label {
display: block;
margin-bottom: 0.5rem;
font-weight: bold;
color: #a8e6cf;
}
.control-group input, .control-group select {
width: 100%;
padding: 0.8rem;
border: none;
border-radius: 8px;
background: rgba(255, 255, 255, 0.9);
color: #333;
font-size: 1rem;
}
.btn-quantum {
background: linear-gradient(45deg, #00f5ff, #0099cc);
color: white;
padding: 1rem 2rem;
border: none;
border-radius: 8px;
font-size: 1rem;
cursor: pointer;
transition: all 0.3s ease;
margin: 0.5rem;
}
.btn-quantum:hover {
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(0, 245, 255, 0.4);
}
.simulation-results {
background: rgba(255, 255, 255, 0.1);
backdrop-filter: blur(10px);
border-radius: 16px;
padding: 2rem;
margin: 2rem 0;
border: 1px solid rgba(255, 255, 255, 0.2);
}
.results-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 1.5rem;
margin: 1rem 0;
}
.result-card {
background: rgba(0, 0, 0, 0.3);
border-radius: 8px;
padding: 1.5rem;
border: 1px solid rgba(255, 255, 255, 0.1);
}
.quantum-visualization {
background: rgba(255, 255, 255, 0.05);
border-radius: 12px;
padding: 1.5rem;
margin: 2rem 0;
text-align: center;
}
.quantum-state {
display: inline-block;
width: 80px;
height: 80px;
border-radius: 50%;
margin: 10px;
display: flex;
align-items: center;
justify-content: center;
color: white;
font-weight: bold;
animation: quantum-pulse 2s infinite;
}
@keyframes quantum-pulse {
0%, 100% { transform: scale(1); opacity: 0.8; }
50% { transform: scale(1.1); opacity: 1; }
}
.loading-quantum {
display: none;
text-align: center;
padding: 2rem;
}
.quantum-spinner {
border: 4px solid rgba(0, 245, 255, 0.3);
border-radius: 50%;
border-top: 4px solid #00f5ff;
width: 50px;
height: 50px;
animation: spin 1s linear infinite;
margin: 0 auto 1rem;
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
.cocoon-list {
max-height: 300px;
overflow-y: auto;
background: rgba(0, 0, 0, 0.2);
border-radius: 8px;
padding: 1rem;
}
.cocoon-item {
background: rgba(255, 255, 255, 0.05);
border-radius: 4px;
padding: 0.8rem;
margin-bottom: 0.5rem;
border-left: 3px solid #00f5ff;
}
</style>
</head>
<body>
<div class="container">
<nav class="nav-bar">
<a href="/">π Home</a>
<a href="/dashboard">π Dashboard</a>
<a href="/quantum">βοΈ Quantum</a>
<a href="/cognitive">π§ Cognitive</a>
</nav>
<header class="header">
<h1>βοΈ Quantum Simulation Interface</h1>
<p>Citizen-science quantum and chaos simulations with AI meta-commentary</p>
</header>
<div class="simulation-controls">
<h2>π¬ Simulation Parameters</h2>
<div class="control-group">
<label for="coreCount">CPU Cores to Use:</label>
<input type="number" id="coreCount" value="4" min="1" max="16">
</div>
<div class="control-group">
<label for="simulationType">Simulation Type:</label>
<select id="simulationType">
<option value="quantum_chaos">Quantum + Chaos</option>
<option value="quantum_only">Quantum Only</option>
<option value="chaos_only">Chaos Only</option>
<option value="cosmic_entropy">Cosmic Entropy</option>
</select>
</div>
<div class="control-group">
<label for="perspectiveAgents">AI Perspective Agents:</label>
<select id="perspectiveAgents" multiple>
<option value="Quantum" selected>Quantum</option>
<option value="Newton" selected>Newtonian</option>
<option value="Stardust" selected>Stardust</option>
<option value="DaVinci">Da Vinci</option>
<option value="Ethical">Ethical</option>
</select>
</div>
<button onclick="runQuantumSimulation()" class="btn-quantum">
π Launch Quantum Simulation
</button>
<button onclick="analyzeCocoons()" class="btn-quantum">
π Analyze Cocoons
</button>
<button onclick="visualize3D()" class="btn-quantum">
π 3D Visualization
</button>
</div>
<div class="loading-quantum" id="quantumLoading">
<div class="quantum-spinner"></div>
<p>Running quantum simulation across multiple cores...</p>
<p>AI agents are analyzing each universe...</p>
</div>
<div class="simulation-results" id="resultsSection" style="display: none;">
<h2>π― Simulation Results</h2>
<div class="quantum-visualization" id="quantumViz">
<h3>Quantum State Visualization</h3>
<div id="quantumStates"></div>
</div>
<div class="results-grid" id="resultsGrid">
<!-- Results will be populated here -->
</div>
<div>
<h3>π Generated Cocoons</h3>
<div class="cocoon-list" id="cocoonList">
<!-- Cocoon files will be listed here -->
</div>
</div>
</div>
</div>
<script>
async function runQuantumSimulation() {
const cores = parseInt(document.getElementById('coreCount').value);
const loading = document.getElementById('quantumLoading');
const results = document.getElementById('resultsSection');
// Show loading
loading.style.display = 'block';
results.style.display = 'none';
try {
const response = await fetch('/api/quantum-simulation', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
cores: cores,
simulation_type: document.getElementById('simulationType').value
})
});
const data = await response.json();
// Hide loading
loading.style.display = 'none';
results.style.display = 'block';
if (data.error) {
alert(`Simulation Error: ${data.error}`);
} else {
displaySimulationResults(data);
}
} catch (error) {
loading.style.display = 'none';
alert(`Network Error: ${error.message}`);
}
}
function displaySimulationResults(data) {
const resultsGrid = document.getElementById('resultsGrid');
const cocoonList = document.getElementById('cocoonList');
const quantumStates = document.getElementById('quantumStates');
// Clear previous results
resultsGrid.innerHTML = '';
cocoonList.innerHTML = '';
quantumStates.innerHTML = '';
// Display quantum states visualization
for (let i = 0; i < data.cores_used; i++) {
const state = document.createElement('div');
state.className = 'quantum-state';
state.style.background = `hsl(${i * 360 / data.cores_used}, 70%, 50%)`;
state.textContent = `Core ${i + 1}`;
quantumStates.appendChild(state);
}
// Display results cards
data.results.forEach((result, index) => {
const card = document.createElement('div');
card.className = 'result-card';
card.innerHTML = `
<h4>π¬ Core ${index + 1} Results</h4>
<p><strong>File:</strong> ${result}</p>
<p><strong>Status:</strong> β
Simulation Complete</p>
<p><strong>AI Commentary:</strong> Generated</p>
`;
resultsGrid.appendChild(card);
});
// Display cocoon files
data.results.forEach(result => {
const cocoonItem = document.createElement('div');
cocoonItem.className = 'cocoon-item';
cocoonItem.innerHTML = `
<strong>π¦ ${result}</strong><br>
<small>Quantum state, chaos dynamics, and AI perspectives</small>
`;
cocoonList.appendChild(cocoonItem);
});
}
async function analyzeCocoons() {
alert('Cocoon analysis will be implemented in the next update!');
}
async function visualize3D() {
alert('3D visualization will be implemented in the next update!');
}
// Initialize page
document.addEventListener('DOMContentLoaded', function() {
console.log('Quantum interface initialized');
});
</script>
</body>
</html> |