Chapter 5. Run the RAG pattern


After you select a RAG pattern from the AutoRAG leaderboard, run the notebooks in an OpenShift AI workbench to use the pattern with your documents.

Prerequisites

  • You have selected a RAG pattern from a completed AutoRAG optimization run. For more information, see Evaluate AutoRAG results.
  • You have downloaded the indexing and inference notebooks from the AutoRAG leaderboard or pattern details view.
  • You have a running workbench in your OpenShift AI project.
  • You have the connection details for your S3-compatible object storage and your OGX instance.
  • The models used in your selected RAG pattern are available on your OGX instance.

Procedure

  1. In the OpenShift AI dashboard, open your workbench.
  2. Attach the following data connections to the workbench. Use the same S3 bucket and OGX instance that you used for the optimization run.

    • An S3-compatible object storage connection for your documents
    • A connection for your OGX instance that includes the API key and base URL
  3. Optional: To index additional documents, upload and run the indexing notebook.

    The vector database is already populated from the optimization run.

  4. Upload the inference notebook to the workbench.
  5. Open the inference notebook and run each cell.

    The notebook prompts you to enter a question. Enter a question to verify that the RAG system returns relevant answers from your documents.

Verification

  • If you ran the indexing notebook, verify that all cells completed without errors.
  • The inference notebook returns answers grounded in your documents.
  • If the notebook displays an error, check your connection details.
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat Documentation

Legal Notice

Theme

© 2026 Red Hat
Back to top