-
Notifications
You must be signed in to change notification settings - Fork 545
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Is your feature request related to a problem? Please describe.
In MCPB, it is expected that when statically defining a prompt, the developer can say "Order a ${sandwichKind} sandwich" as the text of the prompt.
It would be beneficial for tools operating on the assembly to be able to extract the string template for the prompt. But today, all we have is whatever the code decided to return at runtime.
Describe the solution you'd like
[McpServerPrompt(Name = "complex_prompt",
Template = "Set the temperature to ${arguments.temperature} and reply in ${arguments.style} style"),
Description("A prompt with arguments")]
public partial static IEnumerable<ChatMessage> ComplexPrompt(
[Description("Temperature setting")] int temperature,
[Description("Output style")] string? style = null);
Then the source generator will use the new Template
attribute parameter to generate the code to return $"Set the temperature to {temperature} and reply in {style} style"
.
Describe alternatives you've considered
n/a
Additional context
n/a
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request