added vector store methods

This commit is contained in:
raghotham 2024-07-05 15:08:54 -07:00 committed by GitHub
parent ae732c6a5c
commit 1a2b17af7f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -396,10 +396,16 @@ paths:
schema: schema:
$ref: '#/components/schemas/SyntheticDataGenJob' $ref: '#/components/schemas/SyntheticDataGenJob'
# RAG APIs # RAG APIs
/embedding: /vector_store
/batch_embedding/jobs/submit: /vector_store/create
/batch_embedding/jobs/status: /vector_store/drop
/batch_embedding/jobs/cancel: /vector_store/update
/vector_store/insert/jobs/submit:
/vector_store/insert/jobs/status:
/vector_store/insert/jobs/cancel:
/vector_store/delete/jobs/submit:
/vector_store/delete/jobs/status:
/vector_store/delete/jobs/cancel:
# Agentic APIs # Agentic APIs
/agents/execute: /agents/execute:
post: post:
@ -428,55 +434,6 @@ paths:
application/json: application/json:
schema: schema:
$ref: '#/components/schemas/Turn' $ref: '#/components/schemas/Turn'
/memory/create_bank:
post:
summary: Create a memory bank
description: Creates a new memory bank that stores a corpora of text content/facts to later query.
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
name:
type: string
description: The name of the memory bank.
description:
type: string
description: A brief description of the memory bank's purpose and contents.
responses:
'200':
description: Successfully created the memory bank.
content:
application/json:
schema:
$ref: '#/components/schemas/MemoryBank'
/memory/add_to_bank:
post:
summary: Add a memory nugget to a memory bank
description: Stores some text corpus as a nugget within the provided memory bank to be queried at a later time.
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
bankId:
type: string
description: The ID of the memory bank to add the nugget to.
content:
type: string
description: The content to embed and add as a nugget.
responses:
'200':
description: Successfully added the memory nugget to the memory bank.
content:
application/json:
schema:
$ref: '#/components/schemas/MemoryNugget'
/memory/fetch_memories:
get: get:
summary: Fetch memories from multiple memory banks summary: Fetch memories from multiple memory banks
description: Embeds input, queries for nuggets across specified memory banks. description: Embeds input, queries for nuggets across specified memory banks.
@ -519,26 +476,14 @@ components:
description: "Additional metadata as JSON." description: "Additional metadata as JSON."
Attachment: Attachment:
type: object type: object
properties: description: Represents a file (text or media).
type: properites:
$ref: '#/components/schemas/AttachmentType' uri:
kind:
$ref: '#/components/schemas/AttachmentKind'
data:
type: string type: string
AttachmentType: description: The path at which the attachment resides.
mime-type:
type: string type: string
enum: description: The attachment's MIME type.
- image
- text
description: "Type of media attachment. Currently only support image and text."
AttachmentKind:
type: string
enum:
- raw_bytes
- filepath
- uri
description: "How media attachment is provided."
ModelOutputMessage: ModelOutputMessage:
type: object type: object
properties: properties:
@ -546,10 +491,6 @@ components:
type: string type: string
text: text:
type: string type: string
attachments:
type: array
items:
$ref: '#/components/schemas/MediaAttachment'
tokens: tokens:
type: array type: array
items: items:
@ -662,7 +603,7 @@ components:
filename: filename:
type: string type: string
description: The filename where logs will be stored on disk. description: The filename where logs will be stored on disk.
FullFineTuneOptions: FullFineTuningOptions:
type: object type: object
properties: properties:
enable_activation_checkpointing: enable_activation_checkpointing:
@ -674,7 +615,7 @@ components:
fsdp_cpu_offload: fsdp_cpu_offload:
type: boolean type: boolean
default: true default: true
LoraFineTuneOptions: LoraFineTuningOptions:
type: object type: object
properties: properties:
lora_attn_modules: lora_attn_modules:
@ -709,8 +650,8 @@ components:
type: boolean type: boolean
custom_training_options: custom_training_options:
oneOf: oneOf:
- $ref: '#/components/schemas/FullFineTuneOptions' - $ref: '#/components/schemas/FullFineTuningOptions'
- $ref: '#/components/schemas/LoraFineTuneOptions' - $ref: '#/components/schemas/LoraFineTuningOptions'
discriminator: discriminator:
propertyName: finetuning_type propertyName: finetuning_type
extras: extras:
@ -899,6 +840,7 @@ components:
type: string type: string
description: The URI for the inference provider description: The URI for the inference provider
batchInferenceProvider: batchInferenceProvider:
metricLoggerProvider: WandB
Agent: Agent:
type: object type: object
description: Represents an AI agent with specific tools and a model configuration. description: Represents an AI agent with specific tools and a model configuration.
@ -1032,9 +974,9 @@ components:
type: object type: object
additionalProperties: true additionalProperties: true
description: A flexible structure to store additional metadata about the turn, such as such as contextual information, execution details, or any other relevant data that needs to be persisted or passed along with the turn. description: A flexible structure to store additional metadata about the turn, such as such as contextual information, execution details, or any other relevant data that needs to be persisted or passed along with the turn.
MemoryBank: VectorStore:
type: object type: object
description: Represents a memory bank. description: Store for RAG
properties: properties:
id: id:
type: string type: string
@ -1045,16 +987,23 @@ components:
description: description:
type: string type: string
description: A brief description of the memory bank's purpose and contents. description: A brief description of the memory bank's purpose and contents.
MemoryNugget: VectorStoreInsertJob:
type: object type: object
description: Represents a memory nugget. description: Represents a job that is uploading a file into a vector store
properties: properties:
id: id:
type: string type: string
description: The unique identifier of the memory nugget. description: The unique identifier of the insert job
content: content:
type: string type: string
description: The embedded content of the memory nugget. description: The embedded content of the memory nugget.
VectorStoreDeleteJob:
type: object
description: Represents a job that is removing contents of a file from a vector store
properties:
id:
type: string
description: The unique identifier of the delete job
AgenticSystemDeploymentConfig: AgenticSystemDeploymentConfig:
type: object type: object
description: Holds global deployment configuration needed to make different API calls across the stack. description: Holds global deployment configuration needed to make different API calls across the stack.