trying removing Collection as return type
Browse files
main.py
CHANGED
@@ -128,12 +128,12 @@ def list_collections():
|
|
128 |
return bkend.list_collections()
|
129 |
|
130 |
@app.post(api_base+"/collections")
|
131 |
-
def create_collection( collection: CreateCollection )
|
132 |
print("Received request to create_collection")
|
133 |
return bkend.create_collection(name=collection.name,metadata=collection.metadata,embedding_function=embedding_function,get_or_create=collection.get_or_create)
|
134 |
|
135 |
@app.get(api_base+"/collections/{collection_name}")
|
136 |
-
def get_collection( collection_name: str)
|
137 |
print("Received get_collection request")
|
138 |
return bkend.get_collection(collection_name,embedding_function=embedding_function)
|
139 |
|
|
|
128 |
return bkend.list_collections()
|
129 |
|
130 |
@app.post(api_base+"/collections")
|
131 |
+
def create_collection( collection: CreateCollection ) :
|
132 |
print("Received request to create_collection")
|
133 |
return bkend.create_collection(name=collection.name,metadata=collection.metadata,embedding_function=embedding_function,get_or_create=collection.get_or_create)
|
134 |
|
135 |
@app.get(api_base+"/collections/{collection_name}")
|
136 |
+
def get_collection( collection_name: str) :
|
137 |
print("Received get_collection request")
|
138 |
return bkend.get_collection(collection_name,embedding_function=embedding_function)
|
139 |
|