feat: frontend file upload support

This commit is contained in:
Timothy J. Baek 2024-01-07 00:57:10 -08:00
parent 3229ec116c
commit fef4725d56
6 changed files with 223 additions and 92 deletions

View file

@ -11,7 +11,6 @@ export const uploadDocToVectorDB = async (token: string, collection_name: string
method: 'POST',
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
authorization: `Bearer ${token}`
},
body: data
@ -85,7 +84,6 @@ export const queryVectorDB = async (
method: 'GET',
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
authorization: `Bearer ${token}`
}
}
@ -96,7 +94,6 @@ export const queryVectorDB = async (
})
.catch((err) => {
error = err.detail;
console.log(err);
return null;
});