Created
September 21, 2024 16:45
-
-
Save pavlovmilen/2bef4623398967602e7631bfd535a4e9 to your computer and use it in GitHub Desktop.
CreateImageContextTool
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
public static ChatTool CreateImageContextTool() | |
{ | |
var imageContextTool = ChatTool.CreateFunctionTool( | |
functionName: "GetImageDataAsync", | |
functionDescription: "Get image bytes from a given image link", | |
functionParameters: BinaryData.FromString(""" | |
{ | |
"type": "object", | |
"properties": { | |
"imageLink": { | |
"type": "string", | |
"description": "image link" | |
} | |
} | |
} | |
""") | |
); | |
return imageContextTool; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment