mirror of
https://github.com/perstarkse/minne.git
synced 2026-03-19 07:54:29 +01:00
moved entry points to bin to clarify
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
use std::time::Instant;
|
||||
|
||||
use text_splitter::TextSplitter;
|
||||
use tracing::{debug, info};
|
||||
|
||||
@@ -35,11 +37,17 @@ impl ContentProcessor {
|
||||
// Store original content
|
||||
store_item(&self.db_client, content.clone()).await?;
|
||||
|
||||
let now = Instant::now();
|
||||
// Process in parallel where possible
|
||||
let (analysis, _similar_chunks) = tokio::try_join!(
|
||||
self.perform_semantic_analysis(content),
|
||||
self.find_similar_content(content),
|
||||
)?;
|
||||
let end = now.elapsed();
|
||||
info!(
|
||||
"{:?} time elapsed during creation of entities and relationships",
|
||||
end
|
||||
);
|
||||
|
||||
// Convert and store entities
|
||||
let (entities, relationships) = analysis
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
use futures_lite::stream::StreamExt;
|
||||
use futures::StreamExt;
|
||||
use lapin::{message::Delivery, options::*, types::FieldTable, Channel, Consumer, Queue};
|
||||
|
||||
use crate::{
|
||||
|
||||
Reference in New Issue
Block a user