On-Device AI Models in System Code: What a Phone Maker's Self-Built LLMs Reveal About the Technical Path of Edge Intelligence
A phone manufacturer's next-gen OS beta code has exposed traces of self-developed large models embedded in the personal agent core and a system-level Memory app. This article analyzes what the leaked model list reveals about on-device AI engineering: model size tiering, sparse activation architectures, agent scheduling, local memory with RAG, model routing strategies, and the engineering challenges of cloud-edge collaboration including quantization, NPU adaptation, and on-device evaluation metrics.
1. Background: What the Beta Code Revealed
Recent reports indicate that a smartphone manufacturer is actively advancing its self-developed AI model stack. Traces of a new version of its in-house large models were discovered in the first public beta code of its next-generation operating system. The model names appear in the core module powering the AI agent functionality, as well as in the implementation code of a system-level Memory app.
The exposed internal model list shows that the manufacturer maintains multiple model versions in parallel: lightweight models with just a few billion parameters, mid-sized models with tens of billions of parameters, and records of several historical versions. This suggests the AI capability is not a single-point breakthrough, but a model matrix covering different parameter scales and targeting different compute scenarios.
More notably, the Memory app’s hidden settings not only list the in-house models, but also check whether the corresponding model files exist locally on the device, displaying them alongside industry-common on-device model solutions. This detail hints that the manufacturer may be testing the ability to run its own models directly on the phone.
2. Why Self-Built On-Device Models Are Becoming a Trend
2.1 Data Privacy and Local Processing
The core value of on-device execution is that data never leaves the device. Sensitive scenarios such as calendars, memos, call summaries, and semantic photo search would incur transmission overhead and privacy concerns if they relied entirely on cloud inference. Moving inference to the local device reduces the risk of sensitive data leakage at the architectural level.
2.2 Lower Latency and Offline Availability
Agent-type features—such as cross-app task execution and real-time summarization—are extremely sensitive to response speed. Cloud round trips often take hundreds of milliseconds or more, while on-device inference compresses the critical path to a local call. Offline availability is also something cloud-based solutions simply cannot cover.
2.3 Supply Chain Autonomy
Self-developed models allow manufacturers to perform deep co-optimization around their own hardware (NPU compute, memory bandwidth), without being constrained by third-party model licensing terms or release cadences. This is why leading manufacturers commonly adopt a dual-track strategy of “self-built plus externally sourced models”—the exposed code shows external model options listed in the settings interface alongside the in-house ones, reflecting exactly this combined approach.
3. Technical Choices Revealed by the Model List
The model naming in the exposed information reveals a typical on-device model engineering methodology:
3.1 Parameter Size Tiering
- ~2B small models: suited for memory-constrained devices, handling high-frequency lightweight tasks such as intent recognition, text classification, and simple summarization.
- Mid-sized models (a few B to ~10B+): aimed at more complex single-modality tasks like long-document summarization, code assistance, and multi-turn dialogue.
- 20B+ models: typically serve as the capability ceiling on the cloud or flagship devices, or are attempted on-device through quantization and compression.
A common industry practice is to maintain a model routing layer that dynamically selects a model based on task complexity, device compute, and battery state. Illustrative logic:
def route_model(task, device):if task.complexity == "low" and device.npu_available:return local_small_model # few-B on-device modelelif device.ram >= 16 and device.charging:return local_mid_model # mid-sized quantized modelelse:return cloud_model # fall back to cloud
3.2 The Importance of Version Management
The fact that multiple historical versions are retained in the code shows the manufacturer has prepared for staged rollouts, A/B testing, and rollback mechanisms. Models are assets, and their version management should resemble CI/CD in software engineering: each version should record the training data snapshot, benchmark scores, quantization scheme, and target device list, so that a quick switch is possible when regressions occur.
3.3 Architectural Clues in the Naming
Naming patterns like “A4B” in the exposed model identifiers usually imply that activated parameters are far fewer than total parameters—in other words, a sparse activation (MoE-style) architecture. The value of such architectures on-device lies in controlling inference cost with a small number of activated parameters while retaining the knowledge breadth of a larger total parameter pool. This is one of the current hot directions for on-device model deployment.
4. Agent Core and Memory App: The Two Carriers of On-Device AI
4.1 Personal Agent Core
Agent functionality requires the model to handle task planning, tool invocation, and cross-app orchestration. Small on-device models typically take care of intent understanding and parameter extraction, while complex reasoning is handed to larger models. This division of labor—“small models for scheduling, large models for execution”—is the mainstream architecture for phone-based agents today.
4.2 The Memory App
The essence of a memory app is building a local knowledge base of the user’s profile: structuring and storing user behavior, preferences, schedules, and other information, then retrieving it via vector search for the model to use. A typical pipeline looks like:
- Information collection → local vectorization (embedding) → storage in an on-device vector store → retrieval-augmented generation (RAG) → model generation
The code logic that “checks whether the model file exists on the device” shows the app uses a capability detection mechanism: full functionality is enabled only when the local model is ready; otherwise it degrades to a rules engine or prompts the user. This is standard fault-tolerant design for shipping on-device features.
5. Engineering Challenges of Cloud-Edge Collaboration
- Quantization and compression: On-device deployment typically requires INT4/INT8 quantization, which demands trade-offs between accuracy loss and memory footprint, plus full regression evaluation of the quantized model.
- Compute adaptation: The same model must adapt to different NPU generations, often requiring multiple sets of operator implementations per chip—a significant engineering effort.
- Security and updates: Integrity verification of model files, delta update delivery, and anti-tampering mechanisms cannot be overlooked.
- Evaluation system: On-device scenarios need additional metrics—time to first token, tokens/s, peak memory, heat, and power consumption—rather than relying solely on general benchmark scores.
6. Conclusion
The appearance of self-developed models in system beta code marks a shift in phone manufacturers’ AI strategy—from “integrating external capabilities” toward “on-device autonomy.” For developers, understanding this methodology—model tiering, agent scheduling, local memory, and cloud-edge collaboration—is more valuable than fixating on any single model name. It represents the common technical foundation for mobile intelligent applications in the coming years. As model compression and device compute continue to advance, “every phone running its own dedicated model” is turning from vision into engineering reality.
