Welcome to the Demo Repository for Azure OpenAI Services in GitHub Models! This repository is part of the GitHub Models session and is designed to help participants explore and understand GitHub Models. Follow the instructions below to set up and run this project.
Looking for a deeper dive? Check out the Introduction to GitHub Models repository for more comprehensive resources and examples.
Click the image above to watch the instruction video.
This repository serves as a hands-on demo for participants to learn how to integrate and use GitHub Models. By following the steps below, you will:
- Fork and clone the repository.
- Set up the required environment.
- Run the demo successfully.
Before you begin, ensure you have the following:
- GitHub Account to fork the repository.
- Git installed on your local machine.
- Node.js (version 14 or higher) installed.
- NPM (Node Package Manager) installed (comes with Node.js).
- GitHub Personal Access Token with appropriate permissions.
Follow these steps to set up the environment:
-
Fork the Repository:
- Navigate to the repository on GitHub.
- Click the "Fork" button in the top-right corner to create your own copy of the repository.
-
Clone the Forked Repository:
git clone https://github.com/Your_Username/Github-Models-Demo.git cd Github-Models-Demo -
Install Dependencies:
npm install
-
Set Up GitHub Token:
- Create an
.envfile in the root directory. - Add the following environment variable:
GITHUB_TOKEN="Your-Github-Token-Here"
- Create an
-
Start the Application:
npm start-sample
-
Access the Application: Once the application starts, you will see prompts and responses directly in the terminal.
You can customize the interaction by editing the messages in the following format:
- Open the
src/sample.jsfile in the repository. - Modify the
messagesarray to include your own context and questions. For example:javascript const messages = [ { role: "developer", content: "You are a helpful assistant" }, { role: "user", content: "<< - Your questions ->> "} ]; - Save the file and restart the application:
bash npm start
This allows you to tailor the interaction to your specific needs.
If you want to try the chatbot experience, you can modify the start command in the package.json file as follows:
- Open the
package.jsonfile in the root directory. - Locate the
scriptssection and update thestartcommand:json "start": "node ./src/chatbot.js" - Save the file and start the application:
npm start
This will run the chatbot experience instead of the default sample application.
Once you have completed the demo:
- Stop the application by pressing
Ctrl+Cin the terminal. - Clean up the repository if needed:
cd .. rm -rf demo-repo
- Fork the repository.
- Clone the forked repository to your local machine.
- Install dependencies using
npm install. - Add your GitHub token to the
.envfile. - Run the application using
npm start. - Test and explore the demo.
- Clean up after use if necessary.
Enjoy exploring GitHub Models! 🚀
📌 Duration: 25 minutes
📌 Units: 7
📌 Link: Learn More
Learn the fundamentals of LLMs, their applications, and how they power AI-driven solutions. Perfect for beginners! 🚀
📌 Overview: Learn the differences between small and large language models, their advantages, and when to use them in AI and machine learning workflows.
📌 Key Points:
✅ Small LMs – Faster, cost-effective, and ideal for precise, well-defined tasks.
✅ Large LMs – Powerful, adaptable, and suited for complex, high-volume tasks.
✅ Experiment with models on Azure Kubernetes Service (AKS) using KAITO for deployment automation.
📌 Read more: Small & Large Language Models
This repository is maintained by Nisal Gunawardhana. Feel free to reach out for any questions or feedback regarding this demo.
Feel free to connect with me on LinkedIn for more updates and professional networking opportunities.
This project is licensed under the MIT License. You are free to use, modify, and distribute this repository for educational and study purposes. See the LICENSE file for more details.

