@tty-pt/auren

License: Proprietary (Free to Use) TypeScript Ready Node.js Native WebAssembly Zero Dependencies

Local GGUF LLM & multimodal vision (mtmd/mmproj) inference, OpenAI-compatible streaming chat, dense vector embeddings, Jev System 1 reflexive classification, and multi-tenant persistent collections for Node.js and the Browser.

๐Ÿ“– Full C & Systems Documentation: See ../README.md for the complete C API (<ttypt/auren.h>), HTTP daemon architecture, and model configuration guide.


1. Overview & Domain Concepts

axil-auren (libaxil-auren.so / @tty-pt/auren) is a zero-cloud local inference engine built on llama.cpp (with Vulkan, Metal, CPU, and mtmd vision acceleration), libcorm, and libsepal:

  1. Three Hardware & RAM Model Tiers (~/.models/):
  1. Jev System 1 Reflexive Engine (/v1/systemone):
  1. Multi-Tenant Persistent Vector Collections (/v1/collections/:name):
  1. Isomorphic Browser Wllama Fallback (AurenBrowserEngine):

2. Installation

npm config set @tty-pt:registry https://tty.pt/npm/
npm install @tty-pt/auren

Native OS & Mobile Packages (tty.pt): Prebuilt native C packages (axil-auren) across all 9 platforms โ€” Linux (apt, apk, pacman, dnf), macOS (brew), Windows (winget, Scoop, MSYS2), OpenBSD (pkg_add), plus static mobile sysroots for Android (https://tty.pt/android/) and iOS (https://tty.pt/ios/ โ€” axil-auren.xcframework + SwiftPM) โ€” are available via the tty.pt package repositories.


3. Quickstart

Launch the Local axil-auren Server via @tty-pt/axil

@tty-pt/auren bundles prebuilt libaxil-auren shared libraries so npx axil can host the inference server on port 4242 directly from node_modules:

npx axil -A -p 4242 -m axil-auren

Streaming Chat, Embeddings, System 1 & Collections

import { createAurenClient, cosineSimilarity } from "@tty-pt/auren";

const auren = createAurenClient({ baseUrl: "http://localhost:4242" });

// 1. OpenAI-Compatible Streaming Chat (/v1/chat/completions)
for await (const chunk of auren.chatStream({
  model: "chat",
  messages: [{ role: "user", content: "Explain C pointers in one sentence." }]
})) {
  process.stdout.write(chunk.choices?.[0]?.delta?.content || "");
}

// 2. Dense Vector Embeddings (/v1/embeddings) & Native Cosine Similarity
const { data } = await auren.embeddings({
  model: "bge-base",
  input: ["Zero-copy memory-mapped storage", "Lexical full-text indexing"]
});
console.log("Cosine similarity:", cosineSimilarity(data[0].embedding, data[1].embedding));

// 3. Jev System 1 Reflexive Classification (~5-15ms)
const decision = await auren.systemOne({
  text: "Fix typo in README.md",
  labels: ["trivial", "complex", "architectural"]
});
console.log("System 1 choice:", decision);

// 4. Persistent Vector Collections (/v1/collections/:name)
const docs = auren.collection("engineering-notes");
await docs.insert({ id: "note-1", text: "Use libsepal for two-stage ANN cosine search." });
const matches = await docs.search("vector similarity search", 5);
console.log("Collection hits:", matches);

Browser WebAssembly Inference (AurenBrowserEngine)

import { AurenBrowserEngine } from "@tty-pt/auren";

const engine = new AurenBrowserEngine();
await engine.init(({ status, percent }) => {
  console.log(`${status} (${percent}%)`);
});

for await (const token of engine.chatStream({
  messages: [{ role: "user", content: "Hello from WebAssembly!" }],
  maxTokens: 128
})) {
  process.stdout.write(token);
}

4. JavaScript / TypeScript API Reference

createAurenClient(options?: AurenClientOptions): AurenClient

Creates an isomorphic HTTP/SSE client for an axil-auren daemon:

AurenBrowserEngine

In-browser WebAssembly GGUF inference engine powered by Wllama:

Vector & Module Utilities


5. C Development Headers & Native Integration

CFLAGS += -I./node_modules/@tty-pt/auren/include
LDLIBS += -laxil-auren

License

Proprietary Free-to-Use License โ€” All Rights Reserved. Copyright (c) 2026, tty-pt. See LICENSE and THIRD_PARTY_NOTICES.