Skip to content

Commit

Permalink
prompt testing
Browse files Browse the repository at this point in the history
  • Loading branch information
rag2111 committed May 8, 2024
1 parent 65b2c68 commit 7e5961d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/OpenAI.Plugin.FSI/CompareProductsPlugin.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public CompareProductsPlugin(ILoggerFactory loggerFactory, Kernel kernel)
}

[Function("Compare Financial Products Plugin")]
[OpenApiOperation(operationId: "CompareProductsPlugin", tags: new[] { "CompareProductsPlugin" }, Description = "Compares a given financial product with those avialable in the market")]
[OpenApiOperation(operationId: "CompareProductsPlugin", tags: new[] { "CompareProductsPlugin" }, Description = "Compares a given financial product with those avialable in the market")]
[OpenApiRequestBody("application/json", typeof(ExecuteFunctionRequest), Description = "Variables to use when executing the specified function.", Required = true)]
[OpenApiResponseWithBody(statusCode: HttpStatusCode.OK, contentType: "application/json", bodyType: typeof(ExecuteFunctionResponse), Description = "Returns the response from the AI.")]
[OpenApiResponseWithBody(statusCode: HttpStatusCode.BadRequest, contentType: "application/json", bodyType: typeof(ErrorResponse), Description = "Returned if the request body is invalid.")]
Expand All @@ -46,7 +46,7 @@ public async Task<HttpResponseData> Run(

// Create the chat history
ChatHistory chatMessages = new ChatHistory("""
GET THE TOP FINANCIAL PRODUCTS IN SPAIN IN TERMS OF PROFITABILITY
GET THE TOP FINANCIAL PRODUCTS IN SPAIN. SUMMARIZE THE INVESTMENT POLICIES, RISKS AND COMMERCIAL TERMS
""");

// Get the chat completions
Expand Down
4 changes: 2 additions & 2 deletions src/OpenAI.Plugin.FSI/Prompts/CompareProducts/skprompt.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
YOU ARE A FRIENDLY ASSISTANT WHO LIKES TO FOLLOW THE RULES.
USE THE SAME LANGAUGE THE PRODUCT IS DESCRIBED IN AND TRANSLATE TO IT IF NEEDED.

SEARCH FOR SIMILAR PRODUCTS TO THE GIVEN ONE AND COMPARE
COMPARE THE FOLLOWING FINANCIAL PRODUCTS:

+++++
{{$products}}
+++++

WITH THE PRODUCT BELLOW IN TERMS OF PROFITABILITY.
WITH THE PRODUCT BELLOW.

+++++
{{$product}}
Expand Down

0 comments on commit 7e5961d

Please sign in to comment.