Class: Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo
- Inherits:
-
Object
- Object
- Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb
Overview
Information describing what natural language understanding was done on the input query.
Defined Under Namespace
Classes: StructuredExtractedFilter
Instance Attribute Summary collapse
-
#extracted_filters ⇒ ::String
The filters that were extracted from the input query.
-
#rewritten_query ⇒ ::String
Rewritten input query minus the extracted filters.
-
#structured_extracted_filter ⇒ ::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter
The filters that were extracted from the input query represented in a structured form.
Instance Attribute Details
#extracted_filters ⇒ ::String
Returns The filters that were extracted from the input query.
1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 |
# File 'proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb', line 1684 class NaturalLanguageQueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The filters that were extracted from the input query represented in a # structured form. # @!attribute [rw] expression # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression] # The expression denoting the filter that was extracted from the input # query in a structured form. It can be a simple expression denoting a # single string, numerical or geolocation constraint or a compound # expression which is a combination of multiple expressions connected # using logical (OR and AND) operators. class StructuredExtractedFilter include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Constraint expression of a string field. # @!attribute [rw] field_name # @return [::String] # Name of the string field as defined in the schema. # @!attribute [rw] values # @return [::Array<::String>] # Values of the string field. The record will only be returned if the # field value matches one of the values specified here. # @!attribute [rw] query_segment # @return [::String] # Identifies the keywords within the search query that match a filter. class StringConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Constraint expression of a number field. Example: price < 100. # @!attribute [rw] field_name # @return [::String] # Name of the numerical field as defined in the schema. # @!attribute [rw] comparison # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint::Comparison] # The comparison operation performed between the field value and the # value specified in the constraint. # @!attribute [rw] value # @return [::Float] # The value specified in the numerical constraint. # @!attribute [rw] query_segment # @return [::String] # Identifies the keywords within the search query that match a filter. class NumberConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The comparison operation that was performed. module Comparison # Undefined comparison operator. COMPARISON_UNSPECIFIED = 0 # Denotes equality `=` operator. EQUALS = 1 # Denotes less than or equal to `<=` operator. LESS_THAN_EQUALS = 2 # Denotes less than `<` operator. LESS_THAN = 3 # Denotes greater than or equal to `>=` operator. GREATER_THAN_EQUALS = 4 # Denotes greater than `>` operator. GREATER_THAN = 5 end end # Constraint of a geolocation field. # Name of the geolocation field as defined in the schema. # @!attribute [rw] field_name # @return [::String] # The name of the geolocation field as defined in the schema. # @!attribute [rw] address # @return [::String] # The reference address that was inferred from the input query. The # proximity of the reference address to the geolocation field will be # used to filter the results. # @!attribute [rw] latitude # @return [::Float] # The latitude of the geolocation inferred from the input query. # @!attribute [rw] longitude # @return [::Float] # The longitude of the geolocation inferred from the input query. # @!attribute [rw] radius_in_meters # @return [::Float] # The radius in meters around the address. The record is returned if # the location of the geolocation field is within the radius. class GeolocationConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Logical `And` operator. # @!attribute [rw] expressions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>] # The expressions that were ANDed together. class AndExpression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Logical `Or` operator. # @!attribute [rw] expressions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>] # The expressions that were ORed together. class OrExpression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The expression denoting the filter that was extracted from the input # query. # @!attribute [rw] string_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::StringConstraint] # String constraint expression. # # Note: The following fields are mutually exclusive: `string_constraint`, `number_constraint`, `geolocation_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] number_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint] # Numerical constraint expression. # # Note: The following fields are mutually exclusive: `number_constraint`, `string_constraint`, `geolocation_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] geolocation_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::GeolocationConstraint] # Geolocation constraint expression. # # Note: The following fields are mutually exclusive: `geolocation_constraint`, `string_constraint`, `number_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] and_expr # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::AndExpression] # Logical "And" compound operator connecting multiple expressions. # # Note: The following fields are mutually exclusive: `and_expr`, `string_constraint`, `number_constraint`, `geolocation_constraint`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] or_expr # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::OrExpression] # Logical "Or" compound operator connecting multiple expressions. # # Note: The following fields are mutually exclusive: `or_expr`, `string_constraint`, `number_constraint`, `geolocation_constraint`, `and_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. class Expression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end |
#rewritten_query ⇒ ::String
Returns Rewritten input query minus the extracted filters.
1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 |
# File 'proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb', line 1684 class NaturalLanguageQueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The filters that were extracted from the input query represented in a # structured form. # @!attribute [rw] expression # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression] # The expression denoting the filter that was extracted from the input # query in a structured form. It can be a simple expression denoting a # single string, numerical or geolocation constraint or a compound # expression which is a combination of multiple expressions connected # using logical (OR and AND) operators. class StructuredExtractedFilter include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Constraint expression of a string field. # @!attribute [rw] field_name # @return [::String] # Name of the string field as defined in the schema. # @!attribute [rw] values # @return [::Array<::String>] # Values of the string field. The record will only be returned if the # field value matches one of the values specified here. # @!attribute [rw] query_segment # @return [::String] # Identifies the keywords within the search query that match a filter. class StringConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Constraint expression of a number field. Example: price < 100. # @!attribute [rw] field_name # @return [::String] # Name of the numerical field as defined in the schema. # @!attribute [rw] comparison # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint::Comparison] # The comparison operation performed between the field value and the # value specified in the constraint. # @!attribute [rw] value # @return [::Float] # The value specified in the numerical constraint. # @!attribute [rw] query_segment # @return [::String] # Identifies the keywords within the search query that match a filter. class NumberConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The comparison operation that was performed. module Comparison # Undefined comparison operator. COMPARISON_UNSPECIFIED = 0 # Denotes equality `=` operator. EQUALS = 1 # Denotes less than or equal to `<=` operator. LESS_THAN_EQUALS = 2 # Denotes less than `<` operator. LESS_THAN = 3 # Denotes greater than or equal to `>=` operator. GREATER_THAN_EQUALS = 4 # Denotes greater than `>` operator. GREATER_THAN = 5 end end # Constraint of a geolocation field. # Name of the geolocation field as defined in the schema. # @!attribute [rw] field_name # @return [::String] # The name of the geolocation field as defined in the schema. # @!attribute [rw] address # @return [::String] # The reference address that was inferred from the input query. The # proximity of the reference address to the geolocation field will be # used to filter the results. # @!attribute [rw] latitude # @return [::Float] # The latitude of the geolocation inferred from the input query. # @!attribute [rw] longitude # @return [::Float] # The longitude of the geolocation inferred from the input query. # @!attribute [rw] radius_in_meters # @return [::Float] # The radius in meters around the address. The record is returned if # the location of the geolocation field is within the radius. class GeolocationConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Logical `And` operator. # @!attribute [rw] expressions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>] # The expressions that were ANDed together. class AndExpression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Logical `Or` operator. # @!attribute [rw] expressions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>] # The expressions that were ORed together. class OrExpression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The expression denoting the filter that was extracted from the input # query. # @!attribute [rw] string_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::StringConstraint] # String constraint expression. # # Note: The following fields are mutually exclusive: `string_constraint`, `number_constraint`, `geolocation_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] number_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint] # Numerical constraint expression. # # Note: The following fields are mutually exclusive: `number_constraint`, `string_constraint`, `geolocation_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] geolocation_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::GeolocationConstraint] # Geolocation constraint expression. # # Note: The following fields are mutually exclusive: `geolocation_constraint`, `string_constraint`, `number_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] and_expr # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::AndExpression] # Logical "And" compound operator connecting multiple expressions. # # Note: The following fields are mutually exclusive: `and_expr`, `string_constraint`, `number_constraint`, `geolocation_constraint`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] or_expr # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::OrExpression] # Logical "Or" compound operator connecting multiple expressions. # # Note: The following fields are mutually exclusive: `or_expr`, `string_constraint`, `number_constraint`, `geolocation_constraint`, `and_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. class Expression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end |
#structured_extracted_filter ⇒ ::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter
Returns The filters that were extracted from the input query represented in a structured form.
1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 |
# File 'proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb', line 1684 class NaturalLanguageQueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The filters that were extracted from the input query represented in a # structured form. # @!attribute [rw] expression # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression] # The expression denoting the filter that was extracted from the input # query in a structured form. It can be a simple expression denoting a # single string, numerical or geolocation constraint or a compound # expression which is a combination of multiple expressions connected # using logical (OR and AND) operators. class StructuredExtractedFilter include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Constraint expression of a string field. # @!attribute [rw] field_name # @return [::String] # Name of the string field as defined in the schema. # @!attribute [rw] values # @return [::Array<::String>] # Values of the string field. The record will only be returned if the # field value matches one of the values specified here. # @!attribute [rw] query_segment # @return [::String] # Identifies the keywords within the search query that match a filter. class StringConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Constraint expression of a number field. Example: price < 100. # @!attribute [rw] field_name # @return [::String] # Name of the numerical field as defined in the schema. # @!attribute [rw] comparison # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint::Comparison] # The comparison operation performed between the field value and the # value specified in the constraint. # @!attribute [rw] value # @return [::Float] # The value specified in the numerical constraint. # @!attribute [rw] query_segment # @return [::String] # Identifies the keywords within the search query that match a filter. class NumberConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # The comparison operation that was performed. module Comparison # Undefined comparison operator. COMPARISON_UNSPECIFIED = 0 # Denotes equality `=` operator. EQUALS = 1 # Denotes less than or equal to `<=` operator. LESS_THAN_EQUALS = 2 # Denotes less than `<` operator. LESS_THAN = 3 # Denotes greater than or equal to `>=` operator. GREATER_THAN_EQUALS = 4 # Denotes greater than `>` operator. GREATER_THAN = 5 end end # Constraint of a geolocation field. # Name of the geolocation field as defined in the schema. # @!attribute [rw] field_name # @return [::String] # The name of the geolocation field as defined in the schema. # @!attribute [rw] address # @return [::String] # The reference address that was inferred from the input query. The # proximity of the reference address to the geolocation field will be # used to filter the results. # @!attribute [rw] latitude # @return [::Float] # The latitude of the geolocation inferred from the input query. # @!attribute [rw] longitude # @return [::Float] # The longitude of the geolocation inferred from the input query. # @!attribute [rw] radius_in_meters # @return [::Float] # The radius in meters around the address. The record is returned if # the location of the geolocation field is within the radius. class GeolocationConstraint include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Logical `And` operator. # @!attribute [rw] expressions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>] # The expressions that were ANDed together. class AndExpression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Logical `Or` operator. # @!attribute [rw] expressions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>] # The expressions that were ORed together. class OrExpression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # The expression denoting the filter that was extracted from the input # query. # @!attribute [rw] string_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::StringConstraint] # String constraint expression. # # Note: The following fields are mutually exclusive: `string_constraint`, `number_constraint`, `geolocation_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] number_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint] # Numerical constraint expression. # # Note: The following fields are mutually exclusive: `number_constraint`, `string_constraint`, `geolocation_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] geolocation_constraint # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::GeolocationConstraint] # Geolocation constraint expression. # # Note: The following fields are mutually exclusive: `geolocation_constraint`, `string_constraint`, `number_constraint`, `and_expr`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] and_expr # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::AndExpression] # Logical "And" compound operator connecting multiple expressions. # # Note: The following fields are mutually exclusive: `and_expr`, `string_constraint`, `number_constraint`, `geolocation_constraint`, `or_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. # @!attribute [rw] or_expr # @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::OrExpression] # Logical "Or" compound operator connecting multiple expressions. # # Note: The following fields are mutually exclusive: `or_expr`, `string_constraint`, `number_constraint`, `geolocation_constraint`, `and_expr`. If a field in that set is populated, all other fields in the set will automatically be cleared. class Expression include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end |