> ## Documentation Index
> Fetch the complete documentation index at: https://docs.enconvo.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Qwen (Tongyi Qianwen)

> Configure Alibaba's Qwen models in EnConvo

## Overview

Qwen (Tongyi Qianwen) is Alibaba Cloud's family of large language models. Qwen models offer excellent multilingual support, particularly for Chinese and English, with strong performance across reasoning, coding, and multimodal tasks.

## Supported Models

| Model          | Description             | Best For                    |
| -------------- | ----------------------- | --------------------------- |
| **Qwen-Max**   | Most capable flagship   | Complex reasoning, analysis |
| **Qwen-Plus**  | Balanced performance    | General tasks, writing      |
| **Qwen-Turbo** | Fast and cost-effective | Quick responses, chat       |
| **Qwen-VL**    | Vision-language model   | Image understanding, OCR    |

## Setup

<Steps>
  <Step title="Get API Key">
    1. Go to [DashScope Console](https://dashscope.aliyun.com)
    2. Sign in with your Alibaba Cloud account (or create one)
    3. Navigate to **API Key Management**
    4. Create a new API key
  </Step>

  <Step title="Configure in EnConvo">
    1. Open **Settings** → **AI Provider**
    2. Select **Qwen**
    3. Go to **Credentials** module
    4. Enter your API key
  </Step>

  <Step title="Select Model">
    Choose your preferred Qwen model from the dropdown
  </Step>
</Steps>

<Note>
  DashScope is Alibaba Cloud's AI service platform. You need an Alibaba Cloud account to obtain an API key.
</Note>

## Configuration

| Setting         | Description           | Default    |
| --------------- | --------------------- | ---------- |
| **Credentials** | API key configuration | Required   |
| **Model Name**  | Model to use          | Qwen-Max   |
| **Temperature** | Creativity (0-2)      | Medium (1) |

## Validate and Use

<Steps>
  <Step title="Validate credentials">
    Click **Validate** in the Qwen credential settings. If validation fails, confirm the DashScope API key is active and the service is enabled for your Alibaba Cloud account.
  </Step>

  <Step title="Choose a tier">
    Use Qwen-Max for high-quality work, Qwen-Plus for daily tasks, Qwen-Turbo for lower-cost chat, and Qwen-VL when you need vision support.
  </Step>

  <Step title="Test latency from your region">
    Send a short prompt first. Depending on your network location, DashScope latency can vary.
  </Step>
</Steps>

## Pricing

Check [DashScope Pricing](https://dashscope.aliyun.com) for current rates. Qwen offers competitive pricing, especially for the Turbo tier.

| Model      | Input       | Output       |
| ---------- | ----------- | ------------ |
| Qwen-Max   | \~\$2.80/1M | \~\$11.20/1M |
| Qwen-Plus  | \~\$0.56/1M | \~\$1.54/1M  |
| Qwen-Turbo | \~\$0.06/1M | \~\$0.22/1M  |

<Tip>
  New DashScope accounts receive free credits, making it easy to evaluate Qwen models before committing.
</Tip>

## Best Practices

<AccordionGroup>
  <Accordion title="Model Selection">
    * **Qwen-Max**: Research, complex analysis, professional writing
    * **Qwen-Plus**: Daily work, coding, moderate reasoning
    * **Qwen-Turbo**: Quick chat, simple Q\&A, high-volume tasks
    * **Qwen-VL**: Image analysis, document understanding, visual Q\&A
  </Accordion>

  <Accordion title="Chinese Language Tasks">
    Qwen models are among the best for Chinese language understanding and generation. They are ideal for Chinese-English translation, Chinese content creation, and bilingual workflows.
  </Accordion>
</AccordionGroup>

## Troubleshooting

<AccordionGroup>
  <Accordion title="Invalid API key">
    * Verify the key is copied correctly from DashScope console
    * Check if the key has been disabled or expired
    * Ensure your Alibaba Cloud account has the DashScope service enabled
  </Accordion>

  <Accordion title="Rate limits">
    * Free tier has rate and token limits
    * Upgrade to a paid plan for higher throughput
    * Use Qwen-Turbo for cost-sensitive workloads
  </Accordion>

  <Accordion title="Connection issues from outside China">
    * DashScope APIs may have higher latency from outside mainland China
    * Consider using a proxy or alternative endpoint if available
    * Check your network connection
  </Accordion>
</AccordionGroup>
