JContextWindow

org.llm4s.javaapi.JContextWindow
See theJContextWindow companion object
final class JContextWindow

How much of a conversation an agent sends the model on each call, for JAgentBuilder.contextWindow (#2476): the Java form of ContextWindowMiddleware. It prunes only what is sent; the conversation keeps every message, so JAgentResult.messages() is whole.

Llm4s.agentBuilder("support", client).contextWindow(JContextWindow.lastMessages(20))

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Any