From the course: OpenAI API and MCP Development
AI development on GitHub: From setup to hands-on playground
From the course: OpenAI API and MCP Development
AI development on GitHub: From setup to hands-on playground
GitHub Models is an AI inference API from GitHub that allows you to run AI models by just using your GitHub credentials. So you can, from here, select from a wide range of large language models from different providers for every use case, for different model types, size, and specialization. So from here, you can select Catalog or the Playground, so you can test out the language model, but also compare them. So in this video, we want to demonstrate the steps to get started with a quick start example. We're going to see how to run queries, how to compare language models. And basically, you just need to get started by connect to your GitHub accounts by just using your GitHub credential. So that's all there is to it to get started with the GitHub models. And then go to the Marketplace and the Playgrounds. So we want to select a language model from the list. So for example, let's go to the bottom and select this one. So from here, from the playground, you can then run queries and generate responses. So you can here ask to explain the basics of machine learning. And I know that this one actually is taking longer and it's telling me that I hit the usage rate limits, but that's okay. You can actually select another one because you may also encounter the same warning message. So I'm going to select Mini. And I know that this one is much faster, and it doesn't have any limitations. So here, it's going to generate a very fast and detailed output to explain the basics of machine learning. The other benefit is that you can also compare the results of the different language models. So we're going to select Nano to compare the two. And here as well, I'm going to ask the same question. So we're going to compare the two by using the same inputs. So on the left, we have the mini. So we can see how long it took to generate the response. So we can see on the right that it was much faster. And also that for the outputs, for the one on the left, it took fewer tokens. So you can say that they are quite comparable. So depending on your needs and what you expect as a result, you can then select the best and most suitable language model. So I'm going to stick to this one, which is Mini. So I'm just going to close this one. So there is another feature and tool that you can use to improve your usage of the language models, which is the Prompt Editor. Because it is also important to write effective and detailed instructions to guide the response from the language model. So I'm gonna ask to give a five sentence explanation with examples. So I'll be very short, and I'm gonna add also for young users. All right, so then I'm gonna ask to improve this prompt. So that's another benefit with the Playground, which is that you can ask to improve whatever you're aiming for. So I'm gonna copy this one, because now I wanna use this improved prompt. So what I want is to provide a concise five-sentence explanation suitable for young users, including relevant and practical. I'm gonna add and practical example. So let's use that. All right, so let's go back to the playground and ask again. So I'm gonna go to the parameters and add this system prompt. And I'm gonna ask the same question. So remember that it was very detailed and long and quite not easy to understand for someone beginner. So I'm going to ask the same question. And this time, it's going to be more concise. So machine learning is when computers learn to do things by looking at lots of examples instead of just following rules. And for example, you just show a computer many pictures of cats and dogs. It can learn to tell which animal is which. And then another example is when a game learns how to get better at playing by trying over and over. So we understand that actually machine learns by repeating things and learning from different examples, and then with supervised training, predict from different patterns and behavior. So that's great. So that's exactly what I was aiming for. And the great thing is that we can test out and compare language models by using the Playground before actually integrating into our next project. And the great thing is that here you can switch between interface. So you can go from the chat interface to the code and then select here, so you can then select the language that you want, and then use the same code, syntax, to start your next project, and see how you can integrate, this time, the GitHub models into your web projects.