Skip to content

Repository files navigation

Yours

A personal AI mobile app that runs open-source language models directly on your phone. Private, free, and personalized — no subscriptions, no forced cloud dependency.

Vision

AI should be personal, private, affordable, and available to everyone — not locked behind expensive subscriptions or constant internet access.

"Yours" puts open models (Qwen, Gemma, and other lightweight models) on the user's device, giving people a free, private AI assistant they fully control.

Models Currently in the App

Live list in src/inference/modelRegistry.ts. "Training size" is the model's parameter count; "Actual size" is the real quantized .gguf download size, verified via HTTP Content-Length on the file itself (not read off a model page — see CHANGELOG.md for why that distinction matters).

Model Training Size Quant Actual Size Context Length
Qwen3 Instruct 0.6B Q4_K_M 484 MB 32,768 tokens
Gemma 3 Instruct 1B Q4_K_M 806 MB 32,768 tokens
SmolLM2 Instruct 135M Q4_K_M 105 MB 8,192 tokens
SmolLM2 Instruct 360M Q4_K_M 271 MB 8,192 tokens
Gemma 3 Instruct 270M Q4_K_M 253 MB 32,768 tokens
FunctionGemma Instruct 270M Q4_K_M 253 MB 32,768 tokens

Current Status

Past the "planning" phase — there's a working app. Two screens (Model Management, Chat) let you download a small GGUF model, load it, and chat with it entirely on-device, with history persisted locally. See CHANGELOG.md for the detailed build history (what was built, what broke on real hardware, and how it was fixed) and Open Issues.md for what's still known to be missing, deferred, or scoped down from the original plan below — most notably, the "Prompt Compiler" concept in this README is not what's actually implemented; a single shared system prompt is used for every model instead. Read Open Issues.md before assuming any section below describes the current behavior rather than the original intent.

Current Scope

  • Platform: Mobile app only (for now — no web, no desktop)
  • Framework: React Native (bare CLI, not Expo — native modules like llama.rn need direct native linking)
  • Phase: Working MVP on Android; iOS untouched (no Xcode/CocoaPods in the development environment used so far — see Open Issues.md)
  • Storage: SQLite (@op-engineering/op-sqlite), used today for chat history

Core Philosophy

Not "another ChatGPT clone" — an AI runtime for open models, built around three ideas:

  1. Private by default — models run locally on the user's phone.
  2. Free and accessible — no expensive subscriptions, no API costs passed to the user.

Architecture Overview

High-Level Flow

User
  │
Mobile App (React Native)
  │
Model Adapter Layer
  │
Local Inference (on-device)

Model Support

  • Format: GGUF (broadest lightweight model availability)
  • Target models: Qwen, Gemma, SmolLM2, and other lightweight models — currently Qwen3 0.6B, Gemma 3 1B, SmolLM2 135M, SmolLM2 360M, Gemma 3 270M, and FunctionGemma 270M (see src/inference/modelRegistry.ts for the live list, with real download URLs and verified file sizes)
  • Local inference approach: llama.rn (llama.cpp bridged to React Native) — MLC LLM was considered but not used

Model Adapter Pattern

Originally specified as a full adapter interface:

generate()
stream()
embedding()
vision()
tool_call()

Currently implemented: generate() and stream() only (src/inference/InferenceManager.ts). embedding(), vision(), and tool_call() don't exist yet — see Open Issues.md.

Prompt System

The original plan was a "Prompt Compiler": prompts assembled dynamically from three composable layers (Global / Model-Specific / Feature), sized differently per model parameter count, rather than one large static system prompt.

What's actually implemented (src/inference/systemPrompt.ts) is simpler: a single unified SYSTEM_PROMPT constant, applied identically to every model in the registry. This is a deliberate scope reduction, not an oversight — see Open Issues.md for the reasoning. The three-level design below is preserved here as the original intent, in case the Prompt Compiler is revisited later.

Three Prompt Levels (original design, not yet built)

  1. Global Prompt — never changes. Identity, behavior, formatting, honesty, reasoning style.
  2. Model-Specific Prompt — tuned per model's quirks (e.g., Qwen: concise, structured; Gemma: direct, no preamble).
  3. Feature Prompt — only added when relevant (coding, writing, translation, math, research, etc.).

Prompt Sizing by Model Size (original design, not yet built)

Model Size System Prompt Strategy
1B and Less Ultra-short (50–100 tokens)
3B Short (100–200 tokens)
7B Medium (200–400 tokens)
14B+ Full-featured, more detailed guidance

Model Prompt Profile (JSON) (original design, not yet built)

Each model has its own settings, loaded automatically when selected:

{
  "model": "qwen3-4b",
  "systemPrompt": "...",
  "temperature": 0.7,
  "topP": 0.9,
  "maxOutputTokens": 2048,
  "stopSequences": []
}

MVP Feature List

  • Chat interface
  • Multiple model support
  • Chat history (persisted via SQLite)
  • Markdown rendering
  • Code block rendering
  • Streaming responses
  • Image attachments
  • Settings screen
  • Prompt library

Tech Stack (Current)

Layer Technology
Mobile React Native (bare CLI)
Navigation @react-navigation/bottom-tabs
Local Inference llama.rn (llama.cpp bridged to React Native)
Model Format GGUF
Downloads react-native-fs (downloadFile)
Local Storage @op-engineering/op-sqlite (chat history)
Clipboard @react-native-clipboard/clipboard
Backend (future, for hybrid cloud) FastAPI, Flask or NestJS — not started

Naming History

  • Originally considered: Nova, Nexa, Synapse, PocketAI, and others
  • Final name: Yours — reflects the personal, private, user-owned philosophy of the app

License

MIT — see LICENSE.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages