File size: 14,079 Bytes
6d71edc
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Aviator Predictor</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        .gradient-bg {
            background: linear-gradient(135deg, #1e3a8a 0%, #7c3aed 100%);
        }
        .card-glow {
            box-shadow: 0 10px 30px -5px rgba(124, 58, 237, 0.5);
        }
        .input-glow:focus {
            box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.3);
        }
        .pulse-animation {
            animation: pulse 2s infinite;
        }
        @keyframes pulse {
            0% { transform: scale(1); }
            50% { transform: scale(1.05); }
            100% { transform: scale(1); }
        }
    </style>
</head>
<body class="gradient-bg min-h-screen flex items-center justify-center p-4">
    <div class="max-w-4xl w-full">
        <div class="bg-white rounded-2xl overflow-hidden shadow-xl card-glow">
            <div class="md:flex">
                <!-- Left Side - Input and Controls -->
                <div class="p-8 md:w-1/2">
                    <div class="flex items-center mb-6">
                        <i class="fas fa-chart-line text-3xl text-indigo-600 mr-3"></i>
                        <h1 class="text-3xl font-bold text-gray-800">Aviator Predictor</h1>
                    </div>
                    
                    <p class="text-gray-600 mb-8">
                        Enter the latest multiplier value to predict the next outcome in the Aviator game.
                        Our AI model analyzes historical patterns to provide insights.
                    </p>
                    
                    <div class="mb-6">
                        <label class="block text-gray-700 font-medium mb-2" for="lastValue">
                            Last Multiplier Value
                        </label>
                        <div class="relative">
                            <input 
                                id="lastValue" 
                                type="number" 
                                step="0.01" 
                                placeholder="e.g. 1.75" 
                                class="w-full px-4 py-3 rounded-lg border-2 border-gray-200 focus:border-indigo-500 input-glow transition duration-200"
                            >
                            <div class="absolute right-3 top-3 text-gray-400">
                                <i class="fas fa-arrow-up"></i>
                            </div>
                        </div>
                    </div>
                    
                    <div class="mb-6">
                        <label class="block text-gray-700 font-medium mb-2">
                            Historical Data Points
                        </label>
                        <div class="flex flex-wrap gap-2">
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.20</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.50</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.30</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.70</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.60</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.80</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">2.00</span>
                            <span class="bg-indigo-100 text-indigo-800 px-3 py-1 rounded-full text-sm">1.90</span>
                        </div>
                    </div>
                    
                    <button 
                        id="predictBtn" 
                        class="w-full bg-indigo-600 hover:bg-indigo-700 text-white font-bold py-3 px-4 rounded-lg transition duration-200 flex items-center justify-center pulse-animation"
                    >
                        <i class="fas fa-brain mr-2"></i>
                        Predict Next Value
                    </button>
                    
                    <div id="resultContainer" class="mt-6 hidden">
                        <div class="bg-indigo-50 border-l-4 border-indigo-600 p-4 rounded">
                            <div class="flex items-start">
                                <div class="flex-shrink-0">
                                    <i class="fas fa-lightbulb text-indigo-600 text-xl"></i>
                                </div>
                                <div class="ml-3">
                                    <h3 class="text-sm font-medium text-indigo-800">AI Prediction</h3>
                                    <div class="mt-1 text-sm text-indigo-700">
                                        <p id="predictionResult" class="font-bold text-lg"></p>
                                        <p id="confidenceLevel" class="text-sm mt-1"></p>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                
                <!-- Right Side - Chart -->
                <div class="bg-gray-50 p-8 md:w-1/2 flex flex-col">
                    <h2 class="text-xl font-bold text-gray-800 mb-6 flex items-center">
                        <i class="fas fa-chart-bar mr-2 text-indigo-600"></i>
                        Historical Data Analysis
                    </h2>
                    <div class="flex-grow">
                        <canvas id="dataChart" class="w-full h-full"></canvas>
                    </div>
                    <div class="mt-6 text-sm text-gray-600">
                        <p class="flex items-center">
                            <span class="w-3 h-3 bg-indigo-600 rounded-full mr-2"></span>
                            Blue line shows actual historical multipliers
                        </p>
                        <p class="flex items-center mt-2">
                            <span class="w-3 h-3 bg-red-500 rounded-full mr-2"></span>
                            Red dot shows predicted next value
                        </p>
                    </div>
                </div>
            </div>
            
            <div class="bg-gray-100 px-8 py-4 flex items-center justify-between">
                <p class="text-sm text-gray-600">
                    <i class="fas fa-info-circle mr-1"></i>
                    Predictions are based on historical patterns and are not guaranteed
                </p>
                <button id="refreshBtn" class="text-indigo-600 hover:text-indigo-800 text-sm font-medium flex items-center">
                    <i class="fas fa-sync-alt mr-1"></i>
                    Refresh Data
                </button>
            </div>
        </div>
    </div>

    <script>
        // Mock data - in a real app this would come from an API
        const historicalData = [1.2, 1.5, 1.3, 1.7, 1.6, 1.8, 2.0, 1.9];
        let predictedValue = null;
        
        // Initialize chart
        const ctx = document.getElementById('dataChart').getContext('2d');
        const chart = new Chart(ctx, {
            type: 'line',
            data: {
                labels: historicalData.map((_, i) => `Round ${i+1}`),
                datasets: [{
                    label: 'Multiplier Value',
                    data: historicalData,
                    borderColor: '#4f46e5',
                    backgroundColor: 'rgba(79, 70, 229, 0.1)',
                    borderWidth: 2,
                    tension: 0.3,
                    fill: true,
                    pointBackgroundColor: '#4f46e5',
                    pointRadius: 4
                }]
            },
            options: {
                responsive: true,
                maintainAspectRatio: false,
                plugins: {
                    legend: {
                        display: false
                    },
                    tooltip: {
                        callbacks: {
                            label: function(context) {
                                return `Multiplier: ${context.parsed.y.toFixed(2)}x`;
                            }
                        }
                    }
                },
                scales: {
                    y: {
                        beginAtZero: true,
                        title: {
                            display: true,
                            text: 'Multiplier Value'
                        }
                    },
                    x: {
                        title: {
                            display: true,
                            text: 'Game Round'
                        }
                    }
                }
            }
        });
        
        // Simple mock prediction function
        function predictNextValue(lastValue) {
            // In a real app, this would use a proper ML model
            const normalizedData = historicalData.map(val => (val - 1.2) / (2.0 - 1.2));
            const normalizedLast = (lastValue - 1.2) / (2.0 - 1.2);
            
            // Mock prediction - average of last 3 values with some randomness
            const avg = normalizedData.slice(-3).reduce((a, b) => a + b, 0) / 3;
            const prediction = avg * 0.8 + normalizedLast * 0.2 + (Math.random() * 0.1 - 0.05);
            
            // Denormalize
            return Math.max(1.1, prediction * (2.0 - 1.2) + 1.2);
        }
        
        // Calculate confidence level (mock)
        function getConfidenceLevel(prediction) {
            const diff = Math.abs(prediction - 1.5) / 0.5;
            const confidence = Math.max(0.6, 1 - diff);
            return Math.round(confidence * 100);
        }
        
        // Event listeners
        document.getElementById('predictBtn').addEventListener('click', function() {
            const lastValueInput = document.getElementById('lastValue');
            const lastValue = parseFloat(lastValueInput.value);
            
            if (isNaN(lastValue) || lastValue <= 0) {
                alert('Please enter a valid positive number');
                return;
            }
            
            // Show loading state
            const btn = this;
            btn.innerHTML = '<i class="fas fa-spinner fa-spin mr-2"></i> Analyzing...';
            btn.classList.remove('pulse-animation');
            
            // Simulate processing delay
            setTimeout(() => {
                // Make prediction
                predictedValue = predictNextValue(lastValue);
                const confidence = getConfidenceLevel(predictedValue);
                
                // Update UI
                document.getElementById('predictionResult').textContent = 
                    `Predicted next value: ${predictedValue.toFixed(2)}x`;
                
                document.getElementById('confidenceLevel').textContent = 
                    `Confidence level: ${confidence}%`;
                
                document.getElementById('resultContainer').classList.remove('hidden');
                
                // Update chart with prediction
                const newLabels = [...chart.data.labels, 'Prediction'];
                const newData = [...chart.data.datasets[0].data, predictedValue];
                
                chart.data.labels = newLabels;
                chart.data.datasets[0].data = newData;
                chart.data.datasets[0].pointBackgroundColor = [...Array(newData.length-1).fill('#4f46e5'), '#ef4444'];
                chart.data.datasets[0].pointRadius = [...Array(newData.length-1).fill(4), 6];
                chart.update();
                
                // Reset button
                btn.innerHTML = '<i class="fas fa-brain mr-2"></i> Predict Next Value';
            }, 1500);
        });
        
        document.getElementById('refreshBtn').addEventListener('click', function() {
            // In a real app, this would fetch fresh data from the server
            const btn = this;
            btn.innerHTML = '<i class="fas fa-spinner fa-spin mr-1"></i> Refreshing...';
            
            setTimeout(() => {
                // Reset to initial state
                chart.data.labels = historicalData.map((_, i) => `Round ${i+1}`);
                chart.data.datasets[0].data = historicalData;
                chart.data.datasets[0].pointBackgroundColor = Array(historicalData.length).fill('#4f46e5');
                chart.data.datasets[0].pointRadius = Array(historicalData.length).fill(4);
                chart.update();
                
                document.getElementById('resultContainer').classList.add('hidden');
                document.getElementById('lastValue').value = '';
                
                btn.innerHTML = '<i class="fas fa-sync-alt mr-1"></i> Refresh Data';
            }, 1000);
        });
    </script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=ConnerOmega07/aviator-predictor" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>