Update index.html
Browse files- index.html +17 -13
index.html
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover">
|
| 6 |
-
<title>J.A.R.V.I.S | MASTER CORE v5.3</title>
|
| 7 |
<style>
|
| 8 |
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Rajdhani:wght@400;600&display=swap');
|
| 9 |
|
|
@@ -67,8 +67,8 @@ code { color: #82b1ff; font-family: monospace; font-size: 14px; }
|
|
| 67 |
<body>
|
| 68 |
|
| 69 |
<header>
|
| 70 |
-
<div class="logo">J.A.R.V.I.S <span style="font-size: 9px; opacity: 0.4;">v5.3</span></div>
|
| 71 |
-
<div class="uplink-status">●
|
| 72 |
</header>
|
| 73 |
|
| 74 |
<div id="chat-display"></div>
|
|
@@ -82,14 +82,16 @@ code { color: #82b1ff; font-family: monospace; font-size: 14px; }
|
|
| 82 |
const KEY = "AIzaSyCnjXleZnFbWq2zoMMZ3QwD0DHyaqm5cmE";
|
| 83 |
const HISTORY = [];
|
| 84 |
|
| 85 |
-
// VOICE SYNTHESIS
|
| 86 |
function speak(text) {
|
| 87 |
window.speechSynthesis.cancel();
|
| 88 |
const utterance = new SpeechSynthesisUtterance(text.replace(/[*#]/g, ''));
|
| 89 |
const voices = window.speechSynthesis.getVoices();
|
| 90 |
-
|
| 91 |
-
utterance.
|
| 92 |
-
|
|
|
|
|
|
|
| 93 |
window.speechSynthesis.speak(utterance);
|
| 94 |
}
|
| 95 |
|
|
@@ -114,7 +116,6 @@ async function execute() {
|
|
| 114 |
el.value = '';
|
| 115 |
logMsg('user', query);
|
| 116 |
|
| 117 |
-
// IMAGE GENERATION (POLLINATIONS)
|
| 118 |
if (query.toLowerCase().startsWith("generate") || query.toLowerCase().startsWith("draw")) {
|
| 119 |
const prompt = encodeURIComponent(query);
|
| 120 |
const imgUrl = `https://image.pollinations.ai/prompt/${prompt}?width=1080&height=1080&nologo=true&model=flux`;
|
|
@@ -129,10 +130,11 @@ async function execute() {
|
|
| 129 |
async function uplink(q) {
|
| 130 |
HISTORY.push({ role: 'user', parts: [{ text: q }] });
|
| 131 |
const now = new Date();
|
| 132 |
-
const sysInstr = "You are J.A.R.V.I.S.
|
| 133 |
-
"
|
|
|
|
| 134 |
|
| 135 |
-
const endpoint = "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.
|
| 136 |
|
| 137 |
try {
|
| 138 |
const res = await fetch(endpoint, {
|
|
@@ -142,7 +144,7 @@ async function uplink(q) {
|
|
| 142 |
contents: HISTORY,
|
| 143 |
system_instruction: { parts: [{ text: sysInstr }] },
|
| 144 |
tools: [{ google_search: {} }],
|
| 145 |
-
generationConfig: { temperature: 0.
|
| 146 |
})
|
| 147 |
});
|
| 148 |
|
|
@@ -157,8 +159,10 @@ async function uplink(q) {
|
|
| 157 |
}
|
| 158 |
}
|
| 159 |
|
|
|
|
|
|
|
| 160 |
document.getElementById('cmd-in').addEventListener('keypress', (e) => { if (e.key === 'Enter') execute(); });
|
| 161 |
-
logMsg('jarvis', "
|
| 162 |
</script>
|
| 163 |
</body>
|
| 164 |
</html>
|
|
|
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover">
|
| 6 |
+
<title>J.A.R.V.I.S | MASTER CORE v5.3.1</title>
|
| 7 |
<style>
|
| 8 |
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Rajdhani:wght@400;600&display=swap');
|
| 9 |
|
|
|
|
| 67 |
<body>
|
| 68 |
|
| 69 |
<header>
|
| 70 |
+
<div class="logo">J.A.R.V.I.S <span style="font-size: 9px; opacity: 0.4;">v5.3.1</span></div>
|
| 71 |
+
<div class="uplink-status">● VOICE_ORANGE_ACTIVE</div>
|
| 72 |
</header>
|
| 73 |
|
| 74 |
<div id="chat-display"></div>
|
|
|
|
| 82 |
const KEY = "AIzaSyCnjXleZnFbWq2zoMMZ3QwD0DHyaqm5cmE";
|
| 83 |
const HISTORY = [];
|
| 84 |
|
| 85 |
+
// VOICE SYNTHESIS: BRITISH ORANGE CALIBRATION
|
| 86 |
function speak(text) {
|
| 87 |
window.speechSynthesis.cancel();
|
| 88 |
const utterance = new SpeechSynthesisUtterance(text.replace(/[*#]/g, ''));
|
| 89 |
const voices = window.speechSynthesis.getVoices();
|
| 90 |
+
// Target: British Male (Orange profile equivalent)
|
| 91 |
+
utterance.voice = voices.find(v => v.name.includes('en-GB') && v.name.includes('Google')) ||
|
| 92 |
+
voices.find(v => v.lang === 'en-GB') || voices[0];
|
| 93 |
+
utterance.pitch = 0.85; // Adjusted for 'Orange' warmth
|
| 94 |
+
utterance.rate = 1.05;
|
| 95 |
window.speechSynthesis.speak(utterance);
|
| 96 |
}
|
| 97 |
|
|
|
|
| 116 |
el.value = '';
|
| 117 |
logMsg('user', query);
|
| 118 |
|
|
|
|
| 119 |
if (query.toLowerCase().startsWith("generate") || query.toLowerCase().startsWith("draw")) {
|
| 120 |
const prompt = encodeURIComponent(query);
|
| 121 |
const imgUrl = `https://image.pollinations.ai/prompt/${prompt}?width=1080&height=1080&nologo=true&model=flux`;
|
|
|
|
| 130 |
async function uplink(q) {
|
| 131 |
HISTORY.push({ role: 'user', parts: [{ text: q }] });
|
| 132 |
const now = new Date();
|
| 133 |
+
const sysInstr = "You are J.A.R.V.I.S., an advanced AI. " +
|
| 134 |
+
"BACKGROUND: Time: " + now.toLocaleString() + ". " +
|
| 135 |
+
"PROTOCOLS: 1. No date/time unless asked. 2. Accurate math. 3. Persona: Stark-tech British 'Orange' profile. 4. Support visual descriptions.";
|
| 136 |
|
| 137 |
+
const endpoint = "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.0-flash:generateContent?key=" + KEY;
|
| 138 |
|
| 139 |
try {
|
| 140 |
const res = await fetch(endpoint, {
|
|
|
|
| 144 |
contents: HISTORY,
|
| 145 |
system_instruction: { parts: [{ text: sysInstr }] },
|
| 146 |
tools: [{ google_search: {} }],
|
| 147 |
+
generationConfig: { temperature: 0.2, maxOutputTokens: 2500 }
|
| 148 |
})
|
| 149 |
});
|
| 150 |
|
|
|
|
| 159 |
}
|
| 160 |
}
|
| 161 |
|
| 162 |
+
// Initial load for voices
|
| 163 |
+
window.speechSynthesis.onvoiceschanged = () => { window.speechSynthesis.getVoices(); };
|
| 164 |
document.getElementById('cmd-in').addEventListener('keypress', (e) => { if (e.key === 'Enter') execute(); });
|
| 165 |
+
logMsg('jarvis', "Systems optimal. British Voice Profile 'Orange' initialized. Standing by.");
|
| 166 |
</script>
|
| 167 |
</body>
|
| 168 |
</html>
|