search
HomeCommon ProblemQuickstart: Get started using ChatGPT and GPT-4 with Azure OpenAI Service

  • Azure Subscription - Create one for free.
  • Grant access to Azure OpenAI in the required Azure subscription. Currently, access to this service can only be granted through the app. You can request access to Azure OpenAI by filling out the form at https://aka.ms/oai/access . Open an issue on this repository to contact us if you encounter problems.
  • Have or gpt-35-turbogpt-41deployed model. For more information about model deployment, see the Resource Deployment Guide.

1 GPT-4 models are currently available by request only. To access these models, existing Azure OpenAI customers can request access by filling out this form.

I'm having a prerequisite problem.

Go to Azure OpenAI Studio

Navigate to Azure OpenAI Studio https://oai.azure.com/ and log in with credentials that have access to OpenAI resources. During the sign-in workflow or later, select the relevant catalog, Azure subscription, and Azure OpenAI resources.

In the Azure OpenAI Studio landing page, select "Chat Playground".

快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service

Playground

Use a no-code approach to start exploring OpenAI capabilities with Azure OpenAI Studio’s chat playground. From this page, you can quickly iterate and experiment with these features.

快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service

Assistant Settings

You can use the "Assistant Settings" drop-down list to select some preloaded system messagesExample to get started.

System Messages Provides the model with instructions on how it should behave and any context it should reference when generating responses. You can describe the assistant's personality, tell it what it should and shouldn't answer, and tell it how to format answers.

Add Few ShotsExamples allows you to provide examples of conversations that the model uses for contextual learning.

When using the Chat Playground, you can select "View Code" at any time to view pre-populated Python, curl, and json code examples based on your current chat session and settings selection. You can then take this code and write an application that accomplishes the same task you currently perform on the playground.

Chat Session

Selecting the "Send" button will send the entered text to the completion API and the results will be returned to the text box.

Select the "Clear Chat" button to delete the current conversation history.

Settings

Name Description
Deployment The deployment name associated with a specific model. For ChatGPT, you need to use this model. gpt-35-turbo
Temperature Control randomness. Lowering the temperature means the model produces a more repeatable and deterministic response. Raising the temperature can lead to more unexpected or creative reactions. Try adjusting either the temperature or the top P, but not both.
Maximum length (tokens) Set a limit on the number of tokens per model response. The API supports sharing up to 4096 tokens between prompts (including system messages, samples, message history, and user queries) and model responses. For typical English text, a token is approximately four characters.
Highest Probability Similar to Temperature, this controls randomness, but uses a different method. Lowering the top P narrows the model's token selection to more likely tokens. Increasing the top P allows the model to choose from tokens with high and low likelihoods. Try adjusting either the temperature or the top P, but not both.
Multiple Conversations Select the number of past messages to include in each new API request. This helps provide model context for new user queries. Setting this number to 10 results in user queries and system responses.
Stop sequence The stop sequence causes the model to end its response at the desired point. The model response ends before the specified sequence, so it does not contain stop sequence text. For ChatGPT, use ensures that model responses do not generate subsequent user queries. Up to four stop sequences can be included.

Show Panels

By default, there are three panels: Assistant Settings, Chat Sessions, and Settings. Show Panels allows you to add, delete and rearrange panels. If you ever closed a panel and need to restore it, use "Show Panel" to restore the lost panel.

Start a chat session

  1. From the Assistant settings drop-down list, select "Xbox Customer Support Agent"
  2. You will be prompted if you want To update the system message, select "Continue".
  3. In the chat session pane, enter the following question: "I'm interested in buying a new Xbox" and then select "Send".
  4. You will receive a response similar to the following: 快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service
  5. Enter a follow-up question, such as: "Which models support 4K?快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service
  6. Now that you have a basic conversation select View code from under Assistant setup and you'll have a replay of the code behind the entire conversation so far:

Python

#Note: The openai-python library support for Azure OpenAI is in preview.import osimport openaiopenai.api_type = "azure"openai.api_base = "https://docs-test-001.openai.azure.com/"openai.api_version = "2023-05-15"openai.api_key = os.getenv("OPENAI_API_KEY")response = openai.ChatCompletion.create(engine="gpt-35-turbo", # replace this value with the deployment name you chose when you deployed the associated model.messages = [{"role":"system","content":"You are an Xbox customer support agent whose primary goal is to help users with issues they are experiencing with their Xbox devices. You are friendly and concise. You only provide factual answers to queries, and do not provide answers that are not related to Xbox."},{"role":"user","content":"How much is a PS5?"},{"role":"assistant","content":"I apologize, but I do not have information about the prices of other gaming devices such as the PS5. My primary focus is to assist with issues regarding Xbox devices. Is there a specific issue you are having with your Xbox device that I may be able to help with?"},{"role":"user","content":"I am interested in buying an Xbox?"},{"role":"assistant","content":"Great! There are several Xbox models available in the market, including the Xbox Series X, Xbox Series S, and Xbox One. The Xbox Series X is the latest and most powerful console, while the Xbox Series S is a more affordable option that still offers great performance. The Xbox One is the previous generation console, but it still has a large library of games available to play.\n\nBefore purchasing an Xbox, you may want to consider factors such as your budget, the types of games you want to play, and whether you want to play games in 4K resolution. Once you have decided on a console, you can purchase it from a retailer or directly from the Xbox website. Let me know if you have any other questions or concerns!"},{"role":"user","content":"Which models are 4K?"},{"role":"assistant","content":"Both the Xbox Series X and Xbox One X support 4K resolution gaming. The Xbox Series S, on the other hand, supports up to 1440p resolution gaming, but it can upscale games to 4K. It's worth noting that in order to take advantage of 4K gaming, you'll need a 4K TV or monitor that supports HDR (High Dynamic Range) and HDMI 2.0 or higher."}],temperature=0,max_tokens=350,top_p=0.95,frequency_penalty=0,presence_penalty=0,stop=None)

I ran into an issue with the playground.

Understanding the prompt structure

If you check View the example in Code and you'll notice some unique tokens that are not part of the typical GPT completion call. ChatGPT is trained to use special tags to describe different parts of the prompt. Content is provided to the model between tokens. Prompts Begins with a system message that can be used to start a model by including a context or description for the model. Afterwards, the prompt contains a series of messages between the user and the assistant.

The assistant's response to the prompt will then be returned below the token, ending with a response indicating that the assistant has completed. You can also use Show original syntaxToggle button to display these tokens in the chat session panel. assistant

ChatGPT Operation Guide An in-depth introduction to the new prompt structure and how to use the model effectively. gpt-35-turbo

Cleaning up resources

After completing the test of the chat playground, if you want to clean up and delete OpenAI resources, you can delete the resource or resource group. Deleting a resource group also deletes any other resources associated with it.

  • Portal
  • Azure CLI

Next Steps

  • Learn more about how to use ChatGPT and the new model with the ChatGPT How-To Guide.gpt-35-turbo
  • For more For examples, check out the Azure OpenAI Samples GitHub repository
  • What is Azure OpenAI Service?

    Azure OpenAI Service provides REST API access to OpenAI’s powerful language models, including the GPT-3, Codex, and Embeddings model families. The new GPT-4 and ChatGPT (gpt-35-turbo) model series have been officially launched. These models can be easily adapted to your specific...

  • Learn how to use ChatGPT and GPT-4 models

    ChatGPT and GPT-4 models are optimized for conversational interfaces Language model. These models behave differently than older GPT-3 models. Previous models took a text input and text output approach, receiving a prompt string and returning the content added to the prompt string. However, ChatGPT and GPT-4 models...

  • 快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service

    #Microsoft launches Bing AI Chat widget for Android and Apple devices

    Launched on Bing 100 days of Microsoft AI Search are being celebrated with a series of exciting system updates. Among these updates, a chatbot widget designed specifically for mobile screens on iOS and Android platforms was introduced. See Microsoft's blog post here. This new feature...

  • 快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service

    Microsoft launches new tabular model definition language for Power BI

    The end of support date for Power BI Desktop on Windows 8.1 has been announced by Microsoft. The tech giant recently updated its leading data analytics platform to add support for TypeScript among other new features. Power BI today released a new Tabular Model Definition Language (TMDL)

  • 快速入门:开始使用 ChatGPT 和 GPT-4 与 Azure OpenAI Service

    ChromeOS Flex USB can now be set up on Linux systems

    ChromeOS Flex has Published, available on PC and Mac. One very annoying decision Google made at the time was that the installer USB had to be set up using a Chromebook recovery utility that was incompatible with Linux distributions like Ubuntu and Linux Mint. Unless you have another one...

The above is the detailed content of Quickstart: Get started using ChatGPT and GPT-4 with Azure OpenAI Service. For more information, please follow other related articles on the PHP Chinese website!

Statement
This article is reproduced at:云东方. If there is any infringement, please contact admin@php.cn delete
deepseek web version official entrancedeepseek web version official entranceMar 12, 2025 pm 01:42 PM

The domestic AI dark horse DeepSeek has risen strongly, shocking the global AI industry! This Chinese artificial intelligence company, which has only been established for a year and a half, has won wide praise from global users for its free and open source mockups, DeepSeek-V3 and DeepSeek-R1. DeepSeek-R1 is now fully launched, with performance comparable to the official version of OpenAIo1! You can experience its powerful functions on the web page, APP and API interface. Download method: Supports iOS and Android systems, users can download it through the app store; the web version has also been officially opened! DeepSeek web version official entrance: ht

In-depth search deepseek official website entranceIn-depth search deepseek official website entranceMar 12, 2025 pm 01:33 PM

At the beginning of 2025, domestic AI "deepseek" made a stunning debut! This free and open source AI model has a performance comparable to the official version of OpenAI's o1, and has been fully launched on the web side, APP and API, supporting multi-terminal use of iOS, Android and web versions. In-depth search of deepseek official website and usage guide: official website address: https://www.deepseek.com/Using steps for web version: Click the link above to enter deepseek official website. Click the "Start Conversation" button on the homepage. For the first use, you need to log in with your mobile phone verification code. After logging in, you can enter the dialogue interface. deepseek is powerful, can write code, read file, and create code

How to solve the problem of busy servers for deepseekHow to solve the problem of busy servers for deepseekMar 12, 2025 pm 01:39 PM

DeepSeek: How to deal with the popular AI that is congested with servers? As a hot AI in 2025, DeepSeek is free and open source and has a performance comparable to the official version of OpenAIo1, which shows its popularity. However, high concurrency also brings the problem of server busyness. This article will analyze the reasons and provide coping strategies. DeepSeek web version entrance: https://www.deepseek.com/DeepSeek server busy reason: High concurrent access: DeepSeek's free and powerful features attract a large number of users to use at the same time, resulting in excessive server load. Cyber ​​Attack: It is reported that DeepSeek has an impact on the US financial industry.

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
3 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

SublimeText3 Linux new version

SublimeText3 Linux new version

SublimeText3 Linux latest version

SecLists

SecLists

SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

WebStorm Mac version

WebStorm Mac version

Useful JavaScript development tools

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!