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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
//! Ferrin core.
//!
//! Text generation loop, streaming pipeline, structured output, agents,
//! middleware, provider registry, retry and timeout policies, and the other
//! modalities (embeddings, images, speech, transcription, reranking, video).
//!
//! Design: `docs/01-architecture/07-generation-loop-and-streaming.md` and following.
//!
//! # Attribution
//!
//! Portions of this crate are derived from the Vercel AI SDK (Apache-2.0,
//! Copyright 2023 Vercel, Inc.), translated from TypeScript to Rust and
//! modified. See the `NOTICE` file in the crate root.
pub
pub
pub
pub use Agent;
pub use AgentCall;
pub use ToolLoopAgent;
pub use cancel_batch;
pub use get_batch_results;
pub use get_batch_status;
pub use list_batches;
pub use start_batch;
pub use Clock;
pub use cosine_similarity;
pub use embed;
pub use embed_many;
pub use Error;
pub use ErrorKind;
pub use upload_file;
pub use GenerateText;
pub use GenerateTextResult;
pub use StepContent;
pub use StepResult;
pub use generate_text;
pub use has_tool_call;
pub use step_count;
pub use HookFn;
pub use Hooks;
pub use generate_image;
pub use LanguageModelMiddleware;
pub use wrap_language_model;
pub use Output;
pub use CallSettings;
pub use Instructions;
pub use RealtimeSession;
pub use realtime_session;
pub use ProviderRegistry;
pub use create_provider_registry;
pub use custom_provider;
pub use rerank;
pub use RetryPolicy;
pub use upload_skill;
pub use generate_speech;
pub use stream_speech_translation;
pub use StreamEvent;
pub use StreamText;
pub use StreamTextResult;
pub use stream_text;
pub use Telemetry;
pub use TelemetryOptions;
pub use Timeout;
pub use stream_transcribe;
pub use transcribe;
pub use generate_video;
/// User-agent suffix appended to every model request.
pub const USER_AGENT: &str = concat!;