Spaces:
Running
Running
File size: 4,590 Bytes
f16878d b30b7c5 f16878d b30b7c5 f16878d b30b7c5 f16878d d305959 b30b7c5 d305959 b30b7c5 d305959 6b45f01 b30b7c5 6b45f01 b30b7c5 6b45f01 d305959 6b45f01 b30b7c5 d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 022d4ca d305959 31d404a d305959 31d404a d305959 31d404a | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 | ---
title: Elffuss Code
emoji: π§βπ»
colorFrom: purple
colorTo: pink
sdk: static
app_file: index.html
pinned: false
license: apache-2.0
short_description: A VS Code-style IDE with a local AI agent, in-browser
tags:
- webgpu
- transformers.js
- local-llm
- agent
- code
- gemma
---
# π§βπ» Elffuss Code β a VS Code-style IDE with an AI agent, 100% in your browser
Open a local folder and a full web IDE unfolds around it β real Monaco (the VS Code editor),
a file tree, tabs β with an AI agent that **reads, searches and edits your project for real**.
The model runs on **your** GPU via WebGPU. Your code never leaves your machine.
> β οΈ **Open it full-screen** ([direct link](https://kikocis-elffuss-code.static.hf.space)) β the
> File System Access API (opening a local folder) is blocked inside the embedded iframe.

In the demo a **small model running entirely in the browser** reads `calc.py`, finds a real
bug and fixes it with a minimal edit β genuine tool-calling, not autocomplete.
## Why it's different
- **Your code stays local.** The folder is opened via the File System Access API β no upload, no account.
- **The model runs on your GPU** (WebGPU, Gemma-4 E4B via LiteRT-LM; ONNX/transformers.js as fallback).
- **Real tool-calling**: `code.tree`, `code.read`, `code.search`, `code.edit`, `code.write` β you watch every call.
- **Edits, not rewrites**: the agent patches the lines that change, even in files of several megabytes.
- **Long tool results don't break the conversation**: they are compacted to fit the model's context instead.
- **Context retrieval that works beyond English** β accents and Cyrillic included (measurements below).
- **Real editor**: Monaco, file tree, tabs, `Ctrl+S`, and git branch/last commit parsed straight from `.git`.
- **Zero install, zero build.** Vanilla ES modules.
- **Your language**: the whole IDE follows your browser's language (English, Spanish and more).
- External providers (OpenAI, Anthropic, Ollama) are **opt-in**; keys stay in your browser.
- Optional local **bridge** for real `node` / `npm` / `python` execution β downloaded from the main site.
## How it's built
Write-ups on the full stack β model, runtime, agent harness, editor and filesystem access,
all in one tab: **<https://bitacora.utopiaia.com/#elffuss>**
## Context management β how it's measured
The context packer isn't chosen by intuition. Numbers measured at the **same token budget**:
**Real agent sessions** (25 sessions, 174 probes, fact recall, no LLM judge):
| | recall |
|---|---|
| tail truncation | 7.0 % |
| previous version | 15.1 % |
| **current** | **65.3 % Β± 8.5** |
**Long-term memory** (200 questions, F1 from the benchmark's own repo, a real model answering, ~8 % of the context):
| | F1 |
|---|---|
| **the FULL context, uncompressed** | **22.56** |
| tail truncation | 6.62 |
| hand-written heuristics | 6.07 |
| BM25 without IDF | 20.34 |
| BM25 | 23.59 |
| embeddings | 23.95 |
| **rank fusion (BM25 + embeddings)** | **28.09** |
**Retrieving well beats having everything**: 28.09 vs 22.56 using 8 % of the tokens. Irrelevant context
isn't neutral ballast β it distracts.
Two more things that were measured, not assumed: turning the heuristics on cost **β3.02 F1**, and
removing IDF costs **β3.25**. Semantic search doesn't replace lexical search, it covers its blind spot:
with no vocabulary overlap between question and answer, embeddings win (24.28 vs 18.60); with overlap,
BM25 wins (29.33 vs 23.58) β and fusion keeps both.
References: BM25 (Robertson et al., TREC-3 1994) Β· IDF (SpΓ€rck Jones, 1972) Β· RRF (Cormack et al., SIGIR 2009) Β·
MMR (Carbonell & Goldstein, SIGIR 1998) Β· attention sinks (Xiao et al., ICLR 2024) Β· valid time (Snodgrass & Ahn, SIGMOD 1985).
The full story, including what went wrong: <https://bitacora.utopiaia.com/posts/16-beaten-by-doing-nothing.html>
## The Elffuss family
- π Full app: <https://code.elffuss.com>
- π» Source (Apache-2.0): <https://github.com/KikoCis/elffuss-code>
- β³οΈ Elffuss Claw β an agentic OS in your browser: <https://claw.elffuss.com> Β· [Space](https://huggingface.co/spaces/KikoCis/elffuss-claw)
- 𧬠Shared core: <https://github.com/KikoCis/elffuss>
- π£οΈ Elffuss Translator β speech-to-speech translation on your device: <https://translator.elffuss.com>
- π Elffuss Copilot β live call notes that never leave your browser: <https://copilot.elffuss.com>
- π° All apps and the blog: <https://elffuss.com>
|