├── README.md ├── changes.md ├── codespaces-guide.md ├── creating-repos.md ├── experiments.md ├── getting-started.md ├── images ├── adhoc-tasks │ ├── ad-hoc-task-full.png │ ├── ad-hoc-task.png │ └── adhoc-task-timeline-representation.png ├── creating-repos │ ├── create-repo-from-template.png │ └── repo-task-timeline-representation.png ├── further-techniques │ └── ambiguous-spec.png ├── general │ ├── dashboard.png │ ├── open-in-workspace-full.png │ └── open-in-workspace.png ├── getting-started │ └── pr.png ├── overview │ ├── current-spec.png │ ├── file-iteration.png │ ├── issue-timeline-representation.png │ ├── plan.png │ ├── proposed-spec.png │ ├── references.png │ ├── session.png │ ├── share-link.png │ ├── task-completion.png │ ├── terminal.png │ └── topic-question.png ├── pull-request-tasks │ └── pr-task-timeline-representation.png ├── tips-and-tricks │ ├── code-editor.png │ ├── experiments.png │ ├── issue-and-code.png │ ├── regen.png │ └── undo-redo.png └── vscode │ ├── ghcw-activity-bar-icon.png │ ├── ghcw-brainstorm-multiple-answers.png │ ├── ghcw-brainstorm-panel.png │ ├── ghcw-branch-example.png │ ├── ghcw-clone-or-open-folder.png │ ├── ghcw-editor-actions.png │ ├── ghcw-extn-install.png │ ├── ghcw-overview.png │ ├── ghcw-plan-view-banner.png │ ├── ghcw-selec-repo-loc.png │ ├── ghcw-session-details-button.png │ ├── ghcw-session-details-no-sync.png │ ├── ghcw-session-details.png │ ├── ghcw-session-list-button.png │ ├── ghcw-session-list-no-sync.png │ ├── ghcw-session-list.png │ ├── ghcw-sign-in-notification.png │ ├── ghcw-task-view-brainstorm.png │ ├── ghcw-uri-sync-not-enabled.png │ ├── status-bar-error.png │ ├── status-bar-not-syncing.png │ ├── status-bar-syncing.png │ ├── status-bar-working.png │ └── upper-right.png ├── known-issues.md ├── origins.md ├── overview.md ├── repo-maintainers.md ├── responsible-ai-faq.md ├── settings.md ├── tips-and-tricks.md ├── troubleshooting.md └── vscode.md /README.md: -------------------------------------------------------------------------------- 1 | # 📖 Copilot Workspace User Manual 2 | 3 | Welcome! 👋 This is the user manual for [Copilot Workspace](https://copilot-workspace.githubnext.com), an experiment by [GitHub Next](https://githubnext.com). Copilot Workspace is an AI-native dev environment that allows you to collaborate with Copilot on repo-wide coding tasks, using natural language and integrated cloud compute. You can learn more about what Copilot Workspace is from its [project page](https://githubnext.com/projects/copilot-workspace/). 4 | 5 | This manual will help you understand how to use Copilot Workspace most effectively, and share tips & tricks that we've learned while using Copilot Workspace to build Copilot Workspace. It also documents some known issues (it's an experiment after all!), as well the technical roadmap and origins of the project. 6 | 7 | ## Table of Contents 8 | 9 | * [Getting Started](getting-started.md) 10 | - [VS Code](vscode.md) ([Extension link](https://gh.io/cw-vscode)) 11 | - [`CHANGELOG`](changes.md) 12 | - [Tips & Tricks](tips-and-tricks.md) 13 | - [Troubleshooting](troubleshooting.md) 14 | * Going Further 15 | - [Creating New Repositories](creating-repos.md) 16 | - [Controls for Repository Maintainers](repo-maintainers.md) 17 | - [Experiments, Roadmap and Known Issues](known-issues.md) 18 | - [Terminal/Codespaces Guide](codespaces-guide.md) 19 | - [Settings](settings.md) 20 | - [Responsible AI FAQ](responsible-ai-faq.md) 21 | * [Origins](origins.md) 22 | - [Conceptual Overview](overview.md) 23 | 24 | ## Feedback 25 | 26 | To give general feedback, please join the [GitHub Next Discord](https://discord.gg/FeGshJZ2yy) and post in the [#copilot-workspace](https://discord.com/channels/735557230698692749/1237161687233200279) forum channel. Please provide a share link to the workspace and a description of the issue you're facing so that we can help you more effectively. 27 | 28 | To report harmful content, please email copilot-safety@github.com with a description of the issue and a share link to the workspace. 29 | -------------------------------------------------------------------------------- /changes.md: -------------------------------------------------------------------------------- 1 | ## 📅 6 December 2024 2 | 3 | As you may have seen in Discord a few weeks ago, [Copilot Workspace is graduating](https://discord.com/channels/735557230698692749/1309719558449397780/1309719558449397780)! It is a very exciting time, and also a time of change. So before getting into the product changes from this week, we want to highlight a few logistical changes, because everyone loves logistics :muscle: 4 | 5 | **Changelog location:** Starting next week we will post changelogs to the main [GitHub changelog](https://github.blog/changelog) rather than this repository. This will be the last changelog posted in this repository, so make sure to follow the [GitHub changelog](https://github.blog/changelog) to stay up to date with the latest and greatest. 6 | 7 | **How to provide feedback:** We are also transitioning from the current Discord to a [GitHub Discussion](https://gh.io/workspace-feedback) as the primary place for feedback and discussions around Copilot Workspace. We will still be available in Discord, but posting in the [discussion](https://gh.io/workspace-feedback) will ensure we see your feedback sooner. 8 | 9 | Okay, now onto the product updates for this week! :tada: 10 | 11 | - [Image Preview Support](#image-preview-support) 12 | - [Simplifying the Experience](#simplifying-the-experience) 13 | - [Reducing Action Button Clicks](#reducing-action-button-clicks) 14 | - [Consolidating the Plan Action Buttons](#consolidating-the-plan-action-buttons) 15 | - [VS Code Extension Improvements](#vs-code-extension-updates) 16 | 17 | ### Image Preview Support 18 | 19 | Building on recent improvements to file and image support, you can now preview images directly in the Workspace editor. Selecting an image from the file tree will now display a full preview of the image, letting you open a preview tab directly within the editor. 20 | 21 | 22 | 23 | ### Simplifying the Experience 24 | 25 | Since our last changes dropped we have invested time into streamlining the Workspace experience, saving you clicks, headaches, and frustration. 26 | 27 | #### Reducing Action Button Clicks 28 | 29 | We updated the primary action button such that secondary actions available in the dropdown no longer require a second click of the primary button - when you select an action it will immediately take effect. 30 | 31 | 32 | 33 | #### Consolidating the Plan Action Buttons 34 | 35 | We have also consolidated plan action buttons like Regenerate and Add File to a kebab menu. 36 | 37 | **Before:** 38 | 39 | 40 | **After:** 41 | 42 | 43 | ### VS Code Extension Updates 44 | 45 | - **Enhanced Session List:** Sessions now appear earlier in their lifecycle in the session list, supporting the new brainstorming feature in VS Code. 46 | - **Stale View Fix:** Resolved an issue where stale view states were retained in certain views. 47 | - **Push to Branch / PR Creation Fix:** Fixed failures when merging into an existing branch with updates to the same files. 48 | - **Binary Detection Fix:** Addressed a false positive issue where folders were incorrectly flagged as binary after session syncing stopped. 49 | - **Error Message Visibility:** Resolved cases where certain error messages did not display. 50 | 51 | ## 📅 22 November 2024 52 | 53 | Coming off the back of [GitHub Universe](https://githubuniverse.com/), we have been making a ton of behind the scenes change, to improve stability, performance, and setting ourselves up for the next stage of product growth. With that said we have a few updates to share with you! 54 | 55 | - [File Attachments](#file-attachments) 56 | - [Sortable Tabs](#sortable-tabs) 57 | - [UI Polish](#ui-polish) 58 | 59 | VS Code Extension Updates: 60 | 61 | - [Brainstorming](#brainstorming) 62 | - [Branch and PR creation](#branch-and-pr-creation) 63 | 64 | ### File Attachments 65 | 66 | Continuing on from the image support we added previously, today we are adding support to attach image and text files from the local machine to a Workspace session. Once attached, file attachments work similar to URL attachments in the sense that they get taken into account as context. 67 | 68 | 69 | 70 | > Note: If you want to give this feature a try, you need to enable the `Allow file(s) to be attached as additional context` setting in the `Experiments` dialog (underneath the avatar menu). 71 | 72 | ### Sortable Tabs 73 | 74 | You can now customize your Workspace experience by sorting and reordering tabs using drag and drop. 75 | 76 | 77 | 78 | ### UI Polish 79 | 80 | Fixing a bunch of small issues that we have noticed and other reported by users to make the experience smoother/more polished. 81 | 82 | ### VS Code Extension Updates 83 | 84 | A number of updates this week to the VS Code extension to make it easier to use and more powerful. 85 | 86 | #### Brainstorming 87 | Initial support for brainstorming is now available in VS Code! Open up your session of choice, and click on the light bulb or a Ideas from brainstorming in Task view to get started. To answer a new question, click question mark in the Task view, or a Suggested questions, or the Answer button in the Brainstorming panel. Once in the panel, attach ideas or answers and the How should I solve this issue? question will get automatically refreshed with the latest info. Generate or update your plan from there and continue on as always! 88 | 89 | 90 | 91 | #### Branch and PR creation 92 | When session syncing is enabled, your changes are automatically synced to the web. But it can be useful to push your changes to a local and/or remote branch, or even create a PR - and you can now do this from VS Code! Click on the push or PR icon in the Plan view and select your options to get started. 93 | 94 | 95 | 96 | ## 📅 25 October 2024 97 | 98 | As the team prepares for [GitHub Universe](https://githubuniverse.com/) next week, we were primarily focused on stabilization, bug fixing, and welcoming new preview users (as we continue to ramp up the waitlist!). That said, we also managed to slip in a few enhancements as well 😄 99 | 100 | - [AI vision](#ai-vision) 101 | - [Auto-installed extension](#auto-installed-extension) 102 | - [Command status](#command-status) 103 | 104 | ### AI vision 105 | 106 | If you open an issue in CW, and that issue includes images in it's description, then those images will now be included in the context of the task. This is a pretty significant capability, since it unlocks new ways of defining your intent, such as using... 107 | 108 | 1. **Architecture/class diagrams**, that outline the structure of code you want to generate ([example](https://copilot-workspace.githubnext.com/githubnext/workspace-blank?shareId=25cc2d17-3d00-4f6c-ad5b-ccf3e53a992c)) 109 | 2. **App screenshots**, which visually highlight a part of the UI you want to change 110 | 3. **UI mock-ups**, which describe the layout/behavior of some client code you want to write 111 | 4. **Photographs**, which capture hand-written notes or drawings from a meeting 112 | 113 |
114 | 115 | When combined with [custom instructions](#custom-instructions) and [web URLs](#external-context), AI vision expands CW's support for managing task context, and defining your tasks in whichever way is most natural. And we're excited to hear how folks make use of it! 116 | 117 | > Note: If you want to give this feature a try, you need to enable the `Use summaries of images in the context` setting in the `Experiments` dialog (underneath the avatar menu). 118 | 119 | ### Auto-installed extension 120 | 121 | When you click the `Open in Codespace` button in a session, the [Copilot Workspace](https://gh.io/cw-vscode) extension for VS Code is now automatically installed within the Codespace. Why is this cool? Because that allows you to transition to the editor, while still being able to view the details of the task and plan. Additionally, it allows you to continue performing NL-based revision, in addition to any many edits. 122 | 123 | 124 | 125 | ### Command status 126 | 127 | The build/test/run button in the `Commands` tab now displays the status of the current/last run command. That way if you're actively using the `Terminal` tab, you can still see that a build (or test/run) is in-progress. Or that the build you were running in parallel, just succeeded 👍 128 | 129 | 130 | 131 | ## 📅 18 October 2024 132 | 133 | - [Error repair](#error-repair) 134 | - [Follow ups](#follow-ups) 135 | - [Brainstorm enhancements](#brainstorm-enhancements) 136 | - [Plan command enhancements](#plan-command-enhancements) 137 | 138 | ### Error repair 139 | 140 | When a [build/test/run command](#commands) fails, CW now displays a lightbulb button in the command's toolbar. When you click this, it will trigger a [brainstorming](#brainstorming) action, and then offer a suggestion for how to fix the error. 141 | 142 | 143 | 144 | When a suggestion comes back, it will include an explaination of the issue, and then present a fix in one of two forms: 145 | 146 | 1. A **terminal command**, which can be run in order to resolve the issue (e.g. installing a missing environment dependency) 147 | 2. A **plan update**, which can be applied, and then implemented in the impacted file(s) (e.g. missing imports, type errors) 148 | 149 | | Terminal fix | Plan fix | 150 | |-|-| 151 | | | | 152 | 153 | After accepting a suggestion, you can then re-run the failed command, and hopefully see it pass. That said, if you encounter another issue (e.g. a build with multiple errors), then you can just continue to command + repair as much as needed 🚀 154 | 155 | ### Follow ups 156 | 157 | We've introduced a new capability into CW, that we're calling `Follow up`. And we're pretty excited about it 😃 158 | 159 | 160 | 161 | #### Let's talk about why it's useful! 162 | 163 | When you're working against a large repository that has complex/inter-file dependencies, it's possible that a simple change/refactoring can impact many other places across the codebase (e.g. updating a shared method signature). And while the plan can do a great job of identifying the core changes needed for a task (the "primary edits"), it can sometimes miss transitive changes that are needed in response (e.g. updating callers of a changed function). 164 | 165 | To address this, after you've implemented a plan, you can open up the `Commands` tab and click the new `Follow up` button. This will perform a thorough, fine-grained check on your codebase + edits, to see if any additional changes are required, in order to complete your task. And if any follow-ups are detected, it will edit the neccessary files, and add them to your existing implementation 👍 166 | 167 | 168 | 169 | This workflow is pretty slick, because it allows the initial CW plan to be both fast and focused, which makes it quicker for you to get to code, and easier for you to review the essence of the change. And in cases that a change has repo-wide impact, you can simply trigger a follow up and let Copilot do the rest 😎 170 | 171 | #### How can you try it? 172 | 173 | At the moment, this experience supports codebases that are written in TypeScript/JavaScript, Python, Java, and C#. So if you're working in one of those languages, we'd love to hear your feedback! And if not, we'd love to hear whether this capability would be useful, in order to help us prioritize new languages in the future 🙏 174 | 175 | And while we let this capability bake a bit, it's currently disabled by default. So if you'd like to give it a try, simply open the `Experiments` panel (under the avatar menu) and check the `Enable follow up` setting. 176 | 177 | ### Brainstorm enhancements 178 | 179 | When you open an issue in CW, or click the `Brainstorm` button for ad-hoc tasks, the initially-generated question (`How do I solve this issue?`) is now presented in a "special" structured format. The response includes two sections (`Current behavior` / `Proposed solution`), and has the advantage of allowing you to add/edit/delete/organize any of the steps, in a very granular way. 180 | 181 | 182 | 183 | Additionally, since we're treating this question as "special", it's automatically updated any time you attach an additional brainstorming question/idea to the task. That way, you can continue to brainstorm further, and ensure that CW's understanding of the overall solution remains always up-to-date 👍 184 | 185 | ### Plan command enhancements 186 | 187 | When a plan includes a `Commands` section (e.g. because your task required installing 3rd-party dependencies), you can now execute an individual command, in addition to the existing "Execute all" support. Additionally, the completion status of commands are now persisted. So when you resume a CW session later, you can see which commands were already run, which failed, and which are still outstanding. 188 | 189 | 190 | 191 | ## 📅 11 October 2024 192 | 193 | - [Commands](#commands) 194 | - [Running commands](#running-commands) 195 | - [Command setup / inference](#command-setup--inference) 196 | - [NL command suggestions](#nl-command-suggestions) 197 | - [Plan commands](#plan-commands) 198 | - [Action bar mode picker](#action-bar-mode-picker) 199 | - [Open in VS Code](#open-in-vs-code) 200 | - [External URL context](#external-url-context) 201 | - [Auto-completing sessions](#auto-completing-sessions) 202 | - [High contrast mode](#high-contrast-mode) 203 | - [Custom instructions](#custom-instructions) 204 | 205 | ### Commands 206 | 207 | As part of our continued revamp of the CW UX (e.g. brainstorming, the action bar, file tabs/tree, etc.), we've introduced a new capability called `Commands`, which replaces the integrated terminal with a full-height panel, and provides a simplified experience for executing and configuring a build/test/run against your code. Conceptually, you can think of this as being the centralized "hub" for all tasks in the workspace that require executing a shell command. 208 | 209 | 210 | 211 | And similar to [brainstorming](#brainstorming), this capability is significant enough in scope, that we need to describe it in four distinct parts 😄 212 | 213 | - [Running commands](#running-commands) 214 | - [Command setup / inference](#command-setup--inference) 215 | - [NL command suggestions](#nl-command-suggestions) 216 | - [Plan commands](#plan-commands) 217 | 218 | #### Running commands 219 | 220 | To begin using the new `Commands` hub, simply click the existing terminal icon in the header bar. Once opened, it will automatically create and connect to a backing Codespace, so you can start running commands as needed. And if your repository has been configured with a `postAttachCommand` (in your [`devcontainer.json` file](https://containers.dev/implementors/spec/#devcontainerjson)), then you'll see a `Post attach` entry appear, that let's you view the output of its underlying shell commands. 221 | 222 | Additionally, if you've configured a `build`, `test`, or `launch` task in your `devcontainer.json`, then you can click to run any of those. This will result in the command being displayed in the list on the `Output` tab, and allow you to view its output, stop it, or re-run it once complete (e.g. to re-trigger a build after editing code). 223 | 224 | 225 | 226 | And just like the existing terminal, if a build/test/run command starts a server, then it will be automatically forwarded, so you can securely view it. 227 | 228 | #### Command setup / inference 229 | 230 | If you haven't configured any tasks in your `devcontainer.json`, then you can simply click on either the build, test, or run command, and then type the respective shell commands into the task editor. When you do that, the entered commands will be automatically added to a `devcontainer.json` file for you, so you can include them in your subsequent PR. 231 | 232 | And if you don't know how to perform a build/test/run on the current repo, then simply click the lightbulb icon next to a task and let CW suggest how to do it for you 🚀 233 | 234 | 235 | 236 | #### NL command suggestions 237 | 238 | While we've optimized the UX for building, testing, and running your code, there are many other tasks you might need to perform during a session (e.g. linting, formatting, etc.). And to make that simpler, the action bar now enters "command mode" (when you're focused on the `Commands` tab), which lets you describe a shell command you want to run, using only natural language. 239 | 240 | After typing an NL request, you'll be presented with a command suggestion, which you can edit or regenerate. And if you click the `Run` button, it will open the `Terminal` tab on the `Commands` hub, and execute it on your behalf. 241 | 242 | 243 | 244 | #### Plan commands 245 | 246 | The "plan commands" feature is now on by default, and when a plan includes shell commands (e.g. running a package manager to include a new dependency), it will execute them via a new `Plan` command entry in the `Commands` tab. 247 | 248 | 249 | 250 | ### Action bar mode picker 251 | 252 | The action bar now allows you to seamlessly switch between its three modes: `Ask`, `Revise`, and `Command`. This ensures that regardless what state your session is in, you can ask a question, revise the plan/implemented files, or execute a terminal command. All using natural language 💙 253 | 254 | 255 | 256 | Even cooler, you can switch between any of these modes using the following keyboard shortcuts, which make it really easy to navigate a session, while jumping between brainstorming, code iteration, and terminal actions. 257 | 258 | | Mode | Keyboard shortcut | 259 | |-|-| 260 | | Ask | ? | 261 | | Revise | > | 262 | | Command | $ | 263 | 264 | Additionally, each mode retains a history of its previous request. So if you realize you wanted to ask a question a slightly different way, or make a subtly different revision, then simply hit the up arrow, edit, and submit 👍 265 | 266 | > By introducing the new `Commands` tab, and allowing all three of the action bar's modes to be usable at any time, the action bar is now the official "central nervous system" for the entire CW experience. We've really fallen in love with how it feels to start and iterate on tasks now. And we're excited to hear how it feels for everyone else! 👋 267 | 268 | ### Open in VS Code 269 | 270 | After a month of _amazing_ feedback from our preview users, we've officially published the [Copilot Workspace extension](https://gh.io/cw-vscode ) to the VS Code marketplace 🥳 271 | 272 | And in order to make it even easier to use, we've introduced a new `Open in VS Code` button to the CW session header. When you click it, we'll launch VS Code, and open your current session directly from within the editor. That way you can start tasks and brainstorm from the web (or your phone!), and when you want to jump into VS Code to finish it off (e.g. step-debug some code), you can now do that in a single-click 💪 273 | 274 | 275 | 276 | Additionally, the official extension release also includes a ton of new capabilities that make the E2E experience a lot better. In particular, we've enhanced the `Sessions` and `Plan` views in the following ways... 277 | 278 | #### `Sessions` view 279 | 280 | In order to make it easier to manage _many_ sessions, your sessions list is now grouped by repository, and each session displays an icon based on its respective type: issue, task, or PR. Additionally, when you're done with a session, you can now delete it directly from the editor, by hovering over it and clicking the trash can icon. 281 | 282 | 283 | 284 | #### `Plan` view 285 | 286 | The VS Code extension now has full parity with the CW web client, when it comes to iterating on the plan and code in a session. And in particular, you can now perform the following actions on the plan, directly from the `Plan` view: 287 | 288 | 1. Adding, editing, and deleting files 289 | 2. Adding, editing, and deleting steps for a file 290 | 3. Re-organizing the plan, by moving/indenting files and steps 291 | 292 | To access these new capabilities, simply click the `...` menu next to a file or step in the plan. We're pretty happy with how this experience "feels", and we're looking forwarding to hearing more feedback 🙌 293 | 294 | | Plan file actions | Plan step actions | 295 | |-|-| 296 | | | | 297 | 298 | > If you use VS Code Insiders, then set the `Open in VS Code Insiders` setting, and the `Open in VS Code` button which launch Insiders instead of Stable. 299 | 300 | ### External URL context 301 | 302 | We've enabled external URL fetching by default, and made the following improvements to the overall user experience: 303 | 304 | 1. The content of external URLs are now included in the context while brainstorming. This is cool because it allows you to ask questions and ensure they can "see" any meaningful context you've added to the task (e.g. GitHub issues, external documentation) 305 | 1. You can now enable/disable individual URLs from the `Task` panel, which allows you to control which external content is used as context, without needing to modify the task description. 306 | 307 | 308 | 309 | > Note: If you'd like to disable external URLs from being enabled by default, then you can turn off the `Automatically include external URLs in context` setting in your `Settings` panel (underneath the avatar menu). 310 | 311 | ### Auto-completing sessions 312 | 313 | We introduced a new setting that allows you to automatically mark sessions as complete after creating a PR/branch/repo for them. For users that create many sessions, this can help keep your `Recent sessions` list (on the [dashboard](https://copilot-workspace.githubnext.com)) nice and clean. And if you later decide that you need to continue a session that was marked as complete, you can always resume it from the [Completed sessions list](https://copilot-workspace-dev.githubnext.com/?view=completed) at any time :thumb: 314 | 315 | > To enable this behavior, open your user `Settings` (underneath the avatar menu in the upper-right), and select the `Mark sessions as complete after committing` option. 316 | 317 | ### High contrast mode 318 | 319 | CW already supports a light and dark color theme, and will match your system preference automatically. However, to further improve usability for all users, we've introduced support for a new high-contrast mode of both color themes. 320 | 321 | 322 | 323 | > To enable this behavior, open your user `Settings` (underneath the avatar menu in the upper-right), and select the `Enable high contrast mode` option. 324 | 325 | ### Custom instructions 326 | 327 | CW now supports configuring repo-wide custom instructions via a `.github/copilot-instructions.md` file, in addition to the existing file location (`.github/copilot-workspace/CONTRIBUTING.md`). If a repo includes a `.github/copilot-instructions.md` file, then it will take precedence over `.github/copilot-workspace/CONTRIBUTING.md` (we don't "merge" the contents if you define both). Otherwise, both files support the exact same set of features and user experience (e.g. the `Task` panel will show custom instructions as additional context, and external URLs in the instructions will be fetched). 328 | 329 | ## 📅 27 September 2024 330 | 331 | - [Brainstorming](#brainstorming) 332 | - [Project exploration / learning](#project-exploration--learning) 333 | - [Solution proposals](#solution-proposals) 334 | - [Asking questions](#asking-questions) 335 | - [Explaining / reviewing code](#explaining--reviewing-code) 336 | - [Create new repository](#create-new-repository) 337 | - [VS Code: Implement/revise specific files](#vs-code-implementrevise-specific-files) 338 | - [File tree filtering](#file-tree-filtering) 339 | - [Plan step filtering](#plan-step-filtering) 340 | - [Improved build/test/run inference](#improved-buildtestrun-inference) 341 | - [Plan + implement](#plan--implement) 342 | - [URL context management](#url-context-management) 343 | 344 | ### Brainstorming 345 | 346 | We've introduced a major new CW capability that we're calling "brainstorming" (💡). And it represents such a significant change, that it needs to be described in four distinct parts 🤗 347 | 348 | - [Project exploration / learning](#project-exploration--learning) 349 | - [Solution proposals](#solution-proposals) 350 | - [Asking questions](#asking-questions) 351 | - [Explaining / reviewing code](#explaining--reviewing-code) 352 | 353 | 354 | 355 | > Note: This feature isn't currently enabled by default. So if you'd like to try it, then enable the `Activate brainstorming` setting in your `Experiments` panel. 356 | 357 | #### Project exploration / learning 358 | 359 | At its core, CW aspires to be an "AI thought partner" that can enable developers to complete everyday tasks, **while learning along the way**. And while the `Specification` panel has successfully helped preview users create thousands of pull requests, it's been clear for a while that we could do a lot better. And in particular, help reduce the activation energy in getting started, **even before you've typed a single character.** 360 | 361 | To that end, when you start a new task in CW, you'll now notice a green `Brainstorm` button in the `Task` panel. 362 | 363 | 364 | 365 | If you click it, it will open a new tab (called `Brainstorm`) and suggest a list of questions that might be relevant for you, in either onboarding to the repository, or learning a bit more about specific behavior/topics (e.g. how to buikd VS Code extensions). 366 | 367 | 368 | 369 | When you click one of these questions, CW will generate an answer to it, using the same repository-wide context that you've already come to know and love 💙 370 | 371 | 372 | 373 | Even cooler, as you select questions, the `Suggestion questions` list will dynamically update to include new, and potentially interesting questions based on your selections. Kind of like a dynamic search engine for code, that can "push" insights at you, instead of waiting for you to ask ⭐ 374 | 375 | And as with all things in CW, a generated answer can be edited, regenerated, or deleted. And if you find something especially useful, you can even add it as context to the task, which will inform the subsequent planning/code generation. 376 | 377 | 378 | 379 | When a brainstorming question is added to the task, it will show up in the task via a new section called `Ideas from brainstorming`. And while it may seem silly, we love this title so much. Why? Because it represents the notion that ideas are the output of brainstorming. And ultimately, we want CW to help you produce new and better ideas 💙 380 | 381 | 382 | 383 | Interestingly enough, this behavior means that you can actually work on tasks with CW, without ever actually typing a task description. You simply perform brainstorming, attach the associated ideas, and then move on to the plan/implementation. However, in order for this to work well, you obviously need to be able to describe your intent or to guide CW in the direction that you want to go. So let's see how that works! 384 | 385 | #### Solution proposals 386 | 387 | If you click the `Brainstorm` button _after_ you've typed a task description, then instead of simply getting a list of suggested questions, CW will actually present you with a proposal for how to solve your task. And this is where things get really fun 😎 388 | 389 | When a brainstorming question can result in multiple solutions/parts, then instead of simply answering it, CW will present you with a list of **ideas**, and allow you to select one, many, or all of them. That way, you can compose your intent by brainstorming with CW, and derive ideas through this collaborative process. Additionally, just like "single answer questions", you can regenerate the question to get new ideas, and then edit/refine them as needed. And as you select ideas, the `Suggested questions` will dynamically update, in order to provide you a pathway towards other interesting questions, which might be worthy of further brainstorming 🧠 390 | 391 | 392 | 393 | > Note: When you open an issue in CW, it will automatically launch the `Brainstorm` tab, and present you with the same experience as manually entered tasks. In this sense, the default `How do I solve this issue?` brainstorming question represents an alternative to the `Specification` panel, but has the benefit of being much more rich and flexible in nature. 394 | 395 | #### Asking questions 396 | 397 | While the default brainstorming experience can help you to learn about repositories, and think through solutions for tasks/issues, it's also important that you can ask arbitrary other questions, in your pursuit of learning/task completion. And to solve that, the existing "NL revision bar" (the pretty textbox that let's you revise the plan/code) has now been converted into an "action bar". This bar is now always visible, and when you start a new task or open an issue/repo, it will present you with a new prompt: `Ask a question...`. 398 | 399 | 400 | 401 | When you enter and submit a question, it will launch the `Brainstorm` tab, and start to generate an answer, which will include multiple ideas if relevant, and allow you to edit/refine it as needed. And again, as you ask new and interesting questions, you can attach those as context for the task, and the `Suggested questions` list will continue to provide you would potentially interesting follow-ups. 402 | 403 | Additionally, questions can be asked at any time. And so while you can ask questions at the start of a task, you can also ask them after planning, impmementing or revising. Which leads up to our next part! 404 | 405 | #### Explaining / reviewing code 406 | 407 | After you've implemented a plan, you'll notice two new buttons in the file diff headers (within the `Files changed` tab), which allow you to enter brainstorming mode in two interesting ways: 408 | 409 | 1. Explaining the changes that were made to the file 410 | 2. Exploring ideas about how to improve the file further 411 | 412 | 413 | 414 | These allow you to extend the learning process into a specific change, and make sure that you fully understand the "what?" and "why?" behind an edit, before you ever send a PR. 415 | 416 | 417 | 418 | Additionally, by being able to brainstorm with CW on a changed file, you can effectively perform a lightweight code review with it, and get some simple follow-up suggestions. Just in case there's anything else worth doing 👍 419 | 420 | 421 | 422 | And as if that wasn't enough...the next section is effectively also an extension of brainstorming. But I felt like this section was getting long enough, so I decided to break it up 😄 423 | 424 | ### Create new repository 425 | 426 | You can now easily create new repositories from CW, by visiting the [dashboard](https://copilot-workspace.githubnext.com) and clicking the `Create new repository` button at the bottom of the `Recent repositories` section. 427 | 428 | 429 | 430 | This will take you into a new session where you can define (or brainstorm!) what you want the new repo to include. And when you finish planning/implementing the code, you can click the `Create repository` button to create the repository and then commit your changes. 431 | 432 | 433 | 434 | Additionally, if you'd like to create a repository from an existing template (as opposed to a blank repo), then simply click the `Choose a repository` link from the dashboard, search for the template you want to use (e.g. `express starter`), and then select it. This will take you into the same "new repo" flow as above, but will display a `Template` panel with the template's `README` contents in it. Between the new repo + template repo flow, and the addition of brainstorming, we're excited to see how much we can improve the process of bootstrapping new projects 💙 435 | 436 | ### VS Code: Implement/revise specific files 437 | 438 | The CW extension for VS Code now allows you to select specific files in the plan that you'd like to implement (by selecting their respective checkboxes in the `Plan` view). Additionally, you can now NL-revise specific files as well, by clicking the target icon in their file tab, and then entering the change you'd like to make. 439 | 440 | Even cooler, you can NL-revise a file that isn't even part of the plan, and it will be added + revised automatically for you. These two changes match the behavior of the CW web/mobile client, and effectively round out the core iteration/feedback loop within VS Code. 441 | 442 | 443 | 444 | > Note: Since this extension is early, we're still not quite ready to publish it to the marketplace. We'll likely do that in the next couple of weeks, but until then, simply hit us up in [Discord](https://gh.io/next-discord) to grab the latest VSIX 😎 445 | 446 | ### File tree filtering 447 | 448 | The integrated file tree now allows filtering it to show only the files that have changed in the session (along with their parent directories). This makes it easier to contextualize the changes being made, through the lens of your repository's folder structure. Additionally, this setting is persisted as part of the session, and so if you toggle it, it will remain filtered whenever you resume working on it later (including from your phone!). 449 | 450 | 451 | 452 | 453 | 454 | 455 | 456 | 457 | 458 | 459 |
Before filteringAfter filtering
460 | 461 | ### Plan step filtering 462 | 463 | The `Plan` panel now allows filtering it to show only the steps that were introduced in the last revision/edit (and their associated files). As a plan grows in size/complexity, this filter can make it alot easier to focus your attention on only the steps that were recently made, and therefore, would benefit from a closer review. This filter builds upon the previously-added blue dots (which indicate an "unseen" plan step), and represent another step towards making plan revision feel much more incremental and easy to follow :muscle: 464 | 465 | 466 | 467 | 468 | 469 | 470 | 471 | 472 | 473 | 474 |
Before filteringAfter filtering
475 | 476 | ### Improved build/test/run inference 477 | 478 | When you click the `Build`, `Test` or `Run` buttons in the integrated terminal, CW will now provide better suggestions for the neccessary shell commands needed to run them. In particular, we now include any Actions workflows, package manifests (e.g. `package.json`), and the `CONTRIBUTING.md` file (if it exists) in the context, which allows CW to more properly infer the best way to build/test/run your code. 479 | 480 | 481 | 482 | ### Plan + implement 483 | 484 | After writing/editing a task, you can now generate the plan and implementation in a single step. As opposed to generating the plan, and then clicking the `Implement` button after its done. For simple/straight-forward tasks, this gives you the option to jump straight to code, and then refine things further from there. And if you notice that the plan isn't quite right while the code is being generated, you can easily cancel, revise the plan, and then re-implement. That way you don't lose any steerability when taking advantage of this shortcut 😎 485 | 486 | 487 | 488 | ### URL context management 489 | 490 | When a task references external URLs (e.g. docs), you can now exclude them from the session context, by clicking their associated trash can icon (within the `Additional context` section of the `Task` panel). Behind the scenes, this simply updates the task description by wrapping the selected URL in backticks (so that it's treated as raw markdown). But since a URL might be buried in an issue description/call stack, or could occur multiple times within the task definition, this new button should make it a lot easier to properly manage the context that you want CW to consider 👍 491 | 492 | 493 | 494 | ## 📅 20 September 2024 495 | 496 | - [Plan commands](#plan-commands) 497 | - [Integrated file tree](#integrated-file-tree) 498 | - [New plan step indicators](#new-plan-step-indicators) 499 | - [Latest changes filter](#latest-changes-filter) 500 | - [Devcontainer tasks improvements](#devcontainer-tasks-improvements) 501 | - [VS Code: Planning & implementing](#vs-code-planning--implementing) 502 | - [URL task context](#url-task-context) 503 | - [Cancellation improvements](#cancellation-improvements) 504 | 505 | ### Plan commands 506 | 507 | In addition to adding/editing/deleting code, the `Plan` can now include terminal commands, whenever they're needed to properly complete a task. For example, if a task requires the use of a new 3rd-party dependency, then instead of editing a package manifest file (e.g. `package.json`), the plan will now suggest running the appropriate package manager (e.g. `npm install`). This has the advantage of ensuring you install the latest dependency version, as well as updating any respective lock files. 508 | 509 | Like everything else in CW, this new `Commands` section is fully editable, and so you can take, tweak, or ignore the provided suggestions. However, once you're happy with them, you can simply click the `Execute all` button, which will spin up the integrated terminal (if needed), run the commands, and then display their status. Any files that are edited as a result of these commands being executed, will then be displayed in the `Files changed` list, just like if you edited them directly 🙌 510 | 511 | 512 | 513 | > Note: This feature isn't currently enabled by default. So if you'd like to give it a try, you'll need to open your avatar menu in the upper-right, select `Experiments`, and then check the `Allow shell command generation in the plan` setting. 514 | 515 | ### Integrated file tree 516 | 517 | We've replaced the file explorer modal with a new integrated file tree, which is displayed as a right-side panel, and retains all of the same features as before (e.g. file name filtering, change annotations). This has the advantage of allowing you to navigate the repository's files, while simultaneously viewing the task/spec/plan and code. Additionally, when you select a file from the tree, it now opens the file as a tab. This is nice, because you can then immediately perform an NL revision to it, which makes the flow of editing new files extremely simple: filter for it in the tree, open it, then revise it 💙 518 | 519 | ![image](https://github.com/user-attachments/assets/24c299a9-54d8-4d15-8b35-f28489997403) 520 | 521 | ### New plan step indicators 522 | 523 | When you perform an NL revision against the plan, new plan steps are now annotated with a blue dot. This is meant to indicate that they are "unseen", and help focus your attention on the net-new changes that were made, as a result of your revision. This experience builds upon the previous change to make plan revision incremental, and we think it makes the overall iteration flow feel a lot more predictable (e.g. you don't have to try to spot what changes CW made based on your request). 524 | 525 | In order to prevent these dots from becoming noisy, they're only visible until the next time you 1) edit the plan, or 2) perform a subsequent revision/implementation. That way, they always indicate steps you haven't "seen", and don't accumulate as you further iterate on your session. Additionally, the dots aren't added to plan steps you add/edit yourself. And they don't persist across browser refreshes. That way, they simply represent AI-contributed changes, that were introduced by a just-made revision 👍 526 | 527 | 528 | 529 | ### Latest changes filter 530 | 531 | The `Files changed` section has a new filter called `Latest changes`, which allows you to focus on the edits that were made by the most recent NL revision/implementation. This makes it a lot easier to perform iterations, and then immediately see the impact of that change (as opposed to all the changes from the session). And when combined with the new plan step indicators, this makes NL revision a lot nicer, since you can perform a revision, and then quickly spot the resulting change in both the plan and the code. 532 | 533 | 534 | 535 | ### Devcontainer tasks improvements 536 | 537 | When you open the integrated terminal, the `Build`, `Test`, `Run` buttons are now always visible, even if the repo you're working against doesn't define them in a `devcontainer.json` file. And when you click any of them, CW will generate an AI-suggestion for the appropriate command(s) needed to run them (e.g. `npm run compile`). 538 | 539 | 540 | 541 | If the command looks right, then you can submit it, which will execute it in the terminal, and then persist it to the `devcontainer.json` file. You can then include this file in your PR/commit, and then all subsequent runs of that task (either build, test, or run) will be able to use this configured command in a single-click. The nice thing about this flow, is that it makes it easier for every repo to configure their build/test/run commands, without needing to remember how to do it. Simply click the buttons, and then let CW suggest and configure it for you 🚀 542 | 543 | 544 | 545 | ### VS Code: Planning & implementing 546 | 547 | The CW extension for VS Code now allows you to generate, regenerate, revise, and implement the plan. Entirely within the editor 🔥 We still require you to **start** sessions from the CW web/mobile client, but once you have a task started, you can resume it within VS Code, and perform the most common iteration operations from there. 548 | 549 | > Note: Since this extension is early, we're still not quite ready to publish it to the marketplace. We'll likely do that in the next couple of weeks, but until them, simply hit us up in [Discord](https://gh.io/next-discord) to grab the latest VSIX 😎 550 | 551 | ### URL task context 552 | 553 | When a task references URLs, they will now be displayed in the `Additional context` section of the `Task` panel. This ensures that you're always aware of any external context being considered, and you can control if it needed (e.g. deleting a link that is confusing the plan/etc.). 554 | 555 | 556 | 557 | > Note: By default, CW will spider URLs that point at GitHub issues, PRs, and repo files. However, if you want it to spider external web URLs, then you need to enable the `Utilize referenced generic web content in analysis` setting in the `Experiments` dialog (underneath your avatar menu). 558 | 559 | ### Cancellation improvements 560 | 561 | When a plan or implementation is in-progress, clicking the cancel button should now feel immediate. Additionally, if you cancel a file implementation mid-way, it will now revert the file back to its previous state (before editing it), as opposed to the previous behavior (which marked the file as `Cancelled`, and looked pretty weird). This is meaningful because when you perform an NL revision, CW automatically updates the plan and then implements it. And in order to make this UX feel delightful, we wanted to make sure you could cancel it at any time, and get the immediate/expected results. 562 | 563 | ## 📅 13 September 2024 564 | 565 | - [VS Code session continuation](#vs-code-session-continuation) 566 | - [Incremental plan revision](#incremental-plan-revision) 567 | - [Improved task context](#improved-task-context) 568 | - [New specification UX](#new-specification-ux) 569 | - [Planned file placeholders](#planned-file-placeholders) 570 | - [Branch switching](#branch-switching) 571 | - [Whitespace changes](#whitespace-changes) 572 | 573 | ### VS Code session continuation 574 | 575 | We're introducing a new VS Code extension, which allows you to resume CW sessions within your editor. This allows you to start tasks from the CW web app/PWA, and after feeling good about the implementation, finish the task from the comfort of your fully-configured dev environment (e.g. using your favorite extensions, color theme, keybindings, etc.) 🤗 576 | 577 | Additionally, this extension allows you to debug and run arbitrary client/desktop projects (e.g. mobile apps, Chrome extensions, etc.), without needing to push/pull the session's code to an intermediate branch. This works because the VS Code extension supports bi-directional file syncing with the CW service/web client. And so as you make changes in one client, they're immediately available in the other. Collectively, this allows you to start and finish work from whichever client is most convenient 😎 578 | 579 |
580 | 581 | > Note: This extension is very early, and therefore, we're not publishing it to the VS Code marketplace just yet. So if you'd like to give it a try and send us feedback, hit us up on the [GitHub Next Discord server](https://gh.io/next-discord) and we'll send you the VSIX. 582 | 583 | ### Incremental plan revision 584 | 585 | When you perform a NL revision (using the pretty input bar at the bottom 💙), the plan is now updated incrementally, as opposed to being completely regenerated. This not only makes it faster to perform iterations, but it also makes it clearer what did and didn't change as a result of your request. To get a sense for how much nicer this feels, check out the following demo 😻 586 | 587 | 588 | 589 | ### Improved task context 590 | 591 | The `Task` panel now includes an `Additional context` footer, which is visible when you open an issue (that has comments), or when you're working on a project that includes repository-wide instructions (e.g. a `.github/copilot-workspace/CONTRIBUTING.md` file). 592 | 593 | 594 | 595 | This is helpful, because it provides visibility into the external context that will be taken into account when analyzing/planning your task. Additionally, it lets you better predict and control the outcome of your session. For example, if you see a `Repository instructions` context item, then you can click it and immediately see the contents of the file (e.g. so you can know what it defines). And if you're working on an issue, that has comments you don't want included (e.g. becuase they're just "conversational noise"), then you can click the trash can icon next to them, and remove them consideration. 596 | 597 | ### New specification UX 598 | 599 | In order to simplify the CW workflow, we're removing the `Specification` panel from the timeline, and introducing it as optional context to the `Task`. That way, if your task description already defines the sufficient details for your intent, then you can jump straight to planning. However, if you'd like CW to help expand/ellaborate/explore on your description, then you can ask it to add a spec, and then treat that as additional input to the plan 🚀 (along with any comments and repo-wide instructions). 600 | 601 | Since this is a noticeable change, we're initially introducing it as an opt-in setting, which you can enable via the `Move specficiation to task panel` option in the `Experiments` dialog. When enabled, you'll see an `Add specification` button in the `Additional context` section of the `Task` panel. When you click that, it will generate the spec as usual, and then display a `Specification` entry in the context section for the task. If you click this, it will open the spec as a file tab, which let's you edit, revise, or regenerate the content. But with a much nicer, and full-screen view ⭐ 602 | 603 | 604 | 605 | ### Planned file placeholders 606 | 607 | After a plan has been generated, the `Files changed` section now immediately displays placeholders for all of the to-be-implemented files. This helps clarify the state you're in (i.e. there are files that are "planned", but not implemented), and creates a stronger association between the plan and the code. 608 | 609 | Additionally, the new `Planned` placeholders contain a delete icon, which let's you quickly delete a file from the plan. This is useful when using CW on mobile, and you want to delete a file from the implementation, without needing to switch back to the timeline view in order to do it. 610 | 611 | 612 | 613 | ### Branch switching 614 | 615 | You can now easily start a CW session against a new branch, by clicking the branch name label in the header bar. This will bring up a dialog with the list of all active branches, and when selected, starts a new task which targets that branch. 616 | 617 | 618 | 619 | ### Whitespace changes 620 | 621 | By default, whitespace changes are now visible within the file diff editors. This makes it easier to spot when Copilot (or you 😄) make any unintended changes to formatting, and can prevent any surprises after creating a PR. And if you'd like to turn this off (e.g. because a file has a lot of "whitespace churn"), you can click the settings icon in the `Files changed` section, and then select `Ignore whitespace changes`. 622 | 623 | 624 | 625 | ## 📅 30 August 2024 626 | 627 | ### Features / Enhancements 628 | 629 | * **Multi-file revision** - You can now select multiple files in the `Files changed` section, and perform an NL revision against them all. This makes it easier to make changes against multiple files, but in a very precise way (e.g. updating an implementation + associated tests, modifying a UI component and the places it's consumed). 630 | 631 | 632 | 633 | To use it, simply click the target icon (in the file header) for all of the files you'd lke to revise. You can then type your intent, and when submitted, all selected files will begin updating their code based on your request. 634 | 635 | * **File tabs** - You can now open a file in a full-screen tab, in order to view its contents more easily. This compliments the existing "stacked diffs" view (which is useful for gaining a high-level overview of the changes), and allows you to simultaneously browse a file, while also reading the spec/plan and/or using the terminal (which wasn't possible using the file explorer modal). 636 | 637 | 638 | 639 | To use it, simply click the arrow icon in a file diff's header, which will open that file in a new tab. Additionally, if you click a file link in the task/spec/plan panels, or select the `Open file` menu item for a file in the plan, then the selected file will now open in a tab (as opposed to the file explorer modal). 640 | 641 | 642 | 643 | Even cooler: the list of open files, and the currently active tab, are persisted as part of your session. So when you resume a session later, or share a session with others, the workspace will be in exactly the same place that you left it 💙 Check out [this example](https://copilot-workspace.githubnext.com/lostintangent/gitdoc/issues/77?shareId=910861ee-876e-428d-b25a-c388fa8cea84) to see what we mean. 644 | 645 | * **URLs in repo-wide instructions** - You can now include URLs in a repo-wide instruction file (`.github/copilot-workspace/CONTRIBUTING.md`), and those URLs will be fetched and included in the context of the session. This makes it easy to augment your repo instructions with documentation, or other reference materials, that can help inform all tasks/issues performed against it. 646 | 647 | * **Issue comments** - The `Issue` panel now displays how many comments the issue has (if any), and allows you to one-click navigate to them for more details. Copilot Workspace has always included issue comments as context for a session, but this change makes it easier to have visibility into when comments exist (since they may impact CW's understanding of the task). 648 | 649 | 650 | 651 | * **PR improvements** - We made a handul of improvements to the flow of creating and updating pull requests from Copilot Workspace. In particular... 652 | 653 | * The option to create a draft PR is now properly disabled, when working against repos that don't support them 654 | * When you update a PR, we no longer create a PR comment for the changes. We simply push a new commit with the specified (or generated) message 655 | * If you manually edit a file, we now automatically switch to `Unpushed` changes mode, when your session is continuing an existing PR (that way the diff view focuses on only net-new changes) 656 | 657 | ## 📅 23 August 2024 658 | 659 | ### Features / Enhancements 660 | 661 | * **Repo-wide instructions** - You can now define instructions for Copilot Workspace, that will be automatically applied to every issue or task performed against a repository. This allows you to document policies, suggestions, and other important guidelines that may not be evident from the codebase, but should always be considered. 662 | 663 | For example, the following screenshot shows a `Proposed` spec that indicates the need to update the `CHANGELOG.md`, despite the issue not mentioning this requirement. This is because the [repo's instructions](https://github.com/lostintangent/codeswing/blob/main/.github/copilot-workspace/CONTRIBUTING.md) define that all new features should include an entry in the changelog. 664 | 665 | 666 | 667 | To start using this feature, simply create the following file in your repository: `.github/copilot-workspace/CONTRIBUTING.md`. As the name suggests, this file acts as contribution guidance for Copilot, and allows you to include any context you think will be helpful 🧠 668 | 669 | By enabling teams to codify common or required guidelines, we hope to reduce mistakes, repetition, and learning barriers for all developers working across a project 🙌 670 | 671 | * **Terminal assist enhancements** - When you encounter an error in the terminal, and Copilot suggestions a change to the spec or plan, that suggestion will now be displayed as an editable diff of the spec/plan. This allows you to quickly understand what the suggestion is, and to easily tweak it as needed, before commiting the change. 672 | 673 | Additionally, if you encounter an error in the terminal that is trivial in nature, and therefore, doesn't justify an update to the spec/plan (e.g. lint errors, typos), then the terminal assistance will now suggest making direct edits to the neccessary files. For example, the following shows the suggestion after running a build, which failed due to a typo. Note that Copilot accurately recommends simply fixing the typo directly (as opposed to updating the plan): 674 | 675 | 676 | 677 | * **File explorer navigation** - The file explorer now supports filtering the tree view by a seach query. As you type, the file tree will be automatically filtered to the matching files, as well as the directories they're contained within. Additionally, directories are now annotated with a green or orange diff icon, to indicate when they contain an added or changed file (respectively). Collectively, these two enhancements should make it a lot easier to navigate codebases within CW (along with the existing support for go-to-definition in the editor). 678 | 679 | 680 | 681 | * **File search on mobile** - You can now easily search the contents of a file on mobile, by tapping the magnifying glass icon in the file's header bar. This has always been possible on desktop, by pressing `CMD+F` within the editor. But this new button provides the same navigation ability, regardless what device you're currently working from 📱 682 | 683 | 684 | 685 | * **Sticky toolbar** - The `Files changed` toolbar is now "sticky", which means that it stays visible as you scroll through the implemented files. This ensures that you can expand/collapse the timeline, discard the implementation, or toggle between split/unified diff view, without needing to scroll to the top of the files list to do it (which was obviously pretty annoying!). 686 | 687 | 688 | 689 | ## 📅 16 August 2024 690 | 691 | ### Features / Enhancements 692 | 693 | * **File regeneration** - The file toolbar now includes a regenerate button, which allows you to ask CW to "try again" with implementing it. This can be useful if you've revised the plan through NL, and noticed that CW may have missed a detail. Or, if you'd like to ask it to get a bit more "creative" with its interpretation of your intent 🎨 694 | 695 | The `Specification` and `Plan` panels already had a regenerate button, and so this change ensures that in addition to editing/revising/undoing, you can regenerate every piece of content within the workspace. 696 | 697 | 698 | 699 | * **Desktop notification** - You can now opt-into getting a system notification whenever a CW session is finished implementing (and the page isn't currently visible). This is useful if you're implementing a large plan, and want to switch to another task while it's running. But then know as soon as it's ready for your review 🏃 700 | 701 | 702 | 703 | To turn this on, simply click your avatar in the upper-right, select `Settings`, and then check the `Show notification after implementing` option. Your browser will ask for permission for CW to show notifications, and so make sure to approve that 👍 704 | 705 | 706 | 707 | * **Improved code search** - As a follow-up to supporting web URLs in the task definition, we've introduced an improvement to the way we perform code search, when analyzing the details of your issues/tasks. Depending on the codebase/scenario, this allows us to better identify the right set of files to edit (across the entire repo). And ultimately, can improve the quality/success-rate of CW. 708 | 709 | We're still refining this enhancement. And so for now, you need to opt-into it by clicking the beaker icon in the header bar, and checking the `Use code search during task analysis` setting. If you get a chance to turn this on, and use CW for a while, then we'd [love to hear](https://gh.io/next-discord) if you notice any improvements 💙 710 | 711 | 712 | 713 | * **Task authoring** - The `Task`/`Issue` panels now match the authoring experience for other markdown editors across GitHub (e.g. issue descriptions, PR comments, etc.). In particular, instead of requiring you to explicitly put the task into "edit mode", or requiring you to explicitly save it in order to preview the content, the panels now provide two tabs that you can seamlessly switch between: `Write` and `Preview`. 714 | 715 | 716 | 717 | * **Issue/PR status** - The workspace header now indicates the status of the issue and/or PR associated with a session, by coloring the issue and PR icons based on whether they're open (green) or closed/merged (purple). This can make it easier to spot if you accidentally opened an issue/PR that has already been completed. At which point, you can work on something else! 🙌 718 | 719 | 720 | 721 | ## 📅 9 August 2024 722 | 723 | ### External context 724 | 725 | When defining a task/issue, you can now include links to external references, and Copilot Workspace will use them as additional context when generating the spec, plan, and code. This makes it a _lot_ easier to express your intent, without having to copy & paste and/or summarize existing content (which can be non-trivial!). In particular, CW supports referencing the following types of assets: 726 | 727 | 1. *Issues / Pull Requests* - If you reference an issue/PR by number (e.g. `#43`) or URL, then CW will take into account it's description and comments. Additionally, if you link to a specific issue/PR comment, then CW will focus it's attention on just that one. This allows you to use an existing discussion/feedback as context, or work on "umbrella issues" that aggregate a set of sub-tasks together. 728 | 729 | 1. *Repository files* - If you reference the URL of a file in a GitHub repository (that you have access to), then CW will include that in its set of prioritized references. Additionally, you can include a link to a specific line ([example](https://github.com/lostintangent/codeswing/blob/b40dbeb3dbf5f133121605c751e1fa7c7a6f67ec/src/extension.ts#L16)) or range of lines in a file ([example](https://github.com/lostintangent/codeswing/blob/b40dbeb3dbf5f133121605c751e1fa7c7a6f67ec/src/preview/layoutManager.ts#L53-L62)), in order to focus CW on that exact code. This allows you to use existing code as a source of inspiration (e.g. "Implement an auth provider just like the one in "), and help steer Copilot in a more precise direction. 730 | 731 | 1. *Arbitrary web URLs* - If you reference a public web URL, then CW will fetch and use a summary of its content. Additionally, if you link to a specific fragment of a page (e.g. `#link-to-a-specific-heading`), then CW will extract and focus on just that section. This allows you to reference documentation/blog posts/tweets/etc. that can provide more recent and/or specific instructions of what you're trying to accomplish 💪 732 | 733 | ### NL revision 734 | 735 | After you implement a plan, Copilot Workspace now displays a natural language revision bar at the bottom of the `Files changed` section. This allows you to update the plan in complex and arbitrary ways, while remaining focused on reviewing the changes. 736 | 737 | 738 | 739 | Additionally, if you'd like to revise a specific file, you can click the bullseye icon in the file's header, which will put the NL revision bar into "scoped file" mode. 740 | 741 | 742 | 743 | Both of these changes are part of a larger theme to elevate/simplify the ability to iterate through natural language. And you can expect to see more improvements in this space in the coming weeks 👍 744 | 745 | ### Terminal repair improvements 746 | 747 | CW's terminal assistance can now perform updates to the plan, when you encounter an error that requires a code change. This can be helpful when a build/test/lint action fails, and you want Copilot to suggest a fix. While this capability is still early (and evolving!), we're excited to make steady progress towards a better workflow for automatically addressing errors. 748 | 749 | ### Exit path improvements 750 | 751 | When you create a PR/branch/repo, CW no longer generates a commit description by default. That way you can decide if you'd like Copilot to write a message for you, or if you'd prefer to craft your own 💙 752 | 753 | Additionally, when you create a PR for a session that's associated with an issue, the PR dialog now includes a checkbox that allows you to indicate whether the code changes fix the issue or not. When checked, CW will insert a `Fixes #` (which is what it did previously). 754 | 755 | 756 | 757 | ### SVG preview 758 | 759 | When you implement or open a `*.svg` file, you can now preview a rendered version of its contents, by clicking the eyeball icon in its header. We previously introduced preview support for Markdown, and plan to continue adding support for other file formats in the coming weeks (HTML? 🤔) 760 | 761 | 762 | 763 | ### Sessions + Settings 764 | 765 | The user menu (that you get to by clicking your avatar in the upper-right) now includes two new items: 766 | 767 | * `Your sessions` - This navigates you to the [CW dashboard](https://copilot-workspace.githubnext.com), so you can see your recent/bookmarked/completed sessions. We got feedback that folks weren't discovering the dashboard, and so we wanted to make this a bit more discoverable (since it's super useful!) 768 | 769 | 770 | 771 | * `Settings` - This opens a dialog with some optional user settings that can be enabled/disabled. To start, this dialog includes the existing options to automatically start a Codespace on session start/implement. But we also introduced a new setting called `Collapse timeline on implement`, which as the name implies, allows you to automatically collapse the left-side panel after implementing. 772 | 773 | When paired with the new NL revision bar, this setting allows you to enter a sort of "zen mode" for Copilot Workspace, where once you're happy with the plan, you can focus your entire screen on reviewing and revising the code 🚀 774 | 775 | 776 | 777 | ### Renamed files 778 | 779 | Renamed files are now collapsed by default in the `Files changed` section. This makes it easier to focus your attention on new and changed code, while simply seeing the presence of renamed or deleted files. If a file is both renamed + changed, then it won't be collapsed post-implement, so you can properly review its changes. 780 | 781 | 782 | 783 | ### Dark mode editor 784 | 785 | The code editor is now properly themed for users with a dark mode system setting. The editor's background was previously a medium greyish color, and now it's black 🖤 786 | 787 | ### Usage quota increase 788 | 789 | Due to popular demand, we've increased the daily usage quota again. That way, the folks that are using CW for many tasks every day, can keep sending us amazing feedback 🙏 790 | 791 | ## 📅 2 August 2024 792 | 793 | ### Features / Enhancements 794 | 795 | * **Terminal error assistance** - When you run a command in the terminal, and it fails (!), the lightbulb button will now turn red. This indicates that Copilot Workspace is aware of the error, and is ready to help you fix it 💪 796 | 797 |
798 | 799 | If you click on the lightbulb in this state, the terminal assistance UI will pop-up, and automatically generate a suggestion for how to address the issue. If the suggestion looks right, you can one-click accept it. Otherwise, you can refine the help instructions, or tweak the generated terminal command, to steer Copilot in the right direction. 800 | 801 | 802 | 803 | This experience can help you perform project and environment setup, correct your usage of CLI tools (seriously, who can remember all these args?), and even suggest modifications to the spec/plan. Over the coming weeks, we'll continue refining this capability even further, to ensure that debugging and repairing build/test/etc. errors is as simple and delightful as possible 🙌 804 | 805 | * **Recent repositories** - When you visit the [Copilot Workspace dashboard](https://copilot.workspace.github.com), the `Recent` tab now displays a section at the top called `Recent repositories`. This provides a list of your five most recently-active repos, and allows you to start a new task for them in a single click. When paired with the CW PWA, this makes it simple to begin/resume work using Copilot Workspace, without needing to create an issue, or search for the desired repo 🚀 806 | 807 | 808 | 809 | * **Implementation panel re-design** - The `Implementation` panel has been removed from the timeline, in favor of three UX enhancements, which _dramatically_ improve the usability of CW on mobile and in fullscreen-mode: 810 | 811 | 1. The "exith path" button has been moved to the upper-right corner of the workspace toolbar. This ensures that it's clear how to complete a task, regardless what state your workspace is in 👍 812 | 813 | 814 | 815 | 2. While an implementation is in-progress, the status indicator and stop button are now displayed at the bottom of the `Files changed` section. This ensures you can see/control the implementation at any-time, as opposed to just when you have the timeline opened + scrolled to the bottom. 816 | 817 | 818 | 819 | 3. The "discard all files" button has been moved to the left of the `Split | Unified` toggle in the `Files changed` section. That way, if you're reviewing code, and decide you want to try another approach, you can clear the session directly from there. 820 | 821 | 822 | 823 | * **List organization** - The spec and plan can now be fully re-organized, by clicking on the `...` menu for any sub-step, and choosing `Move item up` or `Move item down`. This won't impact the code generation in any way, and so you can feel free to order things however feels best/most intuitive to you. In particular, this can be useful when sharing a session with others, and you want to curate the spec/plan a bit for improved readability. 824 | 825 | 826 | 827 | * **Switching branches** - If you're working on a CW session, and realize you'd like to build upon a different branch, you can now click the `New Session` button, and select `Select a branch`. This will display a dialog with a list of the current repo's branches, and let you start a new ad-hoc task for the specified branch. 828 | 829 | 830 | 831 | * **Terminal status** - The terminal icon (in the workspace toolbar) now displays a green dot whenever the terminal is connected. Now that CW auto-start's the terminal (for repos that don't include a `devcontainer.json`), this allows you to quickly see when the terminal is ready, so you can jump into it and start building/running code. 832 | 833 | 834 | 835 | * **Experiments** - We periodically ship new features that are off by-default, since they're not quite ready for prime-time usage. And to make it easier to discover these features, and know when you have them on, the workspace toolbar now displays a beaker icon, that indicates how many experiments you have enabled. 836 | 837 | 838 | 839 | When clicked, this button brings up the `Experiments` dialog, which let's you try out our cutting-edge features (and then hopefully send us feedback!) 🔥 840 | 841 | 842 | 843 | * **Docs/changelog** - To make it easier to access the CW docs and changelog (the thing you're currently reading!), the user menu (in the workspace toolbar) now includes links for the `User manual` and `What's new?`. That way you can keep up with the fun, and see how we're addressing your feedback. But without needing to remember/search for random URLs in our [GitHub Next Discord](https://gh.io/next-discord) 🤗 844 | 845 | 846 | 847 | ## 📅 26 July 2024 848 | 849 | ### Features / Enhancements 850 | 851 | * [Session continuation](#session-continuation) 852 | * [Proceed to plan (task->plan)](#proceed-to-plan-task-plan) 853 | * [Optimized file viewers](#optimized-file-viewers) 854 | * [Spec/plan/code improvements](#specplancode-improvements) 855 | 856 | ### Session continuation 857 | 858 | When you create a repository/PR/branch from Copilot Workspace, we now provide two options for your next step: 859 | 860 | * Starting an entirely new session (for the current repo/PR/branch) 861 | * Continuing to iterate on the current session (this is the new part! 🙌) 862 | 863 |
864 |                          _Just created a PR? Let's stay in the flow!_ 865 | 866 | This is a _significant_ change to the CW workflow, and has the following key benefits: 867 | 868 | * It allows you to share context across multiple commits, and consolidate logically-related changes within a single session 869 | * It allows you to correct post-commit mistakes or address feedback, without having to create follow-up CW sessions 870 | 871 | In this sense, a CW session has evolved from being associated with a single commit, and is now logically associated with a branch, or chain of commits (for trunk-based development). This not only provides a lot more flexibility, but also, reflects the way that many developers wanted to use it. So we're excited to hear feedback! 872 | 873 | 874 | 875 |    _A single CW session that lead to a PR + follow-up commit_ 876 | 877 | To make this multi-commit workflow even more fun...when you implement changes to a CW session (that was already pushed to a repo/PR/branch), you'll see a new `All | Unchanged` toggle button in the toolbar. This allows you to easily see the changes for the most recent iteration, as opposed to the changes for the overall session (which could now include multiple commits). 878 | 879 | For example, if you have a CW session that you created a PR from, you could address PR feedback in that same session, quickly review those exact changes, and then confidently push an update to the PR (after running/testing it in the terminal!) 880 | 881 | 882 | 883 |    _Reviewing a readme update to an existing PR/CW session_ 884 | 885 | --- 886 | 887 | ### Proceed to plan (task->plan) 888 | 889 | When you start an ad-hoc task (opening a repo/PR/branch in CW, as opposed to an issue), you can now choose to skip generating a spec, and proceed directly to planning 🏃 890 | 891 | 892 | 893 | This helps CW feel a lot more optimized, for tasks that fall into the following categories: 894 | 895 | * They're simple or precise in nature (e.g. `Rename the readme and translate it into German`) 896 | * They're very well-defined/articulated (e.g. you write a paragraph/bullet points for the desired behavior) 897 | 898 | In these cases, you likely don't need a summary of the task (because you just wrote it!), or help fleshing out the success criteria (because it's simple!). And in those instances, CW should now feel a lot faster, more lightweight, and easier to iterate 🚀 899 | 900 | When you proceed directly to the plan, the `Specification` panel will still be displayed in the timeline, but it will be greyed out. And if you review the plan/code, and realize that you actually do need a bit more help investigating the task, then you can expand the `Task` panel and select `Add Specification`. That way the spec feels helpful if/when needed, but not required 👍 901 | 902 | 903 | 904 | _The CW timeline, with the `Specification` panel skipped, as we went from task->plan_ 905 | 906 | When you open an issue, CW continues to generate a spec as the first step, and doesn't give you the option to skip it. This is because issues are much more complex and ambiguous in practice, and therefore, they commonly benefit from the summarization/contextualization/thinking that the spec panel offers. 907 | 908 | --- 909 | 910 | ### Optimized file viewers 911 | 912 | When you implement a plan, the `Files changed` list now includes two key improvements, to make it easier to review the code: 913 | 914 | * Added/renamed files are displayed using a code editor (as opposed to a diff editor) 915 | * Deleted files are automatically collapsed, so they don't clutter up the list 916 | 917 | These changes also make it easier to edit code post-implement, since it's a lot nicer to write code in a standard editor vs. a diff editor. Especially with the help of CW's integrated language services + Copilot completions 💙 918 | 919 | 920 | 921 |    _Reviewing added/deleted files in a more natural/distraction-free way_ 922 | 923 | --- 924 | 925 | ### Spec/plan/code improvements 926 | 927 | We made numerous improvements to the way we generate the spec and plan, which should increase the quality a bit, for both larger repos and complex tasks. Additionally, we improved our code generation, so that it shouldn't delete unrelated code/comments when implementing a task. 928 | 929 | Finally, after enabling speculative decoding a few weeks ago, we've confirmed that it's stable enough to be on by default, and we've removed it from the `Experiments` panel. That said, we really appreciate all the great feedback from preview users, as we've continued to focus on improving the perf and quality of code generation 🙏 930 | 931 | ## 📅 12 July 2024 932 | 933 | ### Features / Enhancements 934 | 935 | * **Markdown preview** - The file explorer and file diffs now include support for previewing Markdown content. This allows you to easily visualize how formatting with look (e.g. tables), when you're adding or editing docs. 936 | 937 | To use it, simply click the eye icon in the toolbar above the file. And over time, you can expect to see this icon appear for other file types, as we expand the preview support 🚀 938 | 939 | ![image](https://github.com/user-attachments/assets/f887fcb6-aaf6-4cba-b103-2c65e8eee839) 940 | 941 | * **Codespaces auto-start** - We now automatically spin up a Codespace when you click the `Implement` button, as opposed to waiting until you open the terminal. This has the benefit of providing language services when reviewing code (e.g. hover info, error squiggles, go-to-definition), and making the terminal available as soon as you need it (e.g. to build the code after it's done implementing). 942 | 943 | ![image](https://github.com/user-attachments/assets/c3045665-ac26-41cf-9670-41bda8ebf518) 944 | 945 | _The little green dot indicates that you're session is enriched with language services, thanks to the auto-started Codespaces!_ 946 | 947 | > Note: If a repo includes a `devcontainer.json` file, we don't currently auto-start the Codespace. We'll be adding support for that soon, but in the meantime, you can enable this by checking the `Spin up a codespace on start of implement` setting in the `Experiments` panel. 948 | 949 | * **Increased usage quota** - In order to enable power users to get the most out of Copilot Workspace, we've doubled the daily usage quota. We were seeing lots of cases of folks hitting their limit, and so we're excited to unblock that, and let to AI-assisted creativity flow more freely 💙 950 | 951 | ### Bug Fixes 952 | 953 | * **Exit path dialogs** - When you attempt to create a PR/branch/commit/repo from a Copilot Workspace session, the modal dialog will no longer automatically close when you click outside of it. That way you don't lose any work (e.g. a PR description) as a result of an accidental click/drag. 954 | 955 | * **File explorer view toggle** - When you open a file in the file explorer, the `Code / Diff` toggle button now works correctly for added/edited files. 956 | 957 | * **Invalid markdown in tasks** - If an issue/task includes invalid markdown for image references, Copilot Workspace is now resilient to that, and will simply render it as a broken image. 958 | 959 | * **Resuming interrupted sessions** - If you accidentally close a session while it's in the middle of generating the spec, Copilot Workspace will now automatically resume spec generation once you re-open it. 960 | 961 | ## 📅 3 July 2024 962 | 963 | This week's release is all about performance and quality. So when you use Copilot Workspace, things should feel **noticeably faster** overall. And also, a little bit smarter 😎 964 | 965 | | For example... | Before today | After today | 966 | |-|-|-| 967 | | Generating the code for [this session](https://copilot-workspace.githubnext.com/lostintangent/gistpad?shareId=3538ee23-b72f-4681-932a-b293e7418f82) | ~9.5 minutes | ~2 minutes (-7.5 minutes 🔥) | 968 | | Generating the plan for [this session](https://copilot-workspace-staging.githubnext.com/altryne/openai-cookbook?shareId=7e46d597-7a68-41d2-b95c-66bdd2b8a4bc) |~33 seconds | ~15 seconds (>2x speed-up) | 969 | | Generating the spec for [this session](https://copilot-workspace.githubnext.com/lostintangent/github-security-alerts/issues/10?shareId=7a84f35c-a612-4ea3-ae0f-2505786819ee) | ~15 seconds | ~6 seconds (>2x speed-up) | 970 | 971 | What contributed to these gains? 972 | 973 | * We migrated to GPT-4o, and made numerous improvements to spec/plan/code generation 974 | * We introduced "speculative decoding" for code generation _(read below for details)_ 975 | 976 | ### Speculative decoding 977 | 978 | We [previously shipped](https://github.com/githubnext/copilot-workspace-user-manual/blob/main/changes.md#perf-improvements) an experiment called "speculative decoding", which provided a 2x+ speed-up on code generation. That experiment is now on by default, and is a key part of the boost you'll see when implementing a plan. 979 | 980 | With this enabled, Copilot Workspace now predicts the "edit locations" within a file, as opposed to re-generating every line. This allows us to retain the stability of whole-file generation, but with a **dramatic improvement** in performance. 981 | 982 | Additionally, to indicate when Copilot Workspace is predicting the next edit location (vs. editing code), the progress bar will display a "barber pole" overlay. That way, you know when it's thinking hard on your behalf ❤️ 983 | 984 | ![image](https://github.com/user-attachments/assets/153095d2-8300-4703-8d0a-ae53ba2771fc) 985 | 986 | ### File copy operations 987 | 988 | When a task/issue includes the need to copy a file, this should now work as expected. Previously, Copilot Workspace would incorrectly attempt to rename the existing file. And now, it will translate the copy operation into the creation of a new file, that includes a step for copying the contents of the originating file (along with any subsequent edits). 989 | 990 | For example, here's a [sample session](https://copilot-workspace-staging.githubnext.com/githubnext/hello-world?shareId=a071696d-32e6-4428-9b0f-e09dbf61e1aa) that copies a file, and translates it's `console.log` messages into Japanese: 991 | 992 | 993 | 994 | ## 📅 28 June 2024 995 | 996 | ### Features / Enhancements 997 | 998 | * **Copilot completions and language services in embedded editors** - Support for rich language features (hover info, error squiggles, go-to-definition) and Copilot completions are now enabled by default. This was previously released as an opt-in experiment, and thanks to the amazing feedback from preview users, it's now ready for general usage 🎉 999 | 1000 | 1001 | 1002 | A few things to note: 1003 | 1004 | * Copilot completions are supported in all languages, but the other editor features currently only support JS/TS, Python, and Go. We'll be introducing support for other languages soon, and so let us know which ones you'd like to see next 💪 1005 | 1006 | * The rich editing features are only enabled when a terminal/Codespace is attached to your session. So if you'd like to use them, either manually open the integrated terminal, or enable one of the `Spin up a codespace...` experiments. And in either case, you can tell that rich editing is "activated", because you'll see a cool little green dot in the upper-right of the `Files changed` section. 1007 | 1008 | 1009 | 1010 | * In addition to stabilizing the existing feature set, we've also expanded the editing experience quite a bit. So read on for details about that! 1011 | 1012 | * **Auto-completion / signature help** - When editing code within Copilot Workspace, you'll now see auto-completion everywhere you'd expect. And also, when you call functions, you'll see the editor overlay that describes its signature details. This, along with the existing Copilot completions support, should make it a lot nicer to make any last minute tweaks, before sending out a PR 🚀 1013 | 1014 | 1015 | 1016 | * **Error squiggles on mobile** - When using Copilot Workspace from your phone, you can now place your cursor over an error squiggle in an editor, and correctly see the details of the issue. With this in place, we now have full parity for rich editing, between desktop and mobile 📱 1017 | 1018 | 1019 | 1020 | * **Go-to-definition for external dependencies** - When you perform a go-to-definition on a 3rd-party API (e.g. an NPM package), it will now correctly navigate to the corresponding type definition. That way, you can inspect the API surface for any dependencies, without needing to leave the workspace. 1021 | 1022 | 1023 | 1024 | _Note: This will only work once you've restored app dependencies from the terminal and/or if your repo includes a `devcontainer.json` file that does this automatically._ 1025 | 1026 | * **Copilot in Codespaces** - When you open a session in a Codespace, the [Copilot](https://marketplace.visualstudio.com/items?itemName=GitHub.copilot) and [Copilot Chat](https://marketplace.visualstudio.com/items?itemName=GitHub.copilot-chat) extensions are now automatically installed for you. That way, you can edit along with Copilot in the workspace, and then seamlessly continue doing that in a Codespace, without any additional setup. 1027 | 1028 | 1029 | 1030 | * **Renaming files** - Copilot Workspace now understands when a file is being renamed, but doesn't need to be edited. And in those cases, it can perform the rename immediately, as opposed to AI-generating it's contents. This results in a big perf boost for plans that include simple renames, and is a follow-up to the optimizations we made for deleting files. 1031 | 1032 | 1033 | 1034 | * **Session management** - You can now delete a session from within the workspace, by clicking the `New Session` button and selecting `Delete Session`. This was already possible from [the dashboard](https://copilot-workspace.githubnext.com), but this new entrypoint makes it easier to clean up sessions once you're done with them. 1035 | 1036 | 1037 | 1038 | ## 📅 14 June 2024 1039 | 1040 | ### Features / Enhancements 1041 | 1042 | * **Terminal command suggestions** - In order to make it easier to use the terminal (including from your phone!), you can now describe an action you’d like to perform (e.g. `Build the project`, `List all markdown files in the src directory`), and let Copilot suggest the corresponding shell command. And just like everything else in Copilot Workspace, you can edit or regenerate the suggestion, to make sure you get exactly what you’re looking for 🚀 1043 | 1044 | 1045 | 1046 | * **Devcontainer tasks** - To make it simpler to run common/repeated terminal commands, a repository can now define `tasks` in its `devcontainer.json` file, which configure the shell commands needed to perform a build, test, and/or run against it ([example](https://github.com/lostintangent/contributor-gallery/blob/main/.devcontainer/devcontainer.json)). 1047 | 1048 | When defined, these tasks will appear as buttons in the integrated terminal, so that validating code changes becomes as simple as a couple clicks. Even cooler, you can edit the `devcontainer.json` file directly within Copilot Workspace, and any new/changed tasks will appear immediately 💪 1049 | 1050 | 1051 | 1052 | * **Copilot completions on mobile** - When manually editing code from your phone, you can now make use of Copilot completions, thanks to a new `Accept` button which appears anytime a Copilot suggestion is visible in the editor. 1053 | 1054 | 1055 | 1056 | _Note: In order to make use of Copilot completions, you need to check the `Enable Copilot and language services in editors` option in the `Experiments` dialog (which is available when clicking on your avatar in the upper-right)._ 1057 | 1058 | * **Simplified branch tasks** - When you start a task from the GitHub repository page, Copilot Workspace will now respect the currently selected branch. That way, you can easily perform any tasks, against any branch 🔥 1059 | 1060 | 1061 | 1062 | ### Perf Improvements 1063 | 1064 | * **Speculative decoding** - We're working to improve the feedback loop when implementing a plan. And as part of that, we've introduced a new experiment that should speed up code generation by ~2.5x (!!). We'll be turning this on by default soon, but for now, you can try it out by checking the `Use speculative decoding to speed up implement` option in the `Experiments` dialog (which you can access by clicking your avatar in the upper-right). 1065 | 1066 | * **New Session** - When you click the `New Session` button from the [Copilot Workspace dashboard](https://copilot-workspace.githubnext.com), your MRU list of repositories should show up immediately, since we now pre-fetch/cache them in advance. That way, starting a new session is 2-3 faster 🏎️ 1067 | 1068 | ## 📅 24 May 2024 1069 | 1070 | ### Features / Enhancements 1071 | 1072 | * **PWA support** - You can now install Copilot Workspace on your desktop or mobile home screen, and have a more native app-like feel (e.g. no browser chrome, no accidental back navigations when swiping left, better keyboard handling). This also makes it easier to jump back into in-progress tasks, from any of your devices 💙 1073 | 1074 | To get started, simply navigate to the [Copilot Workspace dashboard](https://copilot-workspace.githubnext.com), and then either click the `Install Copilot Workspace` button in the navigation bar (on desktop), or click `Add to Home Screen` from the share menu (on mobile). 1075 | 1076 | ![image](https://github.com/githubnext/copilot-workspace-user-manual/assets/116461/399ff59d-08b7-464a-9eed-cc5b1b3f2260)
1077 |   _Working on a task in a beautiful Copilot Workspace PWA from your desktop_ 😻 1078 | 1079 |   
1080 |   _Copilot Workspace nestled comfortably on the iOS dock_ 1081 | 1082 | * **Organizing the plan** - You can now re-order the plan by moving files up or down in the list. And since the `Files changed` list is also sorted by the plan, this allows you to better organize sessions for both self-review, but also, to better curate them when sharing sessions with others (like [this](https://copilot-workspace.githubnext.com/lostintangent/gitdoc/issues/52?shareId=94b2e8df-15ea-41bd-b5f6-a1d9f5b376dc)!). 1083 | 1084 | When you actually implement the plan, Copilot Workspace will determine the most logical order to make edits in (e.g. creating shared functions/components, before editing their consumers). So you can feel free to organize the plan in whichever way feels best to you, and rest assured that Copilot will continue to do the right thing 🙌 1085 | 1086 |
1087 |   _Updating the order of files in a plan_ 1088 | 1089 | * **Enhanced social preview image** - When you share a Copilot Workspace session on Slack/Teams/Twitter/SMS/etc. (like [this one](https://copilot-workspace.githubnext.com/lostintangent/gitdoc/issues/52?shareId=94b2e8df-15ea-41bd-b5f6-a1d9f5b376dc)!) the preview now displays a customized image for the repo and task it’s associated with _(for public repos)_. It also now includes a warp speed background, since clicking on the link is sort of like transporting you into another space 🚀 (and of course, it just looks cool...) 1090 | 1091 |
1092 | _Sharing a Copilot Workspace session with someone in Slack_ 1093 | 1094 | ### Bug Fixes 1095 | 1096 | * **Manually adding files to the plan** - The `Add file to plan` dialog now correctly detects existing file paths in all cases, and makes it easy to add/edit/rename/delete files from the plan. 1097 | 1098 | * **File syncing for long-ish running sessions** - The bi-directional file syncer (that syncs changes between the Workspace and the terminal) now properly syncs files for sessions, when the `HEAD` of the branch has since progressed. This makes it easier to work on Workspace sessions throughout the day, or across days, regardless how active the target branch is 💪 1099 | 1100 | ## 📅 17 May 2024 1101 | 1102 | ### Features / Enhancements 1103 | 1104 | * **Revise the spec, plan, and code with natural language** - In addition to making direct edits to the specification or plan, you can now provide natural language instructions for how you'd like to revise them (e.g. `Add tests for this change`). This same capability is also available on the header for changed files, which allows you to revise code based on a specific instruction (e.g. `Move the logging logic into a separate function`), in addition to editing it manually. 1105 | 1106 | ![image](https://github.com/githubnext/copilot-workspace-user-manual/assets/116461/883e48a1-265c-4b12-bfaa-4c70e4ec2317) 1107 | 1108 | * **Copilot completions and language services in embedded editors** - We've shipped an initial experience for getting hover info, error squiggles, go-to-definition, and Copilot completions directly from the embedded editors in Copilot Workspace. That way you can quickly spot issues to fix, easily navigate the code changes, or make manual edits, while receiving the Copilot assistance you know and love 💙 1109 | 1110 | ![image](https://github.com/githubnext/copilot-workspace-user-manual/assets/116461/1fd21aa6-028c-44c7-ac9e-3fa55249c914) 1111 | 1112 | Here's a few things to note about this enhancement: 1113 | 1114 | * It isn't on by default, and so if you want to try it, you need to click on your avatar in the upper right, select `Experiments` and then check the `Enable Copilot and language services in editors` setting. 1115 | * The language services (hover info, error squiggles, go-to-definition) currently only support JavaScript/TypeScript, Python and Go. But more languages are coming! 1116 | * Support for Copilot completions requires an active Copilot subscription. If you don't have one, then you simply won't see "ghost text" in the editor, but you can still use the language services described above. 1117 | 1118 | * **UX layout persistence** - When you collapse changed files and/or minimize the timeline, that UX state is now properly persisted for the session. That way, when you return to a session later, you can pick up exactly where you left off. Or if you share a snapshot with someone else, you can curate the UX to look exactly how you want them to see it 🚀 1119 | 1120 | ![image](https://github.com/githubnext/copilot-workspace-user-manual/assets/116461/529c4aef-19ca-47b1-8d07-47bd6eab799b) 1121 | 1122 | * **Redesigned progress indicator for file implementation** - When a file is currently being implemented, we now display a progress bar underneath it to better visualize the status of the code generation. Additionally, when an existing file is being edited, we now properly display the delta of code changes that were added. 1123 | 1124 | ![image](https://github.com/githubnext/copilot-workspace-user-manual/assets/116461/b58a8c2a-24b7-4cf3-84fb-46a9c4b81daa) 1125 | 1126 | ![image](https://github.com/githubnext/copilot-workspace-user-manual/assets/116461/f725a6ca-2a31-4603-b602-d88c9736c8f8) 1127 | 1128 | * **Easier code review on mobile** - When viewing a multi-file session on a mobile device, you can now click an implemented file to view the changes in a full-screen editor, and then easily page between the other files that were edited. 1129 | 1130 | 1131 | 1132 | * **The "topic" now renders markdown** - The question/task that is displayed at the top of the `Specification` panel is now rendered properly when it includes markdown. In particular, it's common for this to include backticks when the task definition refers to a symbol using them. 1133 | 1134 | 1135 | 1136 | * **Add manually edited files to the plan** - In addition to generating code changes with AI, Copilot Workspace allows you to manually edit files through its file explorer and/or the integrated terminal. And in order to make it easier to include these manually edited files in the plan (e.g. so you could do further AI-assisted iteration on them), they now include a `+` button in their header bar, which let's you one-click add them to the plan. 1137 | 1138 | 1139 | 1140 | * **Share links now include the repo and title in their preview** - If you share a session link with someone via Twitter, Slack, Teams, SMS, etc. the preview that is displayed to them will now properly include the repository that the session is associated with, and the title of the session. That way, it's a little bit clearer what you're sharing, before they actually click it. 1141 | 1142 | 1143 | 1144 | * **Improved status messages for panels** - Whenever you generate/regenerate/revise the spec/plan, or implement files, those steps now display more helpful status messages. 1145 | 1146 | ## 📅 9 May 2024 1147 | 1148 | ### Features / Enhancements 1149 | 1150 | * **Support for very large repositories** - The first release of Copilot Workspace only worked up to limited repository size. These limitations are now largely lifted. 1151 | 1152 | * **Copilot Workspace will now process "delete" operations efficiently** - Copilot Workspace will now process 'delete' operations more promptly, without making any unnecessary model invocations. 1153 | 1154 | * **Color the `Issue` and `Pull Request` panel icons based on their state** - When opening an issue or pull request within Copilot Workspace, we'll now indicate the state of the issue/PR, using the same colors as GitHub.com: open (green), completed/merged (purple), closed (red), and closed as not planned (grey). That way, the status of the issue/PR will be immediately clear 👍 1155 | 1156 | 1157 | 1158 | *Opening an issue that's closed as completed* 1159 | 1160 | 1161 | 1162 | *Opening a pull request that's been closed* 1163 | 1164 | ### Bug Fixes 1165 | 1166 | * **Fix session reload for any session not on default branch of repository**. A user reported that Copilot Workspace could not reload sessions if they were associated with a non-default branch of a repository. This is now fixed. 1167 | 1168 | * **Fix virtual keyboard overlaying editor**. A fix was made for mobile where the virtual keyboard was obscuring some of the file editor. 1169 | 1170 | * **Fix scroll to implementation**. "Scroll to implementation" for a step of the plan was not working as expected. This is now fixed. 1171 | 1172 | * **Numerous mobile layout fixes**. Many subtle but important fixes have been made to layout and interaction on mobile devices. 1173 | 1174 | ## 📅 29 April 2024 1175 | 1176 | Initial release! 🚀 1177 | -------------------------------------------------------------------------------- /codespaces-guide.md: -------------------------------------------------------------------------------- 1 | # Codespaces Starter Guide 2 | 3 | This document contains useful information for using the terminal/Codespace in your Workspace session. 4 | 5 | ## Codespaces Limits 6 | 7 | ### Overall Usage 8 | 9 | The technical preview includes limited free Codespaces compute usage that is reset at the start of the calendar month. 10 | 11 | ### Overall Limits 12 | 13 | The technical preview enforces a total Codespaces and total active Codespaces limits that you may encounter. If closing Workspace sessions does not resolve these issues you may reach out to us [here](https://github.com/githubnext/copilot-workspace-user-manual?tab=readme-ov-file#feedback). 14 | 15 | ### Organization based limits and policies 16 | If the Organization that owns the repository has set policies for Codespaces usage they will be applied to being able to create Codespaces for Workspace. You should reach out to an administrator of the organization to adjust any policies. 17 | 18 | ## Common Errors 19 | 20 | #### You've reached your Copilot Workspace usage limit 21 | 22 | At the start of the next calendar month your free usage limit will reset and you can continue using Workspace. You may reach out to us and give us feedback about the usage limit [here](https://github.com/githubnext/copilot-workspace-user-manual?tab=readme-ov-file#feedback). 23 | 24 | #### Limit of active Copilot Workspace reached. 25 | 26 | Remediate this by closing open Workspace sessions and allowing previous sessions to shutdown before creating new ones. 27 | 28 | #### Limit of Copilot Workspace reached. 29 | Remediate this by closing open Workspace sessions and allowing previous sessions to shutdown before creating new ones. 30 | 31 | #### Repository may not be used for a Codespace 32 | 33 | This may be because of a repository or organization policy restricting Codespaces creation. Please check any settings in the organization or repository that may be preventing Codespaces usage. If you do not find any please reach out to our [technical 34 | preview feedback channels](https://github.com/githubnext/copilot-workspace-user-manual?tab=readme-ov-file#feedback) for assistance. 35 | 36 | #### The assigned location is currently unavailable. 37 | 38 | You may try again in a few minutes. Additionally, you can change your default Codespaces region in your user settings if you continue to run into this error for a particular region by following these [public docs](https://docs.github.com/en/codespaces/setting-your-user-preferences/setting-your-default-region-for-github-codespaces). 39 | 40 | #### Provided `devcontainer.json` cannot be parsed to valid JSON 41 | 42 | In the chosen repository you may need to fix the `devcontainer.json` for syntax errors. You can read more about `devcontainer.json` syntax in the following [public docs](https://docs.github.com/en/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers). 43 | 44 | #### The organization has enabled OAuth App access restrictions, meaning that access to Copilot Workspace is limited. 45 | 46 | Reach out to the organization administrator to give access to the Copilot Workspace OAuth app. 47 | -------------------------------------------------------------------------------- /creating-repos.md: -------------------------------------------------------------------------------- 1 | # Creating Repositories from Templates 2 | 3 | Copilot Workspace allows you to create repositories from templates using natural language. 4 | 5 | ## Using "Use this template" from GitHub.com 6 | 7 | To create a repository with Copilot Workspace, you can navigate to a template repository in GitHub.com and choose “Use this template”, like this: 8 | 9 | Create repository from template
*Creating a repository from a template via Copilot Workspace* 10 | 11 | The task is based on the description of the software to create, plus the README of the template repo. You can also start this kind of task by creating a [new session](#using-new-session-on-the-dashboard). Once started a create repository task looks like this: 12 | 13 | Repo task timeline representation
*The task is labeled as “Repository”, and the “Template” panel indicates the template repo* 14 | 15 | Copilot Workspace will then generate a specification for the repository based on the description you provide, and a plan for creating it, and then the final implementation. 16 | 17 | ## Using "New session" on the dashboard 18 | 19 | You can also create a repository from a template by clicking the “New session” button in the [Copilot Workspace dashboard](https://copilot-workspace.githubnext.com), and search for a template. This will open a new task in the workspace where you can describe the software you want to create. 20 | 21 | ## Using the URL 22 | 23 | You can also turn on “Create Repository” mode for any repository URL by adding `?template=true` as a query parameter. For example: 24 | 25 | https://copilot-workspace.githubnext.com/githubnext/hello-world?template=true 26 | 27 | For incoming URLs, some repositories are treated as templates by default: 28 | 29 | - Any GitHub template repository 30 | - Any repository in an organization containing `templates`, upper or lower case, with dash at start or end 31 | - Any repository with `-template`, `-scaffold`, `-starter` or `-boilerplate` in its name, upper or lower case, with dash at start or end 32 | -------------------------------------------------------------------------------- /experiments.md: -------------------------------------------------------------------------------- 1 | # Experiments 2 | 3 | Copilot Workspace is a technical preview and is under active development. This document lists some known issues and known areas where we'd like to make future improvements. 4 | 5 | We will be doing ongoing continuous releases of Copilot Workspace during the technical preview, adding new features, new experiments and fixing bugs as we go. 6 | 7 | We greatly appreciate any [feedback](https://github.com/githubnext/copilot-workspace-user-manual?tab=readme-ov-file#feedback) on these experiments, as it helps us improve Copilot Workspace and make it more useful for you. 8 | 9 | ## Active experiments 10 | 11 | There are several active "Experiments" available related to things we are working on. We invite you to activate these and will update this document with new experiments when they are available. These features aren't set in stone, and any feedback regarding them would be greatly appreciated. 12 | 13 | ### Use line numbers always (🥼) 14 | 15 | We are experimenting with a feature that allows Copilot Workspace to always use line numbers when generating code. Enable this using the "Use line numbers always" feature in Copilot Workspace. 16 | 17 | ### Use emoji in topic and specs (🥼) 18 | 19 | We are experimenting with a feature that allows Copilot Workspace to use emoji in the topic and specifications. Enable this using the "Use emoji in topic and specs" feature in Copilot Workspace. 20 | 21 | ### Utilize linked issues, PRs, and GitHub file links in analysis (🥼) 22 | 23 | We are experimenting with a feature that allows Copilot Workspace to utilize linked issues, pull requests, and GitHub file links when analyzing tasks. This allows CW to have more context related to linked issues, PRs, and GitHub file links in analysis. Enable this using the "Utilize linked issues, PRs, and GitHub file links in analysis" feature in Copilot Workspace. 24 | 25 | ### Utilize referenced generic web content in analysis (🥼) 26 | 27 | We are experimenting with a feature that allows Copilot Workspace to utilize referenced generic web content when analyzing tasks. Currently, the contents of the URL are summarized and given to Copilot Workspace, in order to aid Copilot Workspace more focused on relevant details. 28 | 29 | ### Use code search during task analysis (🥼) 30 | 31 | We are experimenting with a feature that allows Copilot Workspace to utilize code search during task analysis. This helps Copilot Workspace identify relevant files and code snippets more effectively, improving the overall accuracy and relevance of the generated specifications and plans. Enable this using the "Use code search during task analysis" feature in Copilot Workspace. Note that this experiment may result in slower completion times for spec/plan generation, but will cause Copilot Workspace to be more "focused" on your codebase. 32 | 33 | ### Clarify ambiguous specifications (🥼) 34 | 35 | We are experimenting with a feature that allows Copilot Workspace to detect and warn about ambiguous specifications, in cooperation with the user. Enable this using the "Clarify ambiguous specifications" feature in Copilot Workspace. 36 | 37 | ### Allow skipping the spec and going straight to plan (🥼) 38 | 39 | We are experimenting with a feature that allows users to skip the specification step and go straight to the plan. This is especially useful if you have already written a very detailed task description and want Copilot Workspace to go straight to implementing the task. Enable this using the "Allow skipping the spec and going straight to plan" feature in Copilot Workspace. -------------------------------------------------------------------------------- /getting-started.md: -------------------------------------------------------------------------------- 1 | # Getting Started with Copilot Workspace 2 | 3 | Welcome to the technical preview for Copilot Workspace (CW)! 👋 CW is a "task-centric" dev environment, which allows you to define a task for a repo (using natural language), and then work on it with AI. And to get started, you can define or begin a task using one of the following entrypoints: 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 14 | 17 | 18 | 19 | 22 | 25 | 26 | 27 | 30 | 33 | 34 |
EntrypointScreenshot
12 | GitHub Issue

If you've already got a GitHub issue which describes a task you'd like to perform, then you can simply open the issue and click the "Open in Workspace" button on the right side panel (underneath the "Development" section).

This will open the issue within Copilot Workspace, and begin analyzing how to solve it. 13 |
15 | 16 |
20 | Ad-hoc task (CW dashboard)

If you open the Copilot Workspace dashboard, you can click the "Choose a repository" option underneath the "Start a new session" section. This will let you search for the repository you want to work on, and after selecting it, will allow you to define a new task from scratch (kind of like a draft issue).

And after you've performed a task against a repository, it will appear in the session list under the "Start a new session" section on the dashboard. That way, you can easily start new tasks against projects you're actively working on. 21 |
23 | 24 |
28 | Ad-hoc task (repo page)

As an alternative to the previous entrypoint, you can also navigate to the repository page for the project you'd like to work on, click the green "Code" button, and enter in a new task from the "Copilot" tab. Once you submit the task, it will take you into Copilot Workspace and begin analyzing how to solve it. 29 |
31 | 32 |
35 | -------------------------------------------------------------------------------- /images/adhoc-tasks/ad-hoc-task-full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/adhoc-tasks/ad-hoc-task-full.png -------------------------------------------------------------------------------- /images/adhoc-tasks/ad-hoc-task.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/adhoc-tasks/ad-hoc-task.png -------------------------------------------------------------------------------- /images/adhoc-tasks/adhoc-task-timeline-representation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/adhoc-tasks/adhoc-task-timeline-representation.png -------------------------------------------------------------------------------- /images/creating-repos/create-repo-from-template.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/creating-repos/create-repo-from-template.png -------------------------------------------------------------------------------- /images/creating-repos/repo-task-timeline-representation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/creating-repos/repo-task-timeline-representation.png -------------------------------------------------------------------------------- /images/further-techniques/ambiguous-spec.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/further-techniques/ambiguous-spec.png -------------------------------------------------------------------------------- /images/general/dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/general/dashboard.png -------------------------------------------------------------------------------- /images/general/open-in-workspace-full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/general/open-in-workspace-full.png -------------------------------------------------------------------------------- /images/general/open-in-workspace.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/general/open-in-workspace.png -------------------------------------------------------------------------------- /images/getting-started/pr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/getting-started/pr.png -------------------------------------------------------------------------------- /images/overview/current-spec.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/current-spec.png -------------------------------------------------------------------------------- /images/overview/file-iteration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/file-iteration.png -------------------------------------------------------------------------------- /images/overview/issue-timeline-representation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/issue-timeline-representation.png -------------------------------------------------------------------------------- /images/overview/plan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/plan.png -------------------------------------------------------------------------------- /images/overview/proposed-spec.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/proposed-spec.png -------------------------------------------------------------------------------- /images/overview/references.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/references.png -------------------------------------------------------------------------------- /images/overview/session.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/session.png -------------------------------------------------------------------------------- /images/overview/share-link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/share-link.png -------------------------------------------------------------------------------- /images/overview/task-completion.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/task-completion.png -------------------------------------------------------------------------------- /images/overview/terminal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/terminal.png -------------------------------------------------------------------------------- /images/overview/topic-question.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/overview/topic-question.png -------------------------------------------------------------------------------- /images/pull-request-tasks/pr-task-timeline-representation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/pull-request-tasks/pr-task-timeline-representation.png -------------------------------------------------------------------------------- /images/tips-and-tricks/code-editor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/tips-and-tricks/code-editor.png -------------------------------------------------------------------------------- /images/tips-and-tricks/experiments.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/tips-and-tricks/experiments.png -------------------------------------------------------------------------------- /images/tips-and-tricks/issue-and-code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/tips-and-tricks/issue-and-code.png -------------------------------------------------------------------------------- /images/tips-and-tricks/regen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/tips-and-tricks/regen.png -------------------------------------------------------------------------------- /images/tips-and-tricks/undo-redo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/tips-and-tricks/undo-redo.png -------------------------------------------------------------------------------- /images/vscode/ghcw-activity-bar-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-activity-bar-icon.png -------------------------------------------------------------------------------- /images/vscode/ghcw-brainstorm-multiple-answers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-brainstorm-multiple-answers.png -------------------------------------------------------------------------------- /images/vscode/ghcw-brainstorm-panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-brainstorm-panel.png -------------------------------------------------------------------------------- /images/vscode/ghcw-branch-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-branch-example.png -------------------------------------------------------------------------------- /images/vscode/ghcw-clone-or-open-folder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-clone-or-open-folder.png -------------------------------------------------------------------------------- /images/vscode/ghcw-editor-actions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-editor-actions.png -------------------------------------------------------------------------------- /images/vscode/ghcw-extn-install.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-extn-install.png -------------------------------------------------------------------------------- /images/vscode/ghcw-overview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-overview.png -------------------------------------------------------------------------------- /images/vscode/ghcw-plan-view-banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-plan-view-banner.png -------------------------------------------------------------------------------- /images/vscode/ghcw-selec-repo-loc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-selec-repo-loc.png -------------------------------------------------------------------------------- /images/vscode/ghcw-session-details-button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-session-details-button.png -------------------------------------------------------------------------------- /images/vscode/ghcw-session-details-no-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-session-details-no-sync.png -------------------------------------------------------------------------------- /images/vscode/ghcw-session-details.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-session-details.png -------------------------------------------------------------------------------- /images/vscode/ghcw-session-list-button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-session-list-button.png -------------------------------------------------------------------------------- /images/vscode/ghcw-session-list-no-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-session-list-no-sync.png -------------------------------------------------------------------------------- /images/vscode/ghcw-session-list.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-session-list.png -------------------------------------------------------------------------------- /images/vscode/ghcw-sign-in-notification.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-sign-in-notification.png -------------------------------------------------------------------------------- /images/vscode/ghcw-task-view-brainstorm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-task-view-brainstorm.png -------------------------------------------------------------------------------- /images/vscode/ghcw-uri-sync-not-enabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/ghcw-uri-sync-not-enabled.png -------------------------------------------------------------------------------- /images/vscode/status-bar-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/status-bar-error.png -------------------------------------------------------------------------------- /images/vscode/status-bar-not-syncing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/status-bar-not-syncing.png -------------------------------------------------------------------------------- /images/vscode/status-bar-syncing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/status-bar-syncing.png -------------------------------------------------------------------------------- /images/vscode/status-bar-working.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/status-bar-working.png -------------------------------------------------------------------------------- /images/vscode/upper-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/githubnext/copilot-workspace-user-manual/39d20026f9d40ed11c8a168777207d87415b3230/images/vscode/upper-right.png -------------------------------------------------------------------------------- /known-issues.md: -------------------------------------------------------------------------------- 1 | # Known Issues and Future Improvements 2 | 3 | Please remember that Copilot Workspace is a technical preview and is an area of active development. This document lists some known issues and known areas where we'd like to make future improvements of the product. 4 | 5 | The following are core areas where we are actively working to improve Copilot Workspace. 6 | 7 | ### Rewriting large files 8 | 9 | When Copilot Workspace implements a plan that involves changes in a large file, it can take a long time to complete. Copilot Workspace currently uses "whole file rewriting" as we have found this achieves a high level of thoroughness on the very heterogeneous range of tasks Copilot Workspace can be used for. 10 | 11 | We are working on partial-file rewriting techniques, both automatic and under user-guidance, to improve the performance of this operation. 12 | 13 | ### Code generation 14 | 15 | The quality of the code generated by Copilot Workspace is not always perfect. It is highly related to the quality of the underlying AI-models used. We are working on improving the quality of the code generated by Copilot Workspace on many levels. 16 | 17 | For example, the quality of code generation is affected by the quality of the planning and specification of the task, and the overall user-experience of assessing and clarifying these. We are working to improve these too. 18 | 19 | The achieved quality is also related to the experience of iterating on the generated code. We are actively looking at more fine-grained iteration techniques. 20 | 21 | ### Content selection 22 | 23 | The content selection in Copilot Workspace can sometimes be suboptimal, leading to the generation of code that is not relevant to the task. We are working on improving the content selection in Copilot Workspace. 24 | 25 | ### Web retrieval 26 | 27 | Tasks can include direct links to web resources such as documentation. Further, some web retrieval can also be deduced from the task. Copilot Workspace does not currently perform web retrieval and we are working on adding this feature. 28 | 29 | ### Build/test repair 30 | 31 | After code is generated, both AI and traditional tooling can be used to "repair" the code based on diagnostics generated from building, testing and running the code. We already have some support for this in Copilot Workspace, and we are working on improving this. 32 | 33 | ### Tasks small, tasks large 34 | 35 | Some tasks are very small: updating a few lines of a file. Some tasks are very large: implementing an entirely new repository feature by feature. 36 | 37 | Copilot Workspace is currently designed for the mid-range of tasks typical of GitHub issues. We are interested in delivering variations on the core concepts of Copilot Workspace in arrangements more suitable to tasks both small and large. For example, for small tasks we may offer a "lite" version of Copilot Workspace where there is only the task. For large tasks we may offer a way to decompose the task into sub-tasks. 38 | 39 | ### Authorization 40 | 41 | Copilot Workspace uses a GitHub OAuth App for authentication. Some organizations can have [policies which restrict OAuth applications from interacting with their repositories](https://docs.github.com/en/organizations/managing-oauth-access-to-your-organizations-data/about-oauth-app-access-restrictions). You will not be able to perform tasks in private repositories with Copilot Workspace, or create pull requests in public repositories unless the organization admin approves the Copilot Workspace OAuth application. 42 | 43 | We are working to add a second authorization option for Copilot Workspace based on a GitHub App, and will update this document when this is available. 44 | 45 | ### Scaling 46 | 47 | Copilot Workspace can be used with many existing large repositories. However, some repositories are so large that even listing their files can be a challenging exercise. Further, some repositories contain highly unusual content: files with enormously long lines, or binary files with unusual extensions, and so on. Large repositories are also challenging to content selection and planning. 48 | 49 | Copilot Workspace places a limit on the GitHub-reported size of repositories that may be analyzed. If a repository is above this limit you may see `Copilot Workspace may not be used to analyze / due to size limitations`. 50 | 51 | We are working on improving the scalability of Copilot Workspace to handle these cases. 52 | 53 | ### Validation 54 | 55 | Copilot Workspace provides an integrated terminal to assist with validating code. We are continuously working on a range of techniques to improve the validation capabilities of Copilot Workspace. 56 | 57 | ### Developer tooling 58 | 59 | Copilot Workspace is currently delivered as a web application with an opinionated UX modality. A core design principle is to make this experience available pervasively, and we will be assessing enabling alternative delivery mechanisms in IDEs or at the command-line. 60 | 61 | We are also looking at augmenting the range of developer tooling to integrate with Copilot Workspace web experience. 62 | 63 | ## Known issues 64 | 65 | The following are more specific known issues related to the current release of Copilot Workspace. 66 | 67 | ### Ambiguity detection can kick in too often 68 | 69 | The ambiguity detection in Copilot Workspace can sometimes be too sensitive, and can kick in even when the task is clear. We are working on improving the accuracy of the ambiguity detection in Copilot Workspace. 70 | 71 | ### Choosing an existing issue needs better UX 72 | 73 | When choosing an existing issue to work on, the user experience is not as smooth as it could be, and it can be easier just to adjust the deep-link URL for Copilot Workspace or return to the issue page on GitHub and choose "Open in Workspace". 74 | 75 | ### Commits from Workspaces PRs are not currently signed 76 | 77 | Commits from Workspaces PRs are not currently signed. We will be working on adding this feature. 78 | 79 | ### There is no 'Stop' button when generating pull request descriptions 80 | 81 | There is no 'Stop' button when generating pull request descriptions. We are working on adding this feature. 82 | 83 | ### Auto-completion list is sometimes positioned incorrectly on mobile 84 | 85 | On mobile, the auto-completion list is positioned wrong when adding a file to the plan. A fix is in progress for this. 86 | 87 | ### Terminal start-up time 88 | 89 | We are actively working to improve the terminal start-up time in Copilot Workspace. 90 | 91 | ### Terminal Help Button Timeout 92 | 93 | The repair flow from the terminal to the plan sometimes times out, causing the terminal help button to say it can't assist you. 94 | A workaround for this is to click the send button (up arrow icon) again can regenerate the suggestion. 95 | We understand that this is not ideal, and are working on a solution to this issue. 96 | 97 | 98 | -------------------------------------------------------------------------------- /origins.md: -------------------------------------------------------------------------------- 1 | # Origins of Copilot Workspace 2 | 3 | At GitHub Next we work in phases: ideation, build, ship, learn. Every phase is about learning. 4 | 5 | In May 2023, after launching Copilot-X, our ideation around the [SpecLang project](https://githubnext.com/projects/speclang/) led to new explorations of how to incorporate natural language — and user edits to natural language — into the development process, with a focus on “the whole repository”. 6 | 7 | SpecLang is conceptualized as a compiler for natural language: specs are _permanent_, and code _ephemeral_. But what would happen when specs are updated — is the compilation function stable enough? That led us to ask: what if instead _code_ is permanent, and _specs_ ephemeral? Can the user then change the spec, and see the inferred changes to the code, then throw the spec away? This led to a new ideation: _Extract, Edit, Apply_ — EEA. We would use AI models to _extract_ a specification from existing code, the user would indicate the desired change by _editing_, and the AI would help _apply_ that change. This core concept has proved both fascinating and grounding as we iterated on it — “SpecLang had a code-first baby” was our tagline. 8 | 9 | Another core concept of Copilot Workspace is the all-important “Co” in "Copilot" — the core idea that the human and the AI take a journey together — a continual _pas de deux_ where the human indicates an intention and the AI makes an offering and the human checks and corrects that offering, or ignores it, and the cycle continues. This is a core challenge in task-oriented workflows. Among all the talk of “agents”, this need to design for this repeated AI-human divergence and alignment can be lost. If the AI is going to take steps towards a solution, it must “take the human with it”, and allow review, steering and control at every step of the way. Put differently, if agents are to be human-assistive, they must be “co-agents”. This requires close attention to user experience, and also requires top-rate user experience developers. We don't say we've fully cracked it — but the design principle has been there with us from the start. 10 | 11 | From June 2023 to GitHub Universe in November 2023 and through to technical preview in April 2024, the EEA ideation merged with many practical themes to become Copilot Workspace. We began to focus on [GitHub issues](https://github.com/features/issues) and tasks as the source of change intent. We looked at validation and the possibilities to incorporate AI-assisted build and validation cycles. We did user studies and learned more about the many ways we could support iteration after initial code generation. We looked at extensibility and [“developer flow” integration into GitHub.com](https://github.com/githubnext/copilot-workspace-user-manual/blob/main/overview.md#task). We experimented with AI inference for working out what files — and what parts of files — to change. We integrated a [terminal](https://github.com/githubnext/copilot-workspace-user-manual/blob/main/overview.md#integrated-terminal) and file synchronizer for practical validation. We redesigned in [Primer](https://github.com/primer) to align with GitHub. We started to learn about [the joy of natural language programming on mobile devices](https://www.youtube.com/watch?v=Zv6TuVzcRdY) — drafting issues on-the-go, then “Open in Workspace” and save the results for later. We iterated on [conceptual models of the development process](https://github.blog/2024-01-17-a-developers-second-brain-reducing-complexity-through-partnership-with-ai/), doing interviews with developers to help understand how they experience and use Chat-based AI in their work today, and what scenarios they welcome yet more AI assistance with. We talked widely and openly about the project in GitHub and Microsoft, and were plain, open and honest about our methodology and status, and started to work with partner teams. We began to understand more of the social role of AI-assisted tooling including sharing “sessions” — early drafts of possible code changes. We also learned how Copilot Workspace helps as much when the developer is unfamiliar with a codebase as familiar. We dug through logs to identify faulty GPU clusters or 502s. We worked hard, very hard, on the user experience. And we used the tool ourselves — so-called “dogfooding” — a lot, every day. 12 | 13 | We're excited to continue this development and to take the journey through technical preview, always with the aim to learn more, every single day. 14 | 15 | The GitHub Next Team 16 | -------------------------------------------------------------------------------- /overview.md: -------------------------------------------------------------------------------- 1 | # Copilot Workspace: Overview 2 | 3 | [Copilot Workspace](https://githubnext.com/projects/copilot-workspace/) is a _task-centric_ AI assistant. Each day as a developer you start with a task, and make the journey to explore, understand, refine, and complete that task, a journey that can be exciting, challenging, fascinating, and rewarding. Copilot Workspace takes this journey with you, every step of the way — the journey from task to working code. 4 | 5 | Copilot Workspace is built on a set of principles that guide its design and development: 6 | 7 | * Copilot Workspace is _contextual_. It is deeply integrated with GitHub, and is aware of the context of your task — the repository, the issue, the pull request. 8 | 9 | * Copilot Workspace is _assistive_. It offers a canvas for you to navigate unfamiliar tasks, augmenting your development skills with a new kind of AI assistance. 10 | 11 | * Copilot Workspace is _pervasive_. It is ready and waiting for you, available on every issue in every enabled repository on GitHub. And Copilot Workspace is even there for you when starting new code, available on every template repository, to create new software using natural language. 12 | 13 | * Copilot Workspace is _iterative_. Copilot Workspace encourages you to check, review, refine and iterate on AI-generated outputs. You, the developer, are in control. 14 | 15 | * Copilot Workspace is _collaborative_. You can share sessions with your team and publish links to your sessions on issues and pull requests. And, if you're a repository maintainer, we give you controls to help manage the use of AI-assisted development with your repositories. 16 | 17 | * Copilot Workspace is _configurable_. You can integrate Copilot Workspace into your workflows via deep links to Copilot Workspace that specify common tasks. 18 | 19 | In this manual, we will guide you through the concepts and features of Copilot Workspace, and help you get started with using it effectively. 20 | 21 | A fully-implemented workspace session 22 | 23 | *A fully-implemented workspace session* 24 | 25 | ## Features 26 | 27 | 1. [Task](#task) 28 | 1. [Specification](#specification) 29 | 1. [Plan](#plan) 30 | 1. [Implementation](#implementation) 31 | 1. [Iterating on Files](#iterating-on-files) 32 | 1. [Integrated Terminal](#integrated-terminal) 33 | 1. [Session Sharing](#session-sharing) 34 | 1. [Task Completion](#task-completion) 35 | 1. [Session Dashboard](#session-dashboard) 36 | 37 | ## Task 38 | 39 | Everything in Copilot Workspace begins with a “task”, which is a natural language description of intent. The task always has a context: a GitHub repository. 40 | For this technical preview, Copilot Workspace supports four types of tasks: solving issues, refining pull requests, [creating repositories from templates](creating-repos.md) and ad-hoc tasks. Here we focus on solving issues, which are the most common entry point. 41 | 42 | Once enrolled in the technical preview, then on every issue in GitHub you will find a new "Open in Workspace" button: 43 | 44 | Button on issue page to open in Copilot Workspace 45 | 46 | *Open an issue in Copilot Workspace* 47 | 48 | This will open Copilot Workspace contextualized to this issue. For issue tasks, the task is based in the title and body of the issue, plus the issue’s comment thread. Copilot Workspace will immediately progress to the next step in the timeline. This looks like this: 49 | 50 | Issue task timeline representation 51 | 52 | *The task is labeled as “Issue” and analysis begins* 53 | 54 | ## Specification 55 | 56 | In order to help summarize a non-trivial task definition (e.g. an issue with a long comment thread), Copilot Workspace first generates a “topic” for the task, which takes the form of a question that can be posed against the codebase, and used to define the before/after success criteria (see the [specification](#specification) section below). 57 | 58 | Topic question 59 | 60 | *Note how the topic introduces clarity that is completely missing from the issue title* 61 | 62 | You can think of the topic as a way to distill the task down to its essence, and to give you an early and fast opportunity to see if Copilot Workspace is on the right track. If the topic is wrong, you don't need to continue. But if the topic is right, it helps you better understand the task, and to focus on the most important aspects of the codebase that are relevant to the task. 63 | 64 | After producing the topic, Copilot Workspace generates a bulleted list describing the current behavior of the codebase, based on the task and topic being posed. This helps build your confidence that Copilot Workspace is on the right track, and serves as a means of onboarding you to the context, in cases where you might not fully understand the current state. 65 | 66 | Current specification 67 | 68 | *The current specification answers the question in the topic based on the current state* 69 | 70 | And if Copilot Workspace gets anything wrong, then you can easily edit/delete steps from the current spec, or even choose to regenerate an entirely new spec (“try again”). In practice, we find that these tend to be pretty good on the first try. 71 | 72 | After the current specification, Copilot Workspace generates a “proposed specification”, which is a bulleted list which articulates the state that the codebase would be in after resolving the task (effectively answering the question in the topic). And in particular, the proposed specification is focused on defining the success criteria of the task, as opposed to getting into implementation details (which is the role of the [plan](#plan)). 73 | 74 | Proposed specification 75 | 76 | *The proposed specification indicates how to edit the codebase in order to solve the task* 77 | 78 | ## Content Selection 79 | 80 | To generate the current and proposed specifications, and for all following steps, Copilot Workspace needs to identify which files in the codebase are relevant to understanding and completing the task. It does this by a combination of LLM techniques and traditional code search. The contents of the highest-ranked files are then used as context for nearly all steps in the workflow. 81 | 82 | Users may review the files selected by Copilot Workspace using the "View references" button in the Specification panel. To adjust which files are selected, users can edit the task and use natural language to specify which files are relevant. 83 | 84 | Show references dialog 85 | 86 | *The references that the model used to generate the original and modified specifications* 87 | 88 | ## Plan 89 | 90 | Once you are happy with the current and proposed specs, you can request Copilot Workspace to generate a plan, which is a list of the files that need to be modified (e.g. edited, created, deleted, moved, or renamed) in order to accomplish the success criteria of the proposed spec. Additionally, each changed file includes a list of specific steps that indicate the exact changes that need to be made. 91 | 92 | Like the spec, the plan is fully editable and regeneratable, which allows you to refine and steer Copilot Workspace in the right direction. 93 | 94 | Plan 95 | 96 | *A plan, showing the steps needed to edit one file and add a second one* 97 | 98 | ## Implementation 99 | 100 | When you are happy with the plan, you can click the “Implement” button in order to begin implementing it. This will update the UI to display a series of queued file updates on the right side, and then begin generating the updated file contents one-by-one. When a file begins generating, its associated entry in the plan will show it as being in progress. And when it completes, the plan will indicate it as being done. 101 | 102 | Once a file is implemented, Copilot Workspace renders a diff view for it, and automatically scrolls to the first change. The diff editors are editable, which allows making minor tweaks directly to the code, as opposed to iterating via changes to the task, spec, or plan. 103 | 104 | ## Iterating on Files 105 | 106 | Copilot Workspace doesn't always get everything right, and so it makes it easy for users to iterate on the implementations file by file. Simply add, remove, edit the items in the plan steps for each file, select the checkbox, and click the "Update selected files" button. This will re-generate the contents of the selected files and update the diff view. 107 | 108 | For example, you can edit the diff directly, or you can go back to the plan and make changes there. And if you need to make more extensive changes, you can regenerate the plan entirely. 109 | 110 | Plan panel with file iteration 111 | 112 | *The plan panel enables users to iterate on implementation file by file* 113 | 114 | ## Integrated Terminal 115 | 116 | Once you have implemented the plan, Copilot Workspace enables you to validate the changes for correctness by bringing up an integrated terminal and executing shell commands. This allows performing a build, lint, test, etc. against the changes, and can be a quick and effective way to gain confidence about the task and its completion status. The terminal is backed by a Codespace, so it is a secure sandbox with a full development environment installed. 117 | 118 | Integrated terminal 119 | 120 | *Integrated terminal, showing the generated branch name and access to just-in-time compute* 121 | 122 | If you want to make any more extensive changes or leverage rich editor features (e.g. step debugging), you can open the Copilot Workspace session in a Codespace, using any of Codespace’s supported clients. 123 | 124 | ## Session Sharing 125 | 126 | In order to make it easy to share a workspace session with others (e.g. for doing an ad-hoc code review or sharing an initial implementation idea), Copilot Workspace allows users to generate shared links. These links can be shared with guests, even if they are not part of the Copilot Workspace preview. 127 | 128 | Shared sessions are copies of the original session. Non-guest users can use them as a starting point to continue the task or explore alternative solutions without interfering with the original session. Guest users can view the session but cannot use the workspace to make changes. 129 | 130 | Generating a share link 131 | 132 | *Generating a share link from the header bar* 133 | 134 | When working with issues and pull requests, you can also 135 | 136 | * Publish to issue comment. Copilot Workspace automatically generates a comment with a share link for the session, which is included in the issue. This allows reviewers to quickly access the workspace session and see the proposed changes. 137 | 138 | * Publish to pull request comment. Similar to the issue comment, Copilot Workspace automatically generates a comment with a share link for the session, which is included in the pull request. This allows reviewers to quickly access the workspace session and see the proposed changes. 139 | 140 | ## Task Completion 141 | 142 | When a task is implemented, validated, and reviewed, you can complete the task in different ways, depending on the type of task you’re working on. 143 | 144 | Creating a pull request 145 | 146 | *Creating a pull request for the implemented changes* 147 | 148 | | Task type | Available completions | 149 | |-----------| -------------------- | 150 | | Issue | — Create pull request
— Create draft pull request
— Push to new branch
— Push changes to current branch (only available if you have commit permissions to the repo)

These may fork the repository if you do not have write access | 151 | | Ad-hoc task | — *As for issues* | 152 | | PR task | — Update pull request (pushes a new commit with the changes)
— *As for issues* | 153 | | Repo task | — Create repository (creates a new repo from the selected template repo, and includes the changes) | 154 | 155 | ## Session Dashboard 156 | 157 | Copilot Workspace automatically saves your work. It also provides a session dashboard, which allows you to easily resume your work later. You can start a task from your phone and then finish up on your laptop, or vice versa. 158 | 159 | Copilot Workspace dashboard 160 | 161 | *The Copilot Workspace dashboard showing recent, bookmarked and completed sessions* 162 | 163 | Undo and redo are supported within the session via buttons on the toolbar. 164 | 165 | ## Appendix: Glossary 166 | 167 | | Term | Definition | 168 | |------|------------| 169 | | Copilot Workspace | A Copilot-native dev environment that’s designed for exploring and completing every day tasks | 170 | | Target | A branch of a codebase at a specific commit | 171 | | Task | A natural language description of a change to a target | 172 | | Topic | A brief single-sentence summary of a task, usually in question form | 173 | | Specification | A description of the current and proposed state of the target as it relates to the task | 174 | | Plan | A list of files to add, remove or change, with notes about each of them, that together transform the target from its current state to its proposed state | 175 | | Implementation | A set of changes to the target that, when applied, will complete the task | 176 | | Session | A user’s saved progress towards completing a task, a single task can have many sessions | 177 | | Snapshot session | A snapshot of a user’s session, created when you click “Share link”, including both the task progress and UX state | 178 | -------------------------------------------------------------------------------- /repo-maintainers.md: -------------------------------------------------------------------------------- 1 | # Copilot Workspace for Repository Maintainers 2 | 3 | Copilot Workspace can assist you as a repository maintainer in several ways: 4 | 5 | 1. Copilot Workspace can help you explore potential solutions to issues. 6 | 2. Copilot Workspace can help you generate sketches of solutions to issues for potential contributors, lowering the barrier of entry. 7 | 3. Copilot Workspace can help encourage a culture where issue-creators leave additional helpful notes on how to solve issues, for use by both contributors and AI assistants. 8 | 9 | For example, when a new issue is filed in your repository, you can use Copilot Workspace to generate a sketch of a solution to the issue. You can then use the "Share" button to publish this sketch back to the issue thread, with additional comments about whether you think it is useful or not, and where it might need improvement. This can help potential contributors understand the problem better and provide a starting point for their work. 10 | 11 | Similarly, when a new issue is filed, you can ask the contributor to create a Copilot Workspace session for the issue. This may help the contributor understand the problem better and provide a starting point for their work. You can also include this guidance in the issue template for your repository, assuming your users have access to Copilot Workspace. You can also ask contributors to leave additional notes in the Copilot Workspace session, which can help future contributors and AI assistants understand the problem better. 12 | 13 | ## Restricting the use of Copilot Workspace in your repository 14 | 15 | It is possible for undisciplined contributors to over-use AI-assisted code generation. Because of this, we give repository maintainers the option of disabling the direct use of Copilot Workspaces for creating pull requests and/or issue comments in their repositories. 16 | 17 | To disable the direct creation of pull requests using Copilot Workspace, create a file `.github/copilot-workspace/policy.json` in the default branch of the repository containing the following content: 18 | 19 | ```json 20 | { 21 | "allowPullRequests": false 22 | } 23 | ``` 24 | 25 | To disable the use of Copilot Workspace to directly generate issue comments that contain links to Copilot Workspace sessions, add the following content to the `policy.json` file: 26 | 27 | ```json 28 | { 29 | "allowComments": false 30 | } 31 | ``` 32 | 33 | Users of Copilot Workspace will still be able to: 34 | 35 | - create sharing links to Copilot Workspace sessions and paste them into issue comments 36 | - push to new branches in your repository (if they have write access) 37 | - push to new branches in forks of your repository 38 | - manually create pull requests from branches 39 | - use Copilot Workspace to generate code snippets and files for their own use in their own pull requests and issue comments to your repository 40 | -------------------------------------------------------------------------------- /responsible-ai-faq.md: -------------------------------------------------------------------------------- 1 | # Responsible AI FAQ 2 | 3 | ## What is Copilot Workspace? 4 | 5 | Copilot Workspace is a reimagined developer inner loop. The focal points of the experience are selecting a task, expressing intent, and then collaborating with AI towards a solution. We believe this can dramatically reduce complexity, improve productivity, and delight developers, without taking away the aspects of software development that they value most, such as decision making, creativity, and ownership. 6 | 7 | ## What can Copilot Workspace do? 8 | 9 | Copilot Workspace takes in a development task from a user, for example, a GitHub Issue, and produces a natural-language specification of the current behavior of the code, a plan for how to modify the code to complete the task, and eventually the actual code changes to all relevant files in the repo. Each step (task, spec, plan, and implementation) is editable by the user, enabling the user to steer the AI to complete the task in the best way. 10 | 11 | ## What is/are Copilot Workspace’s intended use(s)? 12 | 13 | Copilot Workspace is intended to: 14 | 15 | 1. Accelerate software developers, helping them make small- and medium-scale code changes quickly and correctly. 16 | 2. Reduce the activation energy for developers to start tasks, by giving them an AI-generated starting point. 17 | 3. Help experienced developers work with unfamiliar programming languages and frameworks. 18 | 4. Help developers contribute to unfamiliar codebases, for example, to open source projects. 19 | 20 | ## How was Copilot Workspace evaluated? What metrics are used to measure performance? 21 | 22 | Copilot Workspace was evaluated in the following ways: 23 | 24 | * Offline evaluations. We have a corpus of known tasks and an entrypoint that allows us to run Copilot Workspace over those tasks in a headless mode. When we make changes to our prompts, switch to a different model, etc., we run those benchmarks and manually validate the changes to Copilot Workspace’s outputs. If we see regressions, we iterate on the prompts until there are no more regressions. In addition, we have a larger set of benchmarks that are mined from GitHub, and we use model-driven evaluations to ensure consistent quality. 25 | * User studies. In January, we ran a round of user studies with GitHub employees where we gave them a standard task and asked them to complete the task using Copilot Workspace. We are planning additional user studies as part of the Technical Preview. 26 | * Extensive dogfooding within our team. We used Copilot Workspace to build Copilot Workspace. 27 | * Red teaming. We have prepared a set of malicious prompts and run Copilot Workspace in headless mode over those prompts. Then we do both human- and model-driven evaluations of the output for harmful responses, and if we see those, we update our prompts and filters so that users do not encounter them. 28 | 29 | ## What are the limitations of Copilot Workspace? How can users minimize the impact of Copilot Workspace’s limitations when using the system? 30 | 31 | Copilot Workspace is not always correct. Users should carefully validate its output and should not blindly trust it. If users detect inaccuracies in Copilot Workspace’s outputs, we have made it easy for them to edit and correct any model-generated outputs. We have also built validation tools, particularly a terminal which allows the user to execute the generated code in a sandboxed environment. The user should use these tools to validate and correct Copilot Workspace’s outputs. 32 | 33 | ## What operational factors and settings allow for effective and responsible use of Copilot Workspace? 34 | 35 | Copilot Workspace will perform best on common programming languages and frameworks and when the natural language is English. 36 | 37 | Code generated by Copilot Workspace should be held to the same standard as human-written code – it should be code reviewed, have automated tests, be analyzed by linters and static analyzers, etc. Copilot Workspace can help add automated tests to in-progress PRs, helping improve the overall health of a software project. 38 | 39 | ## What should a user do if they encounter offensive content while using Copilot Workspace? 40 | 41 | Please report any examples of offensive content to copilot-safety@github.com. Please include a share link so that we can investigate. -------------------------------------------------------------------------------- /settings.md: -------------------------------------------------------------------------------- 1 | # Copilot Workspace Settings 2 | 3 | These settings are preferences for how you want Copilot Workspace to behave with your workflows. 4 | 5 | ## Collapse timeline on implement 6 | 7 | When this setting is enabled, the timeline panel on the left side of the workspace will automatically collapse after you click the "Implement" button. This allows you to focus more on the code changes and less on the timeline, while still being able to revise with natural language. 8 | 9 | ## Spin up a codespace when a session is created 10 | 11 | When this setting is enabled, a Codespace will be automatically created when you start a new session. This provides a full development environment with language services, making it easier to work on your tasks. Note that selecting this option may cause code generated by Copilot Workspace to be executed before you are able to review it. By selecting this, you acknowledge the risks of auto-running AI-generated code. 12 | 13 | ## Spin up a codespace on start of implement 14 | 15 | When this setting is enabled, a Codespace will be automatically created when you click the "Implement" button. This provides a full development environment with language services, making it easier to work on your tasks. Note that selecting this option may cause code generated by Copilot Workspace to be executed before you are able to review it. By selecting this option, you acknowledge the risks of auto-running AI-generated code. 16 | 17 | ## Show notification after implementing 18 | 19 | When this setting is enabled, Copilot Workspace will notify you when it has completed its implementation. This allows you to get back into the flow as soon as possible, without having to constantly check the status of the implementation. You can enable or disable this setting based on your preference. 20 | -------------------------------------------------------------------------------- /tips-and-tricks.md: -------------------------------------------------------------------------------- 1 | # Tips and Tricks 2 | 3 | This document contains assorted tips and tricks for using Copilot Workspace effectively. We'd love to hear your tips and tricks, too! Please share them with us in [feedback channels](README.md#feedback). 4 | 5 | ## Edit the Issue or Task 6 | 7 | ✨ TIP: You can edit the issue or task to guide Copilot Workspace. 8 | 9 | The Issue/Task panel may be prepopulated with content depending on how you entered Copilot Workspace. For example, if you started from an Issue, the Issue panel will be prepopulated with the content of the issue. This content is ephemeral -- edits aren't synced back to the issue -- and so feel free to edit it to provide more context or to steer Copilot Workspace towards better results. 10 | 11 | ## Tasks can be short! 12 | 13 | ✨ TIP: You might be surprised at the effectiveness of simple tasks like "Add unit tests" 14 | 15 | Tasks don't have to be long. Simple, clear statements of intent like "Switch to use Python numpy" or "Add more unit tests for the server code" can get you a long way. You can easily add more clarification and iterate. 16 | 17 | ## Clarify the Issue or Task 18 | 19 | ✨ TIP: A few words clarifications can make a huge difference! 20 | 21 | Just a few words of clarification can make a big difference in the quality of the results you get. For example, 22 | 23 | * _add corresponding unit tests in `test/server`_ or 24 | 25 | * _the problem is in the convolution code_ or 26 | 27 | * _don't change any existing code just add unit tests_ 28 | 29 | are examples of useful clarifications. Use as many of these as you like! 30 | 31 | ## Consider using Examples 32 | 33 | ✨ TIP: Giving examples of what you want can be a great way to clarify a task 34 | 35 | For example, you can say: _Here are some examples of command line invocations that should work after the change..._ and give a few examples. Or you can say: _Here are some examples of the expected output..._ and give a few examples. 36 | 37 | ## Check the Topic and Specification 38 | 39 | ✨ TIP: Check the topic and specification - if they're accurate, then Copilot Workspace is on the right track 40 | 41 | The Topic is your first quick glimpse of Copilot Workspace's analysis of your task in the context of your repository, and the Current Specification follows soon after, then the Updated Specification. If these are accurate, then Copilot Workspace is on the right track. If they're not, then you may need to provide more context, clarifications and hints in the Issue/Task panel, or you may be performing something beyond Copilot Workspace's current capabilities. 42 | 43 | You can edit all of these to correct them, and checking them quickly can save you a lot of time. You can also go back and clarify the issue or task and try again. 44 | 45 | ## Check the Content Selection 46 | 47 | ✨ TIP: Check the content selection and use short notes in the issue or task to say where to look 48 | 49 | You can [check the content selection used](overview.md#content-selection). Often the content selection can be improved, and right now you do this through natural language and notes on the issue/task. If you know where the code that needs to be changed is, you can say so in the issue/task panel. For example, you can say: _Look in `src/server.js`_ or many other variations. 50 | 51 | To determine how to address a task, Copilot Workspace must determine which files in a repo are relevant to the task. This is hard, and Copilot Workspace may not always select the right files. If that happens, you may see low-quality results. 52 | 53 | To review the files that were selected, in the Specification panel, click the "View references" button: 54 | 55 | Show references dialog 56 | 57 | To steer Copilot Workspace towards better file selection, you can mention file names, directory names, etc. in the issue/task panel. Just write it naturally, as if you were writing a normal issue. 58 | 59 | ## If at First You Don't Succeed... 60 | 61 | ✨ TIP: Try regenerating the spec or plan 62 | 63 | If you're not happy with the results you're getting, you can try regenerating the spec and/or plan. To do this, click the "Regenerate" button in the Spec or Plan panels: 64 | 65 | Regenerate button 66 | 67 | ## Iterating on the Implementation 68 | 69 | ✨ TIP: Add short notes to files in the plan, then iterate 70 | 71 | Often Copilot Workspace will get a task *mostly right*, but may have trouble with some parts. In this case, you can reimplement specific files with new or additional instructions. After implementing and reviewing the code, you can select file(s) in the Plan panel and add bullet points, then click "Update selected files" to reimplement those file(s) with the new instructions that you've provided. 72 | 73 | Update selected files flow 74 | 75 | ## Add New Files and Iterate 76 | 77 | ✨ TIP: You can add new files and iterate on the implementation 78 | 79 | If you need to add new files to the implementation, you can do so by clicking the "Add file" button in the Plan panel. This will add a new file to the plan, which you can then implement and iterate on. 80 | 81 | ## Consider Generating New Files 82 | 83 | ✨ TIP: Generating new files can be better than appending to existing files 84 | 85 | This technical preview of Copilot Workspace uses "whole file rewriting". This means that when you ask Copilot Workspace to add code to a file, it will replace the entire file with the new code. When performing tasks like writing unit tests or generating documentation or new implementation code, it can be easier and quicker to generate new files, then rename them. 86 | 87 | ## Share Early, Share Often 88 | 89 | ✨ TIP: You can share your session at any time, including with people who are not part of the Copilot Workspace preview. 90 | 91 | You can share your Copilot Workspace session with others by clicking the "Share" button in the top right corner of the screen. This will generate a link that you can share with others. These links can be shared with guests, even if they are not part of the Copilot Workspace preview. They will need to log in with their GitHub account to view the session. 92 | 93 | Shared sessions are copies of the original session. Non-guest users can use them as a starting point to continue the task or explore alternative solutions without interfering with the original session. Guest users can view the session but cannot use the workspace to make changes. 94 | 95 | Share button 96 | 97 | ## Use the Sessions 98 | 99 | ✨ TIP: Return to your work at any time 100 | 101 | Your sessions are automatically saved, so you won't lose work if you close the browser or navigate away from the page. You can return to your session by going to [your Copilot Workspace dashboard](https://copilot-workspace.githubnext.com). 102 | 103 | ## Configure the Terminal for Your Repository 104 | 105 | ✨ TIP: Set up a `devcontainer.json` file in your repository to configure the terminal 106 | 107 | We provide a built-in terminal so that you can validate the code changes that Copilot Workspace suggests. We use GitHub Codespaces to provide this terminal, and we use the `devcontainer.json` file in your repository to configure the container that powers the terminal. If you need to make changes to the default container to e.g. install necessary software, etc., you can do so by creating a `devcontainer.json` file in your repository. Learn more about Development Containers at https://containers.dev/. 108 | 109 | ## Use the Codespace 110 | 111 | ✨ TIP: Full editing in the Codespace is simple and quick 112 | 113 | Modified files are two-way-synced between Copilot Workspace and the terminal/Codespace. Feel free to edit in either place, and your changes will be reflected in the other. 114 | 115 | Check out [Codespaces Guide](./codespaces-guide.md) for more information. 116 | 117 | ## Explore the Experiments! 118 | 119 | ✨ TIP: Explore our experiments and send us feedback! 120 | 121 | We're always trying new things in Copilot Workspace. You can opt into our current experiments by clicking on your avatar in the top right corner of the screen and selecting "Experiments": 122 | 123 | Experiments selector 124 | 125 | ## Work Around Model "Laziness" 126 | 127 | ✨ TIP: If the model is "lazy" and elides chunks of edited files, copy and paste the missing parts from the diff 128 | 129 | Sometimes the model will be "lazy" and elide chunks of edited files. If you see this happening, you can copy the missing parts from the left-hand side of the diff and paste them into the right-hand side. We know that's not ideal, and we're working hard on this issue. 130 | 131 | ## Edit code in Copilot Workspace 132 | 133 | ✨ TIP: Make edits directly in the code editors per file 134 | 135 | When Copilot Workspace has generated a suggestion, it is presented to you in the implementation panel. But those suggestions aren’t just read-only! You can edit them, and make changes as you desire. 136 | 137 | Edit code in Copilot Workspace 138 | 139 | And if you have a GitHub Codespace open, those edits will sync between Copilot Workspace and the GitHub Codespace too! 140 | 141 | ## Need to go back? 142 | 143 | ✨ TIP: You can use the undo and redo buttons to travel between an older and newer state of your workspace. 144 | 145 | You can use the undo and redo buttons to navigate back to a previous state of your workspace. That can include reverting an implementation, or the additions and tweaks that you may have made to your spec or plan. 146 | 147 | Use Undo and Redo to change states in Copilot Workspace 148 | 149 | 150 | ## On the go? Try Copilot Workspace on Mobile 151 | 152 | ✨ TIP: Copilot Workspace is mobile-friendly, so consider making changes on the go! 153 | 154 | Ideas can happen anywhere, whether you’re at your desk, in a coffee shop or on a bus. With that spark of creativity, you can use Copilot Workspace from your mobile to explore ideas! And if you didn’t fully complete your task, you can use the dashboard in Copilot Workspace to pick up where you left off. 155 | 156 | And if you'd like to easily access Copilot Workspace at any time, you can add it to your mobile homescreen by performing the following steps: 157 | 158 | 1. Open your mobile browser and navigate to the Copilot Workspace dashboard at [https://copilot-workspace.githubnext.com](https://copilot-workspace.githubnext.com). 159 | 2. Once the dashboard loads, tap on the browser's menu and select "Add to Home screen" to easily access Copilot Workspace from your home screen. 160 | 3. Confirm the action if prompted, and Copilot Workspace will be added to your home screen, providing a native app-like experience thanks to PWA support. 161 | 162 | ## Regaining access if you revoked OAuth 163 | 164 | Copilot Workspace is implemented as an OAuth application. If you revoked authorization for the application in your GitHub account settings, you'll no longer be able to use Workspace. You can restore your access at https://copilot-workspace.githubnext.com/ by logging out, then logging in and re-authorizing the OAuth app. 165 | 166 | ## Incoming Links 167 | 168 | ✨ TIP: Copilot Workspace has a capability for the task to be specified by query parameters when the subject is a repository, branch or pull request. 169 | 170 | ``` 171 | https://copilot-workspace.githubnext.com/githubnext/copilot-workspace/pull/695?task=Add%20more%20unit%20tests%20to%20this%20pull%20request. 172 | ``` 173 | 174 | The query parameters supported are 175 | 176 | - `task` - The description of the task. If not specified, and the subject is an issue, the body of the issue is used, otherwise no task body is used and the user must enter one. 177 | - `codeOwner` - The organization or individual for the code repository associated with an issue, e.g. `githubnext` for `githubnext/copilot-workspace` 178 | - `codeRepo` - The name of the code repository associated with an issue, e.g. `copilot-workspace` for `githubnext/copilot-workspace` 179 | - `branch` - The SHA or branch name to analyze the task at, e.g. `main` 180 | -------------------------------------------------------------------------------- /troubleshooting.md: -------------------------------------------------------------------------------- 1 | ## Troubleshooting 2 | 3 | ### Introduction 4 | 5 | Welcome to the troubleshooting guide for Copilot Workspace! In this section, we will provide you with helpful tips and solutions to common issues you may encounter while working with organizations and private repositories in Copilot Workspace. Our goal is to ensure that you have a smooth and productive experience. Let's dive in! 6 | 7 | ### Troubleshooting access 8 | 9 | If you are seeing an "Access Denied" error when trying Copilot Workspace for the first time, here are a few steps that may help: 10 | 11 | - Make sure you have an active, paid copilot license. Trial licenses only allow access once the subscription is upgraded to a paid plan. 12 | - Ensure there are no [trade restrictions](https://docs.github.com/en/site-policy/other-site-policies/github-and-trade-controls) on your account. 13 | - Verify that any organization with Copilot enabled has both the **Copilot Preview Features** setting and the **Copilot Extensions setting** turned ON. If necessary, reach out to your organization’s administrator for assistance. For more details on configuring organization settings for Copilot, please refer to the [documentation](https://docs.github.com/en/copilot/managing-copilot/managing-github-copilot-in-your-organization/managing-policies-for-copilot-in-your-organization). 14 | - For Enterprise users, enable the Copilot Workspace policy through your enterprise account (note this means accepting the [GitHub Next Terms and Conditions](https://github.com/githubnext/githubnext/blob/main/TERMS_AND_CONDITIONS.md)) 15 | 16 | ### Troubleshooting Organizations 17 | 18 | When working with organizations in Copilot Workspace, you may encounter some common issues. Here are some troubleshooting tips to help you resolve them: 19 | 20 | - **You are accessing an org that must approve OAuth apps**. As part of the login you authorize the OAuth app into various orgs, depending on the org policies with regard to OAuth apps. You can request access and the organization can approve the OAuth app. If you need to re-request access or revoke any access at all you can [control the status of your connection with the OAuth app](https://github.com/settings/connections/applications/903eccd8a9d2ff50288f). 21 | 22 | - **Although you appear to have the correct authorization credentials, the `github` organization has enabled OAuth App access restrictions, meaning that data access to third-parties is limited.** This is because an org restricts OAuth apps. Some of authorization attempts for orgs may fail if the org doesn't allow OAuth apps at all. This can affect even access to public repositories in organizations that deny access to OAuth apps. 23 | 24 | - **Resource protected by organization SAML enforcement. You must grant your OAuth token access to this organization**.You may be logging in to an organization with SAML control, e.g. Microsoft. They should 25 | 1. Log out of Copilot Workspace. 26 | 2. Go through SAML auth in the browser by looking at, say, a repository of the organization 27 | 3. Then log back into Copilot Workspace. 28 | - **Other known limitations to working within organizations:** 29 | 1. The enterprise (or org) must opt-in to Copilot feature previews. [Learn how to enable feature previews in GitHub.com](https://docs.github.com/en/get-started/using-github/exploring-early-access-releases-with-feature-preview). 30 | 2. The enterprise (or org) has set the Copilot Extension policy to Enabled. This can be done under your org / enterprise settings under Copilot > Copilot Policies. 31 | **Note:** Due to limitations with Copilot Licensing, all organizations of which you are a member must enable the Copilot Extension policy and opt-in for Copilot feature previews. If any organization of which you are a member disables these settings, you will not be able to access Copilot Workspace. 32 | 4. Developers within the enterprise (or org) must have paid Copilot licenses. 33 | 34 | 35 | ### Troubleshooting Private Repositories 36 | 37 | - **You can't access a private repository in your own account**. After login you should be able to access your personal private repositories unless you have removed access for the OAuth app. If you have trouble, it is possible it is because you landed in Copilot Workspace via a sharing link and have only given public repo privileges. You should log out and log back in again and this should restore access. Failing that you should [check the status of their connection with the OAuth app](https://github.com/settings/connections/applications/903eccd8a9d2ff50288f). 38 | 39 | ## Ambiguity Warnings 40 | 41 | If Copilot Workspace detects that your task is overly ambiguous/unclear (e.g. it doesn’t seem aligned with the goals/focus of the repo), then it may warn you about that and ask you to clarify the task further, before you can carry on. This is done to prevent hallucination in the specification and help guide you towards the “pit of success”, since subsequent stages of the workflow work best with sufficient detail. 42 | 43 | Ambiguous specification 44 | 45 | *A warning that a task is too ambiguous and that their intent needs to be clarified* 46 | 47 | 48 | ### Troubleshooting Codespaces 49 | 50 | - **Billable owner could not be determined for a new codespace, Repository may not be used for a codespace.** The CW OAuth app is not installed in the billable owner's organization. 51 | 52 | Please view the [Codespaces Guide](codespaces-guide.md) for more information on Codespaces and troubleshooting common errors. 53 | -------------------------------------------------------------------------------- /vscode.md: -------------------------------------------------------------------------------- 1 | # GitHub Copilot Workspace VS Code extension 2 | 3 | This Copilot Workspace VS Code extension allows you to use GitHub Copilot Workspace from the comfort of VS Code. Continue an existing session and edit and debug the proposed changes before creating a PR. Whether you use natural language to revise the plan or implementation, or edit files directly, you can use the full power of VS Code and its extension ecosystem all while syncing your local edits to GitHub Copilot Workspace on the web automatically (any saved file change will be visible online within few seconds). 4 | 5 | This is currently an alpha extension and we will be rolling out enhancements to the extension in multiple phases. 6 | 7 | 1. **Continue on:** Browse your Copilot Workspace sessions and sync changes so you can edit and debug your application in VS Code locally, using one of the other [VS Code Remote extensions](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.vscode-remote-extensionpack), or in your own [Codespace](https://github.com/features/codespaces). 8 | 9 | 2. **[IN-PROGRESS] Update your workspace using AI**: 10 | 11 | - **Available:** Brainstorming, natural language revisions to the plan and files in the plan, adding/editing/deleting plan files or steps. 12 | - **Planned**: Support for editing the task and answer text. 13 | 14 | 3. **[FUTURE] Create new:** While not available now, you'll be able to create a new Copilot Workspace session in VS Code. 15 | 16 | ## Getting started 17 | 18 | * [Quick Start](#quick-start) 19 | * [Browsing Sessions](#browsing-sessions) 20 | * [Managing Sessions](#managing-sessions) 21 | * [Planing and Implementing](#plan-and-implement) 22 | * [Natural Language Revisions](#natural-language-revisions) 23 | * [Brainstorming](#brainstorming) 24 | * [Known Limitations](#known-limitations) 25 | 26 | ### Quick Start 27 | 28 | 1. If you haven't already, install [Visual Studio Code](https://code.visualstudio.com/). 29 | 30 | 1. Next, open a session [on the web](https://copilot-workspace.githubnext.com) that you'd like to continue working on in VS Code. 31 | 32 | 1. Click on the `VS Code` button in the session screen. 33 | 34 | ![VS Code icon in web UX](./images/vscode/upper-right.png) 35 | 36 | 1. Allow your browser to open the link in VS Code when prompted. 37 | 38 | Follow the directions that appear in VS Code and make any selections when prompted, and you'll be guided towards syncing the session to your local machine. That's it! 😎 39 | 40 | Here is generally what you can expect to see: 41 | 42 | 1. VS Code will open (if it isn't already running), and you'll be prompted to install the Copilot Workspace extension and then open the URI. If the extension is already installed, you'll just be asked about the URI. Either way, open the URI. 43 | 44 | 45 | 46 | 47 | 1. **[One time]** If you haven't signed in already, you'll be prompted to do so. Click the `Sign in` and complete the sign in process in the browser that opens. 48 | 49 | 50 | 51 | 52 | 1. If the VS Code instance already has a folder with the related repository in it open, the extension will immediately start syncing the session locally. Otherwise you may be prompted to clone the repository or pick an existing folder with it in it. 53 | 54 | 55 | 56 | Once syncing has begun, your local repository will switch to GitHub Copilot Workspace tracking branch with a `ghcw-session` prefix as you can see in the status bar. This is a temporary branch for this session, so you should **not** push your local changes. 57 | 58 | 59 | 60 | Any edits make to the local files will be automatically synced back to the web session. You only have to save a local file and your change will be visible within a few seconds online (no need to push anything). This allows you to use the full power of VS Code with GitHub Copilot Workspace. 61 | 62 | However, if you picked a session that doesn't yet have an implementation with updated files to start syncing, you'll be notified that you can start syncing once you [have an implementation](#planning-and-implementing). 63 | 64 | 65 | 66 | In addition to editing and debugging, you can also make [revisions using natural language](https://github.com/githubnext/copilot-workspace-user-manual/blob/main/vscode.md#natural-language-revisions) or adjust the [plan and implementation](https://github.com/githubnext/copilot-workspace-user-manual/blob/main/vscode.md#planning-and-implementing). When you're done, you can either: 67 | 68 | - Create / update a branch and optionally create a PR by clicking on the **Push Changes into Branch...** icon in the `Plan` view using the command palette (F1 or Cmd/Ctrl+Shift+P). 69 | - Or hop back on the web to push updates to the original branch or create a PR from your session. There's a quick access link in the `...` menu on top of the `Plan` and `Task` views. 70 | 71 | ## Browsing Sessions 72 | 73 | Even if you are not syncing a session locally, you can still browse through your sessions and view their details. To browse and manage your sessions, first click on the `GitHub Copilot Workspace` icon in the activity bar on the left side of the VS Code window. 74 | 75 | 76 | 77 | 78 | After you've clicked the activity bar icon, you'll either see list of your sessions, or details about a specific session you've already selected. 79 | 80 | The session list is sorted by repository. Any repository that applies to currently opened VS Code folders will be on top. You can always get back to the session list when viewing session details by clicking on the `Back to Session List` arrow in the `Task` view or using the **GitHub Copilot Workspace: Back to Session List** command from the Command Pallette (F1 or Ctrl/Cmd+Shift+P). 81 | 82 | Selecting a session in the session list will hide the list and show the related session details instead. A `Task` (or Issue or Pull Request) view and `Plan` view will be visible. Each view can be expanded into a larger panel by clicking on the "full screen" icon. 83 | 84 | The `Task` view includes a description of the task along with links to additional information. The `Plan` view will include details about the related plan for your session (if one exists yet) any files currently in the plan. 85 | 86 | If the [plan has already been implemented](#planning-and-implementing), you'll be able to view any changed files by clicking on file in the plan. 87 | 88 | 89 | 90 | When syncing is active, clicking on the file will open a local changes view of the synced contents. This view is editable and the changes will be synced back to the web session. If the session is not syncing, you will see the changes currently stored in the web session in a read-only mode. 91 | 92 | You can also click on the `Open File` icon when hovering on an file in the plan to open the file (instead of the changes view) in a new tab in VS Code. You may be prompted to start syncing the session if you are not already. 93 | 94 | ## Managing Sessions 95 | 96 | You can sync session file changes locally for any session that has a plan and an initial implementation. 97 | 98 | If the session you opened does not yet have an implementation, see [Planning and Implementing](#planning-and-implementing) for information on creating one from VS Code. You can then sync its contents locally once done. 99 | 100 | ### Stopping Syncing Changes 101 | 102 | The quick start highlighted a fast way to start syncing your session's changes locally, so let's cover how to stop syncing changes next. 103 | 104 | If the session list is visible, you will see a green checkbox next to any session that is currently being synced. When hovering over this session, you will see a `Stop Syncing Changes` button. Otherwise, if the session details are visible for a session that is currently syncing, you will find this same button in the `Plan` view. Simply click this button in either location to stop syncing. 105 | 106 | | Session List | Session Details | 107 | | :--- | :--- | 108 | | | | 109 | 110 | Alternatively, you can use the Command Palette (F1 or Ctrl/Cmd+Shift+P) and select the **GitHub Copilot Workspace: Stop Syncing Changes** command when you have the session details open. 111 | 112 | You'll be switched back to the branch you where on when you started syncing changes, or **main** (or master) if nothing else. Since the changes you made locally are kept in sync automatically when syncing is active, the working tree is also cleaned out so you can easily jump in and out of sessions. 113 | 114 | The next time you sync this same session, the session will go back to this tracking branch and the latest changes in GitHub Copilot Workspace - including your edits - will appear again. 115 | 116 | Note that if you manually change the branch away from the one set when syncing began, syncing will also automatically stop. However, in this case, any changes you made will be kept in the working tree to make sure you don't lose something you intended to keep. Stopping syncing as described above will ensure you've got a clean working tree to continue making other changes. 117 | 118 | ### Syncing Changes Locally 119 | 120 | As outlined in the quick start, you can always click on the VS Code icon in the GitHub Copilot Workspace web UI to start syncing changes locally. But you can also start syncing a session directly from within VS Code. 121 | 122 | However, as described in these previous sections, note that only sessions with a [plan and an initial implementation](#planning-and-implementing) can be synced locally. 123 | 124 | If session list is visible, hovering over a session that is not currently being synced (no green checkbox), will show a `Stop Syncing Changes` button. Otherwise, if the session details are visible instead, you will see this same button the `Plan` view (assuming syncing is inactive for this session). Click this button to start syncing changes for the session locally. 125 | 126 | Note that any other existing session that is already syncing for the same repository will automatically stop syncing first, so you don't have to worry about conflicts. 127 | 128 | | Session List | Session Details | 129 | | :--- | :--- | 130 | | | | 131 | 132 | Similarly, you can use the Command Palette (F1 or Ctrl/Cmd+Shift+P) and select the **GitHub Copilot Workspace: Sync Changes Locally** command when you are in the detail view for a session to start syncing. 133 | 134 | Next you may be prompted as follows: 135 | 1. If you do not currently have the repository for the session open in VS Code, you will be prompted to open a folder with the repository or to clone the repository in a fresh location. 136 | 1. If you do have the correct repository open, but the current working tree has uncommitted changes, you'll be asked what you want to do with them. 137 | 138 | Either way, once this is done, your local repository will be on a GitHub Copilot Workspace tracking branch with a `ghcw-session` prefix as you can see in the status bar. 139 | 140 | 141 | 142 | Regardless, any edits make to the local files will be synced back to the web session, so you do not need to worry about committing or loosing your changes. 143 | 144 | ### Visibility to Sync Status and Processing State 145 | 146 | Since you won't always have the `Plan` view visible while you work, GitHub Copilot Workspace has a status bar item that can help you understand what the extension is doing at that moment. Here are some examples of what you will see: 147 | 148 | | Example | Description | 149 | | :--- | :--- | 150 | | | The extension is signed in, but but idle. | 151 | | | Syncing is enabled for a session, but the extension is currently idle. | 152 | | | The extension is performing an operation indicated by the text (`Starting implementation...`) and spinning loading or sync icon (when files are transferring). | 153 | | | Here, an error occurred while syncing. Clicking on the status bar item will show more information. | 154 | 155 | Clicking on this status bar item will take you to the session details for the session you are syncing (or the session list if you are syncing multiple sessions in a multi-root workspace with multiple repos). The status bar will also turn red if a sync error has occurred, and clicking on it should provide you options to remediate the issue. 156 | 157 | #### Plan View Banner 158 | 159 | However, if you do have the `Plan` view up, you can look at the status banner to see what is happening and in some cases take quick actions based on the current state. 160 | 161 | 162 | 163 | 164 | ### Pushing Session Changes to a Branch or PR 165 | 166 | While the extension automatically syncs changes to the web, you may want to push your changes to a branch or create a PR from the session. This is useful when you are either done with the session, or you want to keep changes to something that is not automatically synced - like something in the .gitignore file or large files that you received a notification where ignored. 167 | 168 | Thankfully, the you can use following buttons in the `Plan` view when you are syncing a session to perform these actions. Note that the command name in this table is also the name of the command in the **Command Palette** (F1 or Ctrl/Cmd+Shift+P) when the appropriate session is visible in the side bar. 169 | 170 | | Button | Command | Description | Location(s) | 171 | | :--- | :--- | :--- | :--- | 172 | | | Push Changes into Branch... | Pushes changes to a new or existing local branch, optionally pushes them remotely too. | Plan view when file syncing is enabled, `...` context menu. | 173 | | | Create PR from Changes... | Pushes changes to a specified remote branch, then makes opens the PR UX in VS Code to let you enter details on the request. | Plan view when file syncing is enabled, `...` context menu. | 174 | 175 | 176 | ### Deleting a Session 177 | 178 | To delete a session, you click on the trash can icon next to the item in the session list. If you are currently viewing a session's details, select **Delete Session** from the context menu that appears when clicking on the `...` button on the `Task` or `Plan` views. 179 | 180 | Alternatively, you can use thee Command Palette (F1 or Ctrl/Cmd+Shift+P) and select the **GitHub Copilot Workspace: Delete Session** command when you are viewing a session's details. 181 | 182 | ## Planning and implementing 183 | When the session details are visible (and you see the `Task` and `Plan` views), you can make changes to the plan and its related implementation for the session right from VS Code. 184 | 185 | In fact, can also generate and implement an initial plan if your session doesn't have one yet. 186 | 187 | You will find a number of different options for interacting with the plan by clicking on the `...` button in the `Plan` view. However, the most common actions will appear as icons. The table below outlines what each of these does. Note that the command name in this table is also the name of the command in the **Command Palette** (F1 or Ctrl/Cmd+Shift+P) when the appropriate session is visible in the side bar. 188 | 189 | | Button | Command | Description | Location(s) | 190 | | :--- | :--- | :--- | :--- | 191 | | | Generate Plan | Generates a plan for the session and creates an inital implementation. | Plan view when no plan exists. Regenerate plan is available in the `...` context menu afterwards. | 192 | | | Implement Plan | Implement (or re-implement) the selected items in the plan view. | Plan view when plan exists, `...` context menu. | 193 | | | Revise Plan | Make revisions to the entire plan using natural language. Will automatically implement the requested changes. | Plan view when plan exists, `...` context menu. | 194 | | | Sync Changes Locally | See Managing Sessions. Start syncing session changes locally. | Plan view if there is an implementation, and the session is not already syncing, `...` context menu. | 195 | | | Stop Syncing Changes | See Managing Sessions. Stops syncing session changes locally. | Plan view if the visible session is already syncing, `...` context menu. | 196 | | | Push Changes into Branch... | Pushes changes to a new or existing local branch, optionally pushes them remotely too. | Plan view when file syncing is enabled, `...` context menu. | 197 | | | Create PR from Changes... | Pushes changes to a specified remote branch, then makes opens the PR UX in VS Code to let you enter details on the request. | Plan view when file syncing is enabled, `...` context menu. | 198 | 199 | The `...` context menu is also available for files and items in the plan when you hover over them. This context menu will allow you to view the files, their changes, or edit, move, delete, or the list items as needed. 200 | 201 | ### Natural Language Revisions 202 | 203 | You can also make revisions to the plan and implementation using natural language. This can be done for the entire plan as highlighted previously, or you can make targeted revisions to a file in the plan. You can even add another file to the plan and revise it in one shot. 204 | 205 | To make file-level revisions easy, there are buttons in the upper-right of any open editor window for a file that can be part of the plan. 206 | 207 | 208 | 209 | Here's a summary of where you can trigger these kinds of revisions: 210 | 211 | 212 | | Button | Command | Description | Location(s) | 213 | | :--- | :--- | :--- | :--- | 214 | | | Revise Plan | Make revisions to the entire plan using natural language. Will automatically implement the requested changes. | Plan view when plan exists, `...` context menu. | 215 | | | Revise File | Make targeted revisions to a file using natural language. Will automatically either add the file to the plan or add a step to an existing entry, and then implement the requested changes. | Plan file items (hover), Editor actions (upper-right), `...` context menu. | 216 | | | Add File to Plan | Adds the file to the plan, but makes no revisions to it. | Editor actions (upper-right), `...` context menu. | 217 | 218 | ## Brainstorming 219 | 220 | > Note that this feature is new to Copilot Workspace, so you may encounter more rough edges that other parts of the experience. Please let us know if you have any feedback! 221 | 222 | Brainstorming provides a way for you to interact with Copilot Workspace to refine the task you want to perform. You can ask or select suggested questions to learn more about potential options for your task and then add the answers you like as additional context to use when planning and implementing. This feature is now available in VS Code so that you can refine your initial task and plan directly from your editor. 223 | 224 | ### Accessing the Brainstorming panel 225 | 226 | You can access brainstorming in a few ways. First, you can click on one of the following buttons to get started. As in other cases in this document, the Command column contains the name of the command in the **Command Palette** (F1 or Ctrl/Cmd+Shift+P) when the appropriate session is visible in the side bar. 227 | 228 | | Button | Command | Description | Location(s) | 229 | | :--- | :--- | :--- | :--- | 230 | | | Brainstorm | Opens the `Brainstorming` panel. If the question "How should I solve this task?" has not already been answered (aka the "spec" has not been created yet), you will see that start at this point. | Task view, `...` context menu. | 231 | | | Answer New Question... | Lets you ask Copilot Workspaces a specific question, and the `Brainstorming` panel then appears with the answer. | Task view, `...` context menu. | 232 | 233 | The `Task` view also includes a list of questions or answers that have already been added to the task in a section after the description. You can click on any of these to see the answer in the `Brainstorming` panel and continue brainstorming. 234 | 235 | 236 | 237 | ### Using the Brainstorming Panel 238 | 239 | When you open the `Brainstorming` panel, you will see the current answer to a question. By default this will be the question "How should I solve this task?" which is always added to the Task. You will then see a series of buttons at the top with possible actions. 240 | 241 | 242 | 243 | Let's go through the buttons you may see and what they do. 244 | 245 | | Button | Description | 246 | | :--- | :--- | 247 | | **Add to Task** | Adds the current answer to the task. This will also automatically trigger regeneration of the "How should I solve this task?" question / spec. Note that answer to any question added to the task will appear in below the task description in the `Task` view. | 248 | | **Remove from Task** | Removes the current answer from the task. This will also automatically trigger regeneration of the "How should I solve this task?" question / spec. | 249 | | **Regenerate** | Asks Copilot Workspace to try to answer the question again. | 250 | | **Delete** | Deletes both the question and its related answer from the list of existing answers. | 251 | | **Answer** | Lets you ask Copilot Workspace a new question. | 252 | | **Open Existing** | Displays a list of answers that have already been generated that you can open in the `Brainstorming` panel. Any answers that have been added to the task will have a check next to them. Useful if you did add an answer to the task or removed it, and changed your mind. | 253 | 254 | #### Multiple Answers 255 | 256 | Sometimes you may also be presented with multiple possible answers to a question. In this case, you can select the one you want to add to the task by clicking on the empty circle next to the option - which will then turn into a green checkmark indicating its been added. If you change your mind, you can click on the checkmark to remove it. 257 | 258 | 259 | 260 | 261 | #### Suggested Questions 262 | 263 | In addition, below the current answer for the question, you will see a list of **suggested questions** that may apply to your task. You can click on any of these to see the answer in the `Brainstorming` panel. 264 | 265 | ### Updating the Plan When You Are Done 266 | 267 | When you are done brainstorming, you can regenerate your plan by clicking `...` in the `Plan` view and selecting **Regenerate Plan**. (And if you don't have a plan yet, you can generate one by clicking `...` in the `Plan` view and selecting **Generate Plan** as described previously.) 268 | 269 | However, if you are generally happy with the plan as it exists, you can make a **[natural language revision](#natural-language-revisions)** to factor in the new information in a more specific way. 270 | 271 | ## Known Limitations 272 | 273 | **Features:** As outlined above, you need to use the web UI for the following as they are not yet available in VS Code: 274 | * Starting a new session 275 | * Direct text edits to the task or an answered question 276 | 277 | **File syncing:** 278 | * File syncing has some limitations placed on it during the technical preview such as not syncing binary files, certain paths or file types, or files over a certain size. These limitations are subject to change as we continue to improve. When using the VS Code extension directly you will be notified when one of these limitations has been hit, and can see which files have been ignored from the **GitHub Copilot Workspace: Show Files Ignored While Syncing** command from the command palette (F1 or Ctrl/Cmd+Shift+P). 279 | * File syncing status does not cross open windows. So if you have multiple windows for the same folder (and repository) open, and each are syncing, you can end up transmitting or applying same file contents multiple times and fail to apply updates. To avoid this, either use a single window for a given repository, or do not start file syncing for more than one. 280 | * Files that where ignored while syncing will not result in a notification when working from a Codespace started by the GitHub Copilot Workspace web UI since the use of the extension in this case is optional. File syncing is handled by a stand-alone process in this case. 281 | 282 | Note that if you see something unexpected, you can check the output view for more details. From the file menu, select **View** > **Output** and then select **GitHub Copilot Workspace** from the dropdown. This can help you identify what happened and can be used to help us diagnose any issues you may encounter. --------------------------------------------------------------------------------