Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix chat response message #28

Merged
merged 1 commit into from
Oct 19, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions apps/SKonsole/Commands/PromptChatCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ private static async Task RunChat(IKernel kernel, ILogger? logger, ISKFunction c
var history = string.Empty;
contextVariables.Set("history", history);

var botMessage = await kernel.RunAsync(contextVariables, chatFunction);
var result = await kernel.RunAsync(contextVariables, chatFunction);
var botMessage = result.GetValue<string>();
var userMessage = string.Empty;

static void HorizontalRule(string title, string style = "white bold")
Expand Down Expand Up @@ -115,7 +116,7 @@ static void HorizontalRule(string title, string style = "white bold")
var result = await kernel.RunAsync(contextVariables, chatFunction);

task.StopTask();
return result;
return result.GetValue<string>();
});
}
}
Expand Down
Loading