precison9 commited on
Commit
7e0ffa2
·
verified ·
1 Parent(s): 1fa06a5

undefined - Initial Deployment

Browse files
Files changed (2) hide show
  1. README.md +7 -5
  2. index.html +594 -19
README.md CHANGED
@@ -1,10 +1,12 @@
1
  ---
2
- title: Ai Teacher
3
- emoji: 🐠
4
- colorFrom: yellow
5
- colorTo: purple
6
  sdk: static
7
  pinned: false
 
 
8
  ---
9
 
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
1
  ---
2
+ title: ai-teacher
3
+ emoji: 🐳
4
+ colorFrom: blue
5
+ colorTo: green
6
  sdk: static
7
  pinned: false
8
+ tags:
9
+ - deepsite
10
  ---
11
 
12
+ Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
index.html CHANGED
@@ -1,19 +1,594 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
19
- </html>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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>AI Learning Portal</title>
7
+ <script src="https://cdn.tailwindcss.com"></script>
8
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js"></script>
9
+ <script src="https://cdn.jsdelivr.net/npm/three@0.128.0/examples/js/loaders/GLTFLoader.min.js"></script>
10
+ <script src="https://cdn.jsdelivr.net/npm/three@0.128.0/examples/js/controls/OrbitControls.min.js"></script>
11
+ <style>
12
+ @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');
13
+
14
+ body {
15
+ font-family: 'Poppins', sans-serif;
16
+ background-color: #f8fafc;
17
+ }
18
+
19
+ .gradient-bg {
20
+ background: linear-gradient(135deg, #6e8efb, #a777e3);
21
+ }
22
+
23
+ .card {
24
+ backdrop-filter: blur(10px);
25
+ background-color: rgba(255, 255, 255, 0.8);
26
+ }
27
+
28
+ .btn-primary {
29
+ background: linear-gradient(135deg, #6e8efb, #a777e3);
30
+ transition: all 0.3s ease;
31
+ }
32
+
33
+ .btn-primary:hover {
34
+ transform: translateY(-2px);
35
+ box-shadow: 0 10px 20px -10px rgba(110, 142, 251, 0.6);
36
+ }
37
+
38
+ .floating {
39
+ animation: floating 3s ease-in-out infinite;
40
+ }
41
+
42
+ @keyframes floating {
43
+ 0% { transform: translateY(0px); }
44
+ 50% { transform: translateY(-15px); }
45
+ 100% { transform: translateY(0px); }
46
+ }
47
+
48
+ #teacher-container {
49
+ width: 100%;
50
+ height: 400px;
51
+ position: relative;
52
+ }
53
+
54
+ .chat-bubble {
55
+ position: relative;
56
+ background: #fff;
57
+ border-radius: 1rem;
58
+ padding: 1rem;
59
+ box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
60
+ max-width: 80%;
61
+ margin-bottom: 1rem;
62
+ }
63
+
64
+ .chat-bubble:after {
65
+ content: '';
66
+ position: absolute;
67
+ bottom: 0;
68
+ left: 20%;
69
+ width: 0;
70
+ height: 0;
71
+ border: 20px solid transparent;
72
+ border-top-color: #fff;
73
+ border-bottom: 0;
74
+ border-left: 0;
75
+ margin-left: -10px;
76
+ margin-bottom: -20px;
77
+ }
78
+
79
+ .user-bubble {
80
+ background: #6e8efb;
81
+ color: white;
82
+ margin-left: auto;
83
+ }
84
+
85
+ .user-bubble:after {
86
+ border-top-color: #6e8efb;
87
+ right: 20%;
88
+ left: auto;
89
+ }
90
+
91
+ .page {
92
+ display: none;
93
+ }
94
+
95
+ .page.active {
96
+ display: block;
97
+ animation: fadeIn 0.5s ease-in-out;
98
+ }
99
+
100
+ @keyframes fadeIn {
101
+ from { opacity: 0; transform: translateY(20px); }
102
+ to { opacity: 1; transform: translateY(0); }
103
+ }
104
+ </style>
105
+ </head>
106
+ <body class="min-h-screen">
107
+ <!-- Navigation -->
108
+ <nav class="bg-white shadow-lg">
109
+ <div class="max-w-6xl mx-auto px-4">
110
+ <div class="flex justify-between">
111
+ <div class="flex space-x-7">
112
+ <div>
113
+ <a href="#" class="flex items-center py-4 px-2">
114
+ <span class="font-semibold text-gray-500 text-lg">AI Learning</span>
115
+ </a>
116
+ </div>
117
+ </div>
118
+ <div class="hidden md:flex items-center space-x-3">
119
+ <a href="#" onclick="showPage('home')" class="py-4 px-2 text-gray-500 font-semibold hover:text-purple-500 transition duration-300">Home</a>
120
+ <a href="#" onclick="showPage('ai')" class="py-4 px-2 text-gray-500 font-semibold hover:text-purple-500 transition duration-300">AI Teacher</a>
121
+ <button onclick="showPage('login')" class="py-2 px-4 font-medium text-white bg-purple-500 rounded hover:bg-purple-400 transition duration-300">Login</button>
122
+ </div>
123
+ <div class="md:hidden flex items-center">
124
+ <button class="outline-none mobile-menu-button">
125
+ <svg class="w-6 h-6 text-gray-500" x-show="!showMenu" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" viewBox="0 0 24 24" stroke="currentColor">
126
+ <path d="M4 6h16M4 12h16M4 18h16"></path>
127
+ </svg>
128
+ </button>
129
+ </div>
130
+ </div>
131
+ </div>
132
+ </nav>
133
+
134
+ <!-- Login Page -->
135
+ <div id="login" class="page min-h-screen flex items-center justify-center gradient-bg py-12 px-4 sm:px-6 lg:px-8">
136
+ <div class="max-w-md w-full space-y-8 p-10 card rounded-xl shadow-2xl">
137
+ <div class="text-center">
138
+ <h2 class="mt-6 text-3xl font-extrabold text-gray-900">
139
+ Sign in to your account
140
+ </h2>
141
+ <p class="mt-2 text-sm text-gray-600">
142
+ Or <a href="#" onclick="showPage('signup')" class="font-medium text-purple-600 hover:text-purple-500">create a new account</a>
143
+ </p>
144
+ </div>
145
+ <form class="mt-8 space-y-6" id="loginForm">
146
+ <div class="rounded-md shadow-sm space-y-4">
147
+ <div>
148
+ <label for="email" class="sr-only">Email address</label>
149
+ <input id="login-email" name="email" type="email" autocomplete="email" required class="appearance-none rounded-md relative block w-full px-3 py-3 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:ring-purple-500 focus:border-purple-500 focus:z-10 sm:text-sm" placeholder="Email address">
150
+ </div>
151
+ <div>
152
+ <label for="password" class="sr-only">Password</label>
153
+ <input id="login-password" name="password" type="password" autocomplete="current-password" required class="appearance-none rounded-md relative block w-full px-3 py-3 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:ring-purple-500 focus:border-purple-500 focus:z-10 sm:text-sm" placeholder="Password">
154
+ </div>
155
+ </div>
156
+
157
+ <div class="flex items-center justify-between">
158
+ <div class="flex items-center">
159
+ <input id="remember-me" name="remember-me" type="checkbox" class="h-4 w-4 text-purple-600 focus:ring-purple-500 border-gray-300 rounded">
160
+ <label for="remember-me" class="ml-2 block text-sm text-gray-900">
161
+ Remember me
162
+ </label>
163
+ </div>
164
+
165
+ <div class="text-sm">
166
+ <a href="#" class="font-medium text-purple-600 hover:text-purple-500">
167
+ Forgot your password?
168
+ </a>
169
+ </div>
170
+ </div>
171
+
172
+ <div>
173
+ <button type="submit" class="group relative w-full flex justify-center py-3 px-4 border border-transparent text-sm font-medium rounded-md text-white btn-primary focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
174
+ Sign in
175
+ </button>
176
+ </div>
177
+ </form>
178
+ </div>
179
+ </div>
180
+
181
+ <!-- Signup Page -->
182
+ <div id="signup" class="page min-h-screen flex items-center justify-center gradient-bg py-12 px-4 sm:px-6 lg:px-8">
183
+ <div class="max-w-md w-full space-y-8 p-10 card rounded-xl shadow-2xl">
184
+ <div class="text-center">
185
+ <h2 class="mt-6 text-3xl font-extrabold text-gray-900">
186
+ Create a new account
187
+ </h2>
188
+ <p class="mt-2 text-sm text-gray-600">
189
+ Or <a href="#" onclick="showPage('login')" class="font-medium text-purple-600 hover:text-purple-500">sign in to your account</a>
190
+ </p>
191
+ </div>
192
+ <form class="mt-8 space-y-6" id="signupForm">
193
+ <div class="rounded-md shadow-sm space-y-4">
194
+ <div>
195
+ <label for="name" class="sr-only">Full Name</label>
196
+ <input id="signup-name" name="name" type="text" autocomplete="name" required class="appearance-none rounded-md relative block w-full px-3 py-3 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:ring-purple-500 focus:border-purple-500 focus:z-10 sm:text-sm" placeholder="Full Name">
197
+ </div>
198
+ <div>
199
+ <label for="email" class="sr-only">Email address</label>
200
+ <input id="signup-email" name="email" type="email" autocomplete="email" required class="appearance-none rounded-md relative block w-full px-3 py-3 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:ring-purple-500 focus:border-purple-500 focus:z-10 sm:text-sm" placeholder="Email address">
201
+ </div>
202
+ <div>
203
+ <label for="password" class="sr-only">Password</label>
204
+ <input id="signup-password" name="password" type="password" autocomplete="new-password" required class="appearance-none rounded-md relative block w-full px-3 py-3 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:ring-purple-500 focus:border-purple-500 focus:z-10 sm:text-sm" placeholder="Password">
205
+ </div>
206
+ <div>
207
+ <label for="confirm-password" class="sr-only">Confirm Password</label>
208
+ <input id="signup-confirm-password" name="confirm-password" type="password" autocomplete="new-password" required class="appearance-none rounded-md relative block w-full px-3 py-3 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:ring-purple-500 focus:border-purple-500 focus:z-10 sm:text-sm" placeholder="Confirm Password">
209
+ </div>
210
+ </div>
211
+
212
+ <div class="flex items-center">
213
+ <input id="terms" name="terms" type="checkbox" class="h-4 w-4 text-purple-600 focus:ring-purple-500 border-gray-300 rounded" required>
214
+ <label for="terms" class="ml-2 block text-sm text-gray-900">
215
+ I agree to the <a href="#" class="font-medium text-purple-600 hover:text-purple-500">Terms and Conditions</a>
216
+ </label>
217
+ </div>
218
+
219
+ <div>
220
+ <button type="submit" class="group relative w-full flex justify-center py-3 px-4 border border-transparent text-sm font-medium rounded-md text-white btn-primary focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
221
+ Sign Up
222
+ </button>
223
+ </div>
224
+ </form>
225
+ </div>
226
+ </div>
227
+
228
+ <!-- Home Page -->
229
+ <div id="home" class="page active">
230
+ <div class="gradient-bg min-h-screen flex items-center justify-center px-4 sm:px-6 lg:px-8">
231
+ <div class="max-w-7xl mx-auto text-center py-12 px-4 sm:px-6 lg:py-16 lg:px-8">
232
+ <h1 class="text-4xl font-extrabold tracking-tight text-white sm:text-5xl lg:text-6xl">
233
+ <span class="block">Welcome to AI Learning</span>
234
+ <span class="block text-purple-200">Interactive Education Platform</span>
235
+ </h1>
236
+ <p class="mt-3 max-w-md mx-auto text-base text-purple-100 sm:text-lg md:mt-5 md:text-xl md:max-w-3xl">
237
+ Learn from our AI teacher, get personalized lessons, and track your progress in real-time.
238
+ </p>
239
+ <div class="mt-10 flex justify-center">
240
+ <div class="inline-flex rounded-md shadow">
241
+ <a href="#" onclick="showPage('ai')" class="inline-flex items-center justify-center px-5 py-3 border border-transparent text-base font-medium rounded-md text-purple-600 bg-white hover:bg-purple-50">
242
+ Talk to AI Teacher
243
+ </a>
244
+ </div>
245
+ <div class="ml-3 inline-flex">
246
+ <a href="#" onclick="showPage('signup')" class="inline-flex items-center justify-center px-5 py-3 border border-transparent text-base font-medium rounded-md text-white bg-purple-600 bg-opacity-60 hover:bg-opacity-70">
247
+ Get Started
248
+ </a>
249
+ </div>
250
+ </div>
251
+ </div>
252
+ </div>
253
+
254
+ <div class="py-12 bg-white">
255
+ <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
256
+ <div class="lg:text-center">
257
+ <h2 class="text-base text-purple-600 font-semibold tracking-wide uppercase">Features</h2>
258
+ <p class="mt-2 text-3xl leading-8 font-extrabold tracking-tight text-gray-900 sm:text-4xl">
259
+ A better way to learn
260
+ </p>
261
+ <p class="mt-4 max-w-2xl text-xl text-gray-500 lg:mx-auto">
262
+ Our platform combines AI technology with interactive learning for maximum engagement.
263
+ </p>
264
+ </div>
265
+
266
+ <div class="mt-10">
267
+ <div class="space-y-10 md:space-y-0 md:grid md:grid-cols-2 md:gap-x-8 md:gap-y-10">
268
+ <div class="relative">
269
+ <div class="absolute flex items-center justify-center h-12 w-12 rounded-md bg-purple-500 text-white">
270
+ <svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
271
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 117.072 0l-.548.547A3.374 3.374 0 0014 18.469V19a2 2 0 11-4 0v-.531c0-.895-.356-1.754-.988-2.386l-.548-.547z"></path>
272
+ </svg>
273
+ </div>
274
+ <p class="ml-16 text-lg leading-6 font-medium text-gray-900">AI-Powered Learning</p>
275
+ <p class="mt-2 ml-16 text-base text-gray-500">
276
+ Our AI teacher adapts to your learning style and pace, providing personalized lessons.
277
+ </p>
278
+ </div>
279
+
280
+ <div class="relative">
281
+ <div class="absolute flex items-center justify-center h-12 w-12 rounded-md bg-purple-500 text-white">
282
+ <svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
283
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 10V3L4 14h7v7l9-11h-7z"></path>
284
+ </svg>
285
+ </div>
286
+ <p class="ml-16 text-lg leading-6 font-medium text-gray-900">Interactive 3D Teacher</p>
287
+ <p class="mt-2 ml-16 text-base text-gray-500">
288
+ Engage with our lifelike 3D teacher avatar that can answer your questions in real-time.
289
+ </p>
290
+ </div>
291
+
292
+ <div class="relative">
293
+ <div class="absolute flex items-center justify-center h-12 w-12 rounded-md bg-purple-500 text-white">
294
+ <svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
295
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z"></path>
296
+ </svg>
297
+ </div>
298
+ <p class="ml-16 text-lg leading-6 font-medium text-gray-900">Progress Tracking</p>
299
+ <p class="mt-2 ml-16 text-base text-gray-500">
300
+ Monitor your learning journey with detailed analytics and personalized recommendations.
301
+ </p>
302
+ </div>
303
+
304
+ <div class="relative">
305
+ <div class="absolute flex items-center justify-center h-12 w-12 rounded-md bg-purple-500 text-white">
306
+ <svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
307
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M7 8h10M7 12h4m1 8l-4-4H5a2 2 0 01-2-2V6a2 2 0 012-2h14a2 2 0 012 2v8a2 2 0 01-2 2h-3l-4 4z"></path>
308
+ </svg>
309
+ </div>
310
+ <p class="ml-16 text-lg leading-6 font-medium text-gray-900">24/7 Availability</p>
311
+ <p class="mt-2 ml-16 text-base text-gray-500">
312
+ Learn anytime, anywhere with our always-available AI teacher.
313
+ </p>
314
+ </div>
315
+ </div>
316
+ </div>
317
+ </div>
318
+ </div>
319
+
320
+ <div class="bg-gray-50">
321
+ <div class="max-w-7xl mx-auto py-12 px-4 sm:px-6 lg:py-16 lg:px-8 lg:flex lg:items-center lg:justify-between">
322
+ <h2 class="text-3xl font-extrabold tracking-tight text-gray-900 sm:text-4xl">
323
+ <span class="block">Ready to dive in?</span>
324
+ <span class="block text-purple-600">Start your learning journey today.</span>
325
+ </h2>
326
+ <div class="mt-8 flex lg:mt-0 lg:flex-shrink-0">
327
+ <div class="inline-flex rounded-md shadow">
328
+ <a href="#" onclick="showPage('signup')" class="inline-flex items-center justify-center px-5 py-3 border border-transparent text-base font-medium rounded-md text-white bg-purple-600 hover:bg-purple-700">
329
+ Get started
330
+ </a>
331
+ </div>
332
+ <div class="ml-3 inline-flex rounded-md shadow">
333
+ <a href="#" onclick="showPage('ai')" class="inline-flex items-center justify-center px-5 py-3 border border-transparent text-base font-medium rounded-md text-purple-600 bg-white hover:bg-gray-50">
334
+ Try AI Teacher
335
+ </a>
336
+ </div>
337
+ </div>
338
+ </div>
339
+ </div>
340
+ </div>
341
+
342
+ <!-- AI Teacher Page -->
343
+ <div id="ai" class="page min-h-screen bg-gray-100 py-8 px-4 sm:px-6 lg:px-8">
344
+ <div class="max-w-7xl mx-auto">
345
+ <div class="text-center mb-8">
346
+ <h1 class="text-3xl font-extrabold text-gray-900 sm:text-4xl">
347
+ Interactive AI Teacher
348
+ </h1>
349
+ <p class="mt-3 max-w-2xl mx-auto text-xl text-gray-500 sm:mt-4">
350
+ Ask questions and get answers from our AI teacher in real-time.
351
+ </p>
352
+ </div>
353
+
354
+ <div class="grid grid-cols-1 lg:grid-cols-3 gap-8">
355
+ <div class="lg:col-span-2 bg-white rounded-xl shadow-lg overflow-hidden">
356
+ <div id="teacher-container" class="w-full h-full bg-gray-200">
357
+ <!-- 3D Teacher will be rendered here -->
358
+ </div>
359
+ </div>
360
+
361
+ <div class="bg-white rounded-xl shadow-lg p-6">
362
+ <div class="flex items-center mb-6">
363
+ <div class="flex-shrink-0">
364
+ <div class="h-10 w-10 rounded-full bg-purple-500 flex items-center justify-center text-white">
365
+ <svg class="h-6 w-6" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
366
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M8 10h.01M12 10h.01M16 10h.01M9 16H5a2 2 0 01-2-2V6a2 2 0 012-2h14a2 2 0 012 2v8a2 2 0 01-2 2h-5l-5 5v-5z"></path>
367
+ </svg>
368
+ </div>
369
+ </div>
370
+ <div class="ml-4">
371
+ <h3 class="text-lg font-medium text-gray-900">AI Teacher Chat</h3>
372
+ <p class="text-sm text-gray-500">Ask me anything about the subject!</p>
373
+ </div>
374
+ </div>
375
+
376
+ <div id="chat-container" class="h-96 overflow-y-auto mb-4 space-y-4">
377
+ <div class="chat-bubble">
378
+ <p>Hello! I'm your AI teacher. How can I help you with your studies today?</p>
379
+ </div>
380
+ </div>
381
+
382
+ <div class="mt-4">
383
+ <div class="flex">
384
+ <input type="text" id="user-question" placeholder="Type your question here..." class="flex-1 min-w-0 block w-full px-3 py-2 rounded-l-md border border-gray-300 focus:outline-none focus:ring-purple-500 focus:border-purple-500 sm:text-sm">
385
+ <button onclick="askQuestion()" class="inline-flex items-center px-4 py-2 border border-transparent text-sm font-medium rounded-r-md text-white bg-purple-600 hover:bg-purple-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
386
+ Ask
387
+ </button>
388
+ </div>
389
+ </div>
390
+ </div>
391
+ </div>
392
+
393
+ <div class="mt-8 bg-white rounded-xl shadow-lg p-6">
394
+ <h3 class="text-lg font-medium text-gray-900 mb-4">Suggested Questions</h3>
395
+ <div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4">
396
+ <button onclick="setQuestion('Explain quantum physics in simple terms')" class="px-4 py-2 border border-gray-300 rounded-md text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
397
+ Explain quantum physics
398
+ </button>
399
+ <button onclick="setQuestion('What is the Pythagorean theorem?')" class="px-4 py-2 border border-gray-300 rounded-md text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
400
+ Pythagorean theorem
401
+ </button>
402
+ <button onclick="setQuestion('How does photosynthesis work?')" class="px-4 py-2 border border-gray-300 rounded-md text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
403
+ Photosynthesis explained
404
+ </button>
405
+ <button onclick="setQuestion('Can you help me with calculus?')" class="px-4 py-2 border border-gray-300 rounded-md text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500">
406
+ Help with calculus
407
+ </button>
408
+ </div>
409
+ </div>
410
+ </div>
411
+ </div>
412
+
413
+ <script>
414
+ // Show the specified page and hide all others
415
+ function showPage(pageId) {
416
+ document.querySelectorAll('.page').forEach(page => {
417
+ page.classList.remove('active');
418
+ });
419
+ document.getElementById(pageId).classList.add('active');
420
+ }
421
+
422
+ // Form handling
423
+ document.getElementById('loginForm').addEventListener('submit', function(e) {
424
+ e.preventDefault();
425
+ const email = document.getElementById('login-email').value;
426
+ const password = document.getElementById('login-password').value;
427
+
428
+ // Simple validation
429
+ if (email && password) {
430
+ alert('Login successful! Redirecting to home page...');
431
+ showPage('home');
432
+ } else {
433
+ alert('Please fill in all fields');
434
+ }
435
+ });
436
+
437
+ document.getElementById('signupForm').addEventListener('submit', function(e) {
438
+ e.preventDefault();
439
+ const name = document.getElementById('signup-name').value;
440
+ const email = document.getElementById('signup-email').value;
441
+ const password = document.getElementById('signup-password').value;
442
+ const confirmPassword = document.getElementById('signup-confirm-password').value;
443
+
444
+ // Simple validation
445
+ if (!name || !email || !password || !confirmPassword) {
446
+ alert('Please fill in all fields');
447
+ return;
448
+ }
449
+
450
+ if (password !== confirmPassword) {
451
+ alert('Passwords do not match');
452
+ return;
453
+ }
454
+
455
+ if (!document.getElementById('terms').checked) {
456
+ alert('You must agree to the terms and conditions');
457
+ return;
458
+ }
459
+
460
+ alert('Account created successfully! Please login.');
461
+ showPage('login');
462
+ });
463
+
464
+ // AI Teacher Page functionality
465
+ function setQuestion(question) {
466
+ document.getElementById('user-question').value = question;
467
+ }
468
+
469
+ function askQuestion() {
470
+ const questionInput = document.getElementById('user-question');
471
+ const question = questionInput.value.trim();
472
+
473
+ if (!question) {
474
+ alert('Please enter a question');
475
+ return;
476
+ }
477
+
478
+ // Add user question to chat
479
+ const chatContainer = document.getElementById('chat-container');
480
+ const userBubble = document.createElement('div');
481
+ userBubble.className = 'chat-bubble user-bubble';
482
+ userBubble.innerHTML = `<p>${question}</p>`;
483
+ chatContainer.appendChild(userBubble);
484
+
485
+ // Clear input
486
+ questionInput.value = '';
487
+
488
+ // Simulate AI response after a delay
489
+ setTimeout(() => {
490
+ const aiBubble = document.createElement('div');
491
+ aiBubble.className = 'chat-bubble';
492
+
493
+ // Simple response logic - in a real app, this would call an API
494
+ const responses = [
495
+ "That's an excellent question! The answer is that it depends on several factors we need to consider.",
496
+ "I'd be happy to explain that concept. Essentially, it works through a process of interaction between multiple components.",
497
+ "This is a fundamental concept in the field. The key points to understand are the underlying principles that govern this behavior.",
498
+ "Let me break this down for you. First, we need to understand the basic components before we can explore the more complex aspects."
499
+ ];
500
+
501
+ const randomResponse = responses[Math.floor(Math.random() * responses.length)];
502
+ aiBubble.innerHTML = `<p>${randomResponse}</p>`;
503
+ chatContainer.appendChild(aiBubble);
504
+
505
+ // Scroll to bottom of chat
506
+ chatContainer.scrollTop = chatContainer.scrollHeight;
507
+
508
+ // Animate teacher model (in a real app, this would trigger specific animations)
509
+ animateTeacher();
510
+ }, 1000);
511
+ }
512
+
513
+ function animateTeacher() {
514
+ // In a real implementation, this would trigger specific animations on the 3D model
515
+ console.log("Teacher is responding with animation");
516
+ }
517
+
518
+ // Initialize 3D Teacher Model
519
+ let scene, camera, renderer, teacher;
520
+
521
+ function initTeacherModel() {
522
+ // Create scene
523
+ scene = new THREE.Scene();
524
+ scene.background = new THREE.Color(0xf0f0f0);
525
+
526
+ // Create camera
527
+ camera = new THREE.PerspectiveCamera(75, window.innerWidth / window.innerHeight, 0.1, 1000);
528
+ camera.position.z = 5;
529
+
530
+ // Create renderer
531
+ const container = document.getElementById('teacher-container');
532
+ renderer = new THREE.WebGLRenderer({ antialias: true });
533
+ renderer.setSize(container.clientWidth, container.clientHeight);
534
+ container.appendChild(renderer.domElement);
535
+
536
+ // Add lights
537
+ const ambientLight = new THREE.AmbientLight(0xffffff, 0.5);
538
+ scene.add(ambientLight);
539
+
540
+ const directionalLight = new THREE.DirectionalLight(0xffffff, 0.8);
541
+ directionalLight.position.set(0, 1, 1);
542
+ scene.add(directionalLight);
543
+
544
+ // Add placeholder geometry (in a real app, this would be a GLTF model)
545
+ const geometry = new THREE.BoxGeometry(1, 2, 1);
546
+ const material = new THREE.MeshPhongMaterial({ color: 0x00ff00 });
547
+ teacher = new THREE.Mesh(geometry, material);
548
+ scene.add(teacher);
549
+
550
+ // Add controls
551
+ const controls = new THREE.OrbitControls(camera, renderer.domElement);
552
+ controls.enableZoom = true;
553
+ controls.enablePan = false;
554
+ controls.enableDamping = true;
555
+ controls.dampingFactor = 0.05;
556
+
557
+ // Handle window resize
558
+ window.addEventListener('resize', onWindowResize);
559
+
560
+ // Start animation loop
561
+ animate();
562
+ }
563
+
564
+ function onWindowResize() {
565
+ const container = document.getElementById('teacher-container');
566
+ camera.aspect = container.clientWidth / container.clientHeight;
567
+ camera.updateProjectionMatrix();
568
+ renderer.setSize(container.clientWidth, container.clientHeight);
569
+ }
570
+
571
+ function animate() {
572
+ requestAnimationFrame(animate);
573
+
574
+ // Simple animation for the placeholder
575
+ if (teacher) {
576
+ teacher.rotation.y += 0.01;
577
+ }
578
+
579
+ renderer.render(scene, camera);
580
+ }
581
+
582
+ // Initialize the page when loaded
583
+ document.addEventListener('DOMContentLoaded', function() {
584
+ // Show home page by default
585
+ showPage('home');
586
+
587
+ // Initialize 3D teacher model on AI page
588
+ if (document.getElementById('teacher-container')) {
589
+ initTeacherModel();
590
+ }
591
+ });
592
+ </script>
593
+ <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=precison9/ai-teacher" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
594
+ </html>