Interface MemorySearchSummary.Builder

  • Method Details

    • memoryId

      MemorySearchSummary.Builder memoryId(String memoryId)

      The memory's ID, assigned by the service. Always present.

      Parameters:
      memoryId - The memory's ID, assigned by the service. Always present.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • memoryType

      MemorySearchSummary.Builder memoryType(String memoryType)

      The memory type of the result.

      Parameters:
      memoryType - The memory type of the result.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • memoryType

      MemorySearchSummary.Builder memoryType(MemoryType memoryType)

      The memory type of the result.

      Parameters:
      memoryType - The memory type of the result.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • strategyName

      MemorySearchSummary.Builder strategyName(String strategyName)

      The name of the strategy the memory belongs to, for example user-facts: the strategy memoryStrategies selects on in SearchMemories. Absent when the memory's strategy is no longer declared on the space, for example right after the strategy is deleted.

      Parameters:
      strategyName - The name of the strategy the memory belongs to, for example user-facts: the strategy memoryStrategies selects on in SearchMemories. Absent when the memory's strategy is no longer declared on the space, for example right after the strategy is deleted.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • content

      The memory text.

      Parameters:
      content - The memory text.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • score

      The relevance score of the result. A higher score is more relevant. Scores aren't normalized to a fixed range and can be greater than 1, so use them only to order results.

      Parameters:
      score - The relevance score of the result. A higher score is more relevant. Scores aren't normalized to a fixed range and can be greater than 1, so use them only to order results.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • systemMetadata

      MemorySearchSummary.Builder systemMetadata(SystemMetadata systemMetadata)

      Provenance for the memory: the actor and session that own it, and when it was created and last updated. It is the same block that ListMemories, GetMemory, and SearchEvents return.

      In a query, filter or sort on the timestamps as system_metadata.created_at and system_metadata.updated_at. Scope by owner with the top-level actorId, not in the query. Searching memories doesn't filter by session.

      Absent when the service has no provenance for the memory.

      Parameters:
      systemMetadata - Provenance for the memory: the actor and session that own it, and when it was created and last updated. It is the same block that ListMemories, GetMemory, and SearchEvents return.

      In a query, filter or sort on the timestamps as system_metadata.created_at and system_metadata.updated_at. Scope by owner with the top-level actorId, not in the query. Searching memories doesn't filter by session.

      Absent when the service has no provenance for the memory.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • systemMetadata

      default MemorySearchSummary.Builder systemMetadata(Consumer<SystemMetadata.Builder> systemMetadata)

      Provenance for the memory: the actor and session that own it, and when it was created and last updated. It is the same block that ListMemories, GetMemory, and SearchEvents return.

      In a query, filter or sort on the timestamps as system_metadata.created_at and system_metadata.updated_at. Scope by owner with the top-level actorId, not in the query. Searching memories doesn't filter by session.

      Absent when the service has no provenance for the memory.

      This is a convenience method that creates an instance of the SystemMetadata.Builder avoiding the need to create one manually via SystemMetadata.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to systemMetadata(SystemMetadata).

      Parameters:
      systemMetadata - a consumer that will call methods on SystemMetadata.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • metadata

      The memory's metadata tags. All values are strings. In a query, filter on a tag as metadata.<key>.

      Parameters:
      metadata - The memory's metadata tags. All values are strings. In a query, filter on a tag as metadata.<key>.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • sourceEventIds

      MemorySearchSummary.Builder sourceEventIds(Collection<String> sourceEventIds)

      The IDs of the events the memory was derived from, without duplicates. Use them with GetEvent or BatchGetEvent, or to search those events' content with SearchEvents by filtering on event_ids in the query. Absent for a memory created directly with CreateMemory. A memory can be derived from several events. The service sets this value.

      Parameters:
      sourceEventIds - The IDs of the events the memory was derived from, without duplicates. Use them with GetEvent or BatchGetEvent, or to search those events' content with SearchEvents by filtering on event_ids in the query. Absent for a memory created directly with CreateMemory. A memory can be derived from several events. The service sets this value.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • sourceEventIds

      MemorySearchSummary.Builder sourceEventIds(String... sourceEventIds)

      The IDs of the events the memory was derived from, without duplicates. Use them with GetEvent or BatchGetEvent, or to search those events' content with SearchEvents by filtering on event_ids in the query. Absent for a memory created directly with CreateMemory. A memory can be derived from several events. The service sets this value.

      Parameters:
      sourceEventIds - The IDs of the events the memory was derived from, without duplicates. Use them with GetEvent or BatchGetEvent, or to search those events' content with SearchEvents by filtering on event_ids in the query. Absent for a memory created directly with CreateMemory. A memory can be derived from several events. The service sets this value.
      Returns:
      Returns a reference to this object so that method calls can be chained together.