updated vector_store to remove parsing module
This commit is contained in:
parent
d1bdfa0be6
commit
9d19dea7dd
1 changed files with 7 additions and 2 deletions
|
@ -1,6 +1,5 @@
|
||||||
mod db;
|
mod db;
|
||||||
mod embedding;
|
mod embedding;
|
||||||
mod parsing;
|
|
||||||
mod search;
|
mod search;
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
|
@ -11,7 +10,6 @@ use db::{FileSha1, VectorDatabase, VECTOR_DB_URL};
|
||||||
use embedding::{EmbeddingProvider, OpenAIEmbeddings};
|
use embedding::{EmbeddingProvider, OpenAIEmbeddings};
|
||||||
use gpui::{actions, AppContext, Entity, ModelContext, ModelHandle, Task, ViewContext};
|
use gpui::{actions, AppContext, Entity, ModelContext, ModelHandle, Task, ViewContext};
|
||||||
use language::{Language, LanguageRegistry};
|
use language::{Language, LanguageRegistry};
|
||||||
use parsing::Document;
|
|
||||||
use project::{Fs, Project};
|
use project::{Fs, Project};
|
||||||
use smol::channel;
|
use smol::channel;
|
||||||
use std::{cmp::Ordering, collections::HashMap, path::PathBuf, sync::Arc};
|
use std::{cmp::Ordering, collections::HashMap, path::PathBuf, sync::Arc};
|
||||||
|
@ -21,6 +19,13 @@ use workspace::{Workspace, WorkspaceCreated};
|
||||||
|
|
||||||
actions!(semantic_search, [TestSearch]);
|
actions!(semantic_search, [TestSearch]);
|
||||||
|
|
||||||
|
#[derive(Debug)]
|
||||||
|
pub struct Document {
|
||||||
|
pub offset: usize,
|
||||||
|
pub name: String,
|
||||||
|
pub embedding: Vec<f32>,
|
||||||
|
}
|
||||||
|
|
||||||
pub fn init(
|
pub fn init(
|
||||||
fs: Arc<dyn Fs>,
|
fs: Arc<dyn Fs>,
|
||||||
http_client: Arc<dyn HttpClient>,
|
http_client: Arc<dyn HttpClient>,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue