如今,大多数开发者都在与 AI 智能体协同工作,或者至少熟悉如何这样做。智能体帮助你探索想法并将其转化为行动,从规划项目到自动化工作流程。很多时候,你只需要一次对话就能推动工作进展。
但那些不太适合对话模式的任务呢?
有些任务在你能够看到信息并与之交互时会更容易完成。你可能需要对积压任务进行分类、可视化复杂信息,或者将来自多个来源的信息整合在一起。可视化界面能让你更轻松地理解模式、发现关联并采取行动。
你无需通过一长串提示词和回复来工作,而是可以直接使用画布与你面前的信息进行交互。
使用画布
这些共享的交互式界面是 Copilot 应用的扩展功能,称为画布。画布是 GitHub Copilot 应用中的一个界面,开发者和智能体可以在其中实时协作。这些共享的交互式界面被称为画布扩展。
智能体可以在工作时更新画布,而你可以通过点击、编辑和其他操作与同一个工作区进行交互。你的操作可以反馈给智能体,也可以由画布在本地处理。
你可以通过让 Copilot 对画布进行迭代来不断调整体验——添加新功能、优化现有功能等等。画布可以随着你的工作一同演进。
要创建画布,请在 GitHub Copilot 应用的智能体会话中使用 /create-canvas,然后描述你希望它创建什么以及它应该支持哪些能力。
由于画布是根据提示词生成的,并且会随着你的工作流程而演进,因此它们可以有多种形式。有些帮助你可视化信息,有些帮助你采取行动,还有一些则提供更有趣的方式来处理积压任务。
以下是画布扩展可以实现的一些示例:
问题分类助手
目标:以快速、可视化的方式对 GitHub Issues 进行分类。
提示词:/create-canvas 创建一个界面,让我能够以卡片形式轻松浏览仓库中的 issues。向右滑动表示发布,向左滑动表示拒绝。
结果:画布展示了一个卡片式界面,每个议题会逐一呈现。你可以直接在界面上进行操作。滑动时,画布会实时更新,记录决策并将项目移入相应的分类区。
交互式代码库关系图
目标:可视化展示项目的结构以及各组件之间的关联方式。
提示词:/create-canvas 生成一个色彩丰富、可交互的关系图,展示该项目中代码如何协同工作、各部分如何相互关联等。
结果:画布生成了一个动态的代码库关系图,每个节点代表系统的不同部分。你可以通过悬停、拖拽和筛选来探索不同的层级。你可以直接与架构进行交互,将对代码库的静态理解转变为可以主动探索的对象。
会话工作树视图
目标:可视化展示所有活跃的 GitHub Copilot 应用会话及其关联的 git 工作树,清晰标示哪些是活跃的、哪些是过时的,并能在需要时轻松清理。
提示词:/create-canvas 创建一个工作树视图,帮助我查看所有当前会话,并了解它们是活跃的还是已孤立。允许我在需要时通过几次点击进行清理。
结果:画布生成了一个可视化视图,展示我的工作树,并清晰标示哪些是活跃的、哪些是当前过时或已孤立的。我可以通过点击按钮来清理过时的工作树。
智能体提示词教练
目标:通过回顾过往交互,提出更清晰、更有效的与智能体协作方式的建议,从而提升提示词质量。
提示词:/create-canvas 创建一个交互式提示词教练,它能针对你在会话中与技能、MCP 服务器等交互时使用的提示词,提出改进建议。注意指出任何拼写错误、语法错误等。
结果:画布展示了一个过往提示词列表,并对每条进行分析,提出诸如缺少上下文、拼写问题等改进建议。你可以利用这些技巧来优化未来的提示词,提升清晰度,并从智能体那里获得更一致的结果。
知识查找器
目标:通过跨 Slack、Teams、电子邮件和文档进行搜索,找到对特定文件或主题有背景了解的人。
提示词:/create-canvas 创建一个方式,让我能够跨 Slack、Teams、电子邮件和文档进行搜索,找到了解某个特定文件的人,或者对相关背景更熟悉的人。
结果:基于搜索,该画布会跨多个工具进行查找,并呈现与给定文件或主题关联最紧密的人员。它会高亮显示该人员是谁,以及关联是在哪里找到的。这让你能快速了解某人与某个主题的关联,从而更容易联系对方以获取更多信息。
随身携带
这些示例仅仅触及了画布功能的皮毛。画布能将 AI 从一个对话工具转变为一个你可以可视化信息、探索不同工作流程,并将枯燥任务变成你真正愿意完成的趣味体验的场所。
画布是一个有趣、共享的工作空间,你和智能体可以在这里一起思考、探索并采取行动。
想试试画布扩展功能吗?你可以从 GitHub Copilot 应用开始。阅读文档了解更多信息 >
Most developers are now working alongside agents, or are at least familiar with how to do so. Agents help you explore ideas and turn them into action, from planning projects to automating workflows. Oftentimes, a conversation is all you need to move your work forward.
But what about tasks that don’t quite fit the conversation mold?
Some tasks are easier when you can see and interact with the information. You may need to triage a backlog, visualize complex information, or bring information together from multiple sources. A visual interface makes it easier to understand patterns, spot connections, and take action.
Instead of working through a long chain of prompts and responses, you can use canvases to interact directly with the information in front of you.
Working with canvases
These shared, interactive surfaces are extensions of the Copilot app called canvases. A canvas is an interface in the GitHub Copilot app where developers and agents can collaborate in real time. These shared, interactive surfaces are called canvas extensions.
The agent can update the canvas as it works, and you can interact with that same workspace through clicks, edits, and other actions. Your interactions can be sent back to the agents or processed locally by the canvas.
You can continuously shape the experience by asking Copilot to iterate on your canvas—adding new functionality, refining existing features, and more. The canvas can evolve alongside your work.
To create a canvas, use /create-canvas in your agent session in the GitHub Copilot app, then describe what you want it to create and what capabilities it should be able to support.
Because canvases are generated from a prompt and evolve alongside your workflow, they can take many forms. Some help you visualize information, some help you take action, others provide a more entertaining way to tackle your backlog.
Here’s some examples of what’s possible with canvas extensions:
Issue triage helper
Goal: Quickly triage GitHub Issues in a fast, visual way.
Prompt: /create-canvas Create an interface that allows me to easily swipe through issues in a repo in card format. Can swipe right to ship, left to reject.
Result: The canvas shows a card-based interface where each issue is surfaced one at a time. You can take action directly from the UI. As you swipe, the canvas updates in real time, tracking decisions and moving the items into the appropriate buckets.
Interactive codebase diagram
Goal: Visualize how a project is structured and how its components relate to each other.
Prompt: /create-canvas Render a colorful, interactive diagram showing how the code in this project is working together, show how things are related, etc.
Result: The canvas generates a dynamic diagram of the codebase where each node represents a different part of the system. You can hover, drag, and filter to explore the different layers. You can interact with the architecture directly, turning a static understanding of a codebase into something you can actively explore.
Sessions worktree view
Goal: Visualize all active GitHub Copilot app sessions and their associated git worktrees, clearly indicating which are active and which are stale, with the ability to easily clean things up where needed.
Prompt: /create-canvas Create a worktree view that will help me see all of my current sessions and whether or not they are active or orphaned. Allow me to clean them up with a few clicks where needed
Result: The canvas generates a visual showing my worktrees with clear indication of what is active and what is currently stale or orphaned. I can clean up stale worktrees with the click of a button.
Agent prompt coach
Goal: Improve prompt quality by reviewing past interactions and suggesting clearer, more effective ways to work with agents.
Prompt: /create-canvas Create an interactive prompt coach that suggests to you how you could have improved your previous prompts in your sessions with skills, mcp servers, etc. Make note of any spelling errors, syntax errors, etc.
Result: The canvas shows a list of previous prompts and analyzes each one, suggesting improvements such as missing context, spelling issues, and more. You can use these tips to refine your future prompts, improve clarity, and get more consistent results from the agent.
Knowledge finder
Goal: Find people who have context on a specific file or topic by searching across Slack, Teams, email, and documentation.
Prompt: /create-canvas Create a way that I can search across Slack, Teams, Email and docs to find people with knowledge of a specific file or someone that would have more context.
Result: Based on the search, the canvas looks across multiple tools and surfaces the people that are most connected to a given file or subject. It highlights who the person is, and where the connection was found. This allows you to quickly understand someone’s connection to a topic and make it easier to reach out for more information.
Take this with you
These examples only scratch the surface of what you can do with canvases. Canvases can turn AI from a conversational tool into a place where you can visualize information, explore different workflows, and turn boring tasks into fun experiences that you’ll actually want to complete.
Canvases are a fun, shared workspace where you and the agent can think, explore, and take action together.
Want to try out canvas extensions? You can get started in the GitHub Copilot app. Read the docs for more information >