Environments

Preview

This feature is in Private Preview. To try it, reach out to your Databricks contact.

Looking for a different RAG Studio doc? Go to the RAG documentation index

Context: RAG development workflows

The RAG development workflow requires having users interact with early versions of the application to provide feedback. Without this feedback, it is difficult to iterate on and improve the application’s quality.

Allowing users to interact with a RAG Application requires you to deploy infrastructure, such as a web-based chat-app and the corresponding REST API endpoint behind the app, and allow that infrastructure to access your production data. Although this can create a blurry line between development and production, it is critically important that developers maintain a clean separation between these environments.

Further, it is ideal if the same code base can be used in development and production (e.g., no code changes, only configuration changes). This is the standard paradigm in full stack application development. Without a shared code base, developers are forced to maintain and sync separate code bases - leading to the risk that the application exhibits online/offline skew, and, in the worst case, fails to deliver high quality answers in production.

How environments work in RAG Studio

RAG Studio addresses this challenge through the concept of Environments.

Environments enable you to have a single code base that is by-default deployable via CI/CD with only configuration changes between dev and prod. RAG Studio’s Environments are based on Databricks Asset Bundles concept of targets.

To understand how Environments work, let’s review the components of a RAG Studio application.

Note

Tip

🚧 Roadmap 🚧 RAG Studio only supports a single Workspace for all environments. Support for RAG Studio applications that use multiple Workspaces is on our roadmap.

Each RAG Application comes with 3 pre-configured environments:

  1. End Users Environment end_users Used for production traffic

  2. Reviewers Environment reviewers Used for testing versions with end users/expert reviewers

  3. Development Environment dev Used for the inner development loop e.g., testing and rapid iteration

Optionally, to support multiple developers working on the same application, you can configure more than 1 dev environment.

Category

Item

dev

reviewers

end_users

Global Configuration

Databricks Workspace

Shared

Shared

Shared

Workspace Folder to host deployed code + config

Shared

Shared

Shared

MLflow Experiment

Shared

Shared

Shared

Unity Catalog Schema*

Shared

Shared

Shared

Version

Code + Config**

Shared

Shared

Shared

Infrastructure to run an App Version

Vector Search Endpoint

Shared

Shared

Shared

🔗 Chain Model Serving Endpoint

Unique

Unique

Unique

<review-ui> Application

Unique

Unique

Unique

* Stores all Delta Tables, Vector Indexes, Models. Naming conventions differentiate items between environments (e.g., logs_prod vs. logs_dev) ** Logged as MLflow runs & model versions

Configure environments in RAG Studio

Environments are configured in rag-config.yml - view the rag-config.yml configuration docs for how-to.