Core Modules
- core/backend.py - unified facade
- core/http_client.py - HTTP client
- core/engine_status.py - engine state
- core/llm_errors.py - error handling
- Model/APImodels.py - API registry
- Model/ModelRegistry.py - model registry
Architecture
NativeLab is a layered application. Each layer talks only to the one beneath it, keeping GUI, CLI, and Labs frontends interchangeable.
Reference
Where things live and what they do.
Backend
All network operations go through NativeLabHttpClient. All backend operations go through NativeLabBackend. No raw urllib calls in new code.
Android
Architecture, file index, constants, and contributing guide for the Android client.
17-layer error handling, singleton pattern, lifecycle protection.
Every file - purpose, classes, functions, constants.
All limits, defaults, colors, URLs, regex patterns.
Complete reference for LAN API server.
Server
Turn any GGUF model into an OpenAI-compatible API server with one command.
$ python -m nativelab.server --model models/llama-7b.gguf # Hardware: 8 cores, 8192 MB RAM # Recommended: threads=4, ctx=2048, n_predict=512 # Server running on 127.0.0.1:8787 # Endpoints: # /v1/chat/completions (OpenAI) # /v1/messages (Anthropic) # /health (status)