PROSTLE commited on
Commit
8c2f11a
Β·
unverified Β·
1 Parent(s): d0b98f4

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +178 -28
index.html CHANGED
@@ -1,19 +1,25 @@
1
  <!DOCTYPE html>
2
  <html lang="en">
 
3
  <head>
4
  <meta charset="UTF-8" />
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
  <title>StockSense AI β€” Live Trading Dashboard</title>
7
- <link rel="stylesheet" href="style.css" />
8
  <script src="https://cdn.jsdelivr.net/npm/chart.js@4.4.0"></script>
9
  </head>
 
10
  <body>
11
 
12
- <!-- ══ TOP BAR ══════════════════════════════════════ -->
13
  <nav class="topbar">
14
  <div class="brand">πŸ“ˆ <span>StockSense AI</span></div>
15
  <div class="search-area">
16
- <input id="tickerInput" type="text" placeholder="Search ticker… (AAPL, TSLA, NVDA)" spellcheck="false" />
 
 
 
 
17
  <button id="analyzeBtn" onclick="loadTicker()">Analyze</button>
18
  </div>
19
  <div class="nav-tabs">
@@ -25,7 +31,29 @@
25
  </div>
26
  </nav>
27
 
28
- <!-- ══ LIVE PRICE BANNER ════════════════════════════ -->
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
  <section class="price-banner hidden" id="priceBanner">
30
  <div class="price-main">
31
  <h1 id="bannerName">β€”</h1>
@@ -42,7 +70,7 @@
42
  </div>
43
  </section>
44
 
45
- <!-- ══ TAB: CHARTS ══════════════════════════════════ -->
46
  <div id="chartsTab" class="tab-content">
47
  <div class="dashboard">
48
  <div class="chart-area">
@@ -54,12 +82,38 @@
54
  <button class="tf-btn" data-tf="1y">1Y</button>
55
  <button class="tf-btn" data-tf="2y">2Y</button>
56
  </div>
57
- <div class="chart-container"><canvas id="mainChart"></canvas></div>
 
 
 
 
 
 
 
 
 
 
 
 
58
  <div class="chart-container volume-chart"><canvas id="volumeChart"></canvas></div>
59
 
60
  <div class="prediction-section hidden" id="predSection">
61
- <h3>πŸ€– Next 5-Day Price Prediction</h3>
62
- <div class="chart-container"><canvas id="predChart"></canvas></div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
63
  <div class="pred-metrics">
64
  <div class="metric-card">
65
  <span class="m-label">Confidence</span>
@@ -70,11 +124,11 @@
70
  <span class="m-value" id="predRisk">β€”</span>
71
  </div>
72
  <div class="metric-card">
73
- <span class="m-label">Pred Day 1</span>
74
  <span class="m-value" id="predDay1">β€”</span>
75
  </div>
76
  <div class="metric-card">
77
- <span class="m-label">Pred Day 5</span>
78
  <span class="m-value" id="predDay5">β€”</span>
79
  </div>
80
  </div>
@@ -98,34 +152,36 @@
98
  </div>
99
  <div class="panel hidden" id="indPanel">
100
  <h3>πŸ“Š Technical Indicators</h3>
101
- <table class="ind-table"><tbody id="indBody"></tbody></table>
 
 
102
  </div>
103
  </aside>
104
  </div>
105
  </div>
106
 
107
- <!-- ══ TAB: AUTO TRADING ════════════════════════════ -->
108
  <div id="tradingTab" class="tab-content hidden">
109
  <div class="trading-dashboard">
110
 
111
- <!-- Portfolio Overview -->
112
  <div class="trade-grid">
113
  <div class="portfolio-header">
114
  <div class="port-card balance">
115
  <span class="pc-label">Portfolio Value</span>
116
- <span class="pc-value" id="portValue">$100,000.00</span>
117
  </div>
118
  <div class="port-card">
119
  <span class="pc-label">Cash Balance</span>
120
- <span class="pc-value" id="portBalance">$100,000.00</span>
121
  </div>
122
  <div class="port-card">
123
  <span class="pc-label">Unrealized P&L</span>
124
- <span class="pc-value" id="portUnrealized">$0.00</span>
125
  </div>
126
  <div class="port-card">
127
  <span class="pc-label">Realized P&L</span>
128
- <span class="pc-value" id="portRealized">$0.00</span>
129
  </div>
130
  <div class="port-card">
131
  <span class="pc-label">Win Rate</span>
@@ -137,7 +193,7 @@
137
  </div>
138
  </div>
139
 
140
- <!-- Bot Controls -->
141
  <div class="bot-controls">
142
  <div class="bot-status">
143
  <span class="bot-dot" id="botDot"></span>
@@ -151,7 +207,7 @@
151
  </div>
152
  </div>
153
 
154
- <!-- Open Positions -->
155
  <div class="trade-panel">
156
  <h3>πŸ“‚ Open Positions</h3>
157
  <div class="positions-table-wrap">
@@ -170,13 +226,15 @@
170
  </tr>
171
  </thead>
172
  <tbody id="positionsBody">
173
- <tr><td colspan="9" class="empty-msg">No open positions</td></tr>
 
 
174
  </tbody>
175
  </table>
176
  </div>
177
  </div>
178
 
179
- <!-- Trade Log -->
180
  <div class="trade-panel">
181
  <h3>πŸ“‹ Trade History</h3>
182
  <div class="trade-log" id="tradeLog">
@@ -184,7 +242,7 @@
184
  </div>
185
  </div>
186
 
187
- <!-- Live Trade Feed -->
188
  <div class="trade-panel">
189
  <h3>⚑ Live Trade Feed</h3>
190
  <div class="trade-feed" id="tradeFeed"></div>
@@ -194,12 +252,104 @@
194
  </div>
195
  </div>
196
 
197
- <!-- ══ DISCLAIMER FOOTER ════════════════════════════ -->
198
- <footer>
199
- <p>⚠️ <strong>PAPER TRADING ONLY</strong> β€” Simulated portfolio with fake money. Not real trades.</p>
200
- <p>For <strong>educational purposes only</strong>. Not financial advice. | StockSense AI β€” Hackathon 2026</p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
201
  </footer>
202
 
203
- <script src="app.js"></script>
204
  </body>
205
- </html>
 
 
1
  <!DOCTYPE html>
2
  <html lang="en">
3
+
4
  <head>
5
  <meta charset="UTF-8" />
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
  <title>StockSense AI β€” Live Trading Dashboard</title>
8
+ <link rel="stylesheet" href="style.css?v=6" />
9
  <script src="https://cdn.jsdelivr.net/npm/chart.js@4.4.0"></script>
10
  </head>
11
+
12
  <body>
13
 
14
+
15
  <nav class="topbar">
16
  <div class="brand">πŸ“ˆ <span>StockSense AI</span></div>
17
  <div class="search-area">
18
+ <div class="search-wrapper">
19
+ <input id="tickerInput" type="text" placeholder="Search stock… (e.g. Tata, Reliance, INFY)" spellcheck="false"
20
+ autocomplete="off" />
21
+ <div class="search-dropdown hidden" id="searchDropdown"></div>
22
+ </div>
23
  <button id="analyzeBtn" onclick="loadTicker()">Analyze</button>
24
  </div>
25
  <div class="nav-tabs">
 
31
  </div>
32
  </nav>
33
 
34
+ <div class="market-bar" id="marketBar">
35
+ <div class="market-bar-inner">
36
+ <div class="market-item" id="mktStock">
37
+ <span class="mkt-label" id="mktStockLabel">STOCK</span>
38
+ <span class="mkt-price" id="mktStockPrice">β€”</span>
39
+ <span class="mkt-change" id="mktStockChange">β€”</span>
40
+ </div>
41
+ <div class="market-sep">β”‚</div>
42
+ <div class="market-item">
43
+ <span class="mkt-label">NIFTY 50</span>
44
+ <span class="mkt-price" id="mktNiftyPrice">β€”</span>
45
+ <span class="mkt-change" id="mktNiftyChange">β€”</span>
46
+ </div>
47
+ <div class="market-sep">β”‚</div>
48
+ <div class="market-item">
49
+ <span class="mkt-label">SENSEX</span>
50
+ <span class="mkt-price" id="mktSensexPrice">β€”</span>
51
+ <span class="mkt-change" id="mktSensexChange">β€”</span>
52
+ </div>
53
+ </div>
54
+ </div>
55
+
56
+
57
  <section class="price-banner hidden" id="priceBanner">
58
  <div class="price-main">
59
  <h1 id="bannerName">β€”</h1>
 
70
  </div>
71
  </section>
72
 
73
+
74
  <div id="chartsTab" class="tab-content">
75
  <div class="dashboard">
76
  <div class="chart-area">
 
82
  <button class="tf-btn" data-tf="1y">1Y</button>
83
  <button class="tf-btn" data-tf="2y">2Y</button>
84
  </div>
85
+ <div class="chart-container" id="mainChartWrap">
86
+ <canvas id="mainChart"></canvas>
87
+ <div class="chart-empty-state" id="chartEmptyState">
88
+ <div class="empty-icon">πŸ“ˆ</div>
89
+ <h3>Explore Any Stock</h3>
90
+ <p>Search for a stock above or pick one from <strong>High Potential Stocks</strong> to view charts, analysis
91
+ & AI insights.</p>
92
+ <div class="empty-hint">Try: <span
93
+ onclick="document.getElementById('tickerInput').focus()">RELIANCE.NS</span> Β· <span
94
+ onclick="document.getElementById('tickerInput').focus()">TCS.NS</span> Β· <span
95
+ onclick="document.getElementById('tickerInput').focus()">TATAMOTORS.NS</span></div>
96
+ </div>
97
+ </div>
98
  <div class="chart-container volume-chart"><canvas id="volumeChart"></canvas></div>
99
 
100
  <div class="prediction-section hidden" id="predSection">
101
+ <h3>πŸ€– Next 5-Day Price Forecast</h3>
102
+
103
+ <div class="pred-loader" id="predLoader">
104
+ <div class="pred-loader-inner">
105
+ <div class="neural-dots">
106
+ <span></span><span></span><span></span><span></span><span></span>
107
+ </div>
108
+ <div class="loader-brain">🧠</div>
109
+ <p class="loader-title">AI Model Training</p>
110
+ <p class="loader-sub" id="predLoaderMsg">Analyzing patterns with 10-feature LSTM...</p>
111
+ <div class="loader-bar">
112
+ <div class="loader-bar-fill"></div>
113
+ </div>
114
+ </div>
115
+ </div>
116
+ <div class="chart-container" id="predChartWrap"><canvas id="predChart"></canvas></div>
117
  <div class="pred-metrics">
118
  <div class="metric-card">
119
  <span class="m-label">Confidence</span>
 
124
  <span class="m-value" id="predRisk">β€”</span>
125
  </div>
126
  <div class="metric-card">
127
+ <span class="m-label">Day 1 Forecast</span>
128
  <span class="m-value" id="predDay1">β€”</span>
129
  </div>
130
  <div class="metric-card">
131
+ <span class="m-label">Day 5 Forecast</span>
132
  <span class="m-value" id="predDay5">β€”</span>
133
  </div>
134
  </div>
 
152
  </div>
153
  <div class="panel hidden" id="indPanel">
154
  <h3>πŸ“Š Technical Indicators</h3>
155
+ <table class="ind-table">
156
+ <tbody id="indBody"></tbody>
157
+ </table>
158
  </div>
159
  </aside>
160
  </div>
161
  </div>
162
 
163
+
164
  <div id="tradingTab" class="tab-content hidden">
165
  <div class="trading-dashboard">
166
 
167
+
168
  <div class="trade-grid">
169
  <div class="portfolio-header">
170
  <div class="port-card balance">
171
  <span class="pc-label">Portfolio Value</span>
172
+ <span class="pc-value" id="portValue">β‚Ή10,00,000.00</span>
173
  </div>
174
  <div class="port-card">
175
  <span class="pc-label">Cash Balance</span>
176
+ <span class="pc-value" id="portBalance">β‚Ή10,00,000.00</span>
177
  </div>
178
  <div class="port-card">
179
  <span class="pc-label">Unrealized P&L</span>
180
+ <span class="pc-value" id="portUnrealized">β‚Ή0.00</span>
181
  </div>
182
  <div class="port-card">
183
  <span class="pc-label">Realized P&L</span>
184
+ <span class="pc-value" id="portRealized">β‚Ή0.00</span>
185
  </div>
186
  <div class="port-card">
187
  <span class="pc-label">Win Rate</span>
 
193
  </div>
194
  </div>
195
 
196
+
197
  <div class="bot-controls">
198
  <div class="bot-status">
199
  <span class="bot-dot" id="botDot"></span>
 
207
  </div>
208
  </div>
209
 
210
+
211
  <div class="trade-panel">
212
  <h3>πŸ“‚ Open Positions</h3>
213
  <div class="positions-table-wrap">
 
226
  </tr>
227
  </thead>
228
  <tbody id="positionsBody">
229
+ <tr>
230
+ <td colspan="9" class="empty-msg">No open positions</td>
231
+ </tr>
232
  </tbody>
233
  </table>
234
  </div>
235
  </div>
236
 
237
+
238
  <div class="trade-panel">
239
  <h3>πŸ“‹ Trade History</h3>
240
  <div class="trade-log" id="tradeLog">
 
242
  </div>
243
  </div>
244
 
245
+
246
  <div class="trade-panel">
247
  <h3>⚑ Live Trade Feed</h3>
248
  <div class="trade-feed" id="tradeFeed"></div>
 
252
  </div>
253
  </div>
254
 
255
+
256
+
257
+
258
+
259
+ <section class="insights-section">
260
+ <h2 class="section-title">🌐 AI Γ— Finance β€” Did You Know?</h2>
261
+ <div class="insights-grid">
262
+ <div class="insight-card">
263
+ <div class="insight-icon">πŸ€–</div>
264
+ <h4>AI Handles 60-70% of Trades</h4>
265
+ <p>Algorithmic and AI-driven systems now execute the majority of trades on major stock exchanges worldwide.</p>
266
+ </div>
267
+ <div class="insight-card">
268
+ <div class="insight-icon">🧠</div>
269
+ <h4>LSTM Remembers Patterns</h4>
270
+ <p>Long Short-Term Memory networks can learn patterns across 60+ trading days, capturing trends that humans
271
+ easily miss.</p>
272
+ </div>
273
+ <div class="insight-card">
274
+ <div class="insight-icon">πŸ“°</div>
275
+ <h4>News Moves Markets</h4>
276
+ <p>Studies show that news sentiment can predict short-term stock movements with up to 70% accuracy when combined
277
+ with technical analysis.</p>
278
+ </div>
279
+ <div class="insight-card">
280
+ <div class="insight-icon">πŸ“Š</div>
281
+ <h4>Bollinger Bands</h4>
282
+ <p>When Bollinger Band width contracts, a big price move is coming. Our model uses this "squeeze" signal in its
283
+ 10-feature pipeline.</p>
284
+ </div>
285
+ <div class="insight-card">
286
+ <div class="insight-icon">⚑</div>
287
+ <h4>Sub-Second Decisions</h4>
288
+ <p>Once trained, our LSTM model generates 5-day forecasts in under 50ms β€” faster than any human analyst could
289
+ process a single chart.</p>
290
+ </div>
291
+ <div class="insight-card">
292
+ <div class="insight-icon">πŸ›‘οΈ</div>
293
+ <h4>Risk Management is Key</h4>
294
+ <p>Professional trading firms never risk more than 2% per trade. Our bot uses stop-loss, take-profit, and
295
+ trailing stops for protection.</p>
296
+ </div>
297
+ </div>
298
+ </section>
299
+
300
+
301
+ <section class="pipeline-section">
302
+ <h2 class="section-title">βš™οΈ How StockSense AI Works</h2>
303
+ <div class="pipeline">
304
+ <div class="pipe-step">
305
+ <div class="pipe-num">01</div>
306
+ <div class="pipe-icon">πŸ“₯</div>
307
+ <h4>Data Ingestion</h4>
308
+ <p>2 years of OHLCV data fetched from Yahoo Finance in real-time for any stock ticker.</p>
309
+ </div>
310
+ <div class="pipe-arrow">β†’</div>
311
+ <div class="pipe-step">
312
+ <div class="pipe-num">02</div>
313
+ <div class="pipe-icon">πŸ“Š</div>
314
+ <h4>Feature Engineering</h4>
315
+ <p>10 technical indicators computed: SMA, EMA, RSI, MACD, Bollinger Bands, ATR, and Volume.</p>
316
+ </div>
317
+ <div class="pipe-arrow">β†’</div>
318
+ <div class="pipe-step">
319
+ <div class="pipe-num">03</div>
320
+ <div class="pipe-icon">🧠</div>
321
+ <h4>AI Prediction</h4>
322
+ <p>3-layer LSTM neural network trained on 60-day windows predicts next 5 business days' prices.</p>
323
+ </div>
324
+ <div class="pipe-arrow">β†’</div>
325
+ <div class="pipe-step">
326
+ <div class="pipe-num">04</div>
327
+ <div class="pipe-icon">πŸ’Ή</div>
328
+ <h4>Smart Trading</h4>
329
+ <p>Composite score (LSTM + Technical + Sentiment) adapts to market regime for auto BUY/SELL.</p>
330
+ </div>
331
+ </div>
332
+ </section>
333
+
334
+
335
+ <footer class="app-footer">
336
+ <div class="footer-content">
337
+ <div class="footer-brand">
338
+ <span class="footer-logo">πŸ“ˆ StockSense AI</span>
339
+ <span class="footer-tagline">Where Machine Learning Meets Market Intelligence</span>
340
+ </div>
341
+ <div class="footer-tech">
342
+ <span>Built with</span>
343
+ <span class="tech-badge">Python</span>
344
+ <span class="tech-badge">PyTorch</span>
345
+ <span class="tech-badge">FastAPI</span>
346
+ <span class="tech-badge">FinBERT</span>
347
+ <span class="tech-badge">Chart.js</span>
348
+ </div>
349
+ </div>
350
  </footer>
351
 
352
+ <script src="app.js?v=6"></script>
353
  </body>
354
+
355
+ </html>