Qwen2 7B Instruct
Qwen2's 7B chat model from June 2024, aligned with supervised fine-tuning and DPO. Qwen reports 79.9 on HumanEval and 77.2 on C-Eval; on Wiro it takes a prompt plus session history.
Overview
Qwen2-7B-Instruct comes from the Qwen2 release of June 2024, one generation before Qwen2.5. Qwen trained the series on English, Chinese and 27 more languages, then aligned the chat model with supervised fine-tuning and direct preference optimization. Its released weights hold 7.6B parameters, and the card gives 131,072 tokens of context with YaRN scaling switched on.
In the card's comparison with similar-sized chat models, it leads on HumanEval (79.9), MultiPL-E (59.1), LiveCodeBench (26.6) and the Chinese tests C-Eval (77.2) and AlignBench (7.21). GPQA is its weak spot: 25.3, against 34.2 for Llama-3-8B-Instruct.
Choosing a variant: the direct successor is Qwen2.5 7B Instruct, which beats it on every instruct benchmark in the Qwen2.5 release tables and, on Wiro, also accepts JSON mode and function definitions. Keep Qwen2 when an existing integration or evaluation set was built on its outputs. Newer sizes run from Qwen2.5 0.5B Instruct and Qwen2.5 1.5B Instruct through Qwen2.5 3B Instruct to Qwen2.5 32B Instruct.
What you can build
- Story and worldbuilding prompts: the sample lists seven numbered events near the Tower of London, each with a plot angle.
- Chinese-language Q&A and writing help, backed by its C-Eval and AlignBench results.
- Code explanation and short function drafts.
Inputs
The prompt is the only required field; its default asks which historical events near the Tower of London could inspire a fictional story. This page has no messages array, tool fields or JSON mode. Wiro stores and replays earlier turns for each user ID and session ID pair.
The system prompt is pre-filled with a generic instruction to answer helpfully and safely, where Qwen's card example uses only "You are a helpful assistant." With YaRN off, at most 32,768 input tokens fit, counting system prompt, history and prompt, and the limit on Wiro can be lower. Longer input loses the oldest turns, then the tail of the latest message, with no error.
Tuning fields: temperature (0.7 default), top-p (0.95), top-k, repetition and length penalties, min and max tokens, stop sequences, a seed, and sampling and quantization switches that start on.
Outputs
Plain text only. Left at 0, the output limit becomes 2,048 tokens for a prompt of that length or less and twice the prompt length for a longer one; a limit you set is honoured within the room left in the window. The sample shows why facts need review: it says Mary, Queen of Scots was tried over the murder of her half-sister Elizabeth I, yet Elizabeth outlived Mary and the two were cousins.
Recommended settings
- Qwen2's shipped generation config pairs temperature 0.7 with top-p 0.8, top-k 20 and a repetition penalty of 1.05.
- For code, switch sampling off for repeatable answers.
Limitations
- The widest gaps to the newer 7B in Qwen's Qwen2.5 table are Arena-Hard (25.0 against 52.0) and MATH (52.9 against 75.5).
Safety & compliance
With Qwen2, Qwen moved every size except the 72B to Apache 2.0, this 7B included, which allows commercial use.
API quick start
Run Qwen2-7B-Instruct with a single API call.
{
"prompt": "What are some interesting historical even…",
"user_id": "...",
"session_id": "...",
"system_prompt": "You are a helpful, respectful and honest …"
}curl -X POST "https://api.wiro.ai/v1/Run/qwen/qwen2-7b-instruct" \
-H "Content-Type: application/json" \
-H "x-api-key: YOUR_WIRO_API_KEY" \
--data-binary @- <<'JSON'
{
"prompt": "What are some interesting historical even…",
"user_id": "...",
"session_id": "...",
"system_prompt": "You are a helpful, respectful and honest …"
}
JSONOther models you might like
Explore similar llm & chat models.



