# Discovery Engine V1 API - Class Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult (v2.8.0)

2.8.0 (latest) 2.7.0 2.6.2 2.5.0 2.4.0 2.3.1 2.2.0 2.1.1 2.0.0 1.5.0 1.4.0 1.3.0 1.2.0 1.1.0 1.0.2 0.9.0 0.8.0 0.7.0 0.6.0 0.5.0 0.4.2 0.3.0 0.2.0 0.1.0 Reference documentation and code samples for the Discovery Engine V1 API class Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult.

Represents the search results.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #chunk

    def chunk() -> ::Google::Cloud::DiscoveryEngine::V1::Chunk

**Returns**

- ([::Google::Cloud::DiscoveryEngine::V1::Chunk](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Chunk)) --- The chunk data in the search response if the [SearchRequest.ContentSearchSpec.search_result_mode](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchRequest-ContentSearchSpec#Google__Cloud__DiscoveryEngine__V1__SearchRequest__ContentSearchSpec_search_result_mode_instance_ "Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec#search_result_mode (method)") is set to [CHUNKS](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchRequest-ContentSearchSpec-SearchResultMode#Google__Cloud__DiscoveryEngine__V1__SearchRequest__ContentSearchSpec__SearchResultMode__CHUNKS "Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::SearchResultMode::CHUNKS (constant)").

### #chunk=

    def chunk=(value) -> ::Google::Cloud::DiscoveryEngine::V1::Chunk

**Parameter**

- **value** ([::Google::Cloud::DiscoveryEngine::V1::Chunk](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Chunk)) --- The chunk data in the search response if the [SearchRequest.ContentSearchSpec.search_result_mode](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchRequest-ContentSearchSpec#Google__Cloud__DiscoveryEngine__V1__SearchRequest__ContentSearchSpec_search_result_mode_instance_ "Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec#search_result_mode (method)") is set to [CHUNKS](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchRequest-ContentSearchSpec-SearchResultMode#Google__Cloud__DiscoveryEngine__V1__SearchRequest__ContentSearchSpec__SearchResultMode__CHUNKS "Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::SearchResultMode::CHUNKS (constant)").
**Returns**

- ([::Google::Cloud::DiscoveryEngine::V1::Chunk](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Chunk)) --- The chunk data in the search response if the [SearchRequest.ContentSearchSpec.search_result_mode](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchRequest-ContentSearchSpec#Google__Cloud__DiscoveryEngine__V1__SearchRequest__ContentSearchSpec_search_result_mode_instance_ "Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec#search_result_mode (method)") is set to [CHUNKS](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchRequest-ContentSearchSpec-SearchResultMode#Google__Cloud__DiscoveryEngine__V1__SearchRequest__ContentSearchSpec__SearchResultMode__CHUNKS "Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::SearchResultMode::CHUNKS (constant)").

### #document

    def document() -> ::Google::Cloud::DiscoveryEngine::V1::Document

**Returns**

- ([::Google::Cloud::DiscoveryEngine::V1::Document](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document)) --- The document data snippet in the search response. Only fields that are marked as `retrievable` are populated.

### #document=

    def document=(value) -> ::Google::Cloud::DiscoveryEngine::V1::Document

**Parameter**

- **value** ([::Google::Cloud::DiscoveryEngine::V1::Document](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document)) --- The document data snippet in the search response. Only fields that are marked as `retrievable` are populated.
**Returns**

- ([::Google::Cloud::DiscoveryEngine::V1::Document](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document)) --- The document data snippet in the search response. Only fields that are marked as `retrievable` are populated.

### #id

    def id() -> ::String

**Returns**

- (::String) --- [Document.id](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document#Google__Cloud__DiscoveryEngine__V1__Document_id_instance_ "Google::Cloud::DiscoveryEngine::V1::Document#id (method)") of the searched [Document](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document "Google::Cloud::DiscoveryEngine::V1::Document (class)").

### #id=

    def id=(value) -> ::String

**Parameter**

- **value** (::String) --- [Document.id](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document#Google__Cloud__DiscoveryEngine__V1__Document_id_instance_ "Google::Cloud::DiscoveryEngine::V1::Document#id (method)") of the searched [Document](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document "Google::Cloud::DiscoveryEngine::V1::Document (class)").
**Returns**

- (::String) --- [Document.id](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document#Google__Cloud__DiscoveryEngine__V1__Document_id_instance_ "Google::Cloud::DiscoveryEngine::V1::Document#id (method)") of the searched [Document](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-Document "Google::Cloud::DiscoveryEngine::V1::Document (class)").

### #model_scores

    def model_scores() -> ::Google::Protobuf::Map{::String => ::Google::Cloud::DiscoveryEngine::V1::DoubleList}

**Returns**

- (::Google::Protobuf::Map{::String =\> ::Google::Cloud::DiscoveryEngine::V1::DoubleList}) --- Output only. Google provided available scores.

### #rank_signals

    def rank_signals() -> ::Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult::RankSignals

**Returns**

- ([::Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult::RankSignals](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchResponse-SearchResult-RankSignals)) --- Optional. A set of ranking signals associated with the result.

### #rank_signals=

    def rank_signals=(value) -> ::Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult::RankSignals

**Parameter**

- **value** ([::Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult::RankSignals](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchResponse-SearchResult-RankSignals)) --- Optional. A set of ranking signals associated with the result.
**Returns**

- ([::Google::Cloud::DiscoveryEngine::V1::SearchResponse::SearchResult::RankSignals](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-discovery_engine-v1/latest/Google-Cloud-DiscoveryEngine-V1-SearchResponse-SearchResult-RankSignals)) --- Optional. A set of ranking signals associated with the result.