MessageTokenInfo

org.llm4s.context.MessageTokenInfo
See theMessageTokenInfo companion object
@Stable
final case class MessageTokenInfo

Token information for a single message

Attributes

Companion
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def withPreview(preview: String): MessageTokenInfo

Sets the content preview.

Sets the content preview.

Attributes

def withRole(role: String): MessageTokenInfo

Sets the message role.

Sets the message role.

Attributes

def withTokens(tokens: Int): MessageTokenInfo

Sets the message's token count.

Sets the message's token count.

Attributes

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product