C# Bindings - Prompt formatting (#712)

* Added support for custom prompt formatting

* more docs added

* bump version
This commit is contained in:
mvenditto
2023-05-29 01:57:00 +02:00
committed by GitHub
parent 44c23cd2e8
commit 9eb81cb549
5 changed files with 55 additions and 3 deletions

View File

@@ -0,0 +1,16 @@
namespace Gpt4All;
public class DefaultPromptFormatter : IPromptFormatter
{
public string FormatPrompt(string prompt)
{
return $"""
### Instruction:
The prompt below is a question to answer, a task to complete, or a conversation
to respond to; decide which and write an appropriate response.
### Prompt:
{prompt}
### Response:
""";
}
}