Record Class LlmConversationBuilder.Information

java.lang.Object
java.lang.Record
com.pnfsoftware.jeb.util.llm.LlmConversationBuilder.Information
Record Components:
totalTokensInCacheHit - total input tokens served from a provider cache
totalTokensIn - total input tokens
totalTokensOut - total output tokens
lastTokensInCacheHit - input tokens served from a provider cache for the last request
lastTokensIn - input tokens for the last request
lastTokensOut - output tokens for the last request
aggrRespTimeMs - aggregate response time in milliseconds
compactedContext - true if the context was compacted
Enclosing class:
LlmConversationBuilder

public static record LlmConversationBuilder.Information(int totalTokensInCacheHit, int totalTokensIn, int totalTokensOut, int lastTokensInCacheHit, int lastTokensIn, int lastTokensOut, long aggrRespTimeMs, boolean compactedContext) extends Record
Usage and timing counters collected for a conversation.
  • Constructor Details

    • Information

      public Information(int totalTokensInCacheHit, int totalTokensIn, int totalTokensOut, int lastTokensInCacheHit, int lastTokensIn, int lastTokensOut, long aggrRespTimeMs, boolean compactedContext)
      Creates an instance of a Information record class.
      Parameters:
      totalTokensInCacheHit - the value for the totalTokensInCacheHit record component
      totalTokensIn - the value for the totalTokensIn record component
      totalTokensOut - the value for the totalTokensOut record component
      lastTokensInCacheHit - the value for the lastTokensInCacheHit record component
      lastTokensIn - the value for the lastTokensIn record component
      lastTokensOut - the value for the lastTokensOut record component
      aggrRespTimeMs - the value for the aggrRespTimeMs record component
      compactedContext - the value for the compactedContext record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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. All components in this record class are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • totalTokensInCacheHit

      public int totalTokensInCacheHit()
      Returns the value of the totalTokensInCacheHit record component.
      Returns:
      the value of the totalTokensInCacheHit record component
    • totalTokensIn

      public int totalTokensIn()
      Returns the value of the totalTokensIn record component.
      Returns:
      the value of the totalTokensIn record component
    • totalTokensOut

      public int totalTokensOut()
      Returns the value of the totalTokensOut record component.
      Returns:
      the value of the totalTokensOut record component
    • lastTokensInCacheHit

      public int lastTokensInCacheHit()
      Returns the value of the lastTokensInCacheHit record component.
      Returns:
      the value of the lastTokensInCacheHit record component
    • lastTokensIn

      public int lastTokensIn()
      Returns the value of the lastTokensIn record component.
      Returns:
      the value of the lastTokensIn record component
    • lastTokensOut

      public int lastTokensOut()
      Returns the value of the lastTokensOut record component.
      Returns:
      the value of the lastTokensOut record component
    • aggrRespTimeMs

      public long aggrRespTimeMs()
      Returns the value of the aggrRespTimeMs record component.
      Returns:
      the value of the aggrRespTimeMs record component
    • compactedContext

      public boolean compactedContext()
      Returns the value of the compactedContext record component.
      Returns:
      the value of the compactedContext record component