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
Expanded Context Window: Can process and generate text based on a significantly larger input, enabling more comprehensive and contextually relevant responses.
Advanced Reasoning and Problem-Solving: Excels in complex tasks that require understanding and manipulating information.
Higher Computational Cost: Demands more resources due to its increased capabilities.
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 Portkey from 'portkey-ai'
const portkey = new Portkey({
apiKey: "PORTKEY_API_KEY", // defaults to process.env["PORTKEY_API_KEY"]
virtualKey: "AZURE_VIRTUAL_KEY" // Your Azure Virtual Key
})
3. Make a request:
const chatCompletion = await portkey.chat.completions.create({
messages: [{ role: 'user', content: 'Say this is a test' }],
model: 'gpt-4-32k', // This would be your deployment or model name
});
console.log(chatCompletion.choices);
Model Specifications
Release Date:
13/6/2023
Max. Context Tokens:
128K
Max. Output Tokens:
32K
Knowledge Cut-Off Date:
January 2022
MMLU:
86.5
%
License:
Proprietary
Pricing
$/Million Input Tokens
$
60
$/Million Output Tokens
$
120
Live updates via Portkey Pricing API. Coming Soon...
© 2024 Portkey, Inc. All rights reserved