GPT-4 Vision Preview

GPT-4 Vision Preview

GPT-4 Vision Preview

by

OpenAI

Model ID:

gpt-4-vision-preview

Use This Model

Model Overview

FAQs

Related Links

Overview

GPT-4 is OpenAI's most advanced model, offering unparalleled intelligence, creativity, and understanding across a wide range of tasks. It significantly improves upon the capabilities of its predecessors, providing deeper reasoning, more nuanced language understanding, and enhanced problem-solving abilities, making it ideal for complex applications and diverse use cases.

Specializations

  • Vision-Language Understanding: Can process and understand images and text simultaneously.

  • Image Description and Analysis: Generates detailed descriptions of images and can answer questions about their content.

  • Visual Reasoning: Can perform tasks like image classification, object detection, and visual question answering.

Integration Guide (Javascript)

To use this model through Portkey, follow these steps:

1. Install Portkey SDK:

npm install --save portkey-ai

2. Set up client with Portkey:

import OpenAI from 'openai';

import { PORTKEY_GATEWAY_URL, createHeaders } from 'portkey-ai'

const openai = new OpenAI({

  apiKey: 'OPENAI_API_KEY',

  baseURL: PORTKEY_GATEWAY_URL,

  defaultHeaders: createHeaders({

    provider: "openai",

    apiKey: "PORTKEY_API_KEY"

  })

});

3. Make a request:

async function getChatCompletionFunctions()

  const response = await portkey.chat.completions.create({

    model: "gpt-4-vision-preview",

    messages: [

      {

        role: "user",

        content: [

          { type: "text", text: "What’s in this image?" },

          {

            type: "image_url",

            image_url:    "https://upload.wikimedia.org/wikipedia/commons/thumb/d/dd/Gfp-wisconsin-madison-the-nature-boardwalk.jpg/2560px-Gfp-wisconsin-madison-the-nature-boardwalk.jpg",

          },

        ],

      },

    ],

  });

  console.log(response)

}

await getChatCompletionFunctions();

Model Specifications

Release Date:

9/4/2024

Knowledge Cut-Off Date:

April 2023

MMLU:

86.5

%

License:

Proprietary

Pricing

$/Million Input Tokens

$

10

$/Million Output Tokens

$

30

Live updates via Portkey Pricing API. Coming Soon...

© 2024 Portkey, Inc. All rights reserved