类 UserInputData

java.lang.Object
io.agentscope.core.agent.user.UserInputData

public class UserInputData extends Object
Data class that holds user input information with dual representation. Contains both content blocks (for message construction) and optional structured data (for typed input validation). This dual nature allows flexible handling of simple text input and complex structured forms within the same unified input system.
  • 构造器详细资料

    • UserInputData

      public UserInputData(List<ContentBlock> blocksInput, Map<String,Object> structuredInput)
      Creates a new UserInputData instance.
      参数:
      blocksInput - List of content blocks representing the user input
      structuredInput - Optional structured data map for typed input (may be null)
  • 方法详细资料

    • getBlocksInput

      public List<ContentBlock> getBlocksInput()
      Gets the content blocks representing the user input.

      Content blocks can include text, images, audio, or other multimodal content. This representation is suitable for constructing message objects.

      返回:
      List of content blocks (may be null or empty)
    • getStructuredInput

      public Map<String,Object> getStructuredInput()
      Gets the structured input data as a key-value map.

      This optional representation allows for typed input validation and complex form handling. For example, a form with name, age, and email fields can be represented as a map.

      返回:
      Map of structured input data, or null if not provided