Skip to main content
Loading navigation
Back to prompt library

RAG System Setup with Weaviate and Prefect

Linked challenge: Agent for Complex Policy & Contract Analysis

Prompt source

implementation1 lines1 sectionsNo variables0 checklist items
Design and implement the RAG pipeline. Set up a **Weaviate** instance (e.g., via Docker). Use **Prefect** to create a workflow that: 1) takes a collection of sample policy documents, 2) chunks them into smaller, semantically meaningful passages, 3) generates embeddings for these chunks (using an appropriate embedding model, e.g., OpenAI's `text-embedding-3-small`), and 4) indexes them into Weaviate. Provide the Prefect flow definition and Python code for Weaviate interaction.