quivr/backend/modules
Stan Girard 311d9bb15c
feat(assistant): check if key of file is same as filename uploaded (#2439)
This pull request fixes the file key validation in the `check_input`
method. Previously, the method only checked if a file was uploaded and
if the key of the file was "doc_to_summarize". However, it did not check
if the key of the file was the same as the name of the file. This PR
adds a check to ensure that the key of the file is the same as the name
of the file. This improves the accuracy of the file validation process.

<!--
ELLIPSIS_HIDDEN
-->


----

| <a href="https://ellipsis.dev" target="_blank"><img
src="https://avatars.githubusercontent.com/u/80834858?s=400&u=31e596315b0d8f7465b3ee670f25cea677299c96&v=4"
alt="Ellipsis" width="30px" height="30px"/></a> | 🚀 This PR
description was created by [Ellipsis](https://www.ellipsis.dev) for
commit 8f04d832ac. |
|--------|--------|

### Summary:
This PR enhances the file validation process in the `SummaryAssistant`
class by ensuring the key of the uploaded file matches its filename.

**Key points**:
- Added a new file key validation in `check_input` method of
`SummaryAssistant` class.
- The validation checks if the key of the uploaded file matches the
filename.
- This is an additional check to the existing file upload and key
validations.


----
Generated with ❤️ by [ellipsis.dev](https://www.ellipsis.dev)



<!--
ELLIPSIS_HIDDEN
-->
2024-04-17 13:27:15 -07:00
..
analytics feat(analytics): rely on sql rather that python loop for brains (#2437) 2024-04-17 07:24:03 -07:00
api_key tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
assistant feat(assistant): check if key of file is same as filename uploaded (#2439) 2024-04-17 13:27:15 -07:00
authorization/utils refactor: to modules (#1754) 2023-11-30 22:29:28 +01:00
brain tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
chat tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
contact_support/controller feat(lcel): migrated to lcel and pydantic (#2185) 2024-02-14 14:01:35 -08:00
knowledge feat(analytics): added analytics page (#2416) 2024-04-10 02:20:21 -07:00
misc/controller refactor: to modules (#1754) 2023-11-30 22:29:28 +01:00
notification tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
onboarding tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
prompt tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
upload tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
user tests: added new way of testing less prone to errors 2024-04-15 18:22:21 +02:00
__init__.py refactor: add modules folder (#1633) 2023-11-15 13:17:51 +01:00