Knowledge bases are a way to bring together Markdown documentation across one or more repositories. When you ask a question in Copilot Chat with a knowledge base selected, Copilot will search the knowledge base for relevant information and synthesize a response.
Creating a knowledge base
You can create a knowledge base from a single repository or a selection of repositories. You can create a knowledge base using public, private, and/or internal repositories.
Knowledge bases you create will be accessible by all organization members with a Copilot Enterprise plan. When an organization member uses a knowledge base as context in GitHub Copilot Chat, the response will only use data from repositories that the organization member has read access to.
-
No canto superior direito de GitHub, selecione sua foto de perfil e clique em Your organizations.
-
Ao lado da organização, clique em Configurações.
-
In the left sidebar, click Copilot then click Knowledge bases.
-
To the right of "Knowledge bases", click New knowledge base.
-
In the "Name" field, enter a unique name for the knowledge base. Optionally, in the "Description" field, you can add a description for the knowledge base.
-
Under "Content", to see a full list of available repositories, click Select repositories.
-
To select a repository or repositories, click the checkbox next to the repository name. When you're finished selecting repositories, click Apply.
-
Optionally, you can specify particular paths within the selected repositories for searches. When a search is conducted using the knowledge base, only the files located in those designated paths will be included in the results. For more information on specifying repository paths, see Entender a sintaxe de pesquisa de código do GitHub
- Click Edit file paths.
- List the paths you want to include in the knowledge base, one path per line. When you're finished, click Apply.
-
Click Create knowledge base.
Updating a knowledge base
Organization owners can update a knowledge base created in their organization.
-
No canto superior direito de GitHub, selecione sua foto de perfil e clique em Your organizations.
-
Ao lado da organização, clique em Configurações.
-
In the left sidebar, click Copilot then click Knowledge bases.
-
To the right of the knowledge base you want to edit, click .
-
Make your desired changes to your knowledge base.
-
Click Update knowledge base.
Deleting a knowledge base
Organization owners can delete a knowledge base created in their organization.
-
No canto superior direito de GitHub, selecione sua foto de perfil e clique em Your organizations.
-
Ao lado da organização, clique em Configurações.
-
In the left sidebar, click Copilot then click Knowledge bases.
-
To the right of the knowledge base you want to delete, click .
-
In the "Confirm deletion" dialog box, review the information and click Delete.
Next steps
- To learn how to use knowledge bases in Copilot Chat, see Asking GitHub Copilot questions in GitHub and Asking GitHub Copilot questions in your IDE.