Commit Graph

754 Commits

Author SHA1 Message Date
Stan Girard
82b25fe924
feat: Update OCR image scale for better accuracy (#3310)
The image scale for OCR processing has been updated to improve accuracy.
This change increases the scale from 300 to 500, resulting in better
quality text recognition.

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-10-03 08:07:10 -07:00
Stan Girard
55a28c0945
feat: Add debug logging for OCR results (#3309)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-10-03 07:37:40 -07:00
Stan Girard
b767f19f28
feat(assistant): cdp (#3305)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):

---------

Co-authored-by: Zewed <dewez.antoine2@gmail.com>
2024-10-03 06:46:59 -07:00
Stan Girard
113e13a573
feat: Add error handling for rate-limited search in fetch_notion_pages (#3298)
The fetch_notion_pages function now includes error handling for
rate-limited searches. If a rate-limited response is received, the
function waits for 10 seconds before retrying the search. This ensures
that the function can handle rate limits and continue fetching Notion
pages.

Co-authored-by: StanGirard <stan@example.com>
Co-authored-by: ZeWed <zewed@example.com>
2024-10-01 05:43:19 -07:00
Stan Girard
08d5caf796
feat: add syncNotion from ConnectionCards (#3292)
This commit removes the syncNotion function from the ConnectionCards
component. The function is no longer needed, simplifying the code and
improving maintainability.

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-30 08:57:23 -07:00
Stan Girard
f0ee99a1cf
feat: update SyncsUser status field to be optional (#3284)
The SyncsUser model in sync_models.py now has an optional status field.
This change allows for more flexibility in managing user synchronization
status.

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-30 06:49:08 -07:00
Stan Girard
fbef123fdc
chore: add wget to Dockerfile dependencies (#3279)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-30 03:42:51 -07:00
Stan Girard
f334dc0f49
chore: update Dockerfile dependencies and copy files (#3277)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-30 03:26:50 -07:00
Stan Girard
11f5448008
feat: update sync_user.py to include sync user id in aget_files call (#3276)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-30 02:43:53 -07:00
AmineDiro
0c90254399
fix: add sync user id aget_files (#3261) 2024-09-25 09:08:12 -07:00
Jacopo Chevallard
ebeb41e579
fix: correctly passing the prompt provided by the user (#3252)
Closes CORE-207

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-24 05:26:18 -07:00
Jacopo Chevallard
1456015c68
fix: wrong default path for CHAT_LLM_CONFIG_PATH env variable (#3247)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-23 10:15:07 -07:00
Jacopo Chevallard
ef90e8e672
feat: introducing configurable retrieval workflows (#3227)
# Description

Major PR which, among other things, introduces the possibility of easily
customizing the retrieval workflows. Workflows are based on LangGraph,
and can be customized using a [yaml configuration
file](core/tests/test_llm_endpoint.py), and adding the implementation of
the nodes logic into
[quivr_rag_langgraph.py](1a0c98437a/backend/core/quivr_core/quivr_rag_langgraph.py)

This is a first, simple implementation that will significantly evolve in
the coming weeks to enable more complex workflows (for instance, with
conditional nodes). We also plan to adopt a similar approach for the
ingestion part, i.e. to enable user to easily customize the ingestion
pipeline.

Closes CORE-195, CORE-203, CORE-204

## Checklist before requesting a review

Please delete options that are not relevant.

- [X] My code follows the style guidelines of this project
- [X] I have performed a self-review of my code
- [X] I have commented hard-to-understand areas
- [X] I have ideally added tests that prove my fix is effective or that
my feature works
- [X] New and existing unit tests pass locally with my changes
- [X] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-23 09:11:06 -07:00
AmineDiro
5e48594c77
feat: remove n+1 query knowledge (#3238)
# Description

closes #3237
2024-09-23 02:41:35 -07:00
Stan Girard
ad87641d19
fix(migration): order migrations (#3231)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-19 06:21:33 -07:00
Chloé Daems
42f4bb724e
feat(integration): Notion (#3173)
# Description

Fix multiple notion bugs 👍 

-> Delete your notion sync and all the notion files from the db
-> Ensure a sync is not already running before launching a sync.
-> Add a status to subscribe to for user_sync

---------

Co-authored-by: Antoine Dewez <44063631+Zewed@users.noreply.github.com>
Co-authored-by: Stan Girard <stan@quivr.app>
Co-authored-by: aminediro <aminedirhoussi1@gmail.com>
Co-authored-by: Stan Girard <girard.stanislas@gmail.com>
2024-09-19 05:37:04 -07:00
Stan Girard
9c6d998c7c
chore(examples): fix chainlit example (#3223)
The commit updates the message content in the `main.py` file of the
chatbot example.

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-18 08:12:24 -07:00
Stan Girard
282fa0e3f8
feat(assistants): mock api (#3195)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-18 03:30:48 -07:00
Stan Girard
4390d318a2
chore(main): release core 0.0.16 (#3218)
🤖 I have created a release *beep* *boop*
---


##
[0.0.16](https://github.com/QuivrHQ/quivr/compare/core-0.0.15...core-0.0.16)
(2024-09-17)


### Bug Fixes

* **core:** enforce langchain &lt;0.3 for pydantic v1
([#3217](https://github.com/QuivrHQ/quivr/issues/3217))
([4bb4800](4bb4800a76))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
2024-09-17 15:18:00 -07:00
Stan Girard
4bb4800a76
fix(core): enforce langchain <0.3 for pydantic v1 (#3217)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-17 15:17:11 -07:00
AmineDiro
6a0dbfe833
fix: knowledge user_id fix (#3216) 2024-09-17 19:06:04 +02:00
Stan Girard
348c1a71b0
chore(main): release core 0.0.15 (#3203)
🤖 I have created a release *beep* *boop*
---


##
[0.0.15](https://github.com/QuivrHQ/quivr/compare/core-0.0.14...core-0.0.15)
(2024-09-16)


### Features

* CRUD KMS (no syncs)
([#3162](https://github.com/QuivrHQ/quivr/issues/3162))
([71edca5](71edca572f))
* save and load brain
([#3202](https://github.com/QuivrHQ/quivr/issues/3202))
([eda619f](eda619f454))


### Bug Fixes

* Update LLMEndpoint to include max_tokens parameter
([#3201](https://github.com/QuivrHQ/quivr/issues/3201))
([13ed225](13ed225b17))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
2024-09-16 05:54:29 -07:00
AmineDiro
71edca572f
feat: CRUD KMS (no syncs) (#3162)
# Description

closes #3056.
closes #3198 


- Create knowledge route
- Get knowledge route
- List knowledge route : accepts knowledge_id | None. None to list root
knowledge for use
- Update (patch) knowledge to rename and move knowledge
- Remove knowledge: Cascade if parent_id in knowledge and cleanup
storage
- Link storage upload to knowledge_service
- Relax sha1 file constraint
- Tests to all repository / service

---------

Co-authored-by: Stan Girard <girard.stanislas@gmail.com>
2024-09-16 04:31:09 -07:00
AmineDiro
eda619f454
feat: save and load brain (#3202)
# Description
- Save and load brain to disk: 
```python
async def main():
    with tempfile.NamedTemporaryFile(mode="w", suffix=".txt") as temp_file:
        temp_file.write("Gold is a liquid of blue-like colour.")
        temp_file.flush()

        brain = await Brain.afrom_files(name="test_brain", file_paths=[temp_file.name])

        save_path = await brain.save("/home/amine/.local/quivr")

        brain_loaded = Brain.load(save_path)
        brain_loaded.print_info()

```

# TODO: 
- Loading all chat history
- Loading from other vector stores, PG for example can be great ...
2024-09-13 06:35:28 -07:00
Stan Girard
13ed225b17
fix: Update LLMEndpoint to include max_tokens parameter (#3201)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-13 01:59:41 -07:00
Stan Girard
d9b0e62618
feat(uptime): check if connection to db works (#3199)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-12 08:22:24 -07:00
Stan Girard
758e87e89c
chore(embeddings): added tests for embeddings (#3183)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-11 07:00:19 -07:00
Stan Girard
452f09280d
feat: Add Azure OpenAI embeddings support (#3182)
The code changes in `dependencies.py` add support for Azure OpenAI
embeddings by parsing the provided URL and extracting the deployment
name, endpoint, and API version. This allows the application to use
Azure OpenAI embeddings for language processing.

Note: The recent user commits and repository commits are not directly
related to the code changes in `dependencies.py` and are not considered
for the commit message.

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-10 09:44:22 -07:00
Stan Girard
9cbb47f75a
feat: Add external Supabase URL support for generating file signed URL (#3179)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-10 07:53:44 -07:00
Stan Girard
fba181077f
chore(main): release core 0.0.14 (#2945)
🤖 I have created a release *beep* *boop*
---


##
[0.0.14](https://github.com/QuivrHQ/quivr/compare/core-0.0.13...core-0.0.14)
(2024-09-09)


### Features

* Add brain_id and brain_name to ChatLLMMetadata model
([#2968](https://github.com/QuivrHQ/quivr/issues/2968))
([1112001](111200184b))
* add chat with models
([#2933](https://github.com/QuivrHQ/quivr/issues/2933))
([fccd197](fccd197511))
* Add get_model method to ModelRepository
([#2949](https://github.com/QuivrHQ/quivr/issues/2949))
([13e9fc4](13e9fc490b))
* **anthropic:** add llm
([#3146](https://github.com/QuivrHQ/quivr/issues/3146))
([8e29218](8e29218865))
* **azure:** quivr compatible with it
([#3005](https://github.com/QuivrHQ/quivr/issues/3005))
([b5f31a8](b5f31a83d4))
* **frontend:** talk with models and handle code markdown
([#2980](https://github.com/QuivrHQ/quivr/issues/2980))
([ef6037e](ef6037e665))
* quivr core 0.1 ([#2970](https://github.com/QuivrHQ/quivr/issues/2970))
([380cf82](380cf82706))
* using langgraph in our RAG pipeline
([#3130](https://github.com/QuivrHQ/quivr/issues/3130))
([8cfdf53](8cfdf53fe7))


### Bug Fixes

* **chat:** order of chat history was reversed
([#3148](https://github.com/QuivrHQ/quivr/issues/3148))
([7209500](7209500d0b))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
2024-09-10 02:00:39 -07:00
Stan Girard
317325c1a9 chore: Add empty file for backend documentation overrides 2024-09-09 11:37:43 +02:00
Stan Girard
af6db28d80 chore: Update pyproject.toml with venv and basedpyright configuration 2024-09-09 11:35:50 +02:00
Stan Girard
c9ddbbdcd3
chore: Add initial documentation files and configuration (#3126)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-09 02:06:16 -07:00
AmineDiro
89d9e2fcaf
fix: remove knowledge and idle conn (#3165)
# Description

- Add set session idle conn
- Remove brain vectore in knowledge routees ( knowledge cascades to
vectors now), should speed up th
- Add session rollback/commit to worker

TODO: Should refactor session in worker . The design async+ celery is
starting to be really bad
2024-09-06 06:56:07 -07:00
Stan Girard
b3a78a2fd2
fix: remove unused 'models' field in check_premium.py (#3164)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-06 02:30:01 -07:00
AmineDiro
f6fb868d23
fix: tests pytest-asyncio (#3157)
# Description


FIX TESTS !
2024-09-05 07:39:27 -07:00
Stan Girard
f11b98ffc6 fix: Fix invalid user check in oauth2callback_azure
The commit fixes an issue in the `oauth2callback_azure` function where the check for a valid user was incorrect. It now correctly compares the `user_id` from the `sync_user_state` object with the `current_user` value.
2024-09-05 11:18:05 +02:00
AmineDiro
9a4ee1506b
fix: url knowledge multiple brain (#3145)
# Description

- Find knowledge path in storage
2024-09-05 01:15:51 -07:00
Stan Girard
7209500d0b
fix(chat): order of chat history was reversed (#3148)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-04 07:29:08 -07:00
Stan Girard
8e29218865
feat(anthropic): add llm (#3146)
This commit adds the langchain_openai and langchain_anthropic
dependencies to the `llm_endpoint.py` file.

# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-09-04 06:24:21 -07:00
AmineDiro
d959927d33
fix: knowledge multiple brains - update knowledge rollback (#3143)
# Description

- rollback update
2024-09-03 18:40:21 +02:00
AmineDiro
43fe0d1539
fix: knowledge multiple brains (#3142)
# Description

- Same knowledge in multiple brains
- Delete knowledge works but removing the brain/knowledge association if
knowledge in multiple brains or remove knowledge if only one brain
exists
- Fix bugs in knowledge service

**NOTE:** 
- There is a risk of race condition but this shouldn't occur that often
- Sync updates could have side effects on sync knowledge that are
updated and are in multiple brains ...

---------

Co-authored-by: Stan Girard <girard.stanislas@gmail.com>
2024-09-03 17:47:57 +02:00
Jacopo Chevallard
8cfdf53fe7
feat: using langgraph in our RAG pipeline (#3130)
# Description

Using LangGraph instead of LangChain LCEL to build and run the RAG
pipeline, as LangGraph enables greater flexibility and an easier
maintainability of complex (agentic) pipelines

Completes CORE-175

## Checklist before requesting a review

Please delete options that are not relevant.

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my code
- [x] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [x] New and existing unit tests pass locally with my changes
- [x] Any dependent changes have been merged

## Screenshots (if appropriate):

---------

Co-authored-by: Stan Girard <girard.stanislas@gmail.com>
2024-09-03 06:23:23 -07:00
AmineDiro
b59fc4c0c9
fix: knowledge user (#3124)
# Description

- Add `user_id` foreign to knowledge table
- Updates knowledges service 
- Updates sha1 contraint to be on (`user_id`,`file_sha1`) on knowledge
- Fix event_loop fixture
- Adds knowledge tests

---------

Co-authored-by: chloedia <chloedaems0@gmail.com>
Co-authored-by: Stan Girard <stan@quivr.app>
Co-authored-by: aminediro <aminedirhoussi@gmail.com>
Co-authored-by: Antoine Dewez <44063631+Zewed@users.noreply.github.com>
Co-authored-by: Stan Girard <girard.stanislas@gmail.com>
Co-authored-by: Chloé Daems <73901882+chloedia@users.noreply.github.com>
Co-authored-by: porter-deployment-app[bot] <87230664+porter-deployment-app[bot]@users.noreply.github.com>
Co-authored-by: Zewed <dewez.antoine2@gmail.com>
2024-09-02 15:07:30 +02:00
Stan Girard
380cf82706
feat: quivr core 0.1 (#2970)
# Description


# Testing backend 

## Docker setup
1. Copy `.env.example` to `.env`. Some env variables were added :
EMBEDDING_DIM
2. Apply supabase migratrions : 
```sh
supabase stop
supabase db reset
supabase start
```
3. Start backend containers
```
make dev
```
## Local setup 
You can also run backend without docker.
1. Install [`rye`](https://rye.astral.sh/guide/installation/). Choose
the managed python version and set the version to 3.11
2. Run the following: 
```
cd quivr/backend
rye sync
```
3. Source `.venv` virtual env : `source .venv/bin/activate`
4. Run the backend, make sure you are running redis and supabase
API: 
```
LOG_LEVEL=debug uvicorn quivr_api.main:app --log-level debug --reload --host 0.0.0.0 --port 5050 --workers 1
```
Worker: 
```
LOG_LEVEL=debug celery -A quivr_worker.celery_worker worker -l info -E --concurrency 1
```
Notifier: 
```
LOG_LEVEL=debug python worker/quivr_worker/celery_monitor.py
```

---------

Co-authored-by: chloedia <chloedaems0@gmail.com>
Co-authored-by: aminediro <aminedirhoussi1@gmail.com>
Co-authored-by: Antoine Dewez <44063631+Zewed@users.noreply.github.com>
Co-authored-by: Chloé Daems <73901882+chloedia@users.noreply.github.com>
Co-authored-by: Zewed <dewez.antoine2@gmail.com>
2024-09-02 10:20:53 +02:00
Stan Girard
d619b0acce
feat: Update send_email.py to conditionally login with SMTP credentials (#3069)
The `send_email` function in `send_email.py` has been updated to
conditionally login with SMTP credentials. This change allows for more
flexibility in handling SMTP authentication.
2024-08-22 11:01:30 -07:00
Stan Girard
bfd309efd8
feat(smtp): not enforcing tls (#3067)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):
2024-08-22 10:40:51 -07:00
Stan Girard
e2df8b37d4
feat(smtp&share): implemented smtp support and fixed share brain (#3049)
completes ENT-53 & fixes ENT-52
2024-08-22 02:20:21 -07:00
Antoine Dewez
6b07a63e4e
feat(frontend): brain snippet selector (#3038)
# Description

Please include a summary of the changes and the related issue. Please
also include relevant motivation and context.

## Checklist before requesting a review

Please delete options that are not relevant.

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have commented hard-to-understand areas
- [ ] I have ideally added tests that prove my fix is effective or that
my feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged

## Screenshots (if appropriate):

---------

Co-authored-by: Stan Girard <stan@quivr.app>
2024-08-21 17:23:59 +02:00
Stan Girard
2a79be8e42
fix: Update Supabase configuration (#3014)
Fix CORE-152
2024-08-16 02:07:11 -07:00