diff --git a/.github/workflows/vercel.yml b/.github/workflows/vercel.yml index 944f7b267..96f49f7fb 100644 --- a/.github/workflows/vercel.yml +++ b/.github/workflows/vercel.yml @@ -14,6 +14,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 + with: + submodules: 'true' - name: Install Vercel CLI run: npm install --global vercel@latest - name: Pull Vercel Environment Information diff --git a/.gitignore b/.gitignore index e2d84c009..66787ddfe 100644 --- a/.gitignore +++ b/.gitignore @@ -71,4 +71,4 @@ backend/pyvenv.cfg backend/share/* backend/slim.report.json volumes/db/data/ -volumes/storage/stub/stub/quivr/* \ No newline at end of file +volumes/storage/stub/stub/quivr/* diff --git a/frontend/lib/api/brain/brain.ts b/frontend/lib/api/brain/brain.ts index 3c6c7ce09..4f2361517 100644 --- a/frontend/lib/api/brain/brain.ts +++ b/frontend/lib/api/brain/brain.ts @@ -11,6 +11,7 @@ import { import { CreateBrainInput, + ListFilesProps, SubscriptionUpdatableProperties, UpdateBrainInput, } from "./types"; @@ -144,8 +145,8 @@ export const getDocsFromQuestion = async ( brainId: string, question: string, axiosInstance: AxiosInstance -): Promise => { - return (await axiosInstance.post>(`/brains/${brainId}/documents`, { +): Promise => { + return (await axiosInstance.post>(`/brains/${brainId}/documents`, { question, })).data.docs; } diff --git a/frontend/lib/api/brain/types.ts b/frontend/lib/api/brain/types.ts index 4ff492a39..eade9e951 100644 --- a/frontend/lib/api/brain/types.ts +++ b/frontend/lib/api/brain/types.ts @@ -23,6 +23,17 @@ export type SubscriptionUpdatableProperties = { role: BrainRoleType | null; }; +export type ListFilesProps = { + files: { + file_name: string; + file_sha1: string; + file_size: number; + file_url: string; + file_id: string; + file_similarity: number; + }[]; +}; + export type ApiBrainDefinitionSecret = { name: string; type: ApiBrainDefinitionSchemaPropertyType;