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.

In this challenge, the Haystack elves are sending you off on a bit of a scavenger hunt! Somewhere, in the first challenge, they have hidden (not very well hidden) some information. That information is about what their favorite animal is!

Your task is to create a retrieval-augmented generative pipeline that will answer a simple question: “What is our favorite animal?”.

Hint: The pipeline from the first challenge will be really useful here. Below is also an image of a pipeline that might work very well for this challenge.

🩵 Here’s the Starter Colab

In the starter colab you will only find what you will have to run once you’ve got a working pipeline, and a PromptBuilder. We’ve also included the imports to some useful components.

  • LinkContentFetcher`: This will allow you to fetch the contents of https://haystack.deepset.ai/advent-of-haystack/day-1#challenge
  • HTMLToDocument: Once you’ve fetched the contents, this component will allow you to convert it to a Document
  • DocumentSplitter (Optional): This is useful if you want to split your Document into chunks
  • TransformersSimilarityRanker (Optional): This is useful if you want to rank your documents (chunked with the splitter above) so that the most relevant is at the top.
  • PromptBuilder: This is used to define how you want to prompt an LLM so that it generates an accurate response for you. We’ve included one for you in the starter Colab that will help you with this challenge.
  • GPTGenerator: This component is used to query GPT. You can change this to one of our other generators as well!

pipeline image