Uses of Class
com.google.genkit.ai.session.Session
Packages that use Session
Package
Description
Provides session management for multi-turn agent conversations with
persistence.
-
Uses of Session in com.google.genkit
Methods in com.google.genkit that return SessionModifier and TypeMethodDescription<S> Session<S> Genkit.createSession()Creates a new session with default options.<S> Session<S> Genkit.createSession(SessionOptions<S> options) Creates a new session with the given options.<S> Session<S> Genkit.currentSession()Gets the current session from the context.Methods in com.google.genkit that return types with arguments of type SessionModifier and TypeMethodDescription<S> CompletableFuture<Session<S>> Genkit.loadSession(String sessionId, SessionOptions<S> options) Loads an existing session from a store. -
Uses of Session in com.google.genkit.ai.session
Methods in com.google.genkit.ai.session that return SessionModifier and TypeMethodDescriptionstatic <S> Session<S> Session.create(Registry registry, SessionOptions<S> options) Creates a new Session with a generated ID.static <S> Session<S> Creates a new Session with a generated ID and agent registry.static <S> Session<S> SessionContext.currentSession()Gets the current session.static <S> Session<S> SessionContext.getCurrentSession()Gets the current session if available.Chat.getSession()Gets the session.Methods in com.google.genkit.ai.session that return types with arguments of type SessionModifier and TypeMethodDescriptionstatic <S> CompletableFuture<Session<S>> Session.load(Registry registry, String sessionId, SessionOptions<S> options) Loads an existing session from a store.static <S> CompletableFuture<Session<S>> Session.load(Registry registry, String sessionId, SessionOptions<S> options, Map<String, Agent> agentRegistry) Loads an existing session from a store with agent registry.Methods in com.google.genkit.ai.session with parameters of type SessionModifier and TypeMethodDescriptionstatic <S> voidSessionContext.runWithSession(Session<S> session, Runnable runnable) Runs a runnable within a session context.static <S,T> T SessionContext.runWithSession(Session<S> session, Callable<T> callable) Runs a function within a session context.static voidSessionContext.setSession(Session<?> session) Sets the current session.