Spaces:
Running
Running
Body scrolls (wheel works in the iframe); give the model today's date
Browse filesFiles changed (3)
- index.html+1
- main.js+2-1
- style.css+2
43 unmodified lines44454647484943 unmodified lines<code>search</code> reads DuckDuckGo results (Brave as backup) and <code>browse</code> reads pages through <a href="https://jina.ai/reader" target="_blank" rel="noopener">Jina Reader</a>'s anonymous, browser-friendly endpoint(it renders JavaScript and gets past most bot walls), with Wikipedia and OpenAlex search and the Wayback Machine as fallbacks.The terminal is a small safe runner written in JavaScript for <code>head tail rg grep sed wc sort uniq cut tr nl</code>; there is no shell. Private and local addresses are refused, as are huggingface.co pages (as upstream blocks them). Each filter pipeline is limited to 5 seconds.</p><p><b>Honest limits.</b> A 4-bit-class model on a free search stack is not the paper's setup: results can be thinner than the reported benchmarks, the free services rate-limit (about 20 page reads a minute, so steps can pause), and answers can be wrong. Check the sources it cites.The model runs on your device; your search queries and the URLs it opens are sent to DuckDuckGo/Brave and Jina (anonymously, from your browser).</p><p id="store"></p>43 unmodified lines4445464748495043 unmodified lines<code>search</code> reads DuckDuckGo results (Brave as backup) and <code>browse</code> reads pages through <a href="https://jina.ai/reader" target="_blank" rel="noopener">Jina Reader</a>'s anonymous, browser-friendly endpoint(it renders JavaScript and gets past most bot walls), with Wikipedia and OpenAlex search and the Wayback Machine as fallbacks.The terminal is a small safe runner written in JavaScript for <code>head tail rg grep sed wc sort uniq cut tr nl</code>; there is no shell. Private and local addresses are refused, as are huggingface.co pages (as upstream blocks them). Each filter pipeline is limited to 5 seconds.</p><p><b>One addition.</b> The system prompt is Ai2's, plus one line giving today's date (the model does not know it and otherwise searches for old news). Add <code>?date=0</code> to the address to remove it.</p><p><b>Honest limits.</b> A 4-bit-class model on a free search stack is not the paper's setup: results can be thinner than the reported benchmarks, the free services rate-limit (about 20 page reads a minute, so steps can pause), and answers can be wrong. Check the sources it cites.The model runs on your device; your search queries and the URLs it opens are sent to DuckDuckGo/Brave and Jina (anonymously, from your browser).</p><p id="store"></p>
84 unmodified lines8586878889909184 unmodified linesconst { engine, system } = await loadEngine();if (aborted) { status('Stopped.', 0); return; }const nCtx = Math.min(CTX, engine.nCtx || CTX), RESERVE = Math.min(6000, Math.floor(nCtx * 0.2)); // room kept free for the final reportlet transcript = firstPrompt(system, question), calls = 0, step = 0, t0 = performance.now(), genTokens = 0, ctxTokens = await engine.countTokens(transcript), wrapUp = false;// One streamed generation from `prompt` into `card`; returns the raw text and how it ended.async function generate(prompt, card, sampling) {84 unmodified lines858687888990919284 unmodified linesconst { engine, system } = await loadEngine();if (aborted) { status('Stopped.', 0); return; }const nCtx = Math.min(CTX, engine.nCtx || CTX), RESERVE = Math.min(6000, Math.floor(nCtx * 0.2)); // room kept free for the final reportconst today = q.get('date') === '0' ? '' : `\n\nToday's date is ${new Date().toLocaleDateString('en-CA')}.`; // not in Ai2's prompt: without it the model assumes its training year and searches for stale newslet transcript = firstPrompt(system + today, question), calls = 0, step = 0, t0 = performance.now(), genTokens = 0, ctxTokens = await engine.countTokens(transcript), wrapUp = false;// One streamed generation from `prompt` into `card`; returns the raw text and how it ended.async function generate(prompt, card, sampling) {
8 unmodified lines910111213148 unmodified lines}* { box-sizing: border-box; }html, body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }main { display: grid; gap: 10px; padding: 10px 12px 24px; max-width: 860px; margin: 0 auto; }#line { margin: 0; font-size: 14px; color: var(--muted); }#line b { color: var(--ink); }8 unmodified lines9101112131415168 unmodified lines}* { box-sizing: border-box; }html, body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }html { height: 100%; overflow: hidden; }body { height: 100%; overflow-y: auto; overscroll-behavior: contain; } /* body is the scroller: wheel scrolling also works when the Space's iframe does not scroll its document */main { display: grid; gap: 10px; padding: 10px 12px 24px; max-width: 860px; margin: 0 auto; }#line { margin: 0; font-size: 14px; color: var(--muted); }#line b { color: var(--ink); }
index.html+1
main.js+2-1
style.css+2