--- license: other license_name: lfm1.0 base_model: LiquidAI/d1-2B pipeline_tag: image-text-to-text library_name: transformers tags: - webbrain - liquid - lfm3 - lfm3-vl - browser-agent - decision-model - webbrain-vld - vldr - pegasus-method - custom_code --- # LFM3-VLD-2B `LFM3-VLD-2B` (Restored Language Head) is a hybrid multimodal browser decision model built using the **Pegasus method** (inspired by `AveLabs/Qwen3.8-27B-Perplexing-Pegasus`). It combines: 1. **Decision Backbone**: The complete 24-layer hybrid architecture (Conv + GQA attention + Feed-Forward), vision tower, multimodal projector, and embeddings from `LiquidAI/d1-2B` (trained on browser actions, verification, and decision trajectories). 2. **Restored Language Head**: The original uncorrupted generative language head (`lm_head.weight`) from `LiquidAI/LFM3-VL-2B`, untied from token embeddings (`tie_word_embeddings: false`). ## The Problem Solved When models like `LiquidAI/d1-2B` undergo full fine-tuning on decision tasks with tied word embeddings, the language head weights drift away from fluent language generation, causing token repetition and degraded prose in standard causal LM generation. By untying the embeddings and restoring the original `LFM3-VL-2B` language head onto the decision-trained backbone, `LFM3-VL-2B-VLDR` achieves: - **Flawless open-ended multimodal chat & text generation** (no repetition artifacts). - **Preserved decision separability**: Hidden states retain deep decision knowledge, reaching **91.27% accuracy** with **0% false completions** on the balanced browser decision benchmark. ## Benchmark Results (d1 Balanced Decision Benchmark — `final_test`, 126 Categorical Decisions) | Model / Method | Accuracy | Completion Found | False Completions | Unknown Recognized | |---|---:|---:|---:|---:| | **LFM3-VLD-2B (Decision Probe)** | **115/126 (91.3%)** | **24/24 (100%)** | **0/48 (0%)** | **24/24 (100%)** | | **LFM3-VLD-2B (`verify` Zero-Shot)** | **85/126 (67.5%)** | **22/24 (91.7%)** | **0/48 (0%)** | **0/24 (0%)** | | LFM3-VL-2B-VLD (LoRA Distillation) | 126/126 (100.0%) | 24/24 (100%) | 0/48 (0%) | 24/24 (100%) | | Base `LiquidAI/LFM3-VL-2B` (`verify` Zero-Shot) | 106/126 (84.1%) | 24/24 (100%) | 0/48 (0%) | 4/24 (16.7%) | ## Companion Repositories - [`webbrain-one/lfm3-vl-2b-vldr-gguf`](https://huggingface.co/webbrain-one/lfm3-vl-2b-vldr-gguf): GGUF quantizations (`BF16`, `Q8_0`, `Q4_K_M`, `mmproj-F16`) for `llama.cpp` (`/v1/chat/completions` + `/v1/systemone`). - [`webbrain-one/lfm3-vl-2b-vldr-onnx`](https://huggingface.co/webbrain-one/lfm3-vl-2b-vldr-onnx): WebGPU-ready ONNX bundle (`decoder_q8f16`, `decoder_q4f16`, `vision_encoder_fp16`, and decision probe JS runtime). ## Quickstart ```python import torch from transformers import AutoModelForImageTextToText, AutoProcessor model_id = "webbrain-one/lfm3-vl-2b-vldr" processor = AutoProcessor.from_pretrained(model_id, trust_remote_code=True) model = AutoModelForImageTextToText.from_pretrained( model_id, torch_dtype=torch.bfloat16, device_map="auto", trust_remote_code=True, ) messages = [ {"role": "user", "content": "What is the capital of France?"} ] text = processor.apply_chat_template(messages, tokenize=False, add_generation_prompt=True) inputs = processor(text=text, return_tensors="pt").to(model.device) with torch.no_grad(): out = model.generate(**inputs, max_new_tokens=64) print(processor.decode(out[0], skip_special_tokens=True)) # The capital of France is Paris. ```