Skip to main content

troupekit_kit/
lib.rs

1#![doc(
2    html_logo_url = "https://raw.githubusercontent.com/ChaoticQubit/troupekit/main/assets/brand/logo-mark.svg",
3    html_favicon_url = "https://raw.githubusercontent.com/ChaoticQubit/troupekit/main/assets/brand/favicon.svg"
4)]
5
6mod agent;
7mod built;
8mod error;
9mod graph;
10#[cfg(feature = "knowledge")]
11pub mod knowledge;
12mod laws;
13#[cfg(feature = "knowledge")]
14mod memory;
15mod model;
16mod output;
17mod route;
18mod storage;
19mod tool;
20mod trace;
21
22#[doc(hidden)]
23pub mod __private;
24
25pub use agent::Agent;
26pub use built::{BuiltAgent, Input, RunOutcome};
27pub use error::KitError;
28pub use graph::{BuiltGraph, Graph, GraphReport};
29#[cfg(feature = "knowledge")]
30pub use knowledge::Knowledge;
31pub use laws::Laws;
32#[cfg(feature = "knowledge")]
33pub use memory::AgentMemory;
34pub use output::{IntoToolOutput, Json};
35pub use storage::Storage;
36pub use tool::{tool, AsTool};
37pub use troupekit_macros::{agent, tool};
38pub use troupekit_tools::{Tool, ToolContext, ToolOutput};
39
40/// The names most programs need, for `use troupekit::prelude::*;`.
41/// Builder, built agent, outcome, storage, laws, errors and tools.
42/// `AsTool`, `IntoToolOutput` and `Input` stay at the crate root.
43pub mod prelude {
44    pub use crate::{
45        agent, tool, Agent, BuiltAgent, BuiltGraph, Graph, Json, KitError, Laws, RunOutcome,
46        Storage,
47    };
48    #[cfg(feature = "knowledge")]
49    pub use crate::{AgentMemory, Knowledge};
50    pub use troupekit_trace::Trace;
51}
52
53#[cfg(feature = "local")]
54mod local;
55#[cfg(feature = "local")]
56pub use local::LocalChoice;