Welcome0:00
So, uh, a couple of real quick things for those who are just getting settled in or just rummaging. First of all, if you're sitting in the back and hoping for a seat, it does look like we are completely full up.
I can move my stuff here. We'll have a seat here, and I think that might be it. Now, having said that, we are going to be— and I want to make sure that I'm clear about this— so if you're working on something else, now is not the time to multitask, but instead pay attention to the person that's babbling up in the front of the room.
We are going to be running the exact same lab. I'm going to say that one more time for effect, but we are going to be running the exact same lab this afternoon at 3:30. So even though that 3:30 lab has a different title, a different abstract, I am here to tell you it is the exact same lab.
How do I know that? Because I'm going to be the one leading it. So, kind of a little bit of authority there. So,
um, do keep that in mind. So if you're hanging out in the back really wanting to do this, check back this room, 3:30, you'll be able to do the exact same thing. Second of all, we are running around and getting everybody added into a particular organization.
That organization is going to give you access to GitHub Copilot. Now, when you get added into an organization in GitHub, you do need to accept that invitation. So, um, please go in, check your email that's associated with your GitHub account, and accept that invitation.
So now is the time to multitask and go ahead and take a look at that. And while you're doing that, I'm going to make the announcement one more time for those in the back of the room. If you want to do this lab, come on back at 3:30.
We're going to be doing the exact same lab at 3:30. Okay, and I'll be back in just a minute.
Where should we look to get that address?
In your email that you have associated with your GitHub account.
It's a hard one.
Cool.
Allright, so here's what we're going to do.
Oh, I can actually take my glove back. So there.
Yeah, if we can get all devices silent, vibrate. If you get a phone call, more than welcome to take that— you're more than welcome to take that phone call behind, outside those doors there. Cool. So while we are getting everything situated, here's what I'm going to do is I am going to— there we go— start talking through this little thing called GitHub Copilot and then begin to introduce the lab and then get you turned over to the first exercise.
Basically, what's going to wind up happening is I'll do a little bit of babbling and then you'll do a little bit of work and then I'll do a little bit of more babbling and then laverence repeat until we have run out of time here.
We have 73 minutes. Should we actually still able to get through the bulk of the lab, or at the very least, we'll be able to get through the cool parts of it? We might, like, skip something just so we can make sure that we can get to the end, but we'll explore and we'll play with all of that as we go here.
So without any further ado, let's talk about this little thing called GitHub Copilot. If you're not already familiar with GitHub Copilot, GitHub Copilot has been given this tag of your AI pair programmer. Now, not only is that wonderful marketing, because it is kind of wonderful marketing, it's actually, I think, honestly, the best way to describe and to think about GitHub Copilot.
AI Pair Programmer3:49
That just as I'm working with a pair programmer, I'm going to ask them to perform different tasks, I'm going to ask them to do different things, and we're going to work together, we're going to collaborate to build out a solution to solve problems.
I'm going to do that exact same thing when we're talking about Copilot. And just like an AI pair programmer, it's going to have certain strengths, it's going to have certain weaknesses, and there are going to be specific workloads that it's going to be able to help out with.
And that's exactly what we're going to see here. That we're going to take a look at a couple of different modes with agent mode locally, with edit mode, with ask mode. We're also going to take a look at what we announced at Build, our brand new Copilot coding agent, which actually allows you to assign issues to Copilot.
And then we're also going to spend an awful lot of time talking about context. Because as I mentioned, again, AI pair programmer, context is really key. It's key across many aspects of life, and it's certainly going to be key whenever we're working with any form of AI, and that does include GitHub Copilot.
So without any further delay, let's go ahead and get into it. Are you comfortable down there, John?
Good for now.
Allright. Okay. Let's talk a little bit about context. And the way that I always like to introduce context is by giving a little bit of a quick story that my partner and I woke up the other day. She looks at me and says, "Let's go get brunch."
Context & Clarity5:27
Fantastic. Who doesn't love brunch? And so I recommended a spot. And then she says, "But here's the thing is we've been there an awful lot lately and I'm kind of burnt out on it. How about we go somewhere else?"
Okay, fantastic. And so then I recommended a different spot. And then she thinks for a minute and says, "You know, I'm really kind of craving waffles." Who doesn't love waffles? Fantastic. And so then I recommended another spot and off we went.
Now, that back and forth is like very normal through human conversation. That I was given a little bit of context, "Let's go to brunch," and then I gave, based on the context that I had, a perfectly valid answer.
And then a little bit more information was provided and I gave another answer, and then eventually we found the solution that we were driving towards. And that's exactly how we're going to work with Copilot, is that we're going to give Copilot context, we're going to help point it in theright direction, and then we're going to work together to get to the solution that we are looking for.
Now, whenever we're talking about context, there's oftentimes a lot of focus on the prompt. Now, don't get me wrong. The prompt that we use for Copilot when we're using chat, when we're creating an issue, all of that is very, very important.
But it really goes beyond just that prompt that we give to Copilot, and I honestly find that a lot of times when people are first getting started with Copilot, that there's a little bit too much focus on that prompt itself.
Because what Copilot is going to use for context is everything that it sees. And so that's going to include your code. So making sure that your code is readable is extremely important. That a lot, unlike a lot of other tools that you're going to be using, well, there'll be a script where it's going to build your code or scan all of your code and look for different patterns and so forth.
With Copilot, again, AI pair programmer, it's going to behave an awful lot like another programmer coming along and reading your code. And if your code isn't readable, if you're using a lot of abbreviations, you're using names that aren't clear, you're using single-letter variable names, which are the bane of my existence, Copilot is not going to be able to easily understand that.
On top of that comment, now, I do have a little bit of a belief that code that's easy to read shouldn't need comments. That the code should describe well enough what it is that it's doing.
But we all know that that's not always the case. We all know that we fall short of that, and that a couple of lines of comments left behind is not only going to help you six months later when you go back to that code base and try to figure out what it is that you're doing, but it's going to help, again, that pair programmer and that AI pair programmer.
So having in a few comments. And then last but not least is having a good project structure. Allowing Copilot to be able to quickly find the different resources that it's going to need is also really important. So all of that plays into context.
And that brings us into this spotright here of helping Copilot help you. I sort of like to say, don't be passive-aggressive with Copilot. That don't throw something at Copilot and kind of like hope that it figures out what you really, really meant.
That if you know something, or if you know that there's a particular piece of information that Copilot should be considering, tell Copilot that. And what you're going to see is you've got a lot of great tools with which to do that.
So again, that context, all that background information, and we're going to see a lot of different ways that we can do this through, like, instruction files or, again, those comments, again, that good project structure. The intent, be clear about what it is that you're trying to do and be clear about it, that clarity aspect.
And when we're talking about clarity, for those of us that have maybe worked around with, like, old chatbots and we got very used to just sending very terse commands, because natural language processing back a few years ago just was not really all that strong.
So we were effectively using it like a command line interface. We want to be a bit more verbose, be a bit more flowery, make sure that we're easy to understand. And then last but not least, that specificity. If we want something done a particular way, let's be clear about it.
Let's get in and do it. So let's introduce real quickly here the different workloads that we have available to us. Now, the glowing one on theright is not necessarily to indicate that, hey, that is the best, but rather just simply that that's new and new things are shiny.
Workloads10:13
So over on the far left is code completion. And this is sort of the original version, if you will, of GitHub Copilot. That I'm typing away, I'm coding away, and then Copilotright in line is going to start making suggestions about what my next line, my next block, my next class, my next function is going to be.
And this is wonderful. If you're in the zone, you know what you're doing, just type away and Copilot can then help you write code. And then we get into chat and we get into edit mode. Now, chat originally just had ask, which is going to be for single shot.
Explain this code to me. I need you to create a file. Whereas with edits mode, what that's going to allow me to do is that's going to allow me to edit multiple files in one shot. Because when we think about even the most basic of updates, say, like, I'm just updating a web page, I'm going to update an HTML file, a CSS file, and a JavaScript file.
There's very few of any code updates that are single file anymore. And so with edits, I can then guide Copilot through editing multiple files. And then we get into local agent mode, where now Copilot is going to kind of lead the way, but what we're really going to see with agent mode is that it's going to behave an awful lot like a developer.
That it will be able to explore your project, it'll be able to find files, and it will be able to run external tasks. So it'll be able to build your code, it'll be able to run tests, and if it detects that anything has gone wrong, it'll actually be able to self-heal.
I'm going to come back to questions in a little bit. Last but not least is Copilot coding agent. And with Copilot coding agent, what I'm going to be able to do is take an issue in my repository, assign that to Copilot, and then I get to go on about doing something else.
So if I have, like, little tasks, little things that I just haven't been able to get to, I can go ahead and assign that issue, and then I can focus my attention on the bigger problems. And so those are the different workloads that are available to us with Copilot.
Lab Setup12:41
And so that is coding agent, we're going to be able to give it a task, and then away we go from there. So without any further delay, I'm going to actually kind of leave that there and let's go ahead and get started.
So first thing, before you click on that URL, this is going to be a real quick test. You know how you were probably in elementary school and you got handed that sheet with, like, 40 steps on it and step one was read all the instructions to the end, and then step two was write your name, and then step 40 was just do steps one and two.
How many people did all the steps?
Three people.
Yeah. Yep. Absolutely. So in any event, this is going to be one of those tests. So first thing is first, before you go there, make sure that you have gone to your email that's associated with your GitHub account, that you've accepted that invitation, and when you got asked, "Hey, do you want a Copilot license?"
say yes to that.
I had about 10 people who have not responded to the email. They can do this directly to go and accept. Some of the emails aren't going through.
Okay.
Give me one second here.
It's just the github.com/.
Okay.
And they should see a banner there if they haven't accepted their membership.
Okay. Beautiful. Thank you. Well done, John. Allright.
That's all. I just said well done. Thank you. Yeah. So if you did not get your invite for whatever reason, you can actually just go directly to github.com/octahl and then accept your invite. Now, I am going to give you a minute to do that in the background, and then I'm going to address the people that are hanging out in the back of the room here.
We are going to be doing the exact same lab at 3:30. So if you want to do the lab, you want to have a seat, you want to be comfortable, you can come back at 3:30, you'll be able to do the exact same lab.
The 3:30 session is going to be an exact repeat of everything that we are doing here.
Allright. Now, if you do not have access yet to octahl, then hang on, we'll be around to help troubleshoot all of that in a minute. Assuming that you do have access, if you head on over to that URLright there, what that will do is that will take you to, let's, oops, let me go to theright spot.
There we go. And there we go. And there we go. Okay. So that will take you to this little readme fileright here. This is going to give you an overview of the lab and everything that you're going to be doing.
You're going to set up the environment, you're going to assign some issues, you're going to configure and interact with some external services, provide context to Copilot, complete a site-wide update, and then review Copilot's work. And you'll notice all the way down to the very bottom, get started, we're going to do this by getting everything set upright here.
We are going to be using code spaces, so you don't need any local installation. You'll be doing everything via the cloud. So the first part is going to be setting all of that up. Follow the instructions that you see there.
When it comes to this spotright here, and this is now where I'm going to need everybody to pay attention to me. So when you go in to create your lab, where you're going to want to create it and how you're going to want to create it, let me create a real quick new slide here.
Sound effects help.
There we go.
Typing skill is inversely proportional to the number of people watching.
Better for passwords.
Okay. So when you go to create your repo, that's going to be the owner that you're going to want will be octahl. It will need to be inside that organization, because otherwise it's not going to work. And then note the name.
Just make that your GitHub handle. We'll kind of make it real nice and easy for everybody. So owner will be octahl. That's going to be your name. And again, if you did not see where to access the lab, that's where to access the lab.
I'm going to leave the slide up for a minute here. That's where you're going to access the lab from. That's going to be going away in five, four, three, two, one.
And then finally, that's where you can go ahead and create your repo. Again, note the owner,
note the name, and away you go from there. So I'm going to let you start roaming through exercise zero. I'm going to let you start roaming through exercise one. If you have questions, that is exactly what John and I are here for.
Now, please do keep one big thing in mind, which is the fact that there are roughly about 80 of you and there are two of us. We are doing our absolute best to run around as quickly as possible, but please be patient with us.
Does everybody know what they should be doingright now?
Yes.
Okay. Last very important thing. I always assume that silence is a, hey, everything is fantastic. Neither John nor I are mind readers. So if something isn't going quiteright, please, please, please say something, let us know. Allright. Now I will let you go ahead and have at it.
Allright. I'll be back in one second.
Has anybody been able to assign an issue to Copilot?
I've assigned it.
Some have. Allright. Let me do this again. Has anybody been
able to successfully have Copilot start work on the issue? A couple of people. Allright. How many people have?
Okay. Of those that just raised their hands, how many already had access to either Copilot Enterprise or Copilot Pro Plus?
Okay. That's allright.
Okay. Yeah. Okay. Yeah. We're trying to figure that out. The org that we put everybody into is supposed to have that level of access. Apparently that doesn't seem to quite be the case. So
in the meantime, here's what I'd like to go ahead and do is kind of just start walking through the exercises here so that way you can at least see it. The other thing that I do want to highlight, and let me put this URL back up here.
Now, granted again, to assign issues to Copilot coding agent, you are going to need Pro Plus or you are going to need Enterprise. So like that part of the lab you won't be able to do unless you have access to that.
But if you have even Copilot free, you'll be able to perform the rest of the lab. And you can see thatright there. That repository is public, and you can go back and play with it all on your own
later on there. Allright. So let's do this. What I'm actually going to do is there was a question here. I'm assuming the question was about Copilot. The gentleman in red, the G-Shock watch?
Yes, sir.
Yeah. You had a question.
Oh, thank you. I was curious, do you consider any of the modes vibe coding? Yes or no?
So
the question is, do I consider any of the modes vibe any of the modes vibe coding? And I would say to a certain extent, basically anything that's going to be agent-driven where you're going to have Copilot kind of like driving the operation rather than you driving the operation, that would certainly fall under that category of vibe coding.
Whether or not that's an approach that you want to take of vibe coding all up, I will kind of leave that up to you. Everybody sort of has their own opinions on that. And one thing that you will notice about me is I typically don't share a whole lot of strong opinions in situations like that.
So I don't necessarily have a strong opinion one way or another on that, but that kind of answers your question. So yeah. Cool. Other questions about Copilot? So I'm bringing this up in the background here. Yeah. Fire away.
How does it differentiate from Cascade and Windsurf?
So I'm going to answer Cascade, Cursor, Windsurf, and all of those questions all up, which is to say that there's a limited number of hours in the day and things move really, really fast. I can keep up with what we're doing.
I can't keep up with what anybody else is doing. So I honestly am not familiar at all with any of the feature sets of any of the alternatives that are out there.
And honestly, going out like bashing competition and things like that is not necessarily my vibe. Don't worry about it.
MCP Introduction23:08
So what I would say is if you're going, "Hey, Windsurf does this, can Copilot do it? Does Cursor do this? Or Cursor does this, can Copilot do that?" I can answer those types of questions, but if you're looking for a feature comparison or things like that, I'm really not able to do that because, again, I just don't know those well enough.
There was a hand over here.
As you're showing that Copilot can be more aware of the environment, can it also be aware of live databases? Can it be connected to your SQL or some other data source? So it has that context as well.
Yeah. So this is a fantastic question. So the question is, can Copilot be aware of external data sources? And the answer is not directly, but with a little thing called MCP or Model Context Protocol, it can. So if you're not already familiar with Model Context Protocol, he says, bringing up the slideright here, the whole goal is to be able to expand Copilot's capabilities.
So Copilot is built on top of an LLM, large language model, and that LLM is always going to be static. And so what MCP allows you to do is it allows you to give Copilot the ability to call out to external services.
And the diagram looks a little bit like this. I need everybody to memorize this. There's going to be a quiz on this in about 15 minutes. And basically what you're going to notice if you look at this is that your request is going to go to Copilot, then it's going to call out to the MCP server, which is then able to access external resources.
So one of the MCP servers that's available, for example, is GitHub. And so what I can actually do then with that MCP server is I can then go to Copilot and I can say, "Hey, create an issue on this."
So that way maybe I'm in the zone, I'm coding, coding, coding, and I realize, "Hey, there's something I want to be able to look at later. Let me just go ahead and create a real quick issue on that."
Then I can do thatright from chat. Or maybe I want to go in and do a search. I can again do thatright from chat. Or again, I've got databases and I want to be able to get that schema or I want to be able to get that data from there, then I can do that with my MCP server.
Now, a couple of real quick things on MCP servers. Number one is that there are a bunch of first-party ones that are created. We have one, Azure has one, Playwright has one. And then there's a lot of community ones that are out there.
Now, here's the catch is that MCP servers are not only able to access data on your behalf, but they're also able to perform tasks on your behalf.
So as a result, before you utilize a third-party MCP server, make sure it is something that you trust. Or you can consider creating one on your own. I'm going to admit I haven't yet created one on my own,
but it is something that is
sorry, I got thrown. Oh, I haven't created one on my own, but I've seen a lot of people create them, and it does seem to be something that's relatively straightforward as far as setting it up that you can just capture the request, process it, and then send it off from there.
And then you basically just create a set of endpoints for Copilot to figure out.
Okay. So really quickly on that, if you have a backup for your database that's in a .sql file, can it consume that and use that as well?
Sure. Absolutely. Absolutely. Yeah. And in fact, you wouldn't even necessarily if what you're looking for is to help Copilot write database queries really well, all that Copilot really needs at that point is your DDL, is your data definition language.
And that's actually something that you can do
internally inside of
where do I want to go? I'm trying to remember this off the top of my head, so I'm probably going to get the exact
the Wi-Fi is going to be wonderful here.
Oh, come on.
Why? I am connected to the speaker Wi-Fi. Yeah. Okay. That's supposed to be faster.
There we go.
Nope. That's not it.
I think this is it. Yeah. There it is. Yeah.
Yeah. So what you could do if all you have is just the DDL is you could actually just include that with your instructions. And then that way anytime that I talk to chat, then Copilot can go ahead and use that and be able to generate it that way.
And that's honestly the simplest thing that works. So yeah. Okay. Yeah.
Is talking about agents MD or Copilot instructions MD in scope of today's?
Absolutely.
So let's talk a little bit let's actually do this. I'm going to
yeah. Yes.
I'm just not able to get to those spaces.
Yeah. Unfortunately, between Wi-Fi issues, access issues, and things like that, we're just not able to do that. So yeah. I'm turning this into sort of like live Q&A and live demos, trying to give everybody the best possible value that I can given the situation that we have.
So yeah. Let me do this. Make yourself comfortable, John.
And then let me
let me do this. Okay.
Coding Agent30:16
Okay. So let's talk a little bit about Copilot coding agent here. So what I've got here is I have an issue that I've created, and this is just copying and pasting straight from the lab, to have it create endpoints for creating and editing games.
And the first thing that I want you to notice about the issue here is, again, the context. That context is key here. That the whole goal of coding agent is to act asynchronously, that I assign an issue to it and I just let it do its thing.
And off, Copilot does, and it does its thing, and then it will eventually come back to me. And that becomes really, really tricky because how do I then know whether or not Copilot has everything that it needs
to be able to perform its work?
I don't know. And so that's the first big key. I always love the little eyes. That's the little indication that Copilot's now on the test. It's kind of cute.
So the first thing I want to highlight is the issue. And you'll notice again, I'm not being passive-aggressive with Copilot. That if I know what I want it to do, if I even know how I want it to approach the task, I'm going to tell Copilot that.
That the more that you leave for ambiguity's sake, the more that you leave for the other party to figure out this is human or this is AI, the more chance that you're going to come back to something that you really didn't exactly want.
So if you want the wall painted a particular shade of red, then say that you want the wall painted a particular shade of red. And so that's exactly what I've done here. But again, as I highlighted, it goes beyond just the prompt, and effectively that's what this is, is this is a prompt.
And so Copilot supports some different instructions files. Now,right now, it does depend a little bit on where you are and what you're doing. But with chat and with coding agent, all of them support
Copilot-instructions.md. So if you're using chat and if you're using coding agent, this supports Copilot instructions, Copilot-instructions.md. And if we take a look at this file, what I want you to notice is just a Markdown file. So nothing special, nothing fancy.
And what I've done inside of this file is I've given it high-level overviews of what we're building, how we're building it, and my project structure. So you'll notice, for example, that I've got some guidelinesright up top. So this is a crowdfunding platform with a developer theme, the application uses, yada, yada, yada.
You'll also notice I've given it coding standards. This is what's required before we each commit. I've given it language guidance. And I've also told it how it is that I want my Python and Flask to be created, how I want my Svelte and Astro to be created, how I want my style, my actions.
I've given it information about the scripts that are available. And I've also documented my repository structure.
Chances are you already have this inside of your projects, or at least one would hope that you do. And if you don't, here's a good opportunity to create it. Hand that to Copilot. And so now, anytime I make a chat request locally or when coding agent does its thing, it's going to be considering that.
Now, going one step further with coding agent, another big question becomes, "Okay, well, where's it going to do its work?" So as it turns out, coding agent behind the scenes is using GitHub Actions. And you'll noticeright here I've got a special action that's created that's called Copilot Setup Steps.
And so in here, I'm now having it install everything that I think it's going to need to do its work. So if there are any libraries, any frameworks, any services, anything like that that you need to have installed, any scripts that you need run, you can set that upright here.
So now Copilot is going to have this as its environment to get in and do its work. And it's also going to have this instructions file that we highlighted a minute ago to be able to act upon as well.
Now, on top of that, let me go over here to my pull requests. As I can see the pull request that Copilot made. So it just made this. It was three minutes ago. So this is not a pre-baked cake.
We're doing this live.
And if I open this up and I scroll on down, I can view the session here. And this will show me Copilot doing its thing behind the scenes. And eventually here, there we go. Moving your mouse makes it go faster.
What I can see is it's actually going out and it's exploring the project and it's digging up information on its own as well. So again, as we were talking, good code, clear code, good comments, good project structure, all of that helps your developers.
And all of that is going to help Copilot out as well. So I can give it information through the issue. I can give it information through my instructions. I give it information kind of implicitly through the project itself.
And then I can also create that environment by setting up that Copilot Steps. There was a hand here first. Yeah.
Custom Instructions35:45
Yeah. For the custom instructions, are they available in edit mode and agent mode and inline edits? Or do you need to specify at workspace?
Yeah. So that's a great question. And I'm going to answer the second part of that at workspace as well. So when it comes to Copilot instructions, those are always going to be available let me get rid of my red squigglies here.
Those are always going to be available
inside of a chat here. So let's say I do this. I'm going to put this into agent mode. I'm going to leave it as Claude 3.7. And by the way, I do not have a stance on which model is better than any other model.
You will notice, and you kind of picked this up in your lab as well. I was one of the authors of the lab. In the lab, we always use Claude 3.5. You'll notice any of my demos, I'm basically always using Claude.
You can read whatever it is that you want from that, but I have no personal stance on which model is better than any other model. There we go. So update the website to allow for filtering by publisher and category.
Add dropdown lists and refresh the page when indexes change. Make sure the tests pass. Okay. So go. So what I want you to notice is I put it into agent mode, so it's not going to I promise you it is going to use the instructions.
It's just not going to show it to me, unfortunately. But on any of the modes in chat oh, well, there it is. I just needed to be patient. There's my Copilot instructions under my references. So there it is.
It's using thatright there. The other thing that I want to highlight is, and thisright now is particular to local chat, is I can even create .instructions files. And this is admittedly a little bit
it's a little bit tricky to, I think, understand kind of the first time that you see it. So kind of go with me on this one. So Copilot-instructions, universal. Every single chat request, this is going to go. The .instructions files, these become manual.
So I can add these in manually to a task that I'm performing inside of chat. He says delaying long enough for it to finally open. So what you're going to notice again, a Markdown file, but this is now particular to a type of task.
So this is for creating a Flask endpoint. And so you'll notice in here that I've given it information about the endpoint. I've given it information about my unit test. I've given it a couple of notes about the project.
And I've even linked to files that it should use as a prototype. And these are actually just existing files. So if I brought this in, now what it would do is it would follow all of those instructions there.
But let's say, for example, with React components, just to use that as an example, that I want to make sure that React components always follow the exact same patterns and practices. So what I can do there is up at the very top, you'll notice the apply to.
And then I can put in a path. So I could go astros, astros, squack,
astros.jsx or tsx if you're using TypeScript. And now, anytime that you're working with a file that matches that pattern, it will then automatically apply that instructions file. So in this case here, it's going to look inside of server tests.
And anytime that it finds a file that matches, test underscore. And you'll notice if I go into my server
tests, you'll notice test underscore games. That matches that patternright there. So anytime that I was working with a test file, that would then go ahead and match. The last thing I want to mention here is that all of this becomes part of your repository.
So is creating these files going to take a little while? Everybody go like this. Yeah. But this is very much like spending three hours to write a script for that task that constantly takes you a couple of minutes, that after a little while you're going to get your money back on it, so to speak.
It's the exact same thing here. So the time that you spend here is going to help improve productivity and help ensure that your code generation is going to be the way that you want it to be. Yeah.
I have a quick question. For the workflow, does it have to literally be named that code for the Copilot stuff?
Org Standards40:34
Yes. It does have to specifically, yeah. If you're using the workflow for setting up coding agent, it does have to have that name. And that is documented.
And for the custom instruction commands, you can put whatever you want before, but it should just be relevant to what you know what I mean? Like this is for Python.
And then sorry, this is too much. The last point is, OK, this is all great, but our org has standards. So we want to put these at the org level. Do we need to propagate it that way?
Yeah. So this is a fantastic question. So the question is, hey, about these standards, can we put these at an org level? And
yes. So there's a few different ways now that you can approach that. Number one is there is an ability to set instructions at the org level as well. So you could do it that way. You can also, again, stand up an MCP server in front of that and allow for searching that way.
And then the last thing that I would mention, and we just recently, like literally yesterday, I think it was, announced this is Copilot Spaces, where this is specifically on GitHub.com, that what you can do is basically point it at a repository, point that at specific files, and say, hey, here's our knowledge basis.
Here's how we want our code to be created. Here's all of our standards. Here's good examples. And then that way, when a developer comes along and they do searches on GitHub.com, they'll be able to then raise the information from there.
You're welcome. There was somebody over here. Yeah. I'm trying my best to be as fair as I can.
Agent Security42:09
So I want to understand. The agent is using the workflow to set up its environment.
Yep.
And what if there's changes required to the environment? Is that up to the developer to add this? Or can Copilot change its environment and change the workflow itself?
Oh, OK. Yeah. So that's a fantastic question. So the question is, hey,
about this workflow file, is this able to be automatically created or edited by Copilot? And the short answer is no. Now, if I was working locally, like let's say I'm not overly familiar with Actions, which I'm not, then I could go in through Copilot manually.
And I could say, hey, I need to create an environment that's going to install this, this, this, and this, and let Copilot generate this for me. Absolutely. But once I launch this into agent mode, agent mode is not going to be going back in and editing that.
Now, keep in mind, and I'm going to kind of lead thisright into the next kind of logical question here. So keep in mind that agent mode or coding agent, so when it's doing its thing in the background here, it does have an ability to run scripts.
So it can run tests and things like that. And in fact, if I
where was I?
Here.
And here.
And
let me scroll on down to view session here.
I'm going to zoom out because ironically, I think it's going to make it a little easier to read. OK. Let me come down here.
One second. Yeah, here we go.
Yeah.
So yeah, it looks like all the tests passed, although we're getting oh, that's cool. They pushed an update to SQLAlchemy. I'll have to go back and now update the project. But in any event, the takeaway that I want you to get out of this is the fact that this is running commands locally.
And so that then kind of raises the next big question, which I think is very directly related to, hey, could it go in and modify that initial set of workflow? And
it can't modify that. And it also is not able to access any external resources. So let me uplevel this real quick. When it comes to coding agent, coding agent was very much built with security in mind. So the first big thing is it's built on top of GitHub Actions.
And if you're not already familiar with GitHub Actions, when you spin up a brand new action to start running, it does so in an ephemeral space. So it creates the one space that it's going to work in. It does all of its work in there.
And then once that's done, all of that's torn down. So that's the only space in which it can work. Copilot only has read access to your repository save for the branch that it's going to create. And it only has write access to that branch.
So in this case here, it's going to be copilot-fix-2. Copilot-fix is what it's always going to start with, dash, and then the number of the issue that was assigned to it. Yep.
So in this case, it was issue number two. So that's why it's copilot-fix-2. So that's the only thing that it's going to have write access to. On top of that, it does not have access to any external services unless you open up the firewall.
So the firewall is going to be completely locked down. It is not able to call the outside world. That includes, by the way, installing packages. So let's say there was a library that needed to be installed, and it tries to install that.
It's going to fail on that unless I've specifically punched open a hole on that. Now, the exception to that, the workflow that I create, that initial setup workflow that we talked about, that workflow, because now I can install those services.
So if there's anything that I know that it needs, then I can go ahead and do that. But otherwise, it's not going to have access to any external resources. So very much designed with that security in mind. It's a very long-winded answer, but there's everything you ever wanted to know.
Yeah.
Testing & DevOps46:58
So with that in mind, do you have a workflow run test YAML that runs as GitHub Action on the master or to main?
Yeah. So let's actually go kind of one step further with this. So I am a good steward of
my repository. And so when I create a PR into main, so I'm going to use this one here, dependent bot wanting to bump a version number. And we're going to notice
we're going to notice there we go that I have a workflow set up here to perform some testing. So it runs unit tests, and it runs some end-to-end tests. So that way, somebody goes in, they create a pull request, and we're going to confirm all of that.
Every organization should, hopefully, have some level of validation that PRs look good before they start merging them in. Everybody go like this. Please, lie to me if you have to. Fantastic. Now, here's the catch. Again, thinking with our security cap, I want to make sure that any of that code is always going to be something that I trust.
So hopefully, anyway, I can trust all my developers. But when it comes to AI, I'm not entirely certain. So what we'll notice is that here's the PR that it finished. And you'll notice if I scroll on down here and I get to that section on workflows, that it has not run those tests.
And it's only going to run those tests if I click that buttonright there. And of course, before I do that, I should go in and review the code and everything else there. So yeah.
So my question is, if they're both running the same script.
Yes.
And that's kind of like what you would recommend, that is to feed it the instructions so that it can run those local tests as well as run them.
Exactly. Yeah. So the question is, so Copilot, when it did its work behind the scenes, and we saw this already, that it ran all of those unit tests locally. And then now we're going to notice here that I'm going to have it run those unit tests again.
I do the exact same thing with Copilot as I do with all of my other developers, which is that balance-and-spenders approach. So I'm going to uplevel this again. Just because I introduce AI does not mean that any of the fundamentals of DevOps change.
So let's think about how I wrote code before AI. So some of it would be from my own knowledge. Some of it would be grabbed from documentation. Some of it would be copied and pasted from Stack Overflow and changing it and hoping and praying that it actually did what I wanted it to do.
Or maybe that's just me.
And then eventually, I'm going to go ahead and I'm going to run my tests locally, hope that all of them work. And then I'm going to create a PR. Now, after we do that PR, now what are we going to do?
Well, we're going to get another developer to come along and review the code. We're going to run all of our actions. And we're going to make sure that our tests pass, that our linters check out, that all of our security scans are run, that we're going to do all of those core fundamentals regardless of how my code is being generated.
And that doesn't change when I'm using AI. So does AI run those tests locally? Absolutely. But am I still going to go in and double-check? I absolutely am. So I'm going to do that here as well.
So can you get it to run all of those tests when it's running locally? Give it more of a contextual base.
I was thinking if I was doing DevOps locally, I probably wouldn't run a full suite of I wouldn't run a script that runs all of the tests. I would probably run a focused set and then a second.
Oh, I see what you're saying. Yeah. So let's say I'm working on a larger project. And admittedly, this is a smaller project. So when I run my unit tests or even my end-to-end tests, it's going to take like 30, 40 seconds.
But if you've got a larger project where now that's going to be taking minutes. So in agent mode then, I can go ahead and direct it. Like, hey, only run the tests on what you're working on until you get to the very end, and then go ahead and run everything.
So I could either just include that in the prompt. Again, don't be passive-aggressive with Copilot. If you want it to do something, tell it to do it. That might also be something that I would consider including in the instructions file of like, hey, make sure that you always do that.
And then on top of that, one of the things that I've noticed about Claude 4 or Claude Sonnet 4 or whatever the naming structure it is they're using on that is it tends to sort of do that on its own, where it will go ahead and run a smaller set of tests and then branch out and do the whole one.
But it's doing that on its own. But again, if you want it to do something specifically, always tell it. Always tell it. Allright. I'm going to go over to this side real quick, and I'll come back to the middle.
Yeah.
So does Copilot support streaming for the HTTP MCP servers, remote servers, yet?
Does Copilot? Yes. Yeah. Copilot does support remote MCP servers. If you're going to be using that with Coding Agent, it will support that with Coding Agent as well. But I need to open up a hole in the firewall for it to be able to access that remote service.
And does that happen at a project level, or?
Yes. Yeah. Right here, if I go to
Settings, and I go to
Coding Agent, there's my MCP. I can go ahead and set the list of my MCP servers there. And then on Environment
and then Copilot, in here,
there's different variables that you could then go ahead and set to open up your firewall. All that's in the documentation, but that's where you would go to go ahead and do that. You're welcome. Yeah.
Soright now, the Coding Agent works with issues that are set up in GitHub itself only?
Correct.
So if I do save Jira.
Yeah.
Would we have to kind of own it? I don't know if Jira had an MCP or not.
Yeah. So the question is, hey, we're using ADO. We're using Jira. We're using fill in the blank for managing our issues. How can I then use that to assign to Copilot? Unfortunately, as ofright now, it's going to be GitHub only.
I don't know whether or not it will stay GitHub only or what a future plan might look like. But yeah, now, one thing that you might want to consider is if there is something in Jira that you want to assign to Copilot, you could create a relatively straightforward script to just copy that issue over and then go ahead and assign it to Copilot from there.
Butright now, the issue does have to be inside of GitHub.
Does it have a relevant MCP server now?
There you go. Yeah. Yeah.
How can you make a Copilot to use a reusable framework or some component libraries within a different repo?
What on the current repo? So instead of creating things from scratch, it can use this reusable thing?
Yeah. So this is a fantastic question. I'm going to actually uplevel this. So the question is, hey, we have internal libraries. And those are created in different repos. And we want to make sure that Copilot's going to use
those external libraries when it goes in to do its code. So
first thing that you can do is make sure that Copilot sees you doing it. So Copilot is a great pattern matcher. And in order for Copilot to be able to use an external library or an external framework, it just needs to see how you're doing it.
Think about all the frameworks that you use on a day-to-day basis. Do you really know how they work behind the scenes? I'm a Svelte developer. I have no idea how Svelte works behind the scenes. But I know how to use Svelte because I've read all the docs, and I've written all the code, and I can get it to do everything that I want it to do.
But I have no idea what it's doing behind the scenes. I want to think of the exact same thing when it comes to Copilot. Copilot doesn't need to see the source code. It just needs to see how you're using it.
And then it can best understand, then in turn, how to do that. So that's the first big thing is show it examples of that. The next thing that you can then do is, again, take advantage of your instructions files.
So what you can do is just list the API. So
if I'm using a particular library, and I know that there's always certain file types that are going to be using that, then I could create that .instructions file, or I could list that inside my instructions file. Or again, if it's a bigger set of libraries, put an MCP server in front of it.
Wrap-up56:30
And then I can go ahead and allow it to search that way and be able to see it that way. So kind of show it how it is
that you're using it.
And there was something else that I wanted to add there that will come to me in a minute.
No.
There's something else, and I just cannot remember what it is now. But yeah.
So do you have an interface that's able to do fine-tuning?
Yeah. So this is a great question. So what about fine-tuning? And the short answer is,right now, we don't support fine-tuning. Fine-tuning, as it turns out, is very tricky. Because one of the things that we've discovered in working with customers and so forth is customers have code bases where they're proud of a lot of it, and then they've got a lot of it that they're not necessarily proud of.
And so training Copilot to understand, hey, this is the good stuff, this is the stuff you don't want to look at becomes a little tricky. So this is, again, where standing up an MCP server really comes into play.
Because now I can then better control, this is what I want you to be looking at. This is what I don't want you to be looking at. So yeah.
How do I reason about the cost of assigning an issue to Copilot? Meaning, my understanding is if you're on Enterprise plan, you get some amount of premium requests, and the Copilot agent is going to choose through some number of things.
Right? But how do I think about that?
I am not a billing person. I am going to.
We hit noon. So why don't we let most of them go?
Oh, I was looking at this clockright here. I thought I had six minutes. Oh, OK. Allright. Thank you. I apologize for our network issues. Again, let me put the one slide back up.
There. You can go ahead and check out the lab from there.
Thank you.
Thank you.
Allright.





