1uniffi::setup_scaffolding!();
2
3mod agent;
4mod error;
5mod graph;
6mod host;
7mod records;
8mod stream;
9
10pub use agent::{AgentBuilder, AgentHandle};
11pub use error::{ErrorCode, HostError, TroupekitError};
12pub use graph::{GraphBuilder, GraphHandle};
13#[cfg(feature = "knowledge")]
14pub use host::HostEmbedder;
15pub use host::{
16 EventListener, HostModel, HostTool, HostTransport, HttpSink, TokenSink, TraceListener,
17};
18pub use records::{
19 Event, EventKind, GraphResult, HostHeader, HostHttpRequest, HostMessage, HostModelCaps,
20 HostReply, HostRequest, Pause, Progress, RunResult, RuntimeSettings, Usage,
21};
22#[cfg(feature = "knowledge")]
23pub use records::{KnowledgeConfig, MemoryConfig};
24pub use stream::RunStream;
25
26#[uniffi::export]
30pub fn version() -> String {
31 troupekit_ffi_core::version()
32}
33
34#[uniffi::export(name = "initialize")]
38pub fn init(settings: RuntimeSettings) -> Result<(), TroupekitError> {
39 Ok(troupekit_ffi_core::init(settings.into())?)
40}