Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions crates/cortexadb-core/src/core/command.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
use serde::{Deserialize, Serialize};

use super::memory_entry::MemoryEntry;
use crate::core::memory_entry::MemoryId;
use crate::core::memory_entry::{MemoryEntry, MemoryId};

/// State-mutating commands for the state machine
#[derive(Debug, Clone, Serialize, Deserialize)]
Expand Down
7 changes: 0 additions & 7 deletions crates/cortexadb-core/src/core/memory_entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,4 @@ mod tests {
assert_eq!(entry.importance, 0.8);
assert_eq!(entry.embedding, Some(vec![0.1, 0.2, 0.3]));
}

#[test]
fn test_memory_id_ordering() {
let id1 = MemoryId(1);
let id2 = MemoryId(2);
assert!(id1 < id2);
}
}
2 changes: 1 addition & 1 deletion crates/cortexadb-core/src/core/state_machine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::collections::{BTreeMap, HashMap};
use serde::{Deserialize, Serialize};
use thiserror::Error;

use super::{
use crate::core::{
command::Command,
memory_entry::{MemoryEntry, MemoryId},
};
Expand Down
2 changes: 1 addition & 1 deletion crates/cortexadb-core/src/engine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ impl Engine {
&self.state_machine
}

/// Get mutable reference to the state machine
/// Get mutable reference to the state machine
pub(crate) fn get_state_machine_mut(&mut self) -> &mut StateMachine {
&mut self.state_machine
}
Expand Down
4 changes: 3 additions & 1 deletion crates/cortexadb-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,7 @@ pub mod store;

// Re-export the primary facade types for convenience.
pub use chunker::{chunk, ChunkMetadata, ChunkResult, ChunkingStrategy};
pub use facade::{BatchRecord, CortexaDB, CortexaDBBuilder, CortexaDBConfig, CortexaDBError, Hit, Memory, Stats};
pub use facade::{
BatchRecord, CortexaDB, CortexaDBBuilder, CortexaDBConfig, CortexaDBError, Hit, Memory, Stats,
};
pub use index::{HnswBackend, HnswConfig, HnswError, IndexMode, MetricKind};
Loading