Package io.jmix.dynmodelai.session
Class AgentEventStreams
java.lang.Object
io.jmix.dynmodelai.session.AgentEventStreams
Transport only. Pending questions and Run transitions belong to Conversation commands.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionAgentEventStreams(ConversationCommands commands, Messages messages, AgentHistory history, ConversationSessions sessions) -
Method Summary
Modifier and TypeMethodDescriptionbooleancompleteRun(UUID conversationId, UUID runId, String summary, @Nullable String detail, RunOutcome outcome) booleancompleteRun(UUID conversationId, UUID runId, String summary, @Nullable String detail, RunOutcome outcome, @Nullable DraftPresentation draft) voidfailRun(UUID conversationId, UUID runId, RuntimeException failure) Terminates transport after a failed mandatory write; no replacement history is invented.voidobserve(UUID conversationId, UUID runId, AgentObservation observation) Saves diagnostics once, then emits only their safe progress projection, with an independent cursor.publish(UUID conversationId, UUID runId, AgentEventPayload payload) voidregisterRun(UUID conversationId, UUID runId) voidreleaseRun(UUID runId) Release transport retention after the owning Conversation resolves or expires its question.reactor.core.publisher.Flux<AgentEvent> streamEvents(UUID conversationId, UUID runId, long afterSequence)
-
Field Details
-
MAX_EVENTS_PER_RUN
public static final int MAX_EVENTS_PER_RUN- See Also:
-
-
Constructor Details
-
AgentEventStreams
public AgentEventStreams(ConversationCommands commands, Messages messages, AgentHistory history, ConversationSessions sessions)
-
-
Method Details
-
registerRun
-
publish
-
observe
Saves diagnostics once, then emits only their safe progress projection, with an independent cursor. -
completeRun
public boolean completeRun(UUID conversationId, UUID runId, String summary, @Nullable String detail, RunOutcome outcome) -
completeRun
public boolean completeRun(UUID conversationId, UUID runId, String summary, @Nullable String detail, RunOutcome outcome, @Nullable DraftPresentation draft) -
failRun
Terminates transport after a failed mandatory write; no replacement history is invented. -
releaseRun
Release transport retention after the owning Conversation resolves or expires its question. -
streamEvents
public reactor.core.publisher.Flux<AgentEvent> streamEvents(UUID conversationId, UUID runId, long afterSequence)
-