Рет қаралды 610
Introduction
In this tutorial, we will learn how to make requests to OpenAI APIs, including GPT-4, whisper-1, and DALL·Eusing Postman. We will cover the following API requests:
Text completion
Chat completion
Edit text
Image generation
Transcription
Translation
Setting Up Postman
Postman is a software for testing API requests. To set up Postman, follow these steps:
Obtain an OpenAI API key from your account.
Install and open Postman.
Add your API key to the authorization header in Postman.
Set the content type to application/json.
API Requests
Text Completion
Text completion can be achieved using the DaVinci model. Send a POST request to the completions endpoint with the model, prompt, max tokens, and temperature parameters.
Chat Completion
Chat completion is a powerful feature of GPT-4. Send a POST request to the chat completions endpoint with the model and messages parameters. You can also pass temperature, max tokens, and other optional parameters.
Edit Text
To fix grammar in a text, use the edits endpoint. Send a POST request with the model, input, and instruction parameters.
Image Generation
Generate images using the DALL·E image generator. Send a POST request to the images generation endpoint with the prompt, number of choices, and size parameters.
myria.com/marketplace/collect...
Check our Udemy courses:
▶️ www.udemy.com/course/solana-b...
GET 1 FREE MONTH SKILLSHARE
▶️ www.skillshare.com/r/user/ser...
Our Skillshare courses:
Learn solana developer foundations:
▶️ skl.sh/3uyTdSp
Learn Smart Contracts in Solana:
▶️ skl.sh/37aCs8t
Learn metahumans on skillshare
▶️ skl.sh/3F1vzmm
To support my project serpent academy you can buy an Official NFT in solsea:
solsea.io/creator/6148adffa71...
Get our MAGIC EDEN NFTS
magiceden.io/marketplace/ape_...
magiceden.io/marketplace/pyra...
Get $serpent token a solana token
mint.serpent.academy
Code here
Our website:
serpent.academy
Our blog:
blog.serpent.academy
Our twitter account:
/ serpentacademy