brianpetro / obsidian-smart-connections

Chat with your notes & see links to related content with AI embeddings. Use local models or 100+ via APIs like Claude, Gemini, ChatGPT & Llama 3
https://smartconnections.app
GNU General Public License v3.0
2.73k stars 181 forks source link

Multiple issues with saving embeddings (2.1.94) #739

Open alk0 opened 2 months ago

alk0 commented 2 months ago

There are multiple issues, I don't even know where to start and how to isolate them.

Less severe:

Any ideas how can I be of more help in investigating any of those?

brianpetro commented 2 months ago

Hi @alk0 and thanks for bringing these issues to my attention 😊

I'm currently testing a new logic for saving data. Since you seem to be interested in digging into the details, you can see the changes here https://github.com/brianpetro/jsbrains/commits/main

The first two bullet-points should be improved/fixed as soon as I ship the above.

As far as duplicate content in those save files, that was actually by design as a way to prevent overwrites (appends rather than re-writes the file, duplicates are handled later during the load process). This has been removed for now in the upcoming version.

re: changes not being immediately reflected: This is something I expect to improve in the future. The challenge is that it is a rather intensive process. So there's a trade-off between auto-triggering the refresh and performance. In the meantime, there is a "Refresh & Make Connections" command that you can use to refresh the embedding and update the Smart Connections results. You can set a hotkey via the native Obsidian hotkeys interface for this command to speed up the process.

re: embedding new notes This is a bug that needs to be addressed. I added the "Untitled" default exclusion for this reason, however, I understand that not all new notes may have this name. Another thing that should work is the "minimum embed input length" setting. The note file/folder path is included in this calculation, so I would make sure the setting is at minimum 100 (characters).

I hope that helps clear things up. The new version that should improve the saving will be shipped to the early release (v2.2) today and should follow in the v2.1 as early as tomorrow,

🌴