Open AI GPT-3Open AI GPT-3
Spread the love

Introduction

This tutorial teaches how to set up a typical python application(GPT-3 sample application) using Anaconda navigator and Visual Studio code. This tutorial shares the common, day-to-day steps for ML developers using Python and Anaconda.

Steps

1). Download and setup Anaconda in your Windows environment if you don’t already have anaconda setup. Here’s the link :-

https://www.anaconda.com/products/distribution

2). Launch Anaconda Navigator from your Window’s Startup menu :-

Anaconda Navigator

3). Open folder contain your python code(if you already have it). If not, let first get some code from github by using git clone :-

      $ git clone https://github.com/Shubhamsaboo/kairos_gpt3

In this case, we are cloning a gpt-3 starter repository.

4). If you launch VS Code application from inside the Anaconda Navigator application, you automatically get a “conda-aware” VSCode integrated terminal.

Launch VS code from Anaconda Navigator and open the Kairos_gpt3 folder.

Visual Studio Code

Next, create an environment using conda, and activate the environment using the following commands :-

        >> conda create –name gpt3

If the environment already exists, or is successfully created then next step is to activate the environment using conda activate command :-

        >> conda activate gpt3

Conda Activate

5). Installing Dependencies for Your GPT-3 Application
From /email_generation folder, you can run the following command in the VS Code terminal to install the required dependencies:-

      >> pip install -r requirements.txt

After installing the required dependencies, you can bring up the main application to validate that its working in your local environment. To bring up the application, you can run the following command from the email_generation folder.
     

      >> streamlit run gpt_app.py

 

GPT-3 Sandbox App in Execution

FAQ’s

What is Conda ?

Conda is an open-source package and environment management system that runs on Windows, macOS, and Linux. Conda quickly installs, runs, and updates packages and their dependencies. It also easily creates, saves, loads, and switches between environments on your local computer. It was created for Python programs, but it can package and distribute software for any language.

Conclusion

In this tutorial, we created a GPT-3 python application by downloading its code from github repository. Along the way, we learned basic steps that are used in building python ML applications.

By Hassan Amin

Dr. Syed Hassan Amin has done Ph.D. in Computer Science from Imperial College London, United Kingdom and MS in Computer System Engineering from GIKI, Pakistan. During PhD, he has worked on Image Processing, Computer Vision, and Machine Learning. He has done research and development in many areas including Urdu and local language Optical Character Recognition, Retail Analysis, Affiliate Marketing, Fraud Prediction, 3D reconstruction of face images from 2D images, and Retinal Image analysis in addition to other areas.

wpChatIcon