can you make the stars in the backgroudn better - Initial Deployment
Browse files- README.md +6 -4
- index.html +186 -19
README.md
CHANGED
|
@@ -1,10 +1,12 @@
|
|
| 1 |
---
|
| 2 |
-
title:
|
| 3 |
-
emoji:
|
| 4 |
colorFrom: green
|
| 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: exodus
|
| 3 |
+
emoji: 🐳
|
| 4 |
colorFrom: green
|
| 5 |
+
colorTo: yellow
|
| 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,186 @@
|
|
| 1 |
-
<!
|
| 2 |
-
<html>
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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>Michael's AI</title>
|
| 7 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
| 8 |
+
<script defer src="https://cdn.jsdelivr.net/npm/alpinejs@3.x.x/dist/cdn.min.js"></script>
|
| 9 |
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
|
| 10 |
+
<style>
|
| 11 |
+
.stars {
|
| 12 |
+
position: fixed;
|
| 13 |
+
top: 0;
|
| 14 |
+
left: 0;
|
| 15 |
+
width: 100%;
|
| 16 |
+
height: 100%;
|
| 17 |
+
pointer-events: none;
|
| 18 |
+
z-index: -1;
|
| 19 |
+
}
|
| 20 |
+
|
| 21 |
+
.star {
|
| 22 |
+
position: absolute;
|
| 23 |
+
background: white;
|
| 24 |
+
border-radius: 50%;
|
| 25 |
+
animation: twinkle 3s infinite ease-in-out;
|
| 26 |
+
filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.8));
|
| 27 |
+
}
|
| 28 |
+
|
| 29 |
+
.star:nth-child(odd) {
|
| 30 |
+
animation-delay: 1.5s;
|
| 31 |
+
}
|
| 32 |
+
|
| 33 |
+
.star:nth-child(3n) {
|
| 34 |
+
animation-delay: 2.5s;
|
| 35 |
+
}
|
| 36 |
+
|
| 37 |
+
@keyframes twinkle {
|
| 38 |
+
0%, 100% { opacity: 0.3; transform: scale(1); }
|
| 39 |
+
50% { opacity: 1; transform: scale(1.3); filter: drop-shadow(0 0 8px rgba(255, 255, 255, 1)); }
|
| 40 |
+
}
|
| 41 |
+
|
| 42 |
+
.shooting-star {
|
| 43 |
+
position: absolute;
|
| 44 |
+
width: 4px;
|
| 45 |
+
height: 4px;
|
| 46 |
+
background: linear-gradient(45deg, white, transparent);
|
| 47 |
+
border-radius: 50%;
|
| 48 |
+
filter: drop-shadow(0 0 5px white);
|
| 49 |
+
animation: shoot 4s linear infinite;
|
| 50 |
+
}
|
| 51 |
+
|
| 52 |
+
@keyframes shoot {
|
| 53 |
+
0% {
|
| 54 |
+
transform: translateX(-100px) translateY(0px) rotate(45deg);
|
| 55 |
+
opacity: 1;
|
| 56 |
+
}
|
| 57 |
+
100% {
|
| 58 |
+
transform: translateX(calc(100vw + 100px)) translateY(calc(100vh + 100px)) rotate(45deg);
|
| 59 |
+
opacity: 0;
|
| 60 |
+
}
|
| 61 |
+
}
|
| 62 |
+
|
| 63 |
+
.gradient-text {
|
| 64 |
+
background: linear-gradient(90deg, #3b82f6, #8b5cf6);
|
| 65 |
+
-webkit-background-clip: text;
|
| 66 |
+
background-clip: text;
|
| 67 |
+
color: transparent;
|
| 68 |
+
}
|
| 69 |
+
|
| 70 |
+
.message-box {
|
| 71 |
+
transition: all 0.3s ease;
|
| 72 |
+
}
|
| 73 |
+
|
| 74 |
+
.message-box:hover {
|
| 75 |
+
transform: translateY(-2px);
|
| 76 |
+
box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
|
| 77 |
+
}
|
| 78 |
+
</style>
|
| 79 |
+
</head>
|
| 80 |
+
<body class="flex justify-center items-center h-screen overflow-hidden bg-black font-sans text-center px-6">
|
| 81 |
+
<div class="stars" id="stars"></div>
|
| 82 |
+
<h1 class="text-8xl font-bold mb-8 w-full text-center transition-all duration-500 transform hover:scale-110 text-white cursor-pointer" style="text-shadow: 0 0 10px rgba(255,255,255,0.5); filter: drop-shadow(0 0 5px transparent); hover:filter: drop-shadow(0 0 20px rgba(255,255,255,0.8));">Welcome</h1>
|
| 83 |
+
<div class="w-full max-w-2xl mx-auto bg-black/50 backdrop-blur-lg rounded-2xl shadow-2xl p-8 border border-white/20 message-box">
|
| 84 |
+
<h1 class="text-4xl lg:text-6xl font-bold font-sans text-white mb-6">
|
| 85 |
+
<span class="text-2xl lg:text-4xl text-white block font-medium mb-2">Michael's AI,</span>
|
| 86 |
+
<span class="text-white">Ask me anything</span>
|
| 87 |
+
</h1>
|
| 88 |
+
|
| 89 |
+
<div class="flex items-center mt-6 gap-3">
|
| 90 |
+
<textarea id="user-input" rows="4" class="mt-4 p-4 border-2 border-gray-700 rounded-xl flex-grow focus:border-blue-500 focus:ring-2 focus:ring-blue-500/50 transition-all bg-gray-900/70 text-white placeholder-gray-400 resize-none" placeholder="Type your message here..."></textarea>
|
| 91 |
+
<button id="send-button" onclick="sendMessage()" class="mt-4 px-6 py-4 bg-gradient-to-r from-blue-600 to-purple-600 text-white rounded-xl hover:from-blue-500 hover:to-purple-500 transition-all shadow-lg hover:shadow-xl active:scale-95 transform transition-transform duration-100">
|
| 92 |
+
<svg xmlns="http://www.w3.org/2000/svg" class="h-6 w-6" fill="none" viewBox="0 0 24 24" stroke="currentColor">
|
| 93 |
+
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 19l9 2-9-18-9 18 9-2zm0 0v-8" />
|
| 94 |
+
</svg>
|
| 95 |
+
</button>
|
| 96 |
+
</div>
|
| 97 |
+
<div id="response" class="mt-6 p-6 border-2 border-gray-700 rounded-xl w-full bg-gray-900/70 min-h-32 max-h-96 overflow-y-auto text-white prose prose-invert">
|
| 98 |
+
<p class="text-gray-400 italic">Waiting for your question...</p>
|
| 99 |
+
</div>
|
| 100 |
+
</div>
|
| 101 |
+
<script>
|
| 102 |
+
// Create stars
|
| 103 |
+
function createStars() {
|
| 104 |
+
const starsContainer = document.getElementById('stars');
|
| 105 |
+
const numStars = 150;
|
| 106 |
+
|
| 107 |
+
for (let i = 0; i < numStars; i++) {
|
| 108 |
+
const star = document.createElement('div');
|
| 109 |
+
star.className = 'star';
|
| 110 |
+
star.style.left = Math.random() * 100 + '%';
|
| 111 |
+
star.style.top = Math.random() * 100 + '%';
|
| 112 |
+
star.style.width = Math.random() * 3 + 1 + 'px';
|
| 113 |
+
star.style.height = star.style.width;
|
| 114 |
+
star.style.animationDelay = Math.random() * 3 + 's';
|
| 115 |
+
starsContainer.appendChild(star);
|
| 116 |
+
}
|
| 117 |
+
|
| 118 |
+
// Add shooting stars
|
| 119 |
+
setInterval(() => {
|
| 120 |
+
const shootingStar = document.createElement('div');
|
| 121 |
+
shootingStar.className = 'shooting-star';
|
| 122 |
+
shootingStar.style.top = Math.random() * 50 + '%';
|
| 123 |
+
starsContainer.appendChild(shootingStar);
|
| 124 |
+
|
| 125 |
+
setTimeout(() => {
|
| 126 |
+
shootingStar.remove();
|
| 127 |
+
}, 4000);
|
| 128 |
+
}, 3000);
|
| 129 |
+
}
|
| 130 |
+
|
| 131 |
+
document.addEventListener('DOMContentLoaded', function() {
|
| 132 |
+
createStars();
|
| 133 |
+
|
| 134 |
+
const userInput = document.getElementById('user-input');
|
| 135 |
+
const sendButton = document.getElementById('send-button');
|
| 136 |
+
const responseDiv = document.getElementById('response');
|
| 137 |
+
|
| 138 |
+
// Send message when button is clicked
|
| 139 |
+
sendButton.addEventListener('click', sendMessage);
|
| 140 |
+
|
| 141 |
+
// Send message when Enter key is pressed
|
| 142 |
+
userInput.addEventListener('keypress', function(e) {
|
| 143 |
+
if (e.key === 'Enter') {
|
| 144 |
+
sendMessage();
|
| 145 |
+
}
|
| 146 |
+
});
|
| 147 |
+
|
| 148 |
+
function sendMessage() {
|
| 149 |
+
const message = userInput.value.trim();
|
| 150 |
+
if (message === '') return;
|
| 151 |
+
|
| 152 |
+
// Show typing indicator
|
| 153 |
+
responseDiv.innerHTML = `
|
| 154 |
+
<div class="flex items-center space-x-2">
|
| 155 |
+
<div class="w-2 h-2 rounded-full bg-blue-400 animate-pulse"></div>
|
| 156 |
+
<div class="w-2 h-2 rounded-full bg-blue-400 animate-pulse delay-75"></div>
|
| 157 |
+
<div class="w-2 h-2 rounded-full bg-blue-400 animate-pulse delay-150"></div>
|
| 158 |
+
<span class="text-blue-400 ml-2">AI is thinking...</span>
|
| 159 |
+
</div>
|
| 160 |
+
`;
|
| 161 |
+
|
| 162 |
+
// Send message to backend
|
| 163 |
+
fetch('http://127.0.0.1:8000/chat', {
|
| 164 |
+
method: 'POST',
|
| 165 |
+
headers: {
|
| 166 |
+
'Content-Type': 'application/json',
|
| 167 |
+
},
|
| 168 |
+
body: JSON.stringify({ message: message })
|
| 169 |
+
})
|
| 170 |
+
.then(response => response.json())
|
| 171 |
+
.then(data => {
|
| 172 |
+
// Update response with AI's message
|
| 173 |
+
responseDiv.innerHTML = `<p class="text-white">${data.response}</p>`;
|
| 174 |
+
})
|
| 175 |
+
.catch(error => {
|
| 176 |
+
console.error('Error:', error);
|
| 177 |
+
responseDiv.innerHTML = '<p class="text-red-400">Error: Could not connect to AI. Please try again.</p>';
|
| 178 |
+
});
|
| 179 |
+
|
| 180 |
+
// Clear input
|
| 181 |
+
userInput.value = '';
|
| 182 |
+
}
|
| 183 |
+
});
|
| 184 |
+
</script>
|
| 185 |
+
<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=Sureblo/exodus" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
|
| 186 |
+
</html>
|