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

# Sarvamai

> TypeScript API reference for the sarvamai llm provider.

<Card title="Usage guide" icon="book" href="/plugins/llm/sarvamai" horizontal>
  Setup, environment variables, and Python/JavaScript/Go usage examples.
</Card>

## SarvamAILLM

Create an LLM instance configured for Sarvam AI.

```ts theme={null}
import { SarvamAILLM } from '@zeroruntime/js-sdk/inference';  // same fields, through the gateway, no vendor key
import { SarvamAILLM } from '@zeroruntime/js-sdk/plugins';  // direct to the vendor, with your key
```

### Options

<ParamField path="model" type="string" default="sarvam-30b" />

<ParamField path="temperature" type="number" default="0.7" />

<ParamField path="tool_choice" type="'auto' | 'required' | 'none'" default="auto" />

<ParamField path="max_completion_tokens" type="number | null" default="null" />

<ParamField path="reasoning_effort" type="'low' | 'medium' | 'high' | null" default="null" />

<ParamField path="wiki_grounding" type="boolean" default="false" />

<ParamField path="top_p" type="number | null" default="null" />

<ParamField path="frequency_penalty" type="number | null" default="null" />

<ParamField path="presence_penalty" type="number | null" default="null" />

<ParamField path="stop" type="string | string[]" default="null" />
