-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added more Assert methods. ContainsInformationSubset
- Loading branch information
Showing
10 changed files
with
177 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
.../Internals/SemanticKernel/Plugins/InformationPlugin/ContainsInformationSubset/config.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"schema": 1, | ||
"type": "completion", | ||
"description": "Compare subset text", | ||
"completion": { | ||
"max_tokens": 10, | ||
"temperature": 0.0, | ||
"top_p": 0.0, | ||
"presence_penalty": 0.0, | ||
"frequency_penalty": 0.0 | ||
}, | ||
"input": { | ||
"parameters": [ | ||
{ | ||
"name": "actual", | ||
"description": "The value to be compared against", | ||
"defaultValue": "" | ||
}, | ||
{ | ||
"name": "expected", | ||
"description": "The expected value", | ||
"defaultValue": "" | ||
} | ||
] | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
...Internals/SemanticKernel/Plugins/InformationPlugin/ContainsInformationSubset/skprompt.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Your task is to check if the [SUBSET] is a subset of the information provided by [TEXT] text. | ||
If affirmative, return TRUE; if negative, return FALSE. | ||
Analyze the [SUBSET] and [TEXT] and determine if [SUBSET] exclusively contains information included in [TEXT]. | ||
Remember, if [SUBSET] contains more information than [TEXT], return false. | ||
Don't provide any explanation, just return TRUE or FALSE. | ||
|
||
[TEXT] | ||
{{$expected}} | ||
[END TEXT] | ||
|
||
[SUBSET] | ||
{{$actual}} | ||
[END SUBSET] |
14 changes: 14 additions & 0 deletions
14
...ticAssertions/Internals/SemanticKernel/Plugins/InformationPlugin/InformationPluginInfo.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// ReSharper disable MemberHidesStaticFromOuterClass | ||
namespace SemanticAssertions.Internals.SemanticKernel.Plugins.InformationPlugin; | ||
|
||
internal static class InformationPluginInfo | ||
{ | ||
public const string Name = "InformationPlugin"; | ||
|
||
public static class ContainsInformationSubset | ||
{ | ||
#pragma warning disable S3218 | ||
public const string Name = nameof(ContainsInformationSubset); | ||
#pragma warning restore S3218 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters