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

.Net: Added support for Structured Outputs in prompts #9873

Merged
Prev Previous commit
Next Next commit
Small improvement
  • Loading branch information
dmytrostruk committed Dec 4, 2024
commit 105802cafeca57fcf5f0fc77909e496c865123ef
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ public async Task StructuredOutputsWithFunctionsFromPromptAsync()
.Build();

// Initialize a path to plugin directory: Resources/Plugins/MoviePlugins/MoviePluginPrompt.
var pluginDirectoryPath = Path.Combine(Directory.GetCurrentDirectory(), "..", "..", "..", "Resources", "Plugins", "MoviePlugins", "MoviePluginPrompt");
var pluginDirectoryPath = Path.Combine(Directory.GetCurrentDirectory(), "Resources", "Plugins", "MoviePlugins", "MoviePluginPrompt");

// Create a function from prompt.
kernel.ImportPluginFromPromptDirectory(pluginDirectoryPath, pluginName: "MoviePlugin");
Expand Down Expand Up @@ -296,7 +296,7 @@ public async Task StructuredOutputsWithFunctionsFromYamlAsync()
.Build();

// Initialize a path to YAML function: Resources/Plugins/MoviePlugins/MoviePluginYaml.
var functionPath = Path.Combine(Directory.GetCurrentDirectory(), "..", "..", "..", "Resources", "Plugins", "MoviePlugins", "MoviePluginYaml", "TopMovies.yaml");
var functionPath = Path.Combine(Directory.GetCurrentDirectory(), "Resources", "Plugins", "MoviePlugins", "MoviePluginYaml", "TopMovies.yaml");

// Load YAML prompt.
using Stream stream = File.OpenRead(functionPath);
Expand Down
Loading