Skip to main content
POST
Train PDF for RAG

Authorizations

x-api-key
string
header
required

Query Parameters

rag_id
string
required

The ID of the RAG configuration to which this document will be added.

Body

multipart/form-data
file
file
required

The PDF file to upload and train.

data_parser
string
default:llmsherpa

Optional parser type. (e.g., "llmsherpa")

extra_info
string
default:{}

Optional additional metadata in stringified JSON.

Response

PDF trained successfully

message
string
Example:

"PDF parsing and training completed successfully"

rag_id
string
Example:

"6848ff3c4c291b4bef798e0c"

document_count
integer
Example:

20