Skip to main content

Crate cognee_models

Crate cognee_models 

Source
Expand description

Core data types shared across the cognee-rust crates (Data, Dataset, Document, DocumentChunk, Entity, KnowledgeGraph, and more).

Re-exports§

pub use has_datapoint::HasDataPoint;
pub use memory::FeedbackEntry;
pub use memory::MemoryEntry;
pub use memory::QAEntry;
pub use memory::TraceEntry;
pub use permission::permissions;
pub use temporal_event::*;

Modules§

has_datapoint
The HasDataPoint trait used by the provenance-stamping algorithm in cognee-core::provenance.
memory
Memory entry types for typed remember() dispatch. Discriminated-union memory entries for remember() typed dispatch.
permission
Permission helpers.
temporal_event
Temporal event and timestamp types for the cognify pipeline.

Structs§

BackendConfig
Configuration for dynamically selecting/creating a backend.
BackendOverrides
Per-call backend configuration overrides.
Data
Represents a piece of data in the system, such as a file or a text. Fields match the Python cognee data table schema for cross-SDK compatibility.
DataPoint
Base model for all storage-layer entities.
Dataset
Document
A classified document derived from a Data item.
DocumentChunk
A chunk of text extracted from a document during the cognify pipeline.
EdgeMetadata
Edge metadata for relationships between DataPoints.
EdgeType
Storage-layer edge type model.
Embedding
Embedding vector for a data point field.
Entity
Storage-layer entity model.
EntityType
Storage-layer entity type model.
Triplet
A triplet representing a semantic relationship between two entities.
User
A registered user. Corresponds to Python cognee.modules.users.models.User.

Enums§

DataInput

Functions§

classify_documents
Classify Data items into Documents based on file extension.
doc_type_for_extension
Map a file extension to a document type string, returning None for unrecognised extensions.