Instructions to use metanthropic/arvi-20b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use metanthropic/arvi-20b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="metanthropic/arvi-20b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("metanthropic/arvi-20b") model = AutoModelForCausalLM.from_pretrained("metanthropic/arvi-20b") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use metanthropic/arvi-20b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "metanthropic/arvi-20b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "metanthropic/arvi-20b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/metanthropic/arvi-20b
- SGLang
How to use metanthropic/arvi-20b with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "metanthropic/arvi-20b" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "metanthropic/arvi-20b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "metanthropic/arvi-20b" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "metanthropic/arvi-20b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use metanthropic/arvi-20b with Docker Model Runner:
docker model run hf.co/metanthropic/arvi-20b
Arvi-20B
Arvi-20B is a foundational reasoning model developed by Metanthropic Research.
Model Card | Website | Citation
🚀 Model Summary
Arvi-20B represents a paradigm shift in efficient intelligence. Built on a specialized Mixture-of-Experts (MoE) architecture, it delivers the knowledge density of a 20-billion parameter system while maintaining the inference speed of a much smaller model.
Designed specifically for complex reasoning protocols, Arvi-20B excels at chain-of-thought generation, agentic tool usage, and high-fidelity instruction following. It serves as the flagship model for Metanthropic's open-weight initiative.
📊 Technical Specifications
| Feature | Specification |
|---|---|
| Developer | Metanthropic Research |
| Model Architecture | Sparse Mixture-of-Experts (MoE) |
| Total Parameters | 20.9 Billion |
| Active Parameters | 3.6 Billion (per token) |
| Context Window | 128,000 Tokens |
| Precision | BFloat16 (Native) |
| License | Apache 2.0 |
⚡ Capabilities
- Deep Reasoning: Native capability to deconstruct complex queries into logical steps before generating a final answer.
- Agentic Workflow: Optimized for function calling and tool interaction, allowing integration into autonomous systems.
- Efficiency: Activates only ~17% of parameters per token, enabling deployment on standard enterprise hardware without sacrificing intelligence.
- Long Context: Capable of ingesting and analyzing massive documents up to 128k tokens in length.
🛠️ Installation & Usage
Arvi-20B utilizes a specialized MoE architecture. To run the model, you must install the required backend kernels and libraries.
1. Install Dependencies
# Install required backend support for Arvi's architecture
pip install gpt-oss transformers peft accelerate torch
2. Python Inference
import torch
import gpt_oss # Registers the Arvi MoE architecture
from transformers import AutoModelForCausalLM, AutoTokenizer
# 1. Configuration
model_id = "metanthropic/arvi-20b"
print(f"🚀 Loading {model_id}...")
# 2. Load Model
# We recommend BFloat16 for the best balance of speed and precision
model = AutoModelForCausalLM.from_pretrained(
model_id,
torch_dtype=torch.bfloat16,
trust_remote_code=True, # Required for Arvi architecture
device_map="auto"
)
# 3. Load Tokenizer
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
# 4. Generate
prompt = "Explain the grandfather paradox and potential resolutions."
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
with torch.no_grad():
outputs = model.generate(
**inputs,
max_new_tokens=256,
temperature=0.7,
do_sample=True
)
print(tokenizer.batch_decode(outputs, skip_special_tokens=True)[0])
📜 License & Citation
Arvi-20B is released under the Apache 2.0 license, allowing for broad commercial use, modification, and redistribution.
If you utilize this model in your research or products, please cite Metanthropic Research:
@misc{arvi2025,
title={Arvi-20B: High-Efficiency Reasoning Model},
author={Metanthropic, Ekjot Singh},
year={2025},
publisher={Hugging Face}
}
- Downloads last month
- 9