-
-
Notifications
You must be signed in to change notification settings - Fork 23
Add support for MCP prompts #336
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
base: main
Are you sure you want to change the base?
Conversation
Important Review skippedReview was skipped due to path filters ⛔ Files ignored due to path filters (19)
CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including You can disable this status message by setting the ✨ Finishing Touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
it looks good and reuse the pattern from tools, so it's as easy and same way of using it. |
72469eb
to
59c00cd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good overall!
{ | ||
PromptMetadata promptMetadata = (PromptMetadata)promtps[promptName]; | ||
MethodInfo method = promptMetadata.Method; | ||
Console.WriteLine($"Prompt name: {promptName}, method: {method.Name}"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
debug rather than console
public static string AnotherSimplePrompt() | ||
{ | ||
return "This is another prompt example"; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe add one with 1 param
5355efd
to
cbc1db4
Compare
- Add prompt registry class and methods. - Add prompt message, prompt parameter and roles classes. - Extract common methods to RegistryBase class. - Adjust McpToolRegistry accordingly. - Add tests for simple prompts. - Update MCP client test to list available prompts.
cbc1db4
to
e64bc4e
Compare
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
few more thigs but looks good overall
/// <inheritdoc/> | ||
public override string ToString() | ||
{ | ||
return $"{{\"name\":\"{Name}\",\"description\":\"{Description}\",\"required\":\"true\"}}"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in the case you have multiple prompts in the same function, you've set them all to be required. Not sure it can smoothly work in that case. Maybe only 1 can be mandatory or leaving the choice in the attribute (with true as default)
@@ -35,7 +35,7 @@ This library provides a lightweight, multi-threaded HTTP/HTTPS WebServer for .NE | |||
|
|||
Using the Web Server is very straight forward and supports event based calls. | |||
|
|||
```csharp | |||
'''csharp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the initial ones were the correct one. The one you've been changing are not the correct ones. applies to the rest of the document.
Description
Motivation and Context
How Has This Been Tested?
Screenshots
Types of changes
Checklist: