> For clean Markdown of any page, append `.md` to the page URL.
> For a complete documentation index, see https://docs.sarvam.ai/llms.txt.
> For full documentation content in one file, see https://docs.sarvam.ai/llms-full.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.sarvam.ai/_mcp/server.

# How to pick a genre and model tier

> Use genre and model_type to tune Sarvam Document Translation for your content category and length.

`genre` tunes the translation prompt for the kind of content you're translating. `model_type` trades off speed against quality for the length of content you're translating.

| Parameter    | Type   | Values                                                                               | Default |
| ------------ | ------ | ------------------------------------------------------------------------------------ | ------- |
| `genre`      | string | `NON_FICTION`, `ADULT_FICTION`, `CHILDREN_FICTION`, `RELIGIOUS`, `LEGAL`, `ACADEMIC` | -       |
| `model_type` | string | `lite` (faster, short-form), `plus` (higher quality, long-form)                      | `plus`  |

`genre` and `model_type` are independent: pick the genre for tone/terminology and the model tier for the length/quality tradeoff that fits your document.

## Example

#### Python

```python
from sarvamai import SarvamAI

client = SarvamAI(api_subscription_key="YOUR_SARVAM_API_KEY")

job = client.document_translation.create(
    job_name="service-agreement-hi",
    source_language_code="en-IN",
    target_language_codes=["hi-IN"],
    original_filename="service-agreement.pdf",
    genre="LEGAL",
    model_type="plus",
)
```

#### JavaScript

```javascript
import { SarvamAIClient } from "sarvamai";

const client = new SarvamAIClient({
    apiSubscriptionKey: "YOUR_SARVAM_API_KEY",
});

const job = await client.documentTranslation.create({
    job_name: "service-agreement-hi",
    source_language_code: "en-IN",
    target_language_codes: ["hi-IN"],
    original_filename: "service-agreement.pdf",
    genre: "LEGAL",
    model_type: "plus",
});
```

Request body equivalent:

```json
{
  "job_name": "service-agreement-hi",
  "source_language_code": "en-IN",
  "target_language_codes": ["hi-IN"],
  "original_filename": "service-agreement.pdf",
  "genre": "LEGAL",
  "model_type": "plus"
}
```

## Related

* [Document Translation Overview](/api/api-guides-tutorials/doc-translation/overview)
* [Set Style Guidelines](/api/api-guides-tutorials/doc-translation/how-to/style-guidelines)