Skip to content
プロジェクト

概要

100% offline Android LLM chat app powered by llama.cpp with Vulkan GPU offload, Arm KleidiAI fallback, and zero internet permission.

仕事効率化・自動化

この数値の測り方

計測したスター増加

24時間
0
7日間
履歴を収集中
15日間
履歴を収集中
1か月
履歴を収集中

期間ごとの純増数です。期間は重複しており、日別の値ではありません。未計測の値は空欄です。スター数は注目度の指標であり、品質の保証ではありません。

LittleBit Chat

Private, on-device AI chat, vision, speech and image studio for Android ARM64. Bring your own GGUF and LiteRT-LM models. Nothing leaves the device unless you explicitly enable a Standard-edition network feature.

Android 9+ ARM64 llama.cpp + MNN Offline edition Version 4.0.0


Editions

Edition Package ID Network permissions Capabilities
Offline com.littlebit.chat None. INTERNET and ACCESS_NETWORK_STATE are removed by the flavor manifest and the build fails if a dependency adds them back. Chat, Vision, Image Studio, on-device speech, Model Hub, Characters, Lorebooks and local tools. Model downloads open in the system browser.
Standard com.littlebit.chat.standard Internet, only for features you opt into. Everything in Offline, plus DuckDuckGo/SearXNG web search, in-app resumable model downloads and Android-Keystore-encrypted OpenAI-compatible cloud APIs.

Both editions are signed ARM64 builds with 16 KiB ELF page alignment.

Feature status

CI proves compilation, pure-JVM regression tests, JNI/Kotlin parity, the Offline manifest contract and 16 KiB packaging. It does not prove runtime behaviour on a physical phone: speed, thermal throttling, Vulkan driver stability and MediaPipe startup still depend on the device.

Area Status
Chat, storage, import/export, templates, samplers Implemented and covered by pure-JVM tests.
Vulkan offload and CPU/KleidiAI fallback Implemented with a full → partial → CPU ladder. Effective backend and layer count are reported in diagnostics. Per-device results vary.
Quantization catalogue Q2_K, Q3_K_M, Q4_K_M and Q8_0 entries are locked to publisher byte counts by tests. Other formats supported by the pinned llama.cpp may load.
LittleBit 0.55-bit (Q1_0) Experimental. The catalogue links a conversion guide, not a prebuilt checkpoint.
Vision Implemented with Qwen2.5-VL GGUF + matching mmproj projector. Device validation is required per model and RAM budget.
Image Studio Implemented with MNN 3.6.2 and Stable Diffusion 1.5 MNN bundles, OpenCL with CPU retry. Device validation is required per GPU/driver.
Speech Kokoro-82M read-aloud and Parakeet-TDT dictation through MediaPipe. Bundles are imported by the user; device validation is required.
Web search Standard edition only. Parsers and prompt grounding are unit-tested; the Offline edition has no networking code or permission.

Chat engine

  • llama.cpp on device. The engine is pinned to llama.cpp 6aee508 with project patches for LittleBit Q1_0 and Android SAF file descriptors. When local inference is used, no prompt or model data leaves the device.
  • Vulkan first, CPU fallback. Vulkan offload is enabled by default and requests 99 GPU layers. If the driver rejects a full offload, the loader retries with half the layers and then CPU/KleidiAI; the accepted count is read back from the model rather than assumed.
  • Mali/Immortalis safety. Mali Vulkan uses an F16 KV cache, disables flash attention and caps a physical batch at 32 tokens. Other Vulkan devices may use a Q8_0 KV cache with flash attention, then retry F16 if context creation rejects it.
  • CPU path. KleidiAI kernels, memory-mapped weights and a 64-token ubatch.
  • Defaults. 2,048-token context (automatically capped on low-RAM devices, configurable up to 16,384), four threads, 512-token logical batch. Reload after changing backend, context or batch settings.
  • KV reuse. Multi-turn chats keep the live prefix and can persist a disk cache keyed by the assembled prompt hash.
  • Sampling and prompts. Temperature, top-k, top-p, min-p, DRY, XTC, Top-N-Sigma, Typical-P, DynaTemp and Mirostat v2, full 32-bit seeds, built-in/custom chat templates and configurable stop strings.
  • Chat workflow. Streaming with reasoning blocks, edit/resend/regenerate/continue, swipe variants, fork, summaries, Characters, Lorebooks, Author's Note, Prompt Inspector and SillyTavern/OpenAI/LittleBit importers.

Quantization

The curated catalogue groups chat models by the categories below, and the Model Hub filters by quantization and parameter count.

Category Catalogue examples Notes
2-bit Q2_K, UD-IQ2_XXS, IQ2_M, IQ2_XS, UD-Q2_K_XL Smallest downloads; measurable quality loss.
3-bit Q3_K_M Lower memory with a smaller quality drop.
4-bit Q4_K_M Recommended balance for most phones.
8-bit Q8_0 Higher precision; needs substantially more RAM.
0.55-bit LittleBit Q1_0 Experimental factorized conversion; guide only.

Q4_0 weights can use llama.cpp's ARM online repacking on supported CPUs for faster prefill. Other quantizations use their compatible kernels.

Vision

Model Hub lists Qwen2.5-VL 3B and 7B Q4_K_M models with the matching F16 mmproj projector from the same publisher repository. Import the language GGUF, then use the model's actions menu to import the projector. The importer checks that the projector's GGUF architecture is clip before registering it. Attach a photo in Chat and ask a question; a text-only GGUF cannot understand images, and the projector must match the model.

Image Studio (MNN)

  • In-process MNN 3.6.2 runs CLIP text conditioning, UNet classifier-free guidance sampling and VAE decoding on device.
  • OpenCL GPU path with CPU retry. MNN's OpenCL backend is used when the driver is available; the engine retries on CPU rather than failing the request.
  • Bring your own bundle. Import a Stable Diffusion 1.5 MNN bundle as a ZIP or SAF folder. The copy is traversal-checked, size-limited and validated before use. Text-to-image works with the standard bundle; img2img/inpainting requires a bundle that also ships vae_encoder.mnn.
  • Cancellation and progress. Phase-aware progress (Preparing… → steps → Decoding VAE…), cancellation between sampler steps, sequential weight staging and PNDM/LCM scheduling.
  • Saving. On Android 10+ images are published through MediaStore with IS_PENDING, so a failed encode cannot leave a broken gallery entry. Android 9 uses the SAF save picker.

Speech

  • Kokoro-82M read-aloud and Parakeet-TDT 0.6B v3 dictation run through MediaPipe tasks-audio 1.2.0.
  • User-imported bundles. Kokoro (Apache-2.0) and Parakeet (CC-BY-4.0) .litertlm files are imported under Settings → Storage → Speech models. The app never downloads them at runtime, and the Offline edition keeps no network permission.
  • Dictation writes to the composer. A final transcript is appended to the current draft even when no language model is loaded; sending still requires a loaded model.
  • Release safety. ProGuard/R8 keeps the MediaPipe entry points and the Protobuf Lite schemas that the native audio tasks resolve by name.

Model Hub

  • Three separate sections: Chat Models, Vision Models and Image Generation.
  • Compact quick-setup guides for the Vision projector pairing and the Image Studio bundle import.
  • Verified catalogue metadata. Every link must be HTTPS, publisher file sizes are stored and asserted by tests, and the LittleBit entry is a conversion guide rather than a fake download. Gemma checkpoints are deliberately excluded from the curated catalogue.
  • RAM-fit guidance. Cards show estimated device RAM and warn before a download that is likely to exceed usable memory.
  • Local files. Direct SAF loading maps a seekable GGUF with 0 B copied; non-seekable providers offer a confirmed private copy. Linked and imported models can be reloaded from My Local Models.
  • Downloads. Standard edition downloads in-app with pause/resume/cancel. Offline edition opens the same verified HTTPS link in the browser.

Search and privacy

Web search exists only in the Standard edition. DuckDuckGo HTML and SearXNG JSON results are parsed into at most three titled excerpts, and the grounded prompt tells the model to cite the supplied URLs and treat excerpts as untrusted quotations. Cloud API keys are encrypted with the Android Keystore. The Offline edition contains no network search implementation, no cloud client and no network permission.

Quick start

  1. Download the Offline or Standard signed ARM64 APK from Releases and verify the matching .sha256 file (sha256sum -c <apk-file>.sha256).
  2. Open Model Hub and download or import a chat GGUF. As a starting point, use a 4-bit model that fits the device RAM shown on the card.
  3. Chat locally, or open Model Hub → Vision Models / Image Generation for the pairing and bundle instructions.
  4. For speech, import the Kokoro and Parakeet bundles under Settings → Storage → Speech models.

Build from source

Requirements: JDK 17, Android SDK 35, NDK 28.2.13676358, CMake 3.22.1, and a host Vulkan SDK with glslc and SPIRV-Headers.

git clone --recurse-submodules https://github.com/aj5649169-svg/littlebit-chat.git
cd littlebit-chat
bash scripts/apply-patches.sh
cd android-app
./gradlew assembleOfflineDebug

Release variants require the signing environment variables ANDROID_RELEASE_STORE_FILE, ANDROID_RELEASE_STORE_PASSWORD, ANDROID_RELEASE_KEY_ALIAS and ANDROID_RELEASE_KEY_PASSWORD. The GitHub Actions workflows are the authoritative build: Static Analysis runs Detekt and Android Lint, Qodana performs its inspection, and the APK workflow builds both flavors, runs the JVM suites, verifies JNI/Kotlin parity, checks the Offline manifest and confirms 16 KiB ELF alignment.

Compatibility and limitations

  • ARM64 only. There is no x86, x86_64 or 32-bit build; native engines are compiled for arm64-v8a.
  • Android 9 (API 28) or newer.
  • RAM matters more than the download size. Weights, KV cache, compute buffers and Android itself all share physical memory. A 4 GB phone is suitable for the smallest models; 4B 4-bit models generally want 6–8 GB, and 8B 4-bit models want 12 GB or more. These are planning estimates, not guarantees.
  • Vulkan is device-dependent. A driver may reject the requested layer count, fall back to partial offload or fail entirely. The app degrades to CPU instead of crashing, but decode speed can drop sharply.
  • Experimental compatibility. LittleBit 0.55-bit conversion and the 16B MoE DeepSeek Coder entries are explicitly marked experimental/unverified. Vision, image generation and speech depend on the imported model bundle and the device.
  • No cloud fallback in Offline. If a model or device is too slow, the app does not silently send prompts to a server.

License

LittleBit Chat is source-available under the LittleBit Chat Noncommercial Source-Available License in LICENSE. It permits personal and other noncommercial use, source study, personal modification and community contributions. Commercial use, monetized clones, and app-store distribution are not permitted. No commercial or dual license is offered for this version.

Releases published before 2 December 2026 were distributed under the MIT License. Those grants remain in effect for those copies; the exact text is preserved in licenses/MIT-historical.txt.

Third-party components, model licenses and redistribution obligations are listed in docs/licensing/THIRD_PARTY_NOTICES.md. This license does not override any upstream license.

Credits

Built with llama.cpp (MIT), Alibaba MNN (Apache-2.0), Arm KleidiAI (Apache-2.0) and MediaPipe (Apache-2.0). Search-result parsing in the Standard edition uses jsoup (MIT).

関連プロジェクトを探す

読み込み中…