Skip to main content

Create a Document

POST 

/documents

Creates a Datasphere Document

Request

Body

required

    oneOf

    max_sentences_per_chunk integer

    Default value: 50

    Maximum number of sentences per chunk.

    chunking_strategy string

    Possible values: [sentence]

    Strategy for chunking the document

    split_newlines boolean

    Whether to split chunks on new lines.

    Default value: false

    url urirequired

    URL of the document.

    tags string[]

    Document tags.

Responses

The request has succeeded and a new resource has been created as a result.

Schema

    id uuidrequired

    Unique ID of a Document.

    filename stringrequired

    Name of the Document.

    status DocumentStatus (string)required

    Possible values: [submitted, in_progress, completed, failed]

    The current Status of the Document.

    tags string[]required

    Document tags.

    chunking_strategy ChunkingStrategy (string)required

    Possible values: [sentence, paragraph, page, sliding]

    Strategy to use when chunking the document.

    max_sentences_per_chunk stringrequired

    Max Sentences per Chunk (only used for chunking type 'sentence')

    split_newlines booleanrequired

    Split on Newlines (only used for chunking type 'sentence')

    overlap_size stringrequired

    Overlap Size (only used for chunking type 'sliding')

    chunk_size stringrequired

    Chunk Size (only used for chunking type 'sliding')

    number_of_chunks integerrequired

    Number of Chunks in the Document.

    created_at date-timerequired

    Document Creation Date.

    updated_at date-timerequired

    Document Update Date.

Loading...