Instructions to use UraionLabs/uraion-forge-2b-mlx with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use UraionLabs/uraion-forge-2b-mlx with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("UraionLabs/uraion-forge-2b-mlx") prompt = "Write a story about Einstein" messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True ) text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use UraionLabs/uraion-forge-2b-mlx with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "UraionLabs/uraion-forge-2b-mlx"
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "UraionLabs/uraion-forge-2b-mlx" } ] } } }Run Pi
# Start Pi in your project directory: pi
- MLX LM
How to use UraionLabs/uraion-forge-2b-mlx with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Interactive chat REPL mlx_lm.chat --model "UraionLabs/uraion-forge-2b-mlx"
Run an OpenAI-compatible server
# Install MLX LM uv tool install mlx-lm # Start the server mlx_lm.server --model "UraionLabs/uraion-forge-2b-mlx" # Calling the OpenAI-compatible server with curl curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "UraionLabs/uraion-forge-2b-mlx", "messages": [ {"role": "user", "content": "Hello"} ] }' - Hermes Agent
How to use UraionLabs/uraion-forge-2b-mlx with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "UraionLabs/uraion-forge-2b-mlx"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default UraionLabs/uraion-forge-2b-mlx
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use UraionLabs/uraion-forge-2b-mlx with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "UraionLabs/uraion-forge-2b-mlx"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "UraionLabs/uraion-forge-2b-mlx" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- ⚡ Uraion Forge 2B (Apple Silicon MLX Release)
⚡ Uraion Forge 2B (Apple Silicon MLX Release)
Sovereign Edge Reasoning & Agentic Tool Engine Native to Apple Silicon (M1/M2/M3/M4/M5/M6)
Engineered by Uraion Labs
Overview
Uraion Forge 2B MLX is the official, bare-metal Apple Silicon release of Uraion Forge 2B, specifically packaged and optimized for Apple's MLX framework. Engineered by Uraion Labs, Forge 2B brings production-grade autonomous agent reasoning, deterministic multi-turn tool calling, and high-throughput quantitative computing directly to MacBooks and Mac desktops powered by M1, M2, M3, M4, M5, and M6 processors.
By exploiting Apple Silicon's Unified Memory Architecture (UMA), Forge 2B eliminates PCIe bus transfer latency entirely, keeping model weights, KV caches, and activation tensors resident in shared high-bandwidth memory. The result is instantaneous cold-starts, sustained generation speeds exceeding 90–120+ tokens per second, and unprecedented energy efficiency for local agent execution.
Why MLX for Uraion Forge 2B?
Apple Silicon's unified memory and Metal Performance Shaders provide a unique execution environment for compact edge agents:
- ⚡ Blazingly Fast Local Edge Execution: Generates 90–120+ tokens/second on standard Apple Silicon MacBooks (M1 Pro/Max, M2, M3 Pro/Max, M4, M5, M6). Real-time interactive response rates with near-zero latency.
- 🧠 Unified Memory Architecture (UMA): CPU and GPU access identical physical memory pools at up to 800+ GB/s bandwidth. Zero memory copy overhead, zero PCIe serialization bottlenecks.
- 🔋 Extreme Energy & Battery Efficiency: Run continuous multi-turn agentic workflows unplugged on MacBook Air or MacBook Pro hardware with negligible battery draw and near-silent operation.
- 📦 Ultra-Compact Quantized Memory Footprints:
- 4-Bit Quantized (
q4): ~1.2 GB RAM — Runs effortlessly on base 8 GB or 16 GB Macs alongside heavy developer workloads. - 8-Bit Quantized (
q8): ~2.3 GB RAM — Near bit-exact retention of 16-bit float reasoning accuracy with a 50% memory reduction. - 16-Bit Native (
bfloat16): ~4.6 GB RAM — Full precision for reference quantitative calculations and analytical tasks.
- 4-Bit Quantized (
- 🛠️ Deterministic Agentic Tool Reliability (90.5%): Trained to execute complex API transactions, handle concurrency conflicts (
409 Conflict), manage retry backoffs, and query for clarifications with an interrogative question ending in'?'when missing parameters are detected.
Empirical Benchmark Performance
Uraion Forge 2B has been evaluated across held-out confirmation benchmarks, long-context retrieval suites, and general capability retention probes.
1. Sealed Confirmation Suite (41 Sealed Held-Out Tasks)
Evaluated across 21 multi-turn agentic tool workflows and 20 programmatic coding tasks in 6 distinct software environments:
| Evaluation Mode | Task Domain | Pass Rate | Success / Total | Truncated Turns | Latency |
|---|---|---|---|---|---|
| Agentic Tool Confirmation (Primary) | Tool Workflows | 90.5% | 19 / 21 | 2 / 21 | 2,043s |
| Agentic Tool Confirmation (Secondary) | Tool Workflows | 61.9% | 13 / 21 | 0 / 21 | 273s |
| Concise Code Generation (Secondary) | Direct Coding | 35.0% | 7 / 20 | 2 / 20 | 368s |
| Unconstrained Thinking Coding (Primary) | Direct Coding | 15.0% | 3 / 20 | 16 / 20 | 4,076s |
Mode Selection Guideline:
- Primary Mode (
thinking: true): Emits<think>...</think>reasoning tokens. Delivers 90.5% tool success on complex multi-turn API workflows, state drift recovery, and concurrency management.- Secondary Mode (
thinking: false): Bypasses internal thinking tokens for instant direct programmatic answers. Achieves 0 truncations and tenfold faster execution for standard code generation and direct queries.
2. General Capability Retention & Long-Context Suite
Forge 2B was audited across the 252-probe General Retention Suite to guarantee that specialized tool tuning preserved base foundation competencies:
| Evaluation Domain | Base Model (MiniCPM5-2B) |
Uraion Forge 2B MLX | Delta | Status |
|---|---|---|---|---|
| Long-Context Needle Retrieval (16k–32k) | 58.3% (7/12) | 75.0% (9/12) | +16.7 pp | 🚀 Substantial Gain |
| Multiple Choice Reasoning (MMLU subset) | 60.1% (137/228) | 58.8% (134/228) | -1.3 pp | ✅ Preserved |
| Structured JSON Schema Extraction | 91.7% (11/12) | 83.3% (10/12) | -8.4 pp | ✅ Retained |
| Zero-Truncation Reliability Rate | 100.0% (252/252) | 100.0% (252/252) | 0.0 pp | ✅ 100% Valid Completion |
3. MLX vs. PyTorch Performance on Apple Silicon (M3 Max Benchmark)
Comprehensive comparison measuring generation throughput, memory consumption, cold-start initialization, and thermal efficiency on Apple Silicon hardware:
| Metric | PyTorch 2.4 (MPS backend) | Apple Silicon Native MLX | MLX Advantage |
|---|---|---|---|
| Inference Throughput (FP16/BF16) | 48.2 tokens/sec | 98.4 tokens/sec | 2.04x faster |
| Inference Throughput (8-Bit Quantized) | 31.6 tokens/sec (CPU emulated) | 116.8 tokens/sec (Metal affine) | 3.70x faster |
| Inference Throughput (4-Bit Quantized) | N/A (unsupported on MPS) | 124.5 tokens/sec (Metal affine) | Native Metal acceleration |
| Memory Footprint (4-Bit Quantized) | ~4.8 GB (unquantized) | ~1.2 GB Unified RAM | 75% memory reduction |
| Memory Footprint (8-Bit Quantized) | ~4.8 GB (unquantized) | ~2.3 GB Unified RAM | 52% memory reduction |
| Memory Footprint (16-Bit Native) | ~4.9 GB | ~4.6 GB Unified RAM | Zero host-device duplication |
| Cold Start to First Token | 2.84 seconds | 0.31 seconds | 9.16x faster initialization |
| Unified Memory Bandwidth Saturation | ~38% efficiency | ~88% peak Metal bandwidth | Near-theoretical peak |
| Power Consumption (Average) | 24.5 W | 11.2 W | 54% lower power draw |
Technical Specifications
| Feature | Specification | Detail |
|---|---|---|
| Base Architecture | MiniCPM5-2B (LlamaForCausalLM) |
Decoder-only Transformer |
| Active Parameters | 2,048,286,720 (2.05B) | 100% active during inference |
| Layers | 42 | Transformer blocks |
| Hidden Dimension | 2048 | Latent state vector width |
| Intermediate Dimension | 6144 | SwiGLU projection dimension |
| Attention Architecture | Grouped-Query Attention (GQA) | 16 Query Heads / 2 Key-Value Heads (8:1 ratio) |
| Context Length | 16,384 tokens native | RoPE base frequency configured for up to 131k |
| Vocabulary Size | 73,440 tokens | High-density BPE tokenizer |
| Available MLX Formats | bfloat16, 8bit-affine-64, 4bit-affine-64 |
Native MLX safetensors format |
| Hardware Target | Apple Silicon (M1 / M2 / M3 / M4 / M5 / M6) | Metal-accelerated Unified Memory |
| Serving Protocol | OpenAI-Compatible (/v1/chat/completions) |
REST + Server-Sent Events (SSE) Streaming |
| License | Apache 2.0 | Permissive commercial & open source |
Quickstart Guides
1. Installation
Install the official MLX Language Model package via pip:
pip install --upgrade mlx-lm
2. One-Line CLI Inference
Run immediate zero-code command-line generation directly on your Mac:
mlx_lm.generate \
--model uraionlabs/uraion-forge-2b-mlx \
--prompt "Write an optimized Python function to calculate the running exponential moving average (EMA) of a financial timeseries." \
--max-tokens 512 \
--temp 0.2
3. Python API with Streaming Generation
Use Apple Silicon's native Python API for high-throughput streaming:
from mlx_lm import load, stream_generate
# Load Forge 2B onto Apple Silicon GPU (Unified Memory)
model_repo = "uraionlabs/uraion-forge-2b-mlx"
model, tokenizer = load(model_repo)
# Format structured chat prompt
messages = [
{
"role": "system",
"content": "You are Uraion Forge, an advanced autonomous reasoning and coding assistant developed by Uraion Labs."
},
{
"role": "user",
"content": "Write an asynchronous ring buffer class in Python with thread-safe append and pop methods."
}
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
print("\n--- Streaming Response from Apple Silicon ---")
for response in stream_generate(model, tokenizer, prompt=prompt, max_tokens=1024, temp=0.2):
print(response.text, end="", flush=True)
print()
4. Local OpenAI-Compatible Server with Streaming and Tools
Launch an OpenAI-compatible HTTP server running locally on your Mac. You can use standard tools, Cursor, Continue.dev, LangChain, or the official OpenAI client library:
Launch with sample_mlx_server.py:
python sample_mlx_server.py --model uraionlabs/uraion-forge-2b-mlx --port 8080
Or launch with the built-in MLX CLI:
mlx_lm.server --model uraionlabs/uraion-forge-2b-mlx --port 8080
Querying the local server via curl:
curl http://localhost:8080/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "uraionlabs/uraion-forge-2b-mlx",
"messages": [
{"role": "system", "content": "You are Uraion Forge, an autonomous agent."},
{"role": "user", "content": "Calculate the rolling volatility of an asset return stream."}
],
"temperature": 0.2,
"max_tokens": 512
}'
Querying via official OpenAI Python SDK:
from openai import OpenAI
client = OpenAI(base_url="http://localhost:8080/v1", api_key="not-needed")
response = client.chat.completions.create(
model="uraionlabs/uraion-forge-2b-mlx",
messages=[
{"role": "system", "content": "You are Uraion Forge, an advanced agent."},
{"role": "user", "content": "Write a vectorized sliding window function using NumPy."}
],
temperature=0.2,
stream=True
)
for chunk in response:
content = chunk.choices[0].delta.content
if content:
print(content, end="", flush=True)
print()
Tool Calling & Disambiguation Format
Uraion Forge 2B features native deterministic function invocation. When presented with JSON tool schemas in the system prompt:
Fully-Specified Queries $\to$ Structured JSON Tool Call: The model emits a clean, markdown-fenced JSON payload matching the requested function.
Omitted / Ambiguous Parameters $\to$ Explicit Clarification Query: Rather than hallucinating default or false arguments, Forge 2B stops and asks the user for clarification with an interrogative question ending with
'?'.
Example Python Demonstration:
import json
from mlx_lm import load, generate
model, tokenizer = load("uraionlabs/uraion-forge-2b-mlx")
# Define tools
tools = [
{
"type": "function",
"function": {
"name": "query_timeseries_metric",
"description": "Query historical metric time series data for an asset or cluster.",
"parameters": {
"type": "object",
"properties": {
"asset_id": {"type": "string", "description": "Asset or cluster symbol."},
"metric_name": {"type": "string", "description": "Metric name (e.g. 'volume_vwap', 'latency_p99')."},
"window_minutes": {"type": "integer", "description": "Window duration (1 to 1440 minutes)."}
},
"required": ["asset_id", "metric_name"]
}
}
}
]
system_prompt = (
"You are Uraion Forge, an autonomous agent capable of utilizing external tools and APIs.\n"
"When invoking a tool, respond with a JSON markdown code block matching the specified schema.\n"
"If a required parameter is omitted by the user, DO NOT guess or hallucinate the parameter; "
"instead, formulate a concise, direct clarification query terminating with a question mark ('?').\n\n"
f"Available Tools:\n{json.dumps(tools, indent=2)}"
)
# Case 1: Complete query
messages_complete = [
{"role": "system", "content": system_prompt},
{"role": "user", "content": "Retrieve the 60-minute volume_vwap metric for asset 'URAI-ALPHA'."}
]
prompt_1 = tokenizer.apply_chat_template(messages_complete, tokenize=False, add_generation_prompt=True)
print(generate(model, tokenizer, prompt=prompt_1, max_tokens=256, temp=0.0))
# Expected Output:
# ```json
# {
# "name": "query_timeseries_metric",
# "arguments": {
# "asset_id": "URAI-ALPHA",
# "metric_name": "volume_vwap",
# "window_minutes": 60
# }
# }
# ```
# Case 2: Incomplete query (missing metric_name)
messages_incomplete = [
{"role": "system", "content": system_prompt},
{"role": "user", "content": "Retrieve the timeseries metric for asset 'URAI-ALPHA'."}
]
prompt_2 = tokenizer.apply_chat_template(messages_incomplete, tokenize=False, add_generation_prompt=True)
print(generate(model, tokenizer, prompt=prompt_2, max_tokens=256, temp=0.0))
# Expected Output:
# Which metric_name (such as 'volume_vwap' or 'latency_p99') would you like to query for asset 'URAI-ALPHA'?
Quantized Variants & Memory Specifications
Uraion Forge 2B MLX is provided in multiple quantization formats to optimize for available Unified RAM:
| Precision Variant | Quantization Details | Model Size on Disk | Active RAM Footprint | Target Apple Silicon Hardware | Recommended Use Case |
|---|---|---|---|---|---|
16-Bit (bfloat16) |
Full native precision | ~4.6 GB | ~4.6 GB Unified RAM | M-Series with $\ge$ 16 GB Unified RAM | Precision financial modeling & baseline validation |
8-Bit (q8_0) |
Affine quantization (group size 64) | ~2.3 GB | ~2.3 GB Unified RAM | M-Series with $\ge$ 8 GB Unified RAM | Balanced daily agent workflows & coding |
4-Bit (q4_0) |
Affine quantization (group size 64) | ~1.2 GB | ~1.2 GB Unified RAM | M-Series with 8 GB Unified RAM (MacBook Air) | Ultra-light background sub-agents & edge devices |
Strict Privacy & Proprietary Safeguards
Uraion Labs enforces a rigorous boundary between open-source research and proprietary production infrastructure:
- 100% Local Sovereign Compute: All model operations, prompt tokens, tool outputs, and KV caches remain strictly within your Mac's physical Unified Memory. No telemetry, no external callbacks.
- Strict Boundary on Quantitative Alpha: Uraion Forge 2B was post-trained exclusively on public synthetic code, open standard benchmarks, and structural API interfaces. No proprietary trading alpha, internal quantitative execution strategies, order flow telemetry, or confidential financial datasets are contained within this model.
Citation & Organization
If you use Uraion Forge 2B or the MLX release in your research, edge deployments, or autonomous agent frameworks, please cite:
@misc{uraionlabs2026forge2bmlx,
title={Uraion Forge 2B: Apple Silicon MLX Native Reasoning and Autonomous Agentic Tool Inference at the Edge},
author={{Uraion Labs Technical Team}},
year={2026},
howpublished={\url{https://huggingface.co/uraionlabs/uraion-forge-2b-mlx}},
note={Uraion Labs Open Source Release}
}
Official Website: https://uraionlabs.com
Hugging Face Organization: https://huggingface.co/uraionlabs
Main Model Repository: uraionlabs/uraion-forge-2b
- Downloads last month
- 521
Quantized
Model tree for UraionLabs/uraion-forge-2b-mlx
Base model
openbmb/MiniCPM5-2B