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

# Nova Video

> Generate chat completions using Nova VLM model with text, video, and image inputs.

<Info>
  **Product**: Visual Intelligence — Video Model APIs (atomic)
  **Use case**: Call a Video Language Model (Gemini / Nova / Qwen) directly with your own prompt. Full control over model selection, prompt, and parameters. For ready-made tasks (no prompt needed), see Video Task APIs.
  **Host**: `https://mavi-backend.memories.ai/serve/api/v2`
  **Auth**: `Authorization: sk-mavi-...` (no `Bearer` prefix)
</Info>

This endpoint allows you to generate chat completions with text, video, and image inputs using Nova model.

<Info>
  **Endpoint:** `POST https://mavi-backend.memories.ai/serve/api/v2/vu/chat/completions`

  Video Understanding (VLM) endpoints use the `/vu` path prefix. Image Understanding (ILM) endpoints use `/iu` instead.
</Info>

## Supported Models

All models require the `nova:` prefix when used in the `model` parameter (e.g., `nova:us.amazon.nova-lite-v1:0`).

### Amazon Nova Models

| Model                           | Input Price      | Output Price      |
| ------------------------------- | ---------------- | ----------------- |
| **us.amazon.nova-premier-v1:0** | \$2.50/1M tokens | \$12.50/1M tokens |
| **us.amazon.nova-pro-v1:0**     | \$0.80/1M tokens | \$3.20/1M tokens  |
| **us.amazon.nova-2-lite-v1:0**  | \$0.33/1M tokens | \$2.75/1M tokens  |
| **us.amazon.nova-lite-v1:0**    | \$0.06/1M tokens | \$0.24/1M tokens  |

<Note>
  **Pricing Notes:**

  * All prices are per 1,000,000 (1M) tokens
  * Nova Premier offers the highest quality for complex multimodal tasks
  * Nova Pro provides balanced performance and cost
  * Nova 2 Lite and Nova Lite are optimized for cost-effective operations
  * Remember to include the `nova:` prefix: `"model": "nova:us.amazon.nova-lite-v1:0"`
</Note>

### Request Body

| Parameter          | Type                    | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                     |
| ------------------ | ----------------------- | -------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| model              | string                  | Yes      | -       | The model to use (e.g., `nova:us.amazon.nova-lite-v1:0`)                                                                                                                                                                                                                                                                                                                                        |
| messages           | array                   | Yes      | -       | Array of message objects. Each message contains:<br />- `role`: Role type, values: `system`, `user`, `assistant`<br />- `content`: Message content, can be a string or array. Array items can contain:<br />  - `type`: Content type, `text` or `video_url`<br />  - `text`: Text content (when type is text)<br />  - `video_url`: Video URL or base64 encoded video (when type is video\_url) |
| temperature        | number                  | No       | 1.0     | Controls randomness: 0.0-2.0, higher = more random                                                                                                                                                                                                                                                                                                                                              |
| max\_tokens        | integer                 | No       | 1000    | Maximum number of tokens to generate                                                                                                                                                                                                                                                                                                                                                            |
| top\_p             | number                  | No       | 1.0     | Nucleus sampling: 0.0-1.0, consider tokens with top\_p probability mass                                                                                                                                                                                                                                                                                                                         |
| frequency\_penalty | number                  | No       | 0.0     | Reduces repetition of frequent tokens: -2.0 to 2.0                                                                                                                                                                                                                                                                                                                                              |
| presence\_penalty  | number                  | No       | 0.0     | Increases likelihood of new topics: -2.0 to 2.0                                                                                                                                                                                                                                                                                                                                                 |
| n                  | integer                 | No       | 1       | Number of completions to generate                                                                                                                                                                                                                                                                                                                                                               |
| stream             | boolean                 | No       | false   | Whether to stream the response                                                                                                                                                                                                                                                                                                                                                                  |
| stop               | string \| array \| null | No       | null    | Stop sequences. Can be a string, array of strings, or null                                                                                                                                                                                                                                                                                                                                      |
| extra\_body        | object                  | No       | -       | Additional body parameters. Contains:<br />- `metadata`: Metadata object<br />  - `toolConfig`: Tool configuration<br />    - `tools`: Array of tool specifications                                                                                                                                                                                                                             |

### Code Example

<CodeGroup>
  ```python Python theme={null}
  from openai import OpenAI

  client = OpenAI(
      api_key="sk-mavi-...",
      base_url="https://mavi-backend.memories.ai/serve/api/v2/vu"
  )

  def call_my_vlm():
      resp = client.chat.completions.create(
          model="nova:us.amazon.nova-lite-v1:0",
          messages=[
              {"role": "system", "content": "You are a multimodal assistant. Keep your answers concise."},
              {
                  "role": "user",
                  "content": [
                      {
                          "type": "video_url",
                          "video_url": {
                              "url": "https://storage.googleapis.com/memories-test-data/test_1min.mp4"
                              # or use base64: "url": f"data:video/mp4;base64,{base64_string}"
                          }
                      },
                      {"type": "text", "text": "What is the content of this video?"}
                  ]
              }
          ],
          temperature=1.0,  # Controls randomness: 0.0-2.0, higher = more random
          max_tokens=1000,  # Maximum number of tokens to generate
          top_p=1.0,  # Nucleus sampling: 0.0-1.0, consider tokens with top_p probability mass
          frequency_penalty=0.0,  # -2.0 to 2.0, reduces repetition of frequent tokens
          presence_penalty=0.0,  # -2.0 to 2.0, increases likelihood of new topics
          n=1,  # Number of completions to generate
          stream=False,  # Whether to stream the response
          stop=None,  # Stop sequences (list of strings)
          extra_body={
              "metadata": {
                  "toolConfig": {
                      "tools": [
                          {
                              "toolSpec": {
                                  "name": "extract_video_summary",
                                  "description": "Extract a concise summary of the video",
                                  "inputSchema": {
                                      "json": {
                                          "type": "object",
                                          "properties": {
                                              "result": {"type": "string", "description": "Summary content."}
                                          },
                                          "required": ["result"]
                                      }
                                  }
                              }
                          }
                      ]
                  }
              }
          }
      )
      return resp

  # Usage example
  result = call_my_vlm()
  print(result)
  ```
</CodeGroup>

### Response

Returns the chat completion response.

<ResponseExample>
  ```json theme={null}
  {
    "id": "chatcmpl_705304384e4143db9e162cda30295762",
    "object": "chat.completion",
    "created": 1767098064,
    "model": "nova:amazon.nova-lite-v1:0",
    "choices": [{
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "At the start of the video, the screen displays the words \"VACUUM VS ORANGE\". The objects in the video are visible. The first is an orange resting on a stand. The second involves a small orange placed on a stand that is inside of a tall glass. The third is a glass filled with a yellow, orange-like liquid. The background is blurry. At 3 seconds, there is a small burst of citrus juice from the small orange that was resting on a stand. The juice splatters and travels onto the large orange. At 7 seconds, there is another burst of juice. This time, the juice comes from the glass, and more juices splatters onto the large orange. A hand can be seen at the top of the screen. This hand adjusts some sort of machinery, which is the metal pipe and circular object that is directly above the objects in the glass box. At around 14 seconds, liquid pours from the glass. At 17 seconds, the person adjusts the machinery again. The same things happens around 27 seconds. By 34 seconds, there is an excessive amount of juice and liquid inside of the glass box. At 43 seconds, all of the juice and liquid is gone from the glass box. At 46 seconds, there is no juice or liquid inside of the glass box. At 53 seconds, the person adjusts the machinery again."
      },
      "finish_reason": "stop"
    }],
    "usage": {
      "prompt_tokens": 17463,
      "output_token": 290,
      "total_tokens": 17753
    }
  }
  ```
</ResponseExample>

### Response Parameters

| Parameter                  | Type    | Description                                        |
| -------------------------- | ------- | -------------------------------------------------- |
| id                         | string  | Unique identifier for the chat completion          |
| object                     | string  | Object type, always "chat.completion"              |
| created                    | integer | Unix timestamp of when the completion was created  |
| model                      | string  | The model used for the completion                  |
| choices                    | array   | Array of completion choices                        |
| choices\[].index           | integer | Index of the choice in the choices array           |
| choices\[].message         | object  | Message object containing the assistant's response |
| choices\[].message.role    | string  | Role of the message, always "assistant"            |
| choices\[].message.content | string  | Content of the message                             |
| choices\[].finish\_reason  | string  | Reason why the completion finished                 |
| usage                      | object  | Token usage information                            |
| usage.prompt\_tokens       | integer | Number of tokens in the prompt                     |
| usage.output\_token        | integer | Number of tokens in the completion output          |
| usage.total\_tokens        | integer | Total number of tokens used                        |


## OpenAPI

````yaml visual-intelligence/nova/openapi.json POST /vu/chat/completions
openapi: 3.1.0
info:
  title: Nova API Reference
  description: REST APIs for Nova ILM and VLM models
  version: v1.0.0
servers:
  - url: https://mavi-backend.memories.ai/serve/api/v2
security:
  - ApiKeyAuth: []
paths:
  /vu/chat/completions:
    post:
      summary: Chat Completions Nova
      description: >-
        Generate chat completions using Nova ILM or VLM models with image and
        video inputs.
      operationId: chat_completions_nova
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                model:
                  type: string
                  description: The model to use (e.g., nova:amazon.nova-lite-v1:0)
                  example: nova:amazon.nova-lite-v1:0
                messages:
                  type: array
                  description: Array of message objects
                  items:
                    type: object
                    properties:
                      role:
                        type: string
                        enum:
                          - system
                          - user
                          - assistant
                      content:
                        oneOf:
                          - type: string
                          - type: array
                            items:
                              oneOf:
                                - type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - text
                                    text:
                                      type: string
                                  required:
                                    - type
                                    - text
                                - type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - image_url
                                    image_url:
                                      type: string
                                  required:
                                    - type
                                    - image_url
                                - type: object
                                  properties:
                                    type:
                                      type: string
                                      enum:
                                        - video_url
                                    video_url:
                                      type: string
                                  required:
                                    - type
                                    - video_url
                    required:
                      - role
                      - content
                temperature:
                  type: number
                  description: 'Controls randomness: 0.0-2.0, higher = more random'
                  minimum: 0
                  maximum: 2
                  default: 1
                max_tokens:
                  type: integer
                  description: Maximum number of tokens to generate
                  default: 1000
                top_p:
                  type: number
                  description: 'Nucleus sampling: 0.0-1.0'
                  minimum: 0
                  maximum: 1
                  default: 1
                frequency_penalty:
                  type: number
                  description: 'Reduces repetition of frequent tokens: -2.0 to 2.0'
                  minimum: -2
                  maximum: 2
                  default: 0
                presence_penalty:
                  type: number
                  description: 'Increases likelihood of new topics: -2.0 to 2.0'
                  minimum: -2
                  maximum: 2
                  default: 0
                'n':
                  type: integer
                  description: Number of completions to generate
                  default: 1
                stream:
                  type: boolean
                  description: Whether to stream the response
                  default: false
                stop:
                  oneOf:
                    - type: string
                    - type: array
                      items:
                        type: string
                    - type: 'null'
                  description: Stop sequences
                extra_body:
                  type: object
                  properties:
                    metadata:
                      type: object
                      properties:
                        toolConfig:
                          type: object
                          properties:
                            tools:
                              type: array
                              items:
                                type: object
                                properties:
                                  toolSpec:
                                    type: object
                                    properties:
                                      name:
                                        type: string
                                      description:
                                        type: string
                                      inputSchema:
                                        type: object
                                        properties:
                                          json:
                                            type: object
              required:
                - model
                - messages
      responses:
        '200':
          description: Chat completion response
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: Unique identifier for the chat completion
                    example: chatcmpl_705304384e4143db9e162cda30295762
                  object:
                    type: string
                    description: Object type, always "chat.completion"
                    example: chat.completion
                  created:
                    type: integer
                    description: Unix timestamp of when the completion was created
                    example: 1767098064
                  model:
                    type: string
                    description: The model used for the completion
                    example: nova:amazon.nova-lite-v1:0
                  choices:
                    type: array
                    description: Array of completion choices
                    items:
                      type: object
                      properties:
                        index:
                          type: integer
                          description: Index of the choice in the choices array
                        message:
                          type: object
                          description: Message object containing the assistant's response
                          properties:
                            role:
                              type: string
                              enum:
                                - assistant
                              description: Role of the message, always "assistant"
                            content:
                              type: string
                              description: Content of the message
                              example: >-
                                At the start of the video, the screen displays
                                the words "VACUUM VS ORANGE". The objects in the
                                video are visible.
                        finish_reason:
                          type: string
                          description: Reason why the completion finished
                  usage:
                    type: object
                    description: Token usage information
                    properties:
                      prompt_tokens:
                        type: integer
                        description: Number of tokens in the prompt
                        example: 17463
                      output_token:
                        type: integer
                        description: Number of tokens in the completion output
                        example: 290
                      total_tokens:
                        type: integer
                        description: Total number of tokens used
                        example: 17753
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization

````