Create a single-page, responsive web application called "AI Media & Model Hub" with a modern, dark-themed interface (black background, white text, and teal accents). The app should have a sticky, minimal navigation bar at the top with links to four sections: Home, Media Manager, Model Manager, and AI Agent Interface. Ensure the app is SEO-optimized with appropriate metadata and responsive design for all screen sizes. Home Section: Display a welcome message with a fullscreen hero image (use a placeholder image of a futuristic AI interface). Include a brief description of the app’s features and a "Get Started" button linking to the Media Manager section. Media Manager Section: Provide a file explorer interface to access and preview various media and file types (images: PNG, JPEG; audio: MP3; video: MP4; documents: PDF, TXT). Allow users to upload files via a drag-and-drop zone or file input (use browser-based file handling). Display files in a grid with thumbnails for media and icons for documents. Clicking a file shows a preview (images/videos in a lightbox, audio in a player, text/PDF in a readable viewer). Include a download button for each file. Model Manager Section: Create a dashboard to manage AI models. Show a table listing mock AI models (e.g., "Model A: Image Recognition", "Model B: NLP") with columns for name, type, size, and actions. Actions include "Uninstall" (delete model from list) and "Install" (upload a model file or input a URL to simulate adding a model). Include a form to upload or link new models with fields for name, type, and description. Display a confirmation dialog for uninstall actions. AI Agent Interface Section: Design an interactive chat-like interface to prompt AI agents within a fictional "implants" system. Include a text input box for users to enter prompts (e.g., "Analyze image data" or "Generate report"). Display responses in a conversation-style layout with mock AI responses (e.g., "Processing request..." or "Report generated"). Add a dropdown to select different AI agents (e.g., "Vision Agent", "Text Agent"). Include a "Clear Chat" button to reset the conversation. Ensure the app uses clean, production-ready HTML, CSS, and JavaScript, contained in a single HTML file for easy export. Provide real-time previews of all interactions (e.g., file uploads, model changes, chat updates). Add subtle animations for section transitions and button clicks. Include built-in SEO tools for metadata and page structure optimization. Make the app accessible to non-technical users with clear labels and tooltips. - Initial Deployment
Browse files- README.md +6 -4
- index.html +777 -19
- prompts.txt +1 -0
README.md
CHANGED
|
@@ -1,10 +1,12 @@
|
|
| 1 |
---
|
| 2 |
-
title:
|
| 3 |
-
emoji:
|
| 4 |
colorFrom: pink
|
| 5 |
-
colorTo:
|
| 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: maybe
|
| 3 |
+
emoji: 🐳
|
| 4 |
colorFrom: pink
|
| 5 |
+
colorTo: pink
|
| 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,777 @@
|
|
| 1 |
-
<!
|
| 2 |
-
<html>
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>AI Media & Model Hub | Advanced Content Management</title>
|
| 7 |
+
<meta name="description" content="Next-gen interface for managing AI models, media files, and interacting with intelligent agents">
|
| 8 |
+
<meta name="keywords" content="AI, media manager, model manager, neural networks, agent interface">
|
| 9 |
+
<meta name="author" content="AI Media Hub">
|
| 10 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
| 11 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
| 12 |
+
<style>
|
| 13 |
+
/* Custom styles that Tailwind doesn't cover */
|
| 14 |
+
.hero-bg {
|
| 15 |
+
background-image: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.9)), url('https://images.unsplash.com/photo-1677442135136-760c813a743a?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2070&q=80');
|
| 16 |
+
background-size: cover;
|
| 17 |
+
background-position: center;
|
| 18 |
+
}
|
| 19 |
+
|
| 20 |
+
.file-card {
|
| 21 |
+
transition: all 0.3s ease;
|
| 22 |
+
}
|
| 23 |
+
|
| 24 |
+
.file-card:hover {
|
| 25 |
+
transform: translateY(-5px);
|
| 26 |
+
box-shadow: 0 10px 20px rgba(0, 255, 203, 0.1);
|
| 27 |
+
}
|
| 28 |
+
|
| 29 |
+
.chat-message {
|
| 30 |
+
animation: fadeIn 0.3s ease;
|
| 31 |
+
}
|
| 32 |
+
|
| 33 |
+
@keyframes fadeIn {
|
| 34 |
+
from { opacity: 0; transform: translateY(10px); }
|
| 35 |
+
to { opacity: 1; transform: translateY(0); }
|
| 36 |
+
}
|
| 37 |
+
|
| 38 |
+
.drag-drop-area {
|
| 39 |
+
border: 2px dashed #0ff1ce;
|
| 40 |
+
transition: all 0.3s ease;
|
| 41 |
+
}
|
| 42 |
+
|
| 43 |
+
.drag-drop-area.active {
|
| 44 |
+
background-color: rgba(0, 255, 203, 0.1);
|
| 45 |
+
border-color: #0ff1ce;
|
| 46 |
+
}
|
| 47 |
+
|
| 48 |
+
.preview-backdrop {
|
| 49 |
+
background-color: rgba(0, 0, 0, 0.9);
|
| 50 |
+
backdrop-filter: blur(10px);
|
| 51 |
+
}
|
| 52 |
+
|
| 53 |
+
.section {
|
| 54 |
+
opacity: 0;
|
| 55 |
+
transform: translateY(20px);
|
| 56 |
+
transition: opacity 0.5s ease, transform 0.5s ease;
|
| 57 |
+
}
|
| 58 |
+
|
| 59 |
+
.section.active {
|
| 60 |
+
opacity: 1;
|
| 61 |
+
transform: translateY(0);
|
| 62 |
+
}
|
| 63 |
+
</style>
|
| 64 |
+
</head>
|
| 65 |
+
<body class="bg-black text-white min-h-screen">
|
| 66 |
+
<!-- Navigation -->
|
| 67 |
+
<nav class="sticky top-0 z-50 bg-gray-900 bg-opacity-90 backdrop-filter backdrop-blur-md shadow-lg">
|
| 68 |
+
<div class="container mx-auto px-4 py-3">
|
| 69 |
+
<div class="flex justify-between items-center">
|
| 70 |
+
<div class="flex items-center space-x-4">
|
| 71 |
+
<span class="text-2xl font-bold bg-gradient-to-r from-teal-400 to-cyan-500 bg-clip-text text-transparent">AI Hub</span>
|
| 72 |
+
</div>
|
| 73 |
+
<div class="hidden md:flex space-x-8">
|
| 74 |
+
<a href="#home" class="nav-link hover:text-teal-400 transition duration-300">Home</a>
|
| 75 |
+
<a href="#media" class="nav-link hover:text-teal-400 transition duration-300">Media Manager</a>
|
| 76 |
+
<a href="#models" class="nav-link hover:text-teal-400 transition duration-300">Model Manager</a>
|
| 77 |
+
<a href="#agent" class="nav-link hover:text-teal-400 transition duration-300">AI Agent</a>
|
| 78 |
+
</div>
|
| 79 |
+
<button class="md:hidden focus:outline-none" id="menu-toggle">
|
| 80 |
+
<i class="fas fa-bars text-xl"></i>
|
| 81 |
+
</button>
|
| 82 |
+
</div>
|
| 83 |
+
|
| 84 |
+
<!-- Mobile menu -->
|
| 85 |
+
<div class="md:hidden hidden mt-4 space-y-3" id="mobile-menu">
|
| 86 |
+
<a href="#home" class="block nav-link hover:text-teal-400 transition duration-300">Home</a>
|
| 87 |
+
<a href="#media" class="block nav-link hover:text-teal-400 transition duration-300">Media Manager</a>
|
| 88 |
+
<a href="#models" class="block nav-link hover:text-teal-400 transition duration-300">Model Manager</a>
|
| 89 |
+
<a href="#agent" class="block nav-link hover:text-teal-400 transition duration-300">AI Agent</a>
|
| 90 |
+
</div>
|
| 91 |
+
</div>
|
| 92 |
+
</nav>
|
| 93 |
+
|
| 94 |
+
<!-- Main Content -->
|
| 95 |
+
<main class="container mx-auto px-4 py-8">
|
| 96 |
+
<!-- Home Section -->
|
| 97 |
+
<section id="home" class="section min-h-screen flex items-center hero-bg rounded-xl mb-12">
|
| 98 |
+
<div class="container mx-auto px-4 py-20">
|
| 99 |
+
<div class="max-w-3xl">
|
| 100 |
+
<h1 class="text-5xl md:text-7xl font-bold mb-6 leading-tight">
|
| 101 |
+
<span class="bg-gradient-to-r from-teal-400 to-cyan-500 bg-clip-text text-transparent">AI Media & Model Hub</span>
|
| 102 |
+
</h1>
|
| 103 |
+
<p class="text-xl md:text-2xl text-gray-300 mb-8">
|
| 104 |
+
A unified interface for managing your digital assets, AI models, and intelligent agents.
|
| 105 |
+
Streamline your workflow with our next-generation content management system.
|
| 106 |
+
</p>
|
| 107 |
+
<div class="space-x-4">
|
| 108 |
+
<a href="#media" class="bg-gradient-to-r from-teal-500 to-cyan-600 text-white px-6 py-3 rounded-full font-medium hover:opacity-90 transition duration-300 inline-flex items-center">
|
| 109 |
+
Get Started <i class="fas fa-arrow-down ml-2"></i>
|
| 110 |
+
</a>
|
| 111 |
+
<a href="#models" class="border border-teal-400 text-teal-400 px-6 py-3 rounded-full font-medium hover:bg-teal-400 hover:bg-opacity-10 transition duration-300 inline-flex items-center">
|
| 112 |
+
Explore Models <i class="fas fa-robot ml-2"></i>
|
| 113 |
+
</a>
|
| 114 |
+
</div>
|
| 115 |
+
</div>
|
| 116 |
+
</div>
|
| 117 |
+
</section>
|
| 118 |
+
|
| 119 |
+
<!-- Media Manager Section -->
|
| 120 |
+
<section id="media" class="section mb-20">
|
| 121 |
+
<div class="flex items-center mb-8">
|
| 122 |
+
<i class="fas fa-photo-film text-teal-400 text-3xl mr-4"></i>
|
| 123 |
+
<h2 class="text-3xl font-bold">Media Manager</h2>
|
| 124 |
+
</div>
|
| 125 |
+
|
| 126 |
+
<!-- File Upload Area -->
|
| 127 |
+
<div class="drag-drop-area p-12 rounded-xl mb-8 text-center cursor-pointer transition-all"
|
| 128 |
+
id="drag-drop-area">
|
| 129 |
+
<div class="max-w-md mx-auto">
|
| 130 |
+
<i class="fas fa-cloud-arrow-up text-5xl mb-4 text-teal-400"></i>
|
| 131 |
+
<h3 class="text-xl font-semibold mb-2">Drag & Drop Files Here</h3>
|
| 132 |
+
<p class="text-gray-400 mb-4">or click to browse your device</p>
|
| 133 |
+
<input type="file" id="file-input" class="hidden" multiple>
|
| 134 |
+
<button class="bg-gray-800 hover:bg-gray-700 text-white px-4 py-2 rounded transition duration-300">
|
| 135 |
+
Select Files
|
| 136 |
+
</button>
|
| 137 |
+
</div>
|
| 138 |
+
</div>
|
| 139 |
+
|
| 140 |
+
<!-- File Explorer -->
|
| 141 |
+
<div class="mb-8">
|
| 142 |
+
<div class="flex justify-between items-center mb-4">
|
| 143 |
+
<h3 class="text-xl font-semibold">Your Media Files</h3>
|
| 144 |
+
<div class="flex space-x-2">
|
| 145 |
+
<button class="bg-gray-800 hover:bg-gray-700 px-3 py-1 rounded">
|
| 146 |
+
<i class="fas fa-th-large"></i>
|
| 147 |
+
</button>
|
| 148 |
+
<button class="bg-gray-800 hover:bg-gray-700 px-3 py-1 rounded">
|
| 149 |
+
<i class="fas fa-list"></i>
|
| 150 |
+
</button>
|
| 151 |
+
<button class="bg-gray-800 hover:bg-gray-700 px-3 py-1 rounded">
|
| 152 |
+
<i class="fas fa-filter"></i> Filter
|
| 153 |
+
</button>
|
| 154 |
+
</div>
|
| 155 |
+
</div>
|
| 156 |
+
|
| 157 |
+
<!-- File Grid -->
|
| 158 |
+
<div class="grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-5 gap-4" id="file-grid">
|
| 159 |
+
<!-- Sample files will be generated by JS -->
|
| 160 |
+
</div>
|
| 161 |
+
</div>
|
| 162 |
+
|
| 163 |
+
<!-- File Preview Modal -->
|
| 164 |
+
<div class="fixed inset-0 z-50 flex items-center justify-center preview-backdrop hidden" id="preview-modal">
|
| 165 |
+
<div class="bg-gray-900 rounded-xl max-w-4xl w-full max-h-[90vh] overflow-auto relative">
|
| 166 |
+
<button class="absolute top-4 right-4 bg-gray-800 hover:bg-gray-700 p-2 rounded-full" id="close-preview">
|
| 167 |
+
<i class="fas fa-times"></i>
|
| 168 |
+
</button>
|
| 169 |
+
<div class="p-8" id="preview-content">
|
| 170 |
+
<!-- Preview content will be inserted here -->
|
| 171 |
+
</div>
|
| 172 |
+
</div>
|
| 173 |
+
</div>
|
| 174 |
+
</section>
|
| 175 |
+
|
| 176 |
+
<!-- Model Manager Section -->
|
| 177 |
+
<section id="models" class="section mb-20">
|
| 178 |
+
<div class="flex items-center mb-8">
|
| 179 |
+
<i class="fas fa-robot text-teal-400 text-3xl mr-4"></i>
|
| 180 |
+
<h2 class="text-3xl font-bold">Model Manager</h2>
|
| 181 |
+
</div>
|
| 182 |
+
|
| 183 |
+
<div class="grid md:grid-cols-3 gap-8 mb-8">
|
| 184 |
+
<div class="md:col-span-2 order-1">
|
| 185 |
+
<div class="bg-gray-900 rounded-xl p-6 shadow-lg">
|
| 186 |
+
<h3 class="text-xl font-semibold mb-4">Installed AI Models</h3>
|
| 187 |
+
|
| 188 |
+
<div class="overflow-x-auto">
|
| 189 |
+
<table class="min-w-full">
|
| 190 |
+
<thead>
|
| 191 |
+
<tr class="border-b border-gray-800">
|
| 192 |
+
<th class="text-left py-3 px-4">Name</th>
|
| 193 |
+
<th class="text-left py-3 px-4">Type</th>
|
| 194 |
+
<th class="text-left py-3 px-4">Size</th>
|
| 195 |
+
<th class="text-left py-3 px-4">Actions</th>
|
| 196 |
+
</tr>
|
| 197 |
+
</thead>
|
| 198 |
+
<tbody id="model-table-body">
|
| 199 |
+
<!-- Model rows will be inserted here by JS -->
|
| 200 |
+
</tbody>
|
| 201 |
+
</table>
|
| 202 |
+
</div>
|
| 203 |
+
</div>
|
| 204 |
+
</div>
|
| 205 |
+
|
| 206 |
+
<div class="order-2">
|
| 207 |
+
<div class="bg-gray-900 rounded-xl p-6 shadow-lg">
|
| 208 |
+
<h3 class="text-xl font-semibold mb-4">Install New Model</h3>
|
| 209 |
+
|
| 210 |
+
<form id="model-form">
|
| 211 |
+
<div class="mb-4">
|
| 212 |
+
<label class="block text-gray-400 mb-2">Model Name</label>
|
| 213 |
+
<input type="text" class="w-full bg-gray-800 border border-gray-700 rounded px-4 py-2" required>
|
| 214 |
+
</div>
|
| 215 |
+
|
| 216 |
+
<div class="mb-4">
|
| 217 |
+
<label class="block text-gray-400 mb-2">Model Type</label>
|
| 218 |
+
<select class="w-full bg-gray-800 border border-gray-700 rounded px-4 py-2">
|
| 219 |
+
<option>Computer Vision</option>
|
| 220 |
+
<option>Natural Language</option>
|
| 221 |
+
<option>Generative</option>
|
| 222 |
+
<option>Other</option>
|
| 223 |
+
</select>
|
| 224 |
+
</div>
|
| 225 |
+
|
| 226 |
+
<div class="mb-4">
|
| 227 |
+
<label class="block text-gray-400 mb-2">Source</label>
|
| 228 |
+
<div class="flex items-center bg-gray-800 border border-gray-700 rounded overflow-hidden">
|
| 229 |
+
<input type="file" class="hidden" id="model-file-input">
|
| 230 |
+
<input type="text" placeholder="File or URL" class="flex-1 bg-transparent px-4 py-2" id="model-source">
|
| 231 |
+
<button type="button" class="bg-gray-700 hover:bg-gray-600 px-3 py-2" id="browse-model">
|
| 232 |
+
<i class="fas fa-folder-open"></i>
|
| 233 |
+
</button>
|
| 234 |
+
</div>
|
| 235 |
+
</div>
|
| 236 |
+
|
| 237 |
+
<div class="mb-4">
|
| 238 |
+
<label class="block text-gray-400 mb-2">Description</label>
|
| 239 |
+
<textarea class="w-full bg-gray-800 border border-gray-700 rounded px-4 py-2 h-20"></textarea>
|
| 240 |
+
</div>
|
| 241 |
+
|
| 242 |
+
<button type="submit" class="w-full bg-teal-500 hover:bg-teal-600 text-white py-2 rounded font-medium">
|
| 243 |
+
<i class="fas fa-plus mr-2"></i> Add Model
|
| 244 |
+
</button>
|
| 245 |
+
</form>
|
| 246 |
+
</div>
|
| 247 |
+
</div>
|
| 248 |
+
</div>
|
| 249 |
+
|
| 250 |
+
<!-- Uninstall Confirmation Modal -->
|
| 251 |
+
<div class="fixed inset-0 z-50 flex items-center justify-center bg-black bg-opacity-70 hidden" id="confirmation-modal">
|
| 252 |
+
<div class="bg-gray-900 rounded-xl p-6 max-w-md w-full">
|
| 253 |
+
<h3 class="text-xl font-semibold mb-4">Confirm Uninstall</h3>
|
| 254 |
+
<p class="text-gray-400 mb-6">Are you sure you want to uninstall this model? This action cannot be undone.</p>
|
| 255 |
+
<div class="flex justify-end space-x-4">
|
| 256 |
+
<button class="px-4 py-2 rounded border border-gray-700 hover:bg-gray-800" id="cancel-uninstall">Cancel</button>
|
| 257 |
+
<button class="px-4 py-2 rounded bg-red-600 hover:bg-red-700" id="confirm-uninstall">Uninstall</button>
|
| 258 |
+
</div>
|
| 259 |
+
</div>
|
| 260 |
+
</div>
|
| 261 |
+
</section>
|
| 262 |
+
|
| 263 |
+
<!-- AI Agent Interface Section -->
|
| 264 |
+
<section id="agent" class="section mb-20">
|
| 265 |
+
<div class="flex items-center mb-8">
|
| 266 |
+
<i class="fas fa-comments text-teal-400 text-3xl mr-4"></i>
|
| 267 |
+
<h2 class="text-3xl font-bold">AI Agent Interface</h2>
|
| 268 |
+
</div>
|
| 269 |
+
|
| 270 |
+
<div class="bg-gray-900 rounded-xl shadow-lg overflow-hidden">
|
| 271 |
+
<!-- Agent Selector -->
|
| 272 |
+
<div class="border-b border-gray-800 p-4 flex items-center">
|
| 273 |
+
<div class="mr-4">
|
| 274 |
+
<span class="text-gray-400 text-sm">Active Agent:</span>
|
| 275 |
+
<select class="bg-gray-800 border border-gray-700 rounded px-3 py-1 ml-2">
|
| 276 |
+
<option>Vision Agent (v1.2.4)</option>
|
| 277 |
+
<option>Text Agent (v2.1.0)</option>
|
| 278 |
+
<option>Analysis Agent (v1.5.3)</option>
|
| 279 |
+
</select>
|
| 280 |
+
</div>
|
| 281 |
+
<div class="ml-auto">
|
| 282 |
+
<button class="text-gray-400 hover:text-teal-400 px-3 py-1 rounded" id="clear-chat">
|
| 283 |
+
<i class="fas fa-trash mr-1"></i> Clear
|
| 284 |
+
</button>
|
| 285 |
+
</div>
|
| 286 |
+
</div>
|
| 287 |
+
|
| 288 |
+
<!-- Chat Area -->
|
| 289 |
+
<div class="p-4 h-96 overflow-y-auto" id="chat-area">
|
| 290 |
+
<div class="chat-message mb-4">
|
| 291 |
+
<div class="flex items-end">
|
| 292 |
+
<div class="flex-shrink-0 mr-3">
|
| 293 |
+
<div class="bg-teal-500 rounded-full w-8 h-8 flex items-center justify-center">
|
| 294 |
+
<i class="fas fa-robot text-sm"></i>
|
| 295 |
+
</div>
|
| 296 |
+
</div>
|
| 297 |
+
<div class="max-w-xs md:max-w-md bg-gray-800 rounded-lg px-4 py-2">
|
| 298 |
+
<p class="text-sm">Hello, I'm your AI assistant. How can I help you today?</p>
|
| 299 |
+
</div>
|
| 300 |
+
</div>
|
| 301 |
+
</div>
|
| 302 |
+
</div>
|
| 303 |
+
|
| 304 |
+
<!-- Input Area -->
|
| 305 |
+
<div class="border-t border-gray-800 p-4">
|
| 306 |
+
<div class="flex">
|
| 307 |
+
<input type="text" class="flex-1 bg-gray-800 border border-gray-700 rounded-l px-4 py-2 focus:outline-none focus:border-teal-500"
|
| 308 |
+
placeholder="Type your command or inquiry..." id="chat-input">
|
| 309 |
+
<button class="bg-teal-500 hover:bg-teal-600 px-6 py-2 rounded-r font-medium transition duration-300" id="send-message">
|
| 310 |
+
<i class="fas fa-paper-plane"></i>
|
| 311 |
+
</button>
|
| 312 |
+
</div>
|
| 313 |
+
<div class="mt-2 text-xs text-gray-500 flex justify-between">
|
| 314 |
+
<span>Press Enter to send</span>
|
| 315 |
+
<span>Token balance: <span class="text-teal-400 font-bold">24,531</span></span>
|
| 316 |
+
</div>
|
| 317 |
+
</div>
|
| 318 |
+
</div>
|
| 319 |
+
</section>
|
| 320 |
+
</main>
|
| 321 |
+
|
| 322 |
+
<!-- Footer -->
|
| 323 |
+
<footer class="bg-gray-900 border-t border-gray-800 py-8">
|
| 324 |
+
<div class="container mx-auto px-4">
|
| 325 |
+
<div class="flex flex-col md:flex-row justify-between items-center">
|
| 326 |
+
<div class="mb-4 md:mb-0">
|
| 327 |
+
<h3 class="text-xl font-bold bg-gradient-to-r from-teal-400 to-cyan-500 bg-clip-text text-transparent">AI Media & Model Hub</h3>
|
| 328 |
+
<p class="text-gray-500 text-sm">Next-generation content management</p>
|
| 329 |
+
</div>
|
| 330 |
+
<div class="flex space-x-6">
|
| 331 |
+
<a href="#" class="text-gray-400 hover:text-teal-400 transition duration-300">
|
| 332 |
+
<i class="fab fa-github"></i>
|
| 333 |
+
</a>
|
| 334 |
+
<a href="#" class="text-gray-400 hover:text-teal-400 transition duration-300">
|
| 335 |
+
<i class="fab fa-twitter"></i>
|
| 336 |
+
</a>
|
| 337 |
+
<a href="#" class="text-gray-400 hover:text-teal-400 transition duration-300">
|
| 338 |
+
<i class="fas fa-globe"></i>
|
| 339 |
+
</a>
|
| 340 |
+
<a href="#" class="text-gray-400 hover:text-teal-400 transition duration-300">
|
| 341 |
+
<i class="fas fa-envelope"></i>
|
| 342 |
+
</a>
|
| 343 |
+
</div>
|
| 344 |
+
</div>
|
| 345 |
+
<div class="mt-6 pt-6 border-t border-gray-800 text-center text-gray-500 text-sm">
|
| 346 |
+
<p>© 2023 AI Media & Model Hub. All rights reserved.</p>
|
| 347 |
+
</div>
|
| 348 |
+
</div>
|
| 349 |
+
</footer>
|
| 350 |
+
|
| 351 |
+
<script>
|
| 352 |
+
// Activate sections when they come into view
|
| 353 |
+
document.addEventListener('DOMContentLoaded', function() {
|
| 354 |
+
// Navigation
|
| 355 |
+
document.getElementById('menu-toggle').addEventListener('click', function() {
|
| 356 |
+
const menu = document.getElementById('mobile-menu');
|
| 357 |
+
menu.classList.toggle('hidden');
|
| 358 |
+
});
|
| 359 |
+
|
| 360 |
+
// Highlight current nav link
|
| 361 |
+
const navLinks = document.querySelectorAll('.nav-link');
|
| 362 |
+
function highlightNav() {
|
| 363 |
+
const fromTop = window.scrollY + 100;
|
| 364 |
+
|
| 365 |
+
navLinks.forEach(link => {
|
| 366 |
+
const section = document.querySelector(link.getAttribute('href'));
|
| 367 |
+
if (
|
| 368 |
+
section.offsetTop <= fromTop &&
|
| 369 |
+
section.offsetTop + section.offsetHeight > fromTop
|
| 370 |
+
) {
|
| 371 |
+
link.classList.add('text-teal-400');
|
| 372 |
+
link.classList.add('font-medium');
|
| 373 |
+
} else {
|
| 374 |
+
link.classList.remove('text-teal-400');
|
| 375 |
+
link.classList.remove('font-medium');
|
| 376 |
+
}
|
| 377 |
+
});
|
| 378 |
+
}
|
| 379 |
+
|
| 380 |
+
window.addEventListener('scroll', highlightNav);
|
| 381 |
+
highlightNav(); // Run once on load
|
| 382 |
+
|
| 383 |
+
// Section animations
|
| 384 |
+
const sections = document.querySelectorAll('.section');
|
| 385 |
+
function checkSections() {
|
| 386 |
+
sections.forEach(section => {
|
| 387 |
+
const rect = section.getBoundingClientRect();
|
| 388 |
+
if (rect.top < window.innerHeight - 100) {
|
| 389 |
+
section.classList.add('active');
|
| 390 |
+
}
|
| 391 |
+
});
|
| 392 |
+
}
|
| 393 |
+
|
| 394 |
+
window.addEventListener('scroll', checkSections);
|
| 395 |
+
checkSections(); // Run once on load
|
| 396 |
+
|
| 397 |
+
// Media Manager functionality
|
| 398 |
+
const fileGrid = document.getElementById('file-grid');
|
| 399 |
+
const dragDropArea = document.getElementById('drag-drop-area');
|
| 400 |
+
const fileInput = document.getElementById('file-input');
|
| 401 |
+
const previewModal = document.getElementById('preview-modal');
|
| 402 |
+
const closePreview = document.getElementById('close-preview');
|
| 403 |
+
const previewContent = document.getElementById('preview-content');
|
| 404 |
+
|
| 405 |
+
// Sample files
|
| 406 |
+
const sampleFiles = [
|
| 407 |
+
{ name: 'project_diagram.png', type: 'image', size: '1.2 MB', icon: 'fa-image' },
|
| 408 |
+
{ name: 'dataset_final.zip', type: 'archive', size: '458 MB', icon: 'fa-file-zipper' },
|
| 409 |
+
{ name: 'presentation.pdf', type: 'document', size: '8.4 MB', icon: 'fa-file-pdf' },
|
| 410 |
+
{ name: 'training_logs.txt', type: 'text', size: '32 KB', icon: 'fa-file-lines' },
|
| 411 |
+
{ name: 'sample_audio.mp3', type: 'audio', size: '3.5 MB', icon: 'fa-file-audio' },
|
| 412 |
+
{ name: 'demo_video.mp4', type: 'video', size: '24.8 MB', icon: 'fa-file-video' },
|
| 413 |
+
{ name: 'config.json', type: 'code', size: '12 KB', icon: 'fa-file-code' },
|
| 414 |
+
{ name: 'user_guide.docx', type: 'document', size: '2.1 MB', icon: 'fa-file-word' }
|
| 415 |
+
];
|
| 416 |
+
|
| 417 |
+
// Render sample files
|
| 418 |
+
function renderFiles() {
|
| 419 |
+
fileGrid.innerHTML = '';
|
| 420 |
+
sampleFiles.forEach(file => {
|
| 421 |
+
const fileCard = document.createElement('div');
|
| 422 |
+
fileCard.className = 'file-card bg-gray-900 hover:bg-gray-800 rounded-lg p-4 flex flex-col items-center cursor-pointer transition-all';
|
| 423 |
+
fileCard.innerHTML = `
|
| 424 |
+
<div class="text-teal-400 text-3xl mb-2">
|
| 425 |
+
<i class="fas ${file.icon}"></i>
|
| 426 |
+
</div>
|
| 427 |
+
<div class="text-center">
|
| 428 |
+
<h4 class="font-medium text-sm mb-1 truncate w-full">${file.name}</h4>
|
| 429 |
+
<p class="text-gray-400 text-xs">${file.size}</p>
|
| 430 |
+
</div>
|
| 431 |
+
`;
|
| 432 |
+
fileCard.addEventListener('click', () => previewFile(file));
|
| 433 |
+
fileGrid.appendChild(fileCard);
|
| 434 |
+
});
|
| 435 |
+
}
|
| 436 |
+
|
| 437 |
+
// Preview file function
|
| 438 |
+
function previewFile(file) {
|
| 439 |
+
let content = '';
|
| 440 |
+
|
| 441 |
+
if (file.type === 'image') {
|
| 442 |
+
content = `
|
| 443 |
+
<div class="flex flex-col items-center">
|
| 444 |
+
<h4 class="text-xl font-medium mb-4">${file.name}</h4>
|
| 445 |
+
<img src="https://placehold.co/600x400/0f172a/22d3ee?text=${file.name}" alt="${file.name}" class="rounded-lg max-h-[60vh]">
|
| 446 |
+
<div class="mt-6 flex space-x-4">
|
| 447 |
+
<button class="bg-teal-500 hover:bg-teal-600 px-4 py-2 rounded">
|
| 448 |
+
<i class="fas fa-download mr-2"></i> Download
|
| 449 |
+
</button>
|
| 450 |
+
<button class="bg-gray-700 hover:bg-gray-600 px-4 py-2 rounded">
|
| 451 |
+
<i class="fas fa-edit mr-2"></i> Edit Metadata
|
| 452 |
+
</button>
|
| 453 |
+
</div>
|
| 454 |
+
</div>
|
| 455 |
+
`;
|
| 456 |
+
} else if (file.type === 'video') {
|
| 457 |
+
content = `
|
| 458 |
+
<div class="flex flex-col items-center">
|
| 459 |
+
<h4 class="text-xl font-medium mb-4">${file.name}</h4>
|
| 460 |
+
<video controls class="rounded-lg max-h-[60vh]">
|
| 461 |
+
<source src="https://sample-videos.com/video123/mp4/720/big_buck_bunny_720p_1mb.mp4" type="video/mp4">
|
| 462 |
+
Your browser does not support HTML video.
|
| 463 |
+
</video>
|
| 464 |
+
<div class="mt-6 flex space-x-4">
|
| 465 |
+
<button class="bg-teal-500 hover:bg-teal-600 px-4 py-2 rounded">
|
| 466 |
+
<i class="fas fa-download mr-2"></i> Download
|
| 467 |
+
</button>
|
| 468 |
+
</div>
|
| 469 |
+
</div>
|
| 470 |
+
`;
|
| 471 |
+
} else if (file.type === 'audio') {
|
| 472 |
+
content = `
|
| 473 |
+
<div class="flex flex-col items-center">
|
| 474 |
+
<h4 class="text-xl font-medium mb-4">${file.name}</h4>
|
| 475 |
+
<audio controls class="w-full max-w-md">
|
| 476 |
+
<source src="https://sample-videos.com/audio123/mp3/india-national-anthem.mp3" type="audio/mpeg">
|
| 477 |
+
Your browser does not support the audio element.
|
| 478 |
+
</audio>
|
| 479 |
+
<div class="mt-6 flex space-x-4">
|
| 480 |
+
<button class="bg-teal-500 hover:bg-teal-600 px-4 py-2 rounded">
|
| 481 |
+
<i class="fas fa-download mr-2"></i> Download
|
| 482 |
+
</button>
|
| 483 |
+
</div>
|
| 484 |
+
</div>
|
| 485 |
+
`;
|
| 486 |
+
} else {
|
| 487 |
+
content = `
|
| 488 |
+
<div class="flex flex-col items-center">
|
| 489 |
+
<h4 class="text-xl font-medium mb-4">${file.name}</h4>
|
| 490 |
+
<div class="bg-gray-800 p-6 rounded-lg w-full max-h-[60vh] overflow-auto">
|
| 491 |
+
<pre class="text-sm font-mono">This is a preview of the ${file.name} file. In a real application, you would see the actual file content here.
|
| 492 |
+
|
| 493 |
+
File size: ${file.size}
|
| 494 |
+
File type: ${file.type}</pre>
|
| 495 |
+
</div>
|
| 496 |
+
<div class="mt-6 flex space-x-4">
|
| 497 |
+
<button class="bg-teal-500 hover:bg-teal-600 px-4 py-2 rounded">
|
| 498 |
+
<i class="fas fa-download mr-2"></i> Download
|
| 499 |
+
</button>
|
| 500 |
+
</div>
|
| 501 |
+
</div>
|
| 502 |
+
`;
|
| 503 |
+
}
|
| 504 |
+
|
| 505 |
+
previewContent.innerHTML = content;
|
| 506 |
+
previewModal.classList.remove('hidden');
|
| 507 |
+
}
|
| 508 |
+
|
| 509 |
+
// Drag and drop functionality
|
| 510 |
+
['dragenter', 'dragover', 'dragleave', 'drop'].forEach(eventName => {
|
| 511 |
+
dragDropArea.addEventListener(eventName, preventDefaults, false);
|
| 512 |
+
});
|
| 513 |
+
|
| 514 |
+
function preventDefaults(e) {
|
| 515 |
+
e.preventDefault();
|
| 516 |
+
e.stopPropagation();
|
| 517 |
+
}
|
| 518 |
+
|
| 519 |
+
['dragenter', 'dragover'].forEach(eventName => {
|
| 520 |
+
dragDropArea.addEventListener(eventName, highlight, false);
|
| 521 |
+
});
|
| 522 |
+
|
| 523 |
+
['dragleave', 'drop'].forEach(eventName => {
|
| 524 |
+
dragDropArea.addEventListener(eventName, unhighlight, false);
|
| 525 |
+
});
|
| 526 |
+
|
| 527 |
+
function highlight() {
|
| 528 |
+
dragDropArea.classList.add('active');
|
| 529 |
+
}
|
| 530 |
+
|
| 531 |
+
function unhighlight() {
|
| 532 |
+
dragDropArea.classList.remove('active');
|
| 533 |
+
}
|
| 534 |
+
|
| 535 |
+
dragDropArea.addEventListener('drop', handleDrop, false);
|
| 536 |
+
dragDropArea.addEventListener('click', () => fileInput.click());
|
| 537 |
+
fileInput.addEventListener('change', handleFiles);
|
| 538 |
+
|
| 539 |
+
function handleDrop(e) {
|
| 540 |
+
const dt = e.dataTransfer;
|
| 541 |
+
const files = dt.files;
|
| 542 |
+
handleFiles({ target: { files } });
|
| 543 |
+
}
|
| 544 |
+
|
| 545 |
+
function handleFiles(e) {
|
| 546 |
+
const files = e.target.files;
|
| 547 |
+
if (files.length) {
|
| 548 |
+
alert(`You've selected ${files.length} file(s). In a real application, these would be uploaded.`);
|
| 549 |
+
// In a real app, you would upload files here
|
| 550 |
+
}
|
| 551 |
+
}
|
| 552 |
+
|
| 553 |
+
closePreview.addEventListener('click', () => {
|
| 554 |
+
previewModal.classList.add('hidden');
|
| 555 |
+
});
|
| 556 |
+
|
| 557 |
+
// Model Manager functionality
|
| 558 |
+
const modelTableBody = document.getElementById('model-table-body');
|
| 559 |
+
const modelForm = document.getElementById('model-form');
|
| 560 |
+
const browseModel = document.getElementById('browse-model');
|
| 561 |
+
const modelFileInput = document.getElementById('model-file-input');
|
| 562 |
+
const modelSource = document.getElementById('model-source');
|
| 563 |
+
const confirmationModal = document.getElementById('confirmation-modal');
|
| 564 |
+
const cancelUninstall = document.getElementById('cancel-uninstall');
|
| 565 |
+
const confirmUninstall = document.getElementById('confirm-uninstall');
|
| 566 |
+
|
| 567 |
+
let models = [
|
| 568 |
+
{ name: 'Vision Processor', type: 'Computer Vision', size: '1.8 GB', id: 1 },
|
| 569 |
+
{ name: 'NLP Transformer', type: 'Natural Language', size: '845 MB', id: 2 },
|
| 570 |
+
{ name: 'Image Generator', type: 'Generative', size: '2.4 GB', id: 3 }
|
| 571 |
+
];
|
| 572 |
+
|
| 573 |
+
let modelToUninstall = null;
|
| 574 |
+
|
| 575 |
+
function renderModels() {
|
| 576 |
+
modelTableBody.innerHTML = '';
|
| 577 |
+
models.forEach(model => {
|
| 578 |
+
const row = document.createElement('tr');
|
| 579 |
+
row.className = 'border-b border-gray-800 hover:bg-gray-800 transition duration-200';
|
| 580 |
+
row.innerHTML = `
|
| 581 |
+
<td class="py-3 px-4">${model.name}</td>
|
| 582 |
+
<td class="py-3 px-4">${model.type}</td>
|
| 583 |
+
<td class="py-3 px-4">${model.size}</td>
|
| 584 |
+
<td class="py-3 px-4">
|
| 585 |
+
<button class="text-red-400 hover:text-red-300 mr-3 uninstall-btn" data-id="${model.id}">
|
| 586 |
+
<i class="fas fa-trash"></i> Uninstall
|
| 587 |
+
</button>
|
| 588 |
+
<button class="text-teal-400 hover:text-teal-300 details-btn" data-id="${model.id}">
|
| 589 |
+
<i class="fas fa-info-circle"></i> Details
|
| 590 |
+
</button>
|
| 591 |
+
</td>
|
| 592 |
+
`;
|
| 593 |
+
modelTableBody.appendChild(row);
|
| 594 |
+
});
|
| 595 |
+
|
| 596 |
+
// Add event listeners to uninstall buttons
|
| 597 |
+
document.querySelectorAll('.uninstall-btn').forEach(btn => {
|
| 598 |
+
btn.addEventListener('click', (e) => {
|
| 599 |
+
const id = parseInt(e.target.getAttribute('data-id') || e.target.parentElement.getAttribute('data-id'));
|
| 600 |
+
modelToUninstall = id;
|
| 601 |
+
confirmationModal.classList.remove('hidden');
|
| 602 |
+
});
|
| 603 |
+
});
|
| 604 |
+
}
|
| 605 |
+
|
| 606 |
+
modelForm.addEventListener('submit', function(e) {
|
| 607 |
+
e.preventDefault();
|
| 608 |
+
const name = this.elements[0].value;
|
| 609 |
+
const type = this.elements[1].value;
|
| 610 |
+
const source = modelSource.value || "Manually added";
|
| 611 |
+
const description = this.elements[3].value;
|
| 612 |
+
|
| 613 |
+
const newModel = {
|
| 614 |
+
id: models.length + 1,
|
| 615 |
+
name: name,
|
| 616 |
+
type: type,
|
| 617 |
+
size: 'Calculating...',
|
| 618 |
+
source: source,
|
| 619 |
+
description: description
|
| 620 |
+
};
|
| 621 |
+
|
| 622 |
+
models.push(newModel);
|
| 623 |
+
renderModels();
|
| 624 |
+
|
| 625 |
+
// Simulate size calculation
|
| 626 |
+
setTimeout(() => {
|
| 627 |
+
const sizes = ['124 MB', '567 MB', '890 MB', '1.2 GB', '2.5 GB', '3.8 GB'];
|
| 628 |
+
newModel.size = sizes[Math.floor(Math.random() * sizes.length)];
|
| 629 |
+
renderModels();
|
| 630 |
+
}, 1500);
|
| 631 |
+
|
| 632 |
+
this.reset();
|
| 633 |
+
alert('Model added successfully!');
|
| 634 |
+
});
|
| 635 |
+
|
| 636 |
+
browseModel.addEventListener('click', () => {
|
| 637 |
+
modelFileInput.click();
|
| 638 |
+
});
|
| 639 |
+
|
| 640 |
+
modelFileInput.addEventListener('change', () => {
|
| 641 |
+
if (modelFileInput.files.length) {
|
| 642 |
+
modelSource.value = modelFileInput.files[0].name;
|
| 643 |
+
}
|
| 644 |
+
});
|
| 645 |
+
|
| 646 |
+
cancelUninstall.addEventListener('click', () => {
|
| 647 |
+
confirmationModal.classList.add('hidden');
|
| 648 |
+
modelToUninstall = null;
|
| 649 |
+
});
|
| 650 |
+
|
| 651 |
+
confirmUninstall.addEventListener('click', () => {
|
| 652 |
+
models = models.filter(model => model.id !== modelToUninstall);
|
| 653 |
+
renderModels();
|
| 654 |
+
confirmationModal.classList.add('hidden');
|
| 655 |
+
modelToUninstall = null;
|
| 656 |
+
});
|
| 657 |
+
|
| 658 |
+
// AI Agent Interface functionality
|
| 659 |
+
const chatArea = document.getElementById('chat-area');
|
| 660 |
+
const chatInput = document.getElementById('chat-input');
|
| 661 |
+
const sendMessageBtn = document.getElementById('send-message');
|
| 662 |
+
const clearChatBtn = document.getElementById('clear-chat');
|
| 663 |
+
|
| 664 |
+
sendMessageBtn.addEventListener('click', sendMessage);
|
| 665 |
+
chatInput.addEventListener('keypress', (e) => {
|
| 666 |
+
if (e.key === 'Enter') {
|
| 667 |
+
sendMessage();
|
| 668 |
+
}
|
| 669 |
+
});
|
| 670 |
+
|
| 671 |
+
clearChatBtn.addEventListener('click', () => {
|
| 672 |
+
chatArea.innerHTML = `
|
| 673 |
+
<div class="chat-message mb-4">
|
| 674 |
+
<div class="flex items-end">
|
| 675 |
+
<div class="flex-shrink-0 mr-3">
|
| 676 |
+
<div class="bg-teal-500 rounded-full w-8 h-8 flex items-center justify-center">
|
| 677 |
+
<i class="fas fa-robot text-sm"></i>
|
| 678 |
+
</div>
|
| 679 |
+
</div>
|
| 680 |
+
<div class="max-w-xs md:max-w-md bg-gray-800 rounded-lg px-4 py-2">
|
| 681 |
+
<p class="text-sm">Hello, I'm your AI assistant. How can I help you today?</p>
|
| 682 |
+
</div>
|
| 683 |
+
</div>
|
| 684 |
+
</div>
|
| 685 |
+
`;
|
| 686 |
+
});
|
| 687 |
+
|
| 688 |
+
function sendMessage() {
|
| 689 |
+
const message = chatInput.value.trim();
|
| 690 |
+
if (!message) return;
|
| 691 |
+
|
| 692 |
+
// Add user message
|
| 693 |
+
const userMessage = document.createElement('div');
|
| 694 |
+
userMessage.className = 'chat-message mb-4';
|
| 695 |
+
userMessage.innerHTML = `
|
| 696 |
+
<div class="flex items-end justify-end">
|
| 697 |
+
<div class="max-w-xs md:max-w-md bg-teal-600 rounded-lg px-4 py-2">
|
| 698 |
+
<p class="text-sm">${message}</p>
|
| 699 |
+
</div>
|
| 700 |
+
<div class="flex-shrink-0 ml-3">
|
| 701 |
+
<div class="bg-gray-700 rounded-full w-8 h-8 flex items-center justify-center">
|
| 702 |
+
<i class="fas fa-user text-sm"></i>
|
| 703 |
+
</div>
|
| 704 |
+
</div>
|
| 705 |
+
</div>
|
| 706 |
+
`;
|
| 707 |
+
chatArea.appendChild(userMessage);
|
| 708 |
+
|
| 709 |
+
// Clear input
|
| 710 |
+
chatInput.value = '';
|
| 711 |
+
|
| 712 |
+
// Add thinking indicator
|
| 713 |
+
const thinking = document.createElement('div');
|
| 714 |
+
thinking.className = 'chat-message mb-4';
|
| 715 |
+
thinking.innerHTML = `
|
| 716 |
+
<div class="flex items-end">
|
| 717 |
+
<div class="flex-shrink-0 mr-3">
|
| 718 |
+
<div class="bg-teal-500 rounded-full w-8 h-8 flex items-center justify-center">
|
| 719 |
+
<i class="fas fa-robot text-sm"></i>
|
| 720 |
+
</div>
|
| 721 |
+
</div>
|
| 722 |
+
<div class="max-w-xs md:max-w-md bg-gray-800 rounded-lg px-4 py-2">
|
| 723 |
+
<div class="flex space-x-2">
|
| 724 |
+
<div class="w-2 h-2 rounded-full bg-gray-400 animate-pulse"></div>
|
| 725 |
+
<div class="w-2 h-2 rounded-full bg-gray-400 animate-pulse delay-100"></div>
|
| 726 |
+
<div class="w-2 h-2 rounded-full bg-gray-400 animate-pulse delay-200"></div>
|
| 727 |
+
</div>
|
| 728 |
+
</div>
|
| 729 |
+
</div>
|
| 730 |
+
`;
|
| 731 |
+
chatArea.appendChild(thinking);
|
| 732 |
+
|
| 733 |
+
// Scroll to bottom
|
| 734 |
+
chatArea.scrollTop = chatArea.scrollHeight;
|
| 735 |
+
|
| 736 |
+
// Simulate AI response after a delay
|
| 737 |
+
setTimeout(() => {
|
| 738 |
+
thinking.remove();
|
| 739 |
+
|
| 740 |
+
const responses = [
|
| 741 |
+
`I've processed your request about "${message}" and found relevant data. Would you like me to elaborate on any specific aspect?`,
|
| 742 |
+
`Analysis complete. Based on my neural networks, I recommend checking the connected datasets for more context.`,
|
| 743 |
+
`Command understood. Executing task... Task completed successfully with 98.7% accuracy.`,
|
| 744 |
+
`Interesting inquiry! My neural matrix suggests this correlates with patterns we've seen before in similar contexts.`,
|
| 745 |
+
`Processing complete. The operation took 423ms across 8.2 million parameters.`
|
| 746 |
+
];
|
| 747 |
+
|
| 748 |
+
const randomResponse = responses[Math.floor(Math.random() * responses.length)];
|
| 749 |
+
|
| 750 |
+
const aiMessage = document.createElement('div');
|
| 751 |
+
aiMessage.className = 'chat-message mb-4';
|
| 752 |
+
aiMessage.innerHTML = `
|
| 753 |
+
<div class="flex items-end">
|
| 754 |
+
<div class="flex-shrink-0 mr-3">
|
| 755 |
+
<div class="bg-teal-500 rounded-full w-8 h-8 flex items-center justify-center">
|
| 756 |
+
<i class="fas fa-robot text-sm"></i>
|
| 757 |
+
</div>
|
| 758 |
+
</div>
|
| 759 |
+
<div class="max-w-xs md:max-w-md bg-gray-800 rounded-lg px-4 py-2">
|
| 760 |
+
<p class="text-sm">${randomResponse}</p>
|
| 761 |
+
</div>
|
| 762 |
+
</div>
|
| 763 |
+
`;
|
| 764 |
+
chatArea.appendChild(aiMessage);
|
| 765 |
+
|
| 766 |
+
// Scroll to bottom again
|
| 767 |
+
chatArea.scrollTop = chatArea.scrollHeight;
|
| 768 |
+
}, 1500 + Math.random() * 2000);
|
| 769 |
+
}
|
| 770 |
+
|
| 771 |
+
// Initialize everything
|
| 772 |
+
renderFiles();
|
| 773 |
+
renderModels();
|
| 774 |
+
});
|
| 775 |
+
</script>
|
| 776 |
+
<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=BlaqQloud/maybe" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
|
| 777 |
+
</html>
|
prompts.txt
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
Create a single-page, responsive web application called "AI Media & Model Hub" with a modern, dark-themed interface (black background, white text, and teal accents). The app should have a sticky, minimal navigation bar at the top with links to four sections: Home, Media Manager, Model Manager, and AI Agent Interface. Ensure the app is SEO-optimized with appropriate metadata and responsive design for all screen sizes. Home Section: Display a welcome message with a fullscreen hero image (use a placeholder image of a futuristic AI interface). Include a brief description of the app’s features and a "Get Started" button linking to the Media Manager section. Media Manager Section: Provide a file explorer interface to access and preview various media and file types (images: PNG, JPEG; audio: MP3; video: MP4; documents: PDF, TXT). Allow users to upload files via a drag-and-drop zone or file input (use browser-based file handling). Display files in a grid with thumbnails for media and icons for documents. Clicking a file shows a preview (images/videos in a lightbox, audio in a player, text/PDF in a readable viewer). Include a download button for each file. Model Manager Section: Create a dashboard to manage AI models. Show a table listing mock AI models (e.g., "Model A: Image Recognition", "Model B: NLP") with columns for name, type, size, and actions. Actions include "Uninstall" (delete model from list) and "Install" (upload a model file or input a URL to simulate adding a model). Include a form to upload or link new models with fields for name, type, and description. Display a confirmation dialog for uninstall actions. AI Agent Interface Section: Design an interactive chat-like interface to prompt AI agents within a fictional "implants" system. Include a text input box for users to enter prompts (e.g., "Analyze image data" or "Generate report"). Display responses in a conversation-style layout with mock AI responses (e.g., "Processing request..." or "Report generated"). Add a dropdown to select different AI agents (e.g., "Vision Agent", "Text Agent"). Include a "Clear Chat" button to reset the conversation. Ensure the app uses clean, production-ready HTML, CSS, and JavaScript, contained in a single HTML file for easy export. Provide real-time previews of all interactions (e.g., file uploads, model changes, chat updates). Add subtle animations for section transitions and button clicks. Include built-in SEO tools for metadata and page structure optimization. Make the app accessible to non-technical users with clear labels and tooltips.
|