Package com.tnsai.llm
Record Class ParallelLLM.LLMResult
java.lang.Object
java.lang.Record
com.tnsai.llm.ParallelLLM.LLMResult
- Enclosing class:
ParallelLLM
public static record ParallelLLM.LLMResult(String llmName, String response, long durationMs, boolean success, String error)
extends Record
Result of a parallel LLM call.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the value of thedurationMsrecord component.final booleanIndicates whether some other object is "equal to" this one.error()Returns the value of theerrorrecord component.static ParallelLLM.LLMResultfinal inthashCode()Returns a hash code value for this object.llmName()Returns the value of thellmNamerecord component.response()Returns the value of theresponserecord component.booleansuccess()Returns the value of thesuccessrecord component.static ParallelLLM.LLMResultfinal StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
LLMResult
Creates an instance of aLLMResultrecord class.- Parameters:
llmName- the value for thellmNamerecord componentresponse- the value for theresponserecord componentdurationMs- the value for thedurationMsrecord componentsuccess- the value for thesuccessrecord componenterror- the value for theerrorrecord component
-
-
Method Details
-
success
-
failure
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
llmName
Returns the value of thellmNamerecord component.- Returns:
- the value of the
llmNamerecord component
-
response
Returns the value of theresponserecord component.- Returns:
- the value of the
responserecord component
-
durationMs
public long durationMs()Returns the value of thedurationMsrecord component.- Returns:
- the value of the
durationMsrecord component
-
success
public boolean success()Returns the value of thesuccessrecord component.- Returns:
- the value of the
successrecord component
-
error
Returns the value of theerrorrecord component.- Returns:
- the value of the
errorrecord component
-