mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 11:39:01 +01:00 
			
		
		
		
	I don't think this can hurt to prioritize summaries of content
This commit is contained in:
		
							parent
							
								
									d1295ede90
								
							
						
					
					
						commit
						5e50a2918d
					
				| @ -100,9 +100,13 @@ export class VectorSearchTool { | ||||
|                 noteId: note.noteId, | ||||
|                 title: note.title, | ||||
|                 contentPreview: note.content | ||||
|                     ? note.content.length > 200 | ||||
|                     ? (options.summarizeContent | ||||
|                         // Don't truncate already summarized content
 | ||||
|                         ? note.content | ||||
|                         // Only truncate non-summarized content
 | ||||
|                         : (note.content.length > 200 | ||||
|                             ? note.content.substring(0, 200) + '...' | ||||
|                         : note.content | ||||
|                             : note.content)) | ||||
|                     : 'No content available', | ||||
|                 similarity: note.similarity, | ||||
|                 parentId: note.parentId | ||||
| @ -144,10 +148,14 @@ export class VectorSearchTool { | ||||
|             return results.map(result => ({ | ||||
|                 noteId: result.noteId, | ||||
|                 title: result.title, | ||||
|                 contentPreview: result.content ? | ||||
|                     (result.content.length > 200 ? | ||||
|                         result.content.substring(0, 200) + '...' : | ||||
|                         result.content) | ||||
|                 contentPreview: result.content | ||||
|                     ? (summarize | ||||
|                         // Don't truncate already summarized content
 | ||||
|                         ? result.content | ||||
|                         // Only truncate non-summarized content
 | ||||
|                         : (result.content.length > 200 | ||||
|                             ? result.content.substring(0, 200) + '...' | ||||
|                             : result.content)) | ||||
|                     : 'No content available', | ||||
|                 similarity: result.similarity, | ||||
|                 parentId: result.parentId | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 perf3ct
						perf3ct