nextcloud / context_chat_backend

GNU Affero General Public License v3.0
5 stars 5 forks source link

Updates to files in Collectives will not be synchronized to the Context Chat Backend. #72

Open aef5748 opened 3 weeks ago

aef5748 commented 3 weeks ago
  1. Install Collectives.
  2. Create a new Collective and add the file test_file.md
  3. Synchronize the test_file.md file to the Context Chat Backend using php cron.php.
  4. Modify test_file.md and run php cron.php to synchronize, but the updated file content is not synchronized to the Context Chat Backend.
kyteinsky commented 3 weeks ago

Hi, how do you verify the synchronization has completed? The cron process indexes files for all the users so the modification would be listed at the bottom of the indexation jobs, Try asking a question with "Selective context" in the assistant to force it to index it on the fly.

aef5748 commented 2 weeks ago

Hi, I did the following test while observing the logs from the context chat backend

If I add a new file or modify it in files, and manually execute php cron.php, I will see that the file is synchronized to the context chat backend. It seems normal, but when using collectives, only added files will be synchronized. context chat backend, modified files will not be synchronized

kyteinsky commented 1 week ago

Not sure why that happens since the editors in both files and collectives is the same "text" app, and in my testing it emit the NodeWrittenEvent in both the places as expected. To be 100% sure, you can inspect the database of the backend manually. It is located at /nc_app_context_chat_backend_data/vector_db_data/chroma.sqlite3 inside the container nc_app_context_chat_backend. The table embedding_metadata will have the desired data.