Skip to main content

Add a data source to a RAG endpoint

A data source connects your RAG endpoint to a storage location: an S3 bucket, an Azure Blob Storage container or a Windows (SMB) file share. The endpoint keeps itself in sync with that location, so you don't have to upload files by hand.

Before you begin​

  • A RAG endpoint that shows Ready. While it is stopped or restarting, the connection test fails with The data source runtime is unavailable while the RAG endpoint is stopped or restarting.
  • You are an administrator of the endpoint, or an Owner of the tenant.
  • The storage location's address and a read-only account. The account only needs to list and read files, and for an SMB share, also read their permissions.
  • The platform can reach the storage location. S3 and Azure addresses must resolve to a public IP address, but the bucket or container can stay private. An SMB file server can be on a private network.

1. Open the form​

  1. In the sidebar, select RAG, then select your endpoint.
  2. Go to the Files tab.
  3. Under Data sources, select Add source. The Add data source page opens.

The Files tab of a RAG endpoint, with Add source under Data sources

2. Choose the provider and name it​

  • Provider: choose S3, Azure or SMB.
  • Name: a label you'll recognize, for example Product documentation.

3. Fill in the connection details​

The fields depend on the provider. Follow the page for yours:

All providers have Prefix (optional): a folder path inside the bucket, container or share, for example knowledge-base/reports/. Only files under it are synced. Leave it blank to sync all files. For S3 and Azure, end the prefix with /: without it, knowledge-base/reports also syncs knowledge-base/reports-old/.

4. Choose a sync interval and create​

  1. In Sync interval, choose how often the endpoint checks the source for new, changed and deleted files: Manual sync only, 10 minutes, 1 hour, 1 day (the default), 7 days or Custom interval. A custom interval is entered in seconds and must be at least 600 (10 minutes).
  2. Wait for the connection test. It runs on its own once all required fields are filled in:
    • Connection succeeded.: the endpoint can reach the source.
    • Connection test failed: the message below it is general and may not name the real cause. For example, stopped or restarting can also mean a wrong address or credentials. Check that the endpoint is Ready, then check the connection details.
    • Connection succeeded but no objects were read: the endpoint connected but found no files. Check the bucket, container or share, and the prefix.
  3. Select Create. It works even if the test failed or hasn't finished.

The Files tab opens. The source shows Preparing while the endpoint restarts to load it, then starts its first sync.

note

Adding, editing or deleting a source restarts the endpoint, which can't answer queries until it's Ready again. Every source syncs when the endpoint starts, including Manual sync only sources.

Check the sync​

Each source is a row under Data sources. Administrators of the endpoint also see a Status column:

StatusMeaning
PreparingThe endpoint is restarting to load the source. Syncing starts on its own.
Pending, Queued, SyncingA sync is waiting or running.
SyncedAll files were read.
Synced with errorsSome files couldn't be indexed. The others were.
Sync failedThe sync couldn't run. The row shows the reason.
Waiting for endpointThe endpoint is stopped. Start it to sync the source.
Configuration errorThe source's settings or credentials were rejected. See Fix a configuration error.
Status unavailableThe endpoint couldn't report the status, for example while it restarts. Check again shortly.
Deleting files, DeletedThe source was deleted. See Delete a source.
  • To see the source's settings and when it syncs next, open the row with the arrow next to its name. The open row also shows the reason for Sync failed, and Errors, with the number of failed files beside it, lists the files that failed and why.
  • To sync now, for example for a Manual sync only source, select the sync icon on the row.

Which files are indexed​

A source indexes the same file types as uploads. See Which files can be indexed.

  • Images (.jpg, .jpeg, .png, .gif, .bmp, .tiff, .webp) need an OCR model on the endpoint. Without one, they fail with Data source image requires a configured vision model, followed by the extension.
  • Audio (.wav, .mp3, .flac, .ogg, .oga) needs a transcription model. Without one, it fails with Data source audio requires a configured transcription model, followed by the extension.
  • Video and other audio formats are never downloaded. They fail with Data source file format is not supported, followed by the extension.

A file that fails doesn't stop the sync: the other files are still indexed, and the source shows Synced with errors. If a file that was indexed before now fails one of these checks, for example because the OCR model was removed, it is listed as failed and its indexed copy is removed.

Files that failed are tried again on every sync, so after you add a missing model, select the sync icon. Two exceptions:

  • A file too large to process fails with Data source file is too large to process and is never downloaded.
  • A file whose indexing stopped the endpoint fails with Ingestion stopped before finishing, most likely from running out of memory, and is skipped until the file changes.

Edit a source​

Select the edit icon on the row. You can change the Name, the Sync interval and, with Rotate credentials, the account the source uses. For an SMB source you can also change its file permission settings.

To change anything else, such as the bucket, share or prefix, delete the source and add a new one.

Fix a configuration error​

A source shows Configuration error when the platform rejects its settings or can't find its credentials. Syncing pauses, and the documents from that source are hidden from search and file reads. Edit the source to fix its settings or credentials. The error clears on its own once the platform accepts them.

Delete a source​

  1. Select the delete icon on the row.
  2. Choose what happens to its files:
    • Keep Delete indexed files selected to remove the files the source added. They are hidden right away and deleted in the background. The original files in the storage location aren't touched.
    • Clear it to keep the files. They stay readable by anyone with read access to the endpoint, and an SMB source's file permissions are no longer enforced on them.
  3. Select Delete.

The source stops syncing and its credentials are deleted. If you chose to delete its files and that can't start, the source isn't deleted either. To remove the files of a source you deleted earlier, select Delete files on its row.

If you see File deletion has started, but source settings could not be deleted, the files are still being deleted. Select the delete icon on the source again to finish removing it.

More resources​