• Upload a file to S3 attached to the server. The file will be converted to HTML with tika and chunked algorithmically, images will be OCR’ed with tesseract. The resulting chunks will be indexed and searchable. Optionally, you can only upload the file and manually create chunks associated to the file after. See docs.trieve.ai and/or contact us for more details and tips. Auth’ed user must be an admin or owner of the dataset’s organization to upload a file.

    Example:

    const data = await trieve.uploadFile({
    base64_file: "base64_encoded_file",
    create_chunks: true,
    description: "This is an example file",
    file_mime_type: "application/pdf",
    file_name: "example.pdf",
    link: "https://example.com",
    metadata: {
    key1: "value1",
    key2: "value2",
    },
    });

    Parameters

    Returns Promise<UploadFileResponseBody>