Class ThreadMessageRequest
Inheritance
ThreadMessageRequest
Assembly: Glitch9.AIDevKit.Provider.OpenAI.dll
Syntax
[JsonConverter(typeof(ThreadMessageRequestConverter))]
public class ThreadMessageRequest : OpenAIRequest, IJsonRequest
Constructors
|
Edit this page
View Source
ThreadMessageRequest()
Declaration
public ThreadMessageRequest()
|
Edit this page
View Source
Declaration
public ThreadMessageRequest(string prompt, IEnumerable<ToolEnvelope> tools = null, IEnumerable<IFile> uploadFiles = null, IEnumerable<string> imageUrls = null, IEnumerable<string> fileIds = null, IEnumerable<string> imageFileIds = null)
Parameters
Properties
|
Edit this page
View Source
Attachments
A list of files attached to the message, and the tools they should be added to.
Declaration
[JsonProperty("attachments")]
public List<Attachment> Attachments { get; set; }
Property Value
|
Edit this page
View Source
Content
Required. The content of the message.
Declaration
[JsonProperty("content")]
public MessageContent Content { get; set; }
Property Value
|
Edit this page
View Source
Role
Required. The role of the entity that is creating the message.
Currently only User is supported.
Declaration
[JsonProperty("role")]
public ChatRole Role { get; }
Property Value
Methods
|
Edit this page
View Source
Declaration
public ThreadMessageRequest AddInputFiles(params IFile[] files)
Parameters
| Type |
Name |
Description |
| IFile[] |
files |
|
Returns
|
Edit this page
View Source
SetFileIds(IEnumerable<string>)
Declaration
public ThreadMessageRequest SetFileIds(IEnumerable<string> attachmentFileIds)
Parameters
Returns
|
Edit this page
View Source
SetImageFileIds(IEnumerable<string>)
Declaration
public ThreadMessageRequest SetImageFileIds(IEnumerable<string> imageFileIds)
Parameters
Returns
|
Edit this page
View Source
SetImageUrls(IEnumerable<string>)
Declaration
public ThreadMessageRequest SetImageUrls(IEnumerable<string> imageUrls)
Parameters
Returns
|
Edit this page
View Source
Declaration
public ThreadMessageRequest SetInputFiles(params IFile[] files)
Parameters
| Type |
Name |
Description |
| IFile[] |
files |
|
Returns
|
Edit this page
View Source
SetPrompt(string)
Declaration
public ThreadMessageRequest SetPrompt(string prompt)
Parameters
| Type |
Name |
Description |
| string |
prompt |
|
Returns
|
Edit this page
View Source
Declaration
public ThreadMessageRequest SetTools(params ToolEnvelope[] tools)
Parameters
Returns
Implements
Extension Methods