Search Instructions | Yext Hitchhikers Platform

What You’ll Learn

By the end of this unit, you will be able to:

  • Create a goal with a search instruction
  • Explain when it is useful to utilize permitted vertical and field filter
  • List the three main ways to optimize Yext Search to be used with Chat

Overview

The search instruction utilizes a Yext Search experience to look for the answer to a user’s question from the data stored in Yext Content.

Yext Search can be used for a variety of different applications including:

  • Looking up documentation and help articles
  • Looking up relevant products based on attributes or user preferences
  • Looking up physical locations (stores, hospitals, bank branches, etc.)
  • Looking up people (doctors, financial advisors, insurance agents, etc.)

Because Yext Chat sits on top of Yext Content and Yext Search, you can easily use Yext Chat to search through any content you have stored in Yext Content. This is one of the most common and powerful use cases for Yext Chat.

In order to use this instruction type, you must have an existing Search experience set up in your Yext account (or you can create one!). Linking your Search experience with Chat is what enables chat to search through your entities and surface relevant answers to users.

How the Search Action Type Works

When a user asks a question that triggers a goal with a Search instruction action type in it, the bot runs a search against your Yext Search experience to look through the data stored in Content for the answer.

For example, if a user searches for “How do I sign up for an account” in Chat, the bot will trigger a search in your Search experience. Yext Search will then look through the entities in Content and find the answer within the description field of an FAQ entity. This information will then be readily available for Chat to answer the user’s question!

To get that answer to the user, the Search instruction must be used in conjunction with a Reply instruction. This will be the case every time you use a Search instruction action within a goal. As you may recall from the last unit, the Reply instruction should utilize the Direct Answer mode since the bot is using information stored in a data source to respond to the user’s query.

book
Note
When linking a Search experience with Yext Chat, you are asking the model to answer questions based only on the data stored in Yext Content. If you want to use other data you will need to use a different action type such as REST API.

Setting up a Search Instruction

If you linked a Search experience to your bot during the initial creation flow, this goal will automatically be set up for you. However, you can always edit it at a later time if needed.

Once you are in the Add/Edit an instruction modal, you have the following inputs to complete:

  • Instruction: A description of what you want the bot to do. search instructions are usually something like “Use Yext Search to find the answer to the user’s question”.
  • Linked Search Experience: Select the Search experience you’d like your bot to utilize. If you do not already have one in your account, you will need to create one before you can add a goal with a Search instruction step.

select search step

Additional Search Configuration Options

Once you link a Search experience, you have additional configuration options that you can set up. These are optional and do not need to be completed to set up the Search instruction type:

  • Locale: The locale you want to search from. This is used in cases where you have multi-language Search experiences.
  • Search Experience Version: The bot can utilize the Staging or Production version of a Search experience. This is set to Production by default.
  • Permitted Verticals: A chatbot can be configured to include or exclude entire verticals. Excluded verticals will not be searched by the chatbot.

select verticals

  • Field Filter: In addition to including or excluding verticals, you can also include or exclude certain fields. This allows you to restrict the fields of the entities that are returned in Search. select filed filters

    • If you use the Include Fields filter, then only those fields will be sent to the model, and all others will be ignored.

    • Excluded fields will not be included in any responses returned by the chatbot. Excluded fields can still be used by the Search experience to find matching data to return from Yext Content.

Best Practices for Field Filter and Permitted Verticals

When it comes to utilizing permitted verticals or field filters, it is important to understand that AI models have a limit to how much information they can consider at a given time. When managing Search for the bot, it is important to try and show only the most relevant fields to the bot when responding to questions. This narrows the overall scope of information the bot has access to, which helps the bot return better answers.

By default, the entire API response returned by Yext Search is inserted into the answerQuestion prompt that the model uses to answer a user’s question. However, the API response can often contain irrelevant data. The more irrelevant information you give to the AI model, the more likely it is to be confused or misled. This is where using config options like Field Filter to exclude fields like photos, internal or employee-only fields, and logo fields is helpful.

For example, if you are creating a search instruction for a goal that is triggered by phrases such as, “What is your pricing?” you can use permitted verticals to include your FAQs vertical but exclude your Blogs or Jobs verticals. You can also use permitted fields to exclude any internal or employee-only fields, as well as any photo or logo fields.

Basic Example

When using a linked Search experience, we recommend creating a broad goal intended for general answering of questions with information from Yext Content.

If you link a Search experience upon creating your bot, there will automatically be an “Answer Question” goal with example phrases such as “What is the purpose of your business?” and “What are some upcoming events?”

The first and most key instruction is the Search instruction with the following settings:

  • Instruction: Use Yext Search to find the answer to the user’s question
  • Action: Search
  • Search Experience: [[Search Experience Name]]

It is then followed by a Direct Answer Reply Instruction telling the bot the following: “Based on the provided data, reply with an answer to the user’s question clearly and comprehensively.”

When creating a basic bot, this type of search instruction is likely all that you will need to answer user questions that are about your brand.

Optimizing Yext Search for Chat

If you are already using Yext Search, you’ll need to decide whether to use an existing search experience or create a new one. This depends on how your existing Search experience is configured. When deciding how to set up or edit Search, there are a few considerations you will want to keep in mind. We will walk through each below.

Using a Separate Search Experience

Sometimes, a search experience configured for a web front-end may have a configuration that isn’t optimal for Yext Chat.

For example, a Yext chatbot cannot use facets or static filters when interacting with the search experience. On the other hand, semantic search and document search tend to work best for a Yext chatbot. You may also want your Yext Chat bot to have access to different content than your Yext Search experience.

If any of these are the case, it may make sense to manage a separate “Chat back-end” search experience.

Consolidating Verticals

Sometimes it is beneficial to consolidate different entity types into a single vertical within Search so that they can be searched all at once.

When the differences between two content types are subtle (e.g., help articles, blogs, and FAQs), ask yourself, would a human know which content type to look for? If not, it’s best to consolidate them into a single vertical.

Add More Content

One of the best ways to make Chat and Search work better together is by simply adding more content to Yext! After all, neither Chat nor Search can answer questions about data it doesn’t have. So often the best way to ensure your users are getting their questions answered is to either author more content within Yext Content or to pull in more content from other systems such as Google Drive, Microsoft Sharepoint, or Notion using Connectors.

unit Quiz
+20 points
Daily Quiz Streak Daily Quiz Streak: 0
Quiz Accuracy Streak Quiz Accuracy Streak: 0
    Error Success Question 1 of 4

    What is required in order for Chat to search through entities stored in Yext to respond to a user's question?

    Error Success Question 2 of 4

    When using a using a search instruction, you MUST also use which of the following instruction types?

    Error Success Question 3 of 4

    True or False. When creating a goal with the search instruction, it is recommended to make the goal very specific or restricted to a certain topic.

    Error Success Question 4 of 4

    When might you consolidate vertical in your backend Search experience for use in Chat?

    Way to go, you passed! 🏁

    You've already completed this quiz, so you can't earn more points.You completed this quiz in 1 attempt and earned 0 points! Feel free to review your answers and move on when you're ready.
1st attempt
0 incorrect