Session

org.llm4s.repl.Session
See theSession companion class
object Session

Attributes

Companion
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Session.type

Members list

Value members

Concrete methods

A session on the default provider: the section that llm4s.providers.provider names in application.conf, with the provider modules on the classpath. A configuration that cannot be loaded gives a session whose helpers print the error (Session.failure).

A session on the default provider: the section that llm4s.providers.provider names in application.conf, with the provider modules on the classpath. A configuration that cannot be loaded gives a session whose helpers print the error (Session.failure).

Attributes

def named(name: String): Session

A session on the named section llm4s.providers.<name> of application.conf.

A session on the named section llm4s.providers.<name> of application.conf.

Attributes

def of(client: LLMClient): Session

A session on a client built elsewhere.

A session on a client built elsewhere.

Attributes

def offline(replies: Reply*): Session

A session that needs no key and no network: the first call is answered with the first reply, the second with the second, and so on (the testkit's org.llm4s.testkit.ScriptedLLMClient.sequence). A call past the last reply fails with an error that says so.

A session that needs no key and no network: the first call is answered with the first reply, the second with the second, and so on (the testkit's org.llm4s.testkit.ScriptedLLMClient.sequence). A call past the last reply fails with an error that says so.

given Session = Session.offline(Reply.text("Covariance lets a List[Cat] be a List[Animal]."))

Attributes

A session on a scripted client, for replies that depend on the conversation.

A session on a scripted client, for replies that depend on the conversation.

Attributes

Concrete fields

The number of model calls one ask with tools makes at most, unless Session.withMaxToolSteps changes it.

The number of model calls one ask with tools makes at most, unless Session.withMaxToolSteps changes it.

Attributes