microsoft / microsoft/copilot-camp
Lab B2 - 400 Validation error at #/data_sources/0/azure_search/parameters/role_information: Extra inputs are not permitted
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 664
- Forks
- 175
- Avg merge
- 1m
- Merged PRs (30d)
- 7
Description
When going thru the lab there seems to be an issue with the
defaultPrompt: async () => {
const template = await prompts.getPrompt('chat');
const skprompt = fs.readFileSync(path.join(__dirname, '..', 'prompts', 'chat', 'skprompt.txt'));
const dataSources = (template.config.completion as any)['data_sources'];
dataSources.forEach((dataSource: any) => {
if (dataSource.type === 'azure_search') {
dataSource.parameters.authentication.key = config.azureSearchKey;
dataSource.parameters.endpoint = config.azureSearchEndpoint;
dataSource.parameters.index_name = config.indexName;
dataSource.parameters.embedding_dependency.deployment_name =
config.azureOpenAIEmbeddingDeploymentName;
dataSource.parameters.role_information = `${skprompt.toString('utf-8')}`;
}
});
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the Lab B2 defaultPrompt implementation shown in the issue and inspect how prompts/chat/skprompt.txt is used to build the Azure Search data source. Reproduce the 400 validation error and compare the generated data_sources/0/azure_search/parameters object with the accepted schema. Done means the lab no longer sends the extra role_information input and validation succeeds.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, typescript
- Domain
- cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100