Spaces:
Running
Running
MaduRox commited on
Commit ·
d728fc9
1
Parent(s): 8ca1f22
feat: deploy Kalpana RIF O(1) Studio with Needle-in-a-Haystack benchmarks, layer architecture, and Swagger API
Browse files14 unmodified lines151617181920218 unmodified lines303132333435363738394041424314 unmodified linesconst chatHistory = document.getElementById('chatHistory');const chatInput = document.getElementById('chatInput');const btnSend = document.getElementById('btnSendChat') || document.getElementById('btnSend');const tabButtons = document.querySelectorAll('.nav-btn');const tabPanes = document.querySelectorAll('.tab-pane');const btnOpenIngestModal = document.getElementById('btnOpenIngestModal');8 unmodified linestabButtons.forEach((btn) => {btn.addEventListener('click', () => {const target = btn.getAttribute('data-tab');tabButtons.forEach((b) => b.classList.remove('active'));tabPanes.forEach((p) => p.classList.remove('active'));btn.classList.add('active');const pane = document.getElementById(`tab-${target}`);if (pane) pane.classList.add('active');});});// --- Semantic Feature Embedding (Word & Bigram Hashing into 384-Dim Vector) ---function computeSemanticEmbedding(text, dim = 384) {const vec = new Float32Array(dim);14 unmodified lines151617181920218 unmodified lines3031323334353637383940414243444546474849505114 unmodified linesconst chatHistory = document.getElementById('chatHistory');const chatInput = document.getElementById('chatInput');const btnSend = document.getElementById('btnSendChat') || document.getElementById('btnSend');const tabButtons = document.querySelectorAll('.nav-tab, .nav-btn');const tabPanes = document.querySelectorAll('.tab-pane');const btnOpenIngestModal = document.getElementById('btnOpenIngestModal');8 unmodified linestabButtons.forEach((btn) => {btn.addEventListener('click', () => {const target = btn.getAttribute('data-tab');if (!target) return;tabButtons.forEach((b) => b.classList.remove('active'));tabPanes.forEach((p) => p.classList.remove('active'));btn.classList.add('active');let pane = document.getElementById(target);if (!pane) pane = document.getElementById(`tab-${target}`);if (pane) pane.classList.add('active');});});// Expose swagger accordions toggle globallywindow.toggleSwagger = function(el) {const endpoint = el.closest('.swagger-endpoint');if (endpoint) endpoint.classList.toggle('open');};// --- Semantic Feature Embedding (Word & Bigram Hashing into 384-Dim Vector) ---function computeSemanticEmbedding(text, dim = 384) {const vec = new Float32Array(dim);
app.js+10-2