MicrosoftDocs / semantic-kernel-docs

Semantic Kernel (SK) is a lightweight SDK enabling integration of AI Large Language Models (LLMs) with conventional programming languages.
MIT License
172 stars 100 forks source link

Code Correction in Handlebars template variable(chatHistory) 04-Templatizing-Prompts/Program.cs #77

Open rainmakerho opened 6 months ago

rainmakerho commented 6 months ago

Description:

There seems to be a discrepancy in the code snippets provided in the Create handlebars template for intent 04-Templatizing-Prompts /Program.cs and Semantic Kernel Templatizing your prompts

In the Handlebars template, the code {{#each chatHistory}} should be replaced with {{#each history}}. Alternatively, the code { "history", history } should be replaced with { "chatHistory", history } for the program to function correctly.

This issue is causing confusion and may lead to incorrect implementation. A prompt correction would be appreciated.

Steps to Reproduce:

  1. Visit the Semantic Kernel Templatizing your prompts page or Create handlebars template for intent 04-Templatizing-Prompts /Program.cs.
  2. Scroll down to the code snippets section.
  3. Observe the discrepancy in the Handlebars template and the corresponding code.

Expected Result:

The Handlebars template should be {{#each history}} or the code should be { "chatHistory", history }.

Actual Result:

The Handlebars template is {{#each chatHistory}} and the code is { "history", history }.

Thank you for your attention to this matter.