Advent of Haystack

Try out Haystack 2.0-Beta to discover what’s coming in the next major release

with 10 challenges in the month of December 🎉

From January 5th to 19th, you will also find the solutions of each challenge.

image

In the enchanted realm of the Haystack forest, where the air is filled with the sweet scent of pine and the rustle of leaves, lives Elf Tuana. With an innovative spirit, she embarked on a quest to enhance the existing pipeline by introducing conditional routing.

Inspired by the ever-curious elves seeking knowledge, Elf Tuana envisioned a system capable of seamlessly switching between document-based responses and web searches depending on the nature of the question posed. Her goal was to create a dynamic pipeline that intelligently determines whether the answer resides within the Haystack documents or requires the vast knowledge of the web.

🔍 Challenge Objective:

We have a nearly complete pipeline capable of generating answers based on documents or web search. Your challenge is to finalize the pipeline with a Conditional Router, to make sure it goes down the correct route based on whether the answer to a question exists in our document or not.

For this challenge you will need to use the SerperDevWebSearch which requires an API key. So, we’re giving you one to use for the challenge, you’ll find it in the starter Colab 🫶

📚 Useful documentation:

💚 Here is the Starter Colab