Qwen3 Next 80B A3B Thinking
Qwen3 Next 80B A3B Thinking is a hybrid Transformer-Mamba reasoning model that combines 80 billion total parameters (3B active per token) with a dedicated thinking mode, achieving strong results on AIME25 while supporting ultra-long contexts of 262.1K tokens.
View API reference- Input and output price
- Prices from: Input $0.15, Output $1.20, Per 1M tokens
- 24h uptime
- Loading AI Gateway uptime
import { streamText } from 'ai'
const result = streamText({ model: 'alibaba/qwen3-next-80b-a3b-thinking', prompt: 'Why is the sky blue?'})Copy link to headingPlayground
Try out Qwen3 Next 80B A3B Thinking by Alibaba Cloud. Usage is billed to your team at API rates. Free users (those who haven't made a payment) get $5 of credits every 30 days.
Qwen3 Next 80B A3B Thinking
Copy link to headingProviders
Route requests across multiple providers. Copy a provider slug to set your preference. Visit the docs for more info. Using a provider means you agree to their terms, listed under Legal.
| Provider |
|---|
Copy link to headingUptime24 hours
Direct request success rate on AI Gateway and per-provider. Visit the docs for more info.
Copy link to headingThroughput24 hours
P50 throughput on live AI Gateway traffic, in tokens per second (TPS). Visit the docs for more info.
Copy link to headingLatency24 hours
P50 time to first token (TTFT) on live AI Gateway traffic, in milliseconds. View the docs for more info.
Getting started
Call Qwen3 Next 80B A3B Thinking through AI Gateway with the AI SDK generateText and streamText functions, or through the OpenAI Chat Completions, OpenAI Responses, and Anthropic Messages APIs by changing the base URL. AI Gateway authenticates the request and routes it to an available provider.
Install the AI SDK (pnpm add ai dotenv), create an API key from the API Keys page, and set it as AI_GATEWAY_API_KEY in your environment. Full setup is covered in the text generation quickstart.
import { generateText } from 'ai';import 'dotenv/config';
async function main() { const result = await generateText({ model: 'alibaba/qwen3-next-80b-a3b-thinking', prompt: 'Why is the sky blue?', });
console.log(result.text);}
main().catch(console.error);Top-level parameters
The same Qwen3 Next 80B A3B Thinking request in each API format AI Gateway supports.
import { generateText } from 'ai';import 'dotenv/config';
async function main() { const result = await generateText({ model: 'alibaba/qwen3-next-80b-a3b-thinking', system: 'You are a concise technical assistant.', prompt: 'Summarize the tradeoffs between static generation and SSR.', maxOutputTokens: 1024, });
console.log(result.text);}
main().catch(console.error);Standard parameters like prompt, messages, temperature, and tools work as documented in the AI SDK docs. These are the parameters with model-specific behavior.
| Parameter | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Model ID in the form creator/model, e.g. alibaba/qwen3-next-80b-a3b-thinking. AI Gateway routes the request to an available provider. |
maxOutputTokens | number | No | Hard cap on generated tokens. Qwen3 Next 80B A3B Thinking supports up to 262,144 output tokens. Reasoning tokens count toward this limit. |
reasoning | 'provider-default' | 'none' | 'minimal' | 'low' | 'medium' | 'high' | 'xhigh' | No | Provider-agnostic reasoning effort, available in AI SDK 7 or later. Maps to the provider’s native reasoning configuration; reasoning settings under providerOptions take precedence when both are set. See the Reasoning section below. |
providerOptions | Record<string, JSONValue> | No | AI Gateway routing options under gateway, plus any provider-native options under the provider’s own namespace — see the table below. |
Input limits
| Input | Formats | Sources | Max count | Max size | Limits |
|---|---|---|---|---|---|
| Text | — | — | — | — | Prompt and response share the 262K-token context window |
Provider options
Set AI Gateway routing options under providerOptions.gateway. For provider-specific options, pass them under the provider’s namespace as documented by the AI SDK.
Learn more in the AI SDK alibaba provider docs.
import { generateText } from 'ai';import 'dotenv/config';
async function main() { const result = await generateText({ model: 'alibaba/qwen3-next-80b-a3b-thinking', prompt: 'Why is the sky blue?', providerOptions: { gateway: { only: ['alibaba', 'vertex'], }, }, });
console.log(result.text);}
main().catch(console.error);These AI Gateway routing options apply to every model. Provider-specific options pass through under the provider’s own namespace (for example providerOptions.anthropic) exactly as documented by the AI SDK.
| Parameter | Type | Required | Description |
|---|---|---|---|
providerOptions.gateway.only | string[] | No | Restrict routing to these provider slugs. Requests fail over only within the listed providers. |
providerOptions.gateway.order | string[] | No | Preferred provider order. Listed providers are tried first; unlisted providers remain available as fallbacks. |
providerOptions.gateway.sort | 'cost' | 'ttft' | 'tps' | No | Rank candidate providers by price, time to first token, or tokens per second instead of the default routing order. |
providerOptions.gateway.zeroDataRetention | boolean | No | Route only to providers with a zero-data-retention policy for this model. |
Routing across providers
AI Gateway serves the same model through multiple providers and fails over automatically. order expresses a preference while keeping every provider eligible; only is a hard allowlist — if none of the listed providers are available the request fails instead of falling back.
Options under a provider's own namespace (for example providerOptions.anthropic) are forwarded to that provider with the request. Providers ignore option namespaces that don't apply to them, so it is safe to set provider options alongside gateway routing options.
Reasoning
AI Gateway bridges reasoning across every API format. The AI SDK exposes a provider-agnostic top-level reasoning level (none, minimal, low, medium, high, or xhigh); the Chat Completions and Responses formats take the same effort under reasoning.effort; and the Anthropic Messages format uses a native thinking token budget. Whichever you send, the gateway maps it to the target model’s native configuration, converting between effort levels and token budgets as needed. Reasoning-related settings under providerOptions take full precedence over the top-level reasoning value and are never merged. Reasoning tokens typically count toward your output-token usage, though how they’re reported and billed varies by provider.
Learn more in the AI Gateway reasoning guide.
import { generateText } from 'ai';import 'dotenv/config';
async function main() { const result = await generateText({ model: 'alibaba/qwen3-next-80b-a3b-thinking', prompt: 'Explain the Monty Hall problem step by step.', reasoning: 'high', });
console.log(result.text);}
main().catch(console.error);Tool calling
Expose tools the model can call. Define each tool’s inputs with a Zod schema.
import { generateText, tool } from 'ai';import { z } from 'zod';import 'dotenv/config';
async function main() { const result = await generateText({ model: 'alibaba/qwen3-next-80b-a3b-thinking', prompt: 'What is the weather in San Francisco?', tools: { getWeather: tool({ description: 'Get the current weather for a location', inputSchema: z.object({ location: z.string() }), execute: async ({ location }) => ({ location, temperatureC: 18 }), }), }, });
console.log(result.text);}
main().catch(console.error);Copy link to headingAbout Qwen3 Next 80B A3B Thinking
Qwen3 Next 80B A3B Thinking is the reasoning-mode counterpart to Qwen3-Next-80B-A3B-Instruct. It shares the identical Hybrid Transformer-Mamba architecture, 48 layers in a 12-block pattern of three Gated DeltaNet + MoE layers followed by one Gated Attention + MoE layer, with 512 total experts and only 10 activated per token. What distinguishes the Thinking variant is that thinking mode is the only mode: the model always generates a <think> reasoning trace before its final answer, and the recommended token budget for that trace ranges from 32,768 tokens for typical queries to 81,920 tokens for difficult mathematical or coding problems.
This exclusive thinking mode is a deliberate design choice. By eliminating mode switching, the model is specialized for tasks where getting the right answer matters more than minimizing output length. The architecture's linear-attention Gated DeltaNet layers keep context processing efficient even as reasoning traces extend the total sequence length substantially beyond the prompt, which helps when reasoning chains grow long.
Benchmark results reflect this specialization. Across math and coding benchmarks the model outperforms both the Qwen3-30B-A3B-Thinking-2507 and Qwen3-32B-Thinking predecessors, as well as several proprietary reasoning models in Qwen's published comparisons. See https://modelstudio.console.alibabacloud.com/?tab=doc#/doc/?type=model&url=2840914_2&modelId=qwen3-next-80b-a3b-thinking for detailed benchmark tables.
Copy link to headingWhat To Consider When Choosing a Provider
- Configuration: Because thinking-mode responses can exceed 32K output tokens for complex reasoning tasks, verify that your provider and application timeout settings accommodate extended generation times before deploying.
- Zero Data Retention: Zero Data Retention is available for this model. It is offered on a per-provider and model basis. See the documentation for details.
- Authentication: AI Gateway authenticates requests using an API key or OIDC token. You do not need to manage provider credentials directly.
Copy link to headingWhen to Use Qwen3 Next 80B A3B Thinking
Best for
- Competitive mathematics and science: Rigorous reasoning problems where step-by-step derivation is required
- Hard coding challenges: Competitive programming and algorithmic design that benefit from explicit problem decomposition before code generation
- Cross-reference long-document analysis: Tasks that reason across 100K+ token inputs while maintaining structured thought
- Tutoring and explanation systems: Applications where visible reasoning chains are pedagogically valuable
- Auditable research workflows: Use cases where a transparent inference process allows human review of the model's logic
Consider alternatives when
- High-throughput instruction following: Use Qwen3-Next-80B-A3B-Instruct for short-to-medium tasks without reasoning overhead
- Strict token budgets: Thinking traces add significant output volume and cost per request
- Multimodal input required: This model is text-only; use a vision-language variant for images or video
- Real-time latency requirements: Extended reasoning generation can't meet hard low-latency response targets
Copy link to headingConclusion
Qwen3 Next 80B A3B Thinking occupies a distinct space: an architecture built for long-context efficiency that is simultaneously dedicated exclusively to extended reasoning. Teams working on hard STEM problems, detailed code analysis, or any domain where a visible reasoning chain adds quality and auditability can use it without resorting to a fully dense trillion-parameter alternative.
Copy link to headingFrequently Asked Questions
Why does this model only support thinking mode, not a standard non-thinking mode?
This variant is specialized for complex reasoning. By committing entirely to thinking mode, it avoids the quality compromises that come from training a single model to switch between reasoning and direct-answer behaviors.
How long can the thinking trace be?
The recommended budget is 32,768 tokens for typical queries and up to 81,920 tokens for complex mathematics or coding problems. These are recommendations; actual trace length is determined by the model based on problem complexity.
How does the AIME25 score compare to other models in the family?
The Thinking variant outperforms the Instruct variant's 69.5% on AIME25, and also surpasses Qwen3-30B-A3B-Thinking-2507 and several proprietary reasoning models in Qwen's published comparisons on this benchmark. See https://modelstudio.console.alibabacloud.com/?tab=doc#/doc/?type=model&url=2840914_2&modelId=qwen3-next-80b-a3b-thinking for specific scores.
Does the Hybrid Transformer-Mamba architecture help during reasoning?
Yes. The linear-attention Gated DeltaNet layers allow the model to handle sequences that grow long during reasoning, prompt plus extended thinking trace, at sub-quadratic cost compared to full attention. This keeps generation efficient even for hard problems that trigger long traces.
What is the native context length?
The native context is 262.1K tokens, extensible to approximately one million tokens via YaRN rope scaling. This allows the model to reason over very long input documents alongside its own thinking trace.
How should I parse the thinking content from responses?
The model outputs reasoning between
<think>and</think>before the final answer. If the opening tag is missing, find the closing</think>token (see Qwen reference parsers) and split there into thinking content and final response.How does this model compare to Qwen3-Max-Thinking for reasoning tasks?
Both models support extended reasoning, but they represent different architectural tradeoffs. Qwen3 Next 80B A3B Thinking uses a sparse hybrid architecture optimized for throughput on long sequences; Qwen3-Max-Thinking uses a trillion-parameter model with autonomous tool invocation. The right choice depends on whether autonomous search/code-execution or architecture-driven efficiency is more valuable for your workload.
Your use is subject to Alibaba Cloud's Terms & Privacy Policies.