Skip to content

Commit 8437442

Browse files
committed
removing batch_size from request
1 parent c7da9f0 commit 8437442

File tree

2 files changed

+8
-16
lines changed

2 files changed

+8
-16
lines changed

backend/app/api/routes/collections.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -120,14 +120,15 @@ def create_collection(
120120
with_assistant=with_assistant,
121121
)
122122

123-
metadata = None
123+
metadata = {}
124+
124125
if not with_assistant:
125-
metadata = {
126-
"note": (
127-
"This job will create a vector store only (no Assistant). "
128-
"Assistant creation happens when both 'model' and 'instructions' are included."
129-
)
130-
}
126+
metadata["assistant_note"] = (
127+
"This job will create a vector store only (no Assistant). "
128+
"Assistant creation happens when both 'model' and 'instructions' are included."
129+
)
130+
131+
metadata = metadata if metadata else None
131132

132133
return APIResponse.success_response(
133134
CollectionJobImmediatePublic.model_validate(collection_job), metadata=metadata

backend/app/models/collection.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,6 @@ class CollectionOptions(SQLModel):
102102
documents: list[UUID] = Field(
103103
description="List of document IDs",
104104
)
105-
batch_size: int = Field(
106-
default=10,
107-
description=(
108-
"**[Deprecated]** "
109-
"Number of documents to send to OpenAI in a single "
110-
"transaction. See the `file_ids` parameter in the "
111-
"vector store [create batch](https://platform.openai.com/docs/api-reference/vector-stores-file-batches/createBatch)."
112-
),
113-
)
114105

115106
def model_post_init(self, __context: Any):
116107
self.documents = list(set(self.documents))

0 commit comments

Comments
 (0)