Interface NaruSegmentContent

All Known Implementing Classes:
NaruSegmentContent.Messages, NaruSegmentContent.Tools

public sealed interface NaruSegmentContent permits NaruSegmentContent.Messages, NaruSegmentContent.Tools
The payload of a NaruContextSegment.

Sealed on purpose: a segment can only ever carry one of the two things a provider request is actually built from, so a provider's serializer can switch exhaustively on the type and be forced by the compiler to handle both. An open-ended Object payload would let a caller smuggle in a shape no serializer knows how to emit.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static final record 
    A run of conversation messages, in the order they must be emitted.
    static final record 
    The tool definitions for the request.