1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
//! # cognis-core
//!
//! Foundation layer for the Cognis LLM framework. This crate defines the base
//! traits, types, and abstractions that all other crates in the workspace depend on.
//! It has **zero** dependencies on other workspace crates.
//!
//! ## Key Modules
//!
//! - [`messages`] -- `Message` enum (Human, AI, System, Tool) and utilities for
//! conversion, filtering, trimming, and merging message sequences.
//! - [`language_models`] -- `BaseChatModel` and `BaseLLM` traits that chat model
//! providers implement, plus fake models for testing.
//! - [`runnables`] -- The composable `Runnable` trait and combinators: sequence,
//! parallel, branch, lambda, retry, fallbacks, passthrough.
//! - [`tools`] -- `BaseTool` trait for agent tool calling with JSON schema support.
//! - [`prompts`] -- Chat prompt templates, few-shot example selectors, and
//! structured prompt builders.
//! - [`output_parsers`] -- Parsers for JSON, string, list, XML, and tool-call outputs.
//! - [`callbacks`] -- Extensible callback system with handler traits and run managers.
//! - [`vectorstores`] -- `VectorStore` trait and in-memory implementation.
//! - [`embeddings`] -- `Embeddings` trait for vector embedding providers.
//! - [`documents`] -- `Document` type used across loaders, splitters, and retrievers.
//!
//! ## Quick Example
//!
//! ```rust
//! use cognis_core::messages::Message;
//!
//! let msg = Message::human("What is the capital of France?");
//! assert_eq!(msg.message_type(), cognis_core::messages::MessageType::Human);
//! ```
pub use ;
pub use CancellationToken;