This lesson guides you on how to set up and run code samples for an AI course. To get started, you need a GitHub account, Python 3.12 or later, an Azure subscription, and an Azure AI Foundry account. First, fork the GitHub repository to have your own copy. Then, create a GitHub Personal Access Token for accessing Large Language Models. Set this token in a .env file alongside other required variables from the Azure portal. Install necessary Python packages and sign in to Azure using the Azure CLI. Finally, set up keyless authentication to run the course code. If you face any challenges, join the Azure AI Community or report issues on GitHub. Happy learning!
Introduction to Setting Up Your AI Course Environment
If you’re eager to dive into the world of AI with our course, you need to set up your environment properly. This guide will walk you through each step, ensuring you’re ready to start coding quickly and efficiently.
Requirements for the Course
Before we get started, make sure you have these essential tools:
– A GitHub account
– Python 3.12 or higher
– An Azure subscription
– An Azure AI Foundry account
Clone or Fork the GitHub Repository
To kick off, you should clone or fork our GitHub repository. This creates your own version of the course materials, allowing you to run, test, and modify the code as needed. You can easily do this by clicking the link to fork the repository.
Setting Up Your GitHub Personal Access Token
This course uses the GitHub Models Marketplace, which provides free access to Large Language Models (LLMs) necessary for creating AI Agents. To access this service, you must create a GitHub Personal Access Token (PAT). Navigate to your GitHub account’s Personal Access Tokens settings to generate a new token.
Configure Your Environment Variables
Next, you’ll need to fill out your .env file with various environment variables. This file connects your setup to Azure and GitHub. Make sure you copy the token you created earlier into the GITHUB_TOKEN field of your .env file.
Install Required Packages
To run our code effectively, you must install the necessary Python packages. We recommend using a virtual environment to keep everything organized. You can do this by running the command in your terminal to install the required packages.
Sign in to Azure
With your packages installed, the next step is to sign into your Azure account. Open a new terminal and use the az login command, following the instructions provided.
Accessing Environment Variables
To ensure your application can access the necessary environment variables, import the os and dotenv libraries in your code. This makes retrieving your settings straightforward.
Set Up Keyless Authentication
Avoid hardcoding credentials by setting up keyless authentication with Azure OpenAI. This approach enhances security and simplifies the integration process.
Conclusion
By following these steps, you will be well on your way to running the code samples in our AI course. If you encounter any challenges during the setup, feel free to reach out through our Azure AI Community Discord or open an issue on GitHub.
Next Up
Ready for the next step? Start your journey with the introduction to AI Agents and explore various use cases that will enrich your understanding of this exciting field.
Tags: AI, Azure, Python, GitHub, AI Agents
What is the “AI Agents for Beginners” course?
The “AI Agents for Beginners” course is designed to help newcomers learn about artificial intelligence agents. It covers the basics, including what AI agents are, how they work, and practical applications.
Who is this course for?
This course is for anyone interested in AI, especially those with no prior knowledge. Whether you are a student, a professional looking to learn something new, or just curious about AI, this course is made for you.
What will I learn in this course?
In this course, you will learn the fundamentals of AI agents, including their functions and types. You will also explore how to create simple AI agents and understand their real-world uses.
Do I need any special skills or tools to take this course?
No special skills are needed. The course starts from the basics, so you can follow along easily. You just need a computer and an internet connection to access the materials.
How long does the course take to complete?
The course is designed to be flexible. You can complete it at your own pace, but most learners finish it in about 4 to 6 weeks if they spend a few hours each week on the lessons.