Module org.elasticsearch.xcore
Class StreamingUnifiedChatCompletionResults.ChatCompletionChunk
java.lang.Object
org.elasticsearch.xpack.core.inference.results.StreamingUnifiedChatCompletionResults.ChatCompletionChunk
- All Implemented Interfaces:
ChunkedToXContent
- Enclosing class:
StreamingUnifiedChatCompletionResults
public static class StreamingUnifiedChatCompletionResults.ChatCompletionChunk
extends Object
implements ChunkedToXContent
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final record -
Field Summary
Fields inherited from interface org.elasticsearch.common.xcontent.ChunkedToXContent
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionChatCompletionChunk(String id, List<StreamingUnifiedChatCompletionResults.ChatCompletionChunk.Choice> choices, String model, String object, StreamingUnifiedChatCompletionResults.ChatCompletionChunk.Usage usage) -
Method Summary
Modifier and TypeMethodDescriptiongetId()getModel()getUsage()Iterator<? extends org.elasticsearch.xcontent.ToXContent> toXContentChunked(org.elasticsearch.xcontent.ToXContent.Params params) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.common.xcontent.ChunkedToXContent
isFragment, toXContentChunked, toXContentChunkedV8
-
Constructor Details
-
ChatCompletionChunk
public ChatCompletionChunk(String id, List<StreamingUnifiedChatCompletionResults.ChatCompletionChunk.Choice> choices, String model, String object, StreamingUnifiedChatCompletionResults.ChatCompletionChunk.Usage usage)
-
-
Method Details
-
getId
-
getChoices
-
getModel
-
getObject
-
getUsage
-
toXContentChunked
public Iterator<? extends org.elasticsearch.xcontent.ToXContent> toXContentChunked(org.elasticsearch.xcontent.ToXContent.Params params) - Specified by:
toXContentChunkedin interfaceChunkedToXContent
-