When you search the IBM watsonx.ai product documentation, a large language model generates a short answer to supplement the usual search results. This solution can answer factual questions like "What does top-p mean?" and "What are all the foundation models available in watsonx.ai?"
Note: This feature is only available when you view the documentation while logged in to watsonx.ai. Asking questions using this feature does not cost you anything and does not consume your monthly foundation model tokens.
How does it work?
We leverage our existing documentation search and prompt a foundation model in watsonx.ai:
- Someone reading the watsonx.ai product documentation types a question in the search bar
- The documentation search runs as usual, returning matching topics
- We extract the contents of the topics in the top few search results as plain text
- We paste the topic contents and the question into a question-answering prompt (see below)
- We send the prompt to a model in watsonx.ai, which then generates a short answer
Sample prompt text
In the Prompt Lab in watsonx.ai, you can experiment with different prompts and different models to see what works best for your use case. Here’s the kind of prompt we use for this solution:
[ Topic text goes here ]
Answer the following question using only information from the article.
Answer in a complete sentence, with proper capitalization and punctuation.
If there is no good answer in the article, say "I don't know".
Question: [ Customer question goes here ]
Big customer experience improvement for a small implementation effort
This simple example demonstrates the tremendous potential of text-generating models:
- Before, customers searched for relevant topics and then read through them to find details they needed.
- Now, customers have the option to find those details by simply asking questions in their own words.
The best part: we built this solution using what we already had! We used existing APIs to search and get topic contents, and we didn't have to make any changes to use them for this new purpose.
Prompting a model to answer questions based on the documentation was a small effort for a big improvement.
Try out watsonx.ai here: Try IBM watsonx.ai for free