Package org.openapitools.client.api
Class ChunkApi
- java.lang.Object
-
- org.openapitools.client.api.ChunkApi
-
public class ChunkApi extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ReturnQueuedChunkcreateChunk(String trDataset, CreateChunkData createChunkData)Create or Upsert Chunk or Chunks Create or Upsert Chunk or Chunks Create a new chunk.okhttp3.CallcreateChunkAsync(String trDataset, CreateChunkData createChunkData, ApiCallback<ReturnQueuedChunk> _callback)Create or Upsert Chunk or Chunks (asynchronously) Create or Upsert Chunk or Chunks Create a new chunk.okhttp3.CallcreateChunkCall(String trDataset, CreateChunkData createChunkData, ApiCallback _callback)Build call for createChunkApiResponse<ReturnQueuedChunk>createChunkWithHttpInfo(@NotNull String trDataset, @NotNull CreateChunkData createChunkData)Create or Upsert Chunk or Chunks Create or Upsert Chunk or Chunks Create a new chunk.SuggestedQueriesResponsecreateSuggestedQueriesHandler(String trDataset, SuggestedQueriesRequest suggestedQueriesRequest)Generate suggested queries Generate suggested queries This endpoint will generate 3 suggested queries based off the query provided in the request body and return them as a JSON object.okhttp3.CallcreateSuggestedQueriesHandlerAsync(String trDataset, SuggestedQueriesRequest suggestedQueriesRequest, ApiCallback<SuggestedQueriesResponse> _callback)Generate suggested queries (asynchronously) Generate suggested queries This endpoint will generate 3 suggested queries based off the query provided in the request body and return them as a JSON object.okhttp3.CallcreateSuggestedQueriesHandlerCall(String trDataset, SuggestedQueriesRequest suggestedQueriesRequest, ApiCallback _callback)Build call for createSuggestedQueriesHandlerApiResponse<SuggestedQueriesResponse>createSuggestedQueriesHandlerWithHttpInfo(@NotNull String trDataset, @NotNull SuggestedQueriesRequest suggestedQueriesRequest)Generate suggested queries Generate suggested queries This endpoint will generate 3 suggested queries based off the query provided in the request body and return them as a JSON object.voiddeleteChunk(String trDataset, UUID chunkId)Delete Chunk Delete Chunk Delete a chunk by its id.okhttp3.CalldeleteChunkAsync(String trDataset, UUID chunkId, ApiCallback<Void> _callback)Delete Chunk (asynchronously) Delete Chunk Delete a chunk by its id.voiddeleteChunkByTrackingId(String trDataset, String trackingId)Delete Chunk By Tracking Id Delete Chunk By Tracking Id Delete a chunk by tracking_id.okhttp3.CalldeleteChunkByTrackingIdAsync(String trDataset, String trackingId, ApiCallback<Void> _callback)Delete Chunk By Tracking Id (asynchronously) Delete Chunk By Tracking Id Delete a chunk by tracking_id.okhttp3.CalldeleteChunkByTrackingIdCall(String trDataset, String trackingId, ApiCallback _callback)Build call for deleteChunkByTrackingIdApiResponse<Void>deleteChunkByTrackingIdWithHttpInfo(@NotNull String trDataset, @NotNull String trackingId)Delete Chunk By Tracking Id Delete Chunk By Tracking Id Delete a chunk by tracking_id.okhttp3.CalldeleteChunkCall(String trDataset, UUID chunkId, ApiCallback _callback)Build call for deleteChunkApiResponse<Void>deleteChunkWithHttpInfo(@NotNull String trDataset, @NotNull UUID chunkId)Delete Chunk Delete Chunk Delete a chunk by its id.StringgenerateOffChunks(String trDataset, GenerateChunksRequest generateChunksRequest)RAG on Specified Chunks RAG on Specified Chunks This endpoint exists as an alternative to the topic+message concept where our API handles chat memory.okhttp3.CallgenerateOffChunksAsync(String trDataset, GenerateChunksRequest generateChunksRequest, ApiCallback<String> _callback)RAG on Specified Chunks (asynchronously) RAG on Specified Chunks This endpoint exists as an alternative to the topic+message concept where our API handles chat memory.okhttp3.CallgenerateOffChunksCall(String trDataset, GenerateChunksRequest generateChunksRequest, ApiCallback _callback)Build call for generateOffChunksApiResponse<String>generateOffChunksWithHttpInfo(@NotNull String trDataset, @NotNull GenerateChunksRequest generateChunksRequest)RAG on Specified Chunks RAG on Specified Chunks This endpoint exists as an alternative to the topic+message concept where our API handles chat memory.ApiClientgetApiClient()ChunkMetadatagetChunkById(String trDataset, UUID chunkId)Get Chunk By Id Get Chunk By Id Get a singular chunk by id.okhttp3.CallgetChunkByIdAsync(String trDataset, UUID chunkId, ApiCallback<ChunkMetadata> _callback)Get Chunk By Id (asynchronously) Get Chunk By Id Get a singular chunk by id.okhttp3.CallgetChunkByIdCall(String trDataset, UUID chunkId, ApiCallback _callback)Build call for getChunkByIdApiResponse<ChunkMetadata>getChunkByIdWithHttpInfo(@NotNull String trDataset, @NotNull UUID chunkId)Get Chunk By Id Get Chunk By Id Get a singular chunk by id.ChunkMetadatagetChunkByTrackingId(String trDataset, String trackingId)Get Chunk By Tracking Id Get Chunk By Tracking Id Get a singular chunk by tracking_id.okhttp3.CallgetChunkByTrackingIdAsync(String trDataset, String trackingId, ApiCallback<ChunkMetadata> _callback)Get Chunk By Tracking Id (asynchronously) Get Chunk By Tracking Id Get a singular chunk by tracking_id.okhttp3.CallgetChunkByTrackingIdCall(String trDataset, String trackingId, ApiCallback _callback)Build call for getChunkByTrackingIdApiResponse<ChunkMetadata>getChunkByTrackingIdWithHttpInfo(@NotNull String trDataset, @NotNull String trackingId)Get Chunk By Tracking Id Get Chunk By Tracking Id Get a singular chunk by tracking_id.StringgetCustomBaseUrl()intgetHostIndex()List<ChunkMetadataWithFileData>getRecommendedChunks(String trDataset, RecommendChunksRequest recommendChunksRequest)Get Recommended Chunks Get Recommended Chunks Get recommendations of chunks similar to the chunks in the request.okhttp3.CallgetRecommendedChunksAsync(String trDataset, RecommendChunksRequest recommendChunksRequest, ApiCallback<List<ChunkMetadataWithFileData>> _callback)Get Recommended Chunks (asynchronously) Get Recommended Chunks Get recommendations of chunks similar to the chunks in the request.okhttp3.CallgetRecommendedChunksCall(String trDataset, RecommendChunksRequest recommendChunksRequest, ApiCallback _callback)Build call for getRecommendedChunksApiResponse<List<ChunkMetadataWithFileData>>getRecommendedChunksWithHttpInfo(@NotNull String trDataset, @NotNull RecommendChunksRequest recommendChunksRequest)Get Recommended Chunks Get Recommended Chunks Get recommendations of chunks similar to the chunks in the request.SearchChunkQueryResponseBodysearchChunk(String trDataset, SearchChunkData searchChunkData)Search Search This route provides the primary search functionality for the API.okhttp3.CallsearchChunkAsync(String trDataset, SearchChunkData searchChunkData, ApiCallback<SearchChunkQueryResponseBody> _callback)Search (asynchronously) Search This route provides the primary search functionality for the API.okhttp3.CallsearchChunkCall(String trDataset, SearchChunkData searchChunkData, ApiCallback _callback)Build call for searchChunkApiResponse<SearchChunkQueryResponseBody>searchChunkWithHttpInfo(@NotNull String trDataset, @NotNull SearchChunkData searchChunkData)Search Search This route provides the primary search functionality for the API.voidsetApiClient(ApiClient apiClient)voidsetCustomBaseUrl(String customBaseUrl)voidsetHostIndex(int hostIndex)voidupdateChunk(String trDataset, UpdateChunkData updateChunkData)Update Chunk Update Chunk Update a chunk.okhttp3.CallupdateChunkAsync(String trDataset, UpdateChunkData updateChunkData, ApiCallback<Void> _callback)Update Chunk (asynchronously) Update Chunk Update a chunk.voidupdateChunkByTrackingId(String trDataset, UpdateChunkByTrackingIdData updateChunkByTrackingIdData)Update Chunk By Tracking Id Update Chunk By Tracking Id Update a chunk by tracking_id.okhttp3.CallupdateChunkByTrackingIdAsync(String trDataset, UpdateChunkByTrackingIdData updateChunkByTrackingIdData, ApiCallback<Void> _callback)Update Chunk By Tracking Id (asynchronously) Update Chunk By Tracking Id Update a chunk by tracking_id.okhttp3.CallupdateChunkByTrackingIdCall(String trDataset, UpdateChunkByTrackingIdData updateChunkByTrackingIdData, ApiCallback _callback)Build call for updateChunkByTrackingIdApiResponse<Void>updateChunkByTrackingIdWithHttpInfo(@NotNull String trDataset, @NotNull UpdateChunkByTrackingIdData updateChunkByTrackingIdData)Update Chunk By Tracking Id Update Chunk By Tracking Id Update a chunk by tracking_id.okhttp3.CallupdateChunkCall(String trDataset, UpdateChunkData updateChunkData, ApiCallback _callback)Build call for updateChunkApiResponse<Void>updateChunkWithHttpInfo(@NotNull String trDataset, @NotNull UpdateChunkData updateChunkData)Update Chunk Update Chunk Update a chunk.
-
-
-
Constructor Detail
-
ChunkApi
public ChunkApi()
-
ChunkApi
public ChunkApi(ApiClient apiClient)
-
-
Method Detail
-
getApiClient
public ApiClient getApiClient()
-
setApiClient
public void setApiClient(ApiClient apiClient)
-
getHostIndex
public int getHostIndex()
-
setHostIndex
public void setHostIndex(int hostIndex)
-
getCustomBaseUrl
public String getCustomBaseUrl()
-
setCustomBaseUrl
public void setCustomBaseUrl(String customBaseUrl)
-
createChunkCall
public okhttp3.Call createChunkCall(String trDataset, CreateChunkData createChunkData, ApiCallback _callback) throws ApiException
Build call for createChunk- Parameters:
trDataset- The dataset id to use for the request (required)createChunkData- JSON request payload to create a new chunk (chunk) (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing the created chunk - 400 Error typically due to deserialization issues - 426 Error when upgrade is needed to process more chunks -
-
createChunk
public ReturnQueuedChunk createChunk(String trDataset, CreateChunkData createChunkData) throws ApiException
Create or Upsert Chunk or Chunks Create or Upsert Chunk or Chunks Create a new chunk. If the chunk has the same tracking_id as an existing chunk, the request will fail. Once a chunk is created, it can be searched for using the search endpoint.- Parameters:
trDataset- The dataset id to use for the request (required)createChunkData- JSON request payload to create a new chunk (chunk) (required)- Returns:
- ReturnQueuedChunk
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing the created chunk - 400 Error typically due to deserialization issues - 426 Error when upgrade is needed to process more chunks -
-
createChunkWithHttpInfo
public ApiResponse<ReturnQueuedChunk> createChunkWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull CreateChunkData createChunkData) throws ApiException
Create or Upsert Chunk or Chunks Create or Upsert Chunk or Chunks Create a new chunk. If the chunk has the same tracking_id as an existing chunk, the request will fail. Once a chunk is created, it can be searched for using the search endpoint.- Parameters:
trDataset- The dataset id to use for the request (required)createChunkData- JSON request payload to create a new chunk (chunk) (required)- Returns:
- ApiResponse<ReturnQueuedChunk>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing the created chunk - 400 Error typically due to deserialization issues - 426 Error when upgrade is needed to process more chunks -
-
createChunkAsync
public okhttp3.Call createChunkAsync(String trDataset, CreateChunkData createChunkData, ApiCallback<ReturnQueuedChunk> _callback) throws ApiException
Create or Upsert Chunk or Chunks (asynchronously) Create or Upsert Chunk or Chunks Create a new chunk. If the chunk has the same tracking_id as an existing chunk, the request will fail. Once a chunk is created, it can be searched for using the search endpoint.- Parameters:
trDataset- The dataset id to use for the request (required)createChunkData- JSON request payload to create a new chunk (chunk) (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing the created chunk - 400 Error typically due to deserialization issues - 426 Error when upgrade is needed to process more chunks -
-
createSuggestedQueriesHandlerCall
public okhttp3.Call createSuggestedQueriesHandlerCall(String trDataset, SuggestedQueriesRequest suggestedQueriesRequest, ApiCallback _callback) throws ApiException
Build call for createSuggestedQueriesHandler- Parameters:
trDataset- The dataset id to use for the request (required)suggestedQueriesRequest- JSON request payload to get alternative suggested queries (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 A JSON object containing a list of alternative suggested queries - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
createSuggestedQueriesHandler
public SuggestedQueriesResponse createSuggestedQueriesHandler(String trDataset, SuggestedQueriesRequest suggestedQueriesRequest) throws ApiException
Generate suggested queries Generate suggested queries This endpoint will generate 3 suggested queries based off the query provided in the request body and return them as a JSON object.- Parameters:
trDataset- The dataset id to use for the request (required)suggestedQueriesRequest- JSON request payload to get alternative suggested queries (required)- Returns:
- SuggestedQueriesResponse
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 A JSON object containing a list of alternative suggested queries - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
createSuggestedQueriesHandlerWithHttpInfo
public ApiResponse<SuggestedQueriesResponse> createSuggestedQueriesHandlerWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull SuggestedQueriesRequest suggestedQueriesRequest) throws ApiException
Generate suggested queries Generate suggested queries This endpoint will generate 3 suggested queries based off the query provided in the request body and return them as a JSON object.- Parameters:
trDataset- The dataset id to use for the request (required)suggestedQueriesRequest- JSON request payload to get alternative suggested queries (required)- Returns:
- ApiResponse<SuggestedQueriesResponse>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 A JSON object containing a list of alternative suggested queries - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
createSuggestedQueriesHandlerAsync
public okhttp3.Call createSuggestedQueriesHandlerAsync(String trDataset, SuggestedQueriesRequest suggestedQueriesRequest, ApiCallback<SuggestedQueriesResponse> _callback) throws ApiException
Generate suggested queries (asynchronously) Generate suggested queries This endpoint will generate 3 suggested queries based off the query provided in the request body and return them as a JSON object.- Parameters:
trDataset- The dataset id to use for the request (required)suggestedQueriesRequest- JSON request payload to get alternative suggested queries (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 A JSON object containing a list of alternative suggested queries - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
deleteChunkCall
public okhttp3.Call deleteChunkCall(String trDataset, UUID chunkId, ApiCallback _callback) throws ApiException
Build call for deleteChunk- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunk
public void deleteChunk(String trDataset, UUID chunkId) throws ApiException
Delete Chunk Delete Chunk Delete a chunk by its id. If deleting a root chunk which has a collision, the most recently created collision will become a new root chunk.- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunkWithHttpInfo
public ApiResponse<Void> deleteChunkWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull UUID chunkId) throws ApiException
Delete Chunk Delete Chunk Delete a chunk by its id. If deleting a root chunk which has a collision, the most recently created collision will become a new root chunk.- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)- Returns:
- ApiResponse<Void>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunkAsync
public okhttp3.Call deleteChunkAsync(String trDataset, UUID chunkId, ApiCallback<Void> _callback) throws ApiException
Delete Chunk (asynchronously) Delete Chunk Delete a chunk by its id. If deleting a root chunk which has a collision, the most recently created collision will become a new root chunk.- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunkByTrackingIdCall
public okhttp3.Call deleteChunkByTrackingIdCall(String trDataset, String trackingId, ApiCallback _callback) throws ApiException
Build call for deleteChunkByTrackingId- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to delete (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the tracking_id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunkByTrackingId
public void deleteChunkByTrackingId(String trDataset, String trackingId) throws ApiException
Delete Chunk By Tracking Id Delete Chunk By Tracking Id Delete a chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk. If deleting a root chunk which has a collision, the most recently created collision will become a new root chunk.- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to delete (required)- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the tracking_id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunkByTrackingIdWithHttpInfo
public ApiResponse<Void> deleteChunkByTrackingIdWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull String trackingId) throws ApiException
Delete Chunk By Tracking Id Delete Chunk By Tracking Id Delete a chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk. If deleting a root chunk which has a collision, the most recently created collision will become a new root chunk.- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to delete (required)- Returns:
- ApiResponse<Void>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the tracking_id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
deleteChunkByTrackingIdAsync
public okhttp3.Call deleteChunkByTrackingIdAsync(String trDataset, String trackingId, ApiCallback<Void> _callback) throws ApiException
Delete Chunk By Tracking Id (asynchronously) Delete Chunk By Tracking Id Delete a chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk. If deleting a root chunk which has a collision, the most recently created collision will become a new root chunk.- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to delete (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk with the tracking_id specified was deleted - 400 Service error relating to finding a chunk by tracking_id -
-
generateOffChunksCall
public okhttp3.Call generateOffChunksCall(String trDataset, GenerateChunksRequest generateChunksRequest, ApiCallback _callback) throws ApiException
Build call for generateOffChunks- Parameters:
trDataset- The dataset id to use for the request (required)generateChunksRequest- JSON request payload to perform RAG on some chunks (chunks) (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 This will be a JSON response of a string containing the LLM's generated inference. Response if not streaming. - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
generateOffChunks
public String generateOffChunks(String trDataset, GenerateChunksRequest generateChunksRequest) throws ApiException
RAG on Specified Chunks RAG on Specified Chunks This endpoint exists as an alternative to the topic+message concept where our API handles chat memory. With this endpoint, the user is responsible for providing the context window and the prompt. See more in the \"search before generate\" page at docs.trieve.ai.- Parameters:
trDataset- The dataset id to use for the request (required)generateChunksRequest- JSON request payload to perform RAG on some chunks (chunks) (required)- Returns:
- String
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 This will be a JSON response of a string containing the LLM's generated inference. Response if not streaming. - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
generateOffChunksWithHttpInfo
public ApiResponse<String> generateOffChunksWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull GenerateChunksRequest generateChunksRequest) throws ApiException
RAG on Specified Chunks RAG on Specified Chunks This endpoint exists as an alternative to the topic+message concept where our API handles chat memory. With this endpoint, the user is responsible for providing the context window and the prompt. See more in the \"search before generate\" page at docs.trieve.ai.- Parameters:
trDataset- The dataset id to use for the request (required)generateChunksRequest- JSON request payload to perform RAG on some chunks (chunks) (required)- Returns:
- ApiResponse<String>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 This will be a JSON response of a string containing the LLM's generated inference. Response if not streaming. - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
generateOffChunksAsync
public okhttp3.Call generateOffChunksAsync(String trDataset, GenerateChunksRequest generateChunksRequest, ApiCallback<String> _callback) throws ApiException
RAG on Specified Chunks (asynchronously) RAG on Specified Chunks This endpoint exists as an alternative to the topic+message concept where our API handles chat memory. With this endpoint, the user is responsible for providing the context window and the prompt. See more in the \"search before generate\" page at docs.trieve.ai.- Parameters:
trDataset- The dataset id to use for the request (required)generateChunksRequest- JSON request payload to perform RAG on some chunks (chunks) (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 This will be a JSON response of a string containing the LLM's generated inference. Response if not streaming. - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
getChunkByIdCall
public okhttp3.Call getChunkByIdCall(String trDataset, UUID chunkId, ApiCallback _callback) throws ApiException
Build call for getChunkById- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 chunk with the id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkById
public ChunkMetadata getChunkById(String trDataset, UUID chunkId) throws ApiException
Get Chunk By Id Get Chunk By Id Get a singular chunk by id.- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)- Returns:
- ChunkMetadata
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 chunk with the id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkByIdWithHttpInfo
public ApiResponse<ChunkMetadata> getChunkByIdWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull UUID chunkId) throws ApiException
Get Chunk By Id Get Chunk By Id Get a singular chunk by id.- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)- Returns:
- ApiResponse<ChunkMetadata>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 chunk with the id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkByIdAsync
public okhttp3.Call getChunkByIdAsync(String trDataset, UUID chunkId, ApiCallback<ChunkMetadata> _callback) throws ApiException
Get Chunk By Id (asynchronously) Get Chunk By Id Get a singular chunk by id.- Parameters:
trDataset- The dataset id to use for the request (required)chunkId- Id of the chunk you want to fetch. (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 chunk with the id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkByTrackingIdCall
public okhttp3.Call getChunkByTrackingIdCall(String trDataset, String trackingId, ApiCallback _callback) throws ApiException
Build call for getChunkByTrackingId- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to fetch (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 chunk with the tracking_id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkByTrackingId
public ChunkMetadata getChunkByTrackingId(String trDataset, String trackingId) throws ApiException
Get Chunk By Tracking Id Get Chunk By Tracking Id Get a singular chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use your own id as the primary reference for a chunk.- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to fetch (required)- Returns:
- ChunkMetadata
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 chunk with the tracking_id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkByTrackingIdWithHttpInfo
public ApiResponse<ChunkMetadata> getChunkByTrackingIdWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull String trackingId) throws ApiException
Get Chunk By Tracking Id Get Chunk By Tracking Id Get a singular chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use your own id as the primary reference for a chunk.- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to fetch (required)- Returns:
- ApiResponse<ChunkMetadata>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 chunk with the tracking_id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getChunkByTrackingIdAsync
public okhttp3.Call getChunkByTrackingIdAsync(String trDataset, String trackingId, ApiCallback<ChunkMetadata> _callback) throws ApiException
Get Chunk By Tracking Id (asynchronously) Get Chunk By Tracking Id Get a singular chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use your own id as the primary reference for a chunk.- Parameters:
trDataset- The dataset id to use for the request (required)trackingId- tracking_id of the chunk you want to fetch (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 chunk with the tracking_id that you were searching for - 400 Service error relating to fidning a chunk by tracking_id -
-
getRecommendedChunksCall
public okhttp3.Call getRecommendedChunksCall(String trDataset, RecommendChunksRequest recommendChunksRequest, ApiCallback _callback) throws ApiException
Build call for getRecommendedChunks- Parameters:
trDataset- The dataset id to use for the request (required)recommendChunksRequest- JSON request payload to get recommendations of chunks similar to the chunks in the request (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing chunks with scores which are similar to those in the request body - 400 Service error relating to to getting similar chunks -
-
getRecommendedChunks
public List<ChunkMetadataWithFileData> getRecommendedChunks(String trDataset, RecommendChunksRequest recommendChunksRequest) throws ApiException
Get Recommended Chunks Get Recommended Chunks Get recommendations of chunks similar to the chunks in the request. Think about this as a feature similar to the \"add to playlist\" recommendation feature on Spotify. This request pairs especially well with our groups endpoint.- Parameters:
trDataset- The dataset id to use for the request (required)recommendChunksRequest- JSON request payload to get recommendations of chunks similar to the chunks in the request (required)- Returns:
- List<ChunkMetadataWithFileData>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing chunks with scores which are similar to those in the request body - 400 Service error relating to to getting similar chunks -
-
getRecommendedChunksWithHttpInfo
public ApiResponse<List<ChunkMetadataWithFileData>> getRecommendedChunksWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull RecommendChunksRequest recommendChunksRequest) throws ApiException
Get Recommended Chunks Get Recommended Chunks Get recommendations of chunks similar to the chunks in the request. Think about this as a feature similar to the \"add to playlist\" recommendation feature on Spotify. This request pairs especially well with our groups endpoint.- Parameters:
trDataset- The dataset id to use for the request (required)recommendChunksRequest- JSON request payload to get recommendations of chunks similar to the chunks in the request (required)- Returns:
- ApiResponse<List<ChunkMetadataWithFileData>>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing chunks with scores which are similar to those in the request body - 400 Service error relating to to getting similar chunks -
-
getRecommendedChunksAsync
public okhttp3.Call getRecommendedChunksAsync(String trDataset, RecommendChunksRequest recommendChunksRequest, ApiCallback<List<ChunkMetadataWithFileData>> _callback) throws ApiException
Get Recommended Chunks (asynchronously) Get Recommended Chunks Get recommendations of chunks similar to the chunks in the request. Think about this as a feature similar to the \"add to playlist\" recommendation feature on Spotify. This request pairs especially well with our groups endpoint.- Parameters:
trDataset- The dataset id to use for the request (required)recommendChunksRequest- JSON request payload to get recommendations of chunks similar to the chunks in the request (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 JSON response payload containing chunks with scores which are similar to those in the request body - 400 Service error relating to to getting similar chunks -
-
searchChunkCall
public okhttp3.Call searchChunkCall(String trDataset, SearchChunkData searchChunkData, ApiCallback _callback) throws ApiException
Build call for searchChunk- Parameters:
trDataset- The dataset id to use for the request (required)searchChunkData- JSON request payload to semantically search for chunks (chunks) (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 chunks which are similar to the embedding vector of the search query - 400 Service error relating to searching -
-
searchChunk
public SearchChunkQueryResponseBody searchChunk(String trDataset, SearchChunkData searchChunkData) throws ApiException
Search Search This route provides the primary search functionality for the API. It can be used to search for chunks by semantic similarity, full-text similarity, or a combination of both. Results' `chunk_html` values will be modified with `<b>` tags for sub-sentence highlighting.- Parameters:
trDataset- The dataset id to use for the request (required)searchChunkData- JSON request payload to semantically search for chunks (chunks) (required)- Returns:
- SearchChunkQueryResponseBody
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 chunks which are similar to the embedding vector of the search query - 400 Service error relating to searching -
-
searchChunkWithHttpInfo
public ApiResponse<SearchChunkQueryResponseBody> searchChunkWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull SearchChunkData searchChunkData) throws ApiException
Search Search This route provides the primary search functionality for the API. It can be used to search for chunks by semantic similarity, full-text similarity, or a combination of both. Results' `chunk_html` values will be modified with `<b>` tags for sub-sentence highlighting.- Parameters:
trDataset- The dataset id to use for the request (required)searchChunkData- JSON request payload to semantically search for chunks (chunks) (required)- Returns:
- ApiResponse<SearchChunkQueryResponseBody>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 chunks which are similar to the embedding vector of the search query - 400 Service error relating to searching -
-
searchChunkAsync
public okhttp3.Call searchChunkAsync(String trDataset, SearchChunkData searchChunkData, ApiCallback<SearchChunkQueryResponseBody> _callback) throws ApiException
Search (asynchronously) Search This route provides the primary search functionality for the API. It can be used to search for chunks by semantic similarity, full-text similarity, or a combination of both. Results' `chunk_html` values will be modified with `<b>` tags for sub-sentence highlighting.- Parameters:
trDataset- The dataset id to use for the request (required)searchChunkData- JSON request payload to semantically search for chunks (chunks) (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 chunks which are similar to the embedding vector of the search query - 400 Service error relating to searching -
-
updateChunkCall
public okhttp3.Call updateChunkCall(String trDataset, UpdateChunkData updateChunkData, ApiCallback _callback) throws ApiException
Build call for updateChunk- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkData- JSON request payload to update a chunk (chunk) (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 204 No content Ok response indicating the chunk was updated as requested - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
updateChunk
public void updateChunk(String trDataset, UpdateChunkData updateChunkData) throws ApiException
Update Chunk Update Chunk Update a chunk. If you try to change the tracking_id of the chunk to have the same tracking_id as an existing chunk, the request will fail.- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkData- JSON request payload to update a chunk (chunk) (required)- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 No content Ok response indicating the chunk was updated as requested - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
updateChunkWithHttpInfo
public ApiResponse<Void> updateChunkWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull UpdateChunkData updateChunkData) throws ApiException
Update Chunk Update Chunk Update a chunk. If you try to change the tracking_id of the chunk to have the same tracking_id as an existing chunk, the request will fail.- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkData- JSON request payload to update a chunk (chunk) (required)- Returns:
- ApiResponse<Void>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 No content Ok response indicating the chunk was updated as requested - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
updateChunkAsync
public okhttp3.Call updateChunkAsync(String trDataset, UpdateChunkData updateChunkData, ApiCallback<Void> _callback) throws ApiException
Update Chunk (asynchronously) Update Chunk Update a chunk. If you try to change the tracking_id of the chunk to have the same tracking_id as an existing chunk, the request will fail.- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkData- JSON request payload to update a chunk (chunk) (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 204 No content Ok response indicating the chunk was updated as requested - 400 Service error relating to to updating chunk, likely due to conflicting tracking_id -
-
updateChunkByTrackingIdCall
public okhttp3.Call updateChunkByTrackingIdCall(String trDataset, UpdateChunkByTrackingIdData updateChunkByTrackingIdData, ApiCallback _callback) throws ApiException
Build call for updateChunkByTrackingId- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkByTrackingIdData- JSON request payload to update a chunk by tracking_id (chunks) (required)_callback- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk has been updated as per your request - 400 Service error relating to to updating chunk -
-
updateChunkByTrackingId
public void updateChunkByTrackingId(String trDataset, UpdateChunkByTrackingIdData updateChunkByTrackingIdData) throws ApiException
Update Chunk By Tracking Id Update Chunk By Tracking Id Update a chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk.- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkByTrackingIdData- JSON request payload to update a chunk by tracking_id (chunks) (required)- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk has been updated as per your request - 400 Service error relating to to updating chunk -
-
updateChunkByTrackingIdWithHttpInfo
public ApiResponse<Void> updateChunkByTrackingIdWithHttpInfo(@NotNull @NotNull String trDataset, @NotNull @NotNull UpdateChunkByTrackingIdData updateChunkByTrackingIdData) throws ApiException
Update Chunk By Tracking Id Update Chunk By Tracking Id Update a chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk.- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkByTrackingIdData- JSON request payload to update a chunk by tracking_id (chunks) (required)- Returns:
- ApiResponse<Void>
- Throws:
ApiException- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk has been updated as per your request - 400 Service error relating to to updating chunk -
-
updateChunkByTrackingIdAsync
public okhttp3.Call updateChunkByTrackingIdAsync(String trDataset, UpdateChunkByTrackingIdData updateChunkByTrackingIdData, ApiCallback<Void> _callback) throws ApiException
Update Chunk By Tracking Id (asynchronously) Update Chunk By Tracking Id Update a chunk by tracking_id. This is useful for when you are coordinating with an external system and want to use the tracking_id to identify the chunk.- Parameters:
trDataset- The dataset id to use for the request (required)updateChunkByTrackingIdData- JSON request payload to update a chunk by tracking_id (chunks) (required)_callback- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 204 Confirmation that the chunk has been updated as per your request - 400 Service error relating to to updating chunk -
-
-