mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2024-12-18 20:17:50 +00:00
added similarity for vector databses
This commit is contained in:
parent
a4fc04060b
commit
db85d91ca8
@ -1386,7 +1386,7 @@ class LOLLMSWebUI(LOLLMSElfServer):
|
||||
similarity = source["similarity"]
|
||||
sources_text += f'''
|
||||
<div class="source-item">
|
||||
<button onclick="var details = document.getElementById('source-details-{title}'); details.style.display = details.style.display === 'none' ? 'block' : 'none';" style="text-align: left; font-weight: bold;"><strong>{title}</strong></button>
|
||||
<button onclick="var details = document.getElementById('source-details-{title}'); details.style.display = details.style.display === 'none' ? 'block' : 'none';" style="text-align: left; font-weight: bold;"><strong>{title}</strong> - ({similarity*100:.2f}%)</button>
|
||||
<div id="source-details-{title}" style="display:none;">
|
||||
<div style="max-height: 200px; overflow-y: auto;">
|
||||
<p><strong>Path:</strong> {path}</p>
|
||||
|
Loading…
Reference in New Issue
Block a user