Building AI applications in JavaScript or TypeScript today usually requires duct-taping a fragile multi-process stack:
- Node.js or Python running the application logic.
- External vector databases (like Chroma, Pinecone, or Qdrant) running as separate network services.
- Background LLM daemons (like Ollama or vLLM) communicating across localhost ports.
- A 100–300 ms JSON serialization IPC penalty every time an agent passes tokens, embeddings, or memory snapshots across process boundaries.
We built Sofuu to collapse this entire architecture into a single, in-process runtime under 5.5 MB.
What is Sofuu?
Sofuu is an AI-native runtime for JavaScript and TypeScript. It is not an npm framework or a wrapper around Node; it is a standalone native binary built with QuickJS and a libuv event loop that boots in under 4 milliseconds.
Instead of orchestrating five different daemons to build an AI agent, Sofuu provides the foundational primitives directly in the runtime core:
1. In-Process Cognitive Vector Memory (QTSQ)
Sofuu includes built-in encrypted .qtsq memory containers with hardware-accelerated SIMD vector search. Embeddings and episodic memory are recalled in under 2 milliseconds directly in-process—with zero external database servers.
2. Autonomous Agent Loops & Prompt Sovereignty
Define autonomous multi-step agents with native tools, budget caps, cancel signals, and streaming observability. Sofuu guarantees prompt sovereignty: the runtime never injects hidden system prompts or biases.
3. Native Model Context Protocol (MCP)
Full first-class MCP client and server support is built directly into the standard library. Connect to existing tool ecosystems without installing extra adapter packages.
4. Sandbox v2 & 5-Shield Security
Executing untrusted agent tools or third-party plugins is protected by a deterministic firewall: filesystem jailing, domain allowlists, and instruction fuel metering.
Hello World in Sofuu
Here is how simple it is to initialize memory, query an agent, and execute tools in a single script:
// Memory + Agent + Tools + AI in 15 lines
const brain = sofuu.memory.open("project.qtsq");
brain.remember("Deployment target: AWS us-east-1");
const agent = sofuu.agent.define({
model: "claude-3-5-sonnet",
tools: [sofuu.tools.fs.read, sofuu.tools.web.search],
policy: { net: ["api.github.com"], maxTokens: 4000 }
});
const result = await agent.run({
prompt: "Inspect the repo and summarize deployment requirements.",
context: brain.recall("deployment")
});
console.log(result.output);
Run it immediately with:
sofuu run agent.ts
(No compilation step, no node_modules, no background daemons).
100% Open Source
Sofuu is open source under the permissive MIT License.
- Website & Documentation: https://sofuu.xyz
- GitHub Repository: https://github.com/sofuu-runtime/sofuu
- Official AI Skill: https://sofuu.xyz/SKILL.md
Try it in 10 seconds:
# macOS & Linux (auto-detects architecture)
curl -fsSL https://sofuu.xyz/install | sh
We are actively developing Sofuu and would love your feedback, bug reports, and benchmark tests!
About the author
- solo dev + architect
Comments
Join the discussionNo comments yet. Be the first to comment.