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
//! Function definitions, profiles, and execution types.
//!
//! Functions are composable scoring pipelines that transform structured input
//! into scores. They are the primary interface for most ObjectiveAI users.
//!
//! # Overview
//!
//! A Function consists of:
//! - **Input schema** - Defines expected input structure
//! - **Input maps** - Optional expressions to transform input into arrays for mapped tasks
//! - **Tasks** - A list of operations (Vector Completions or nested Functions)
//! - **Output** - Expression that combines task results into final score(s)
//!
//! # Function Types
//!
//! - [`RemoteFunction`] - GitHub-hosted function with description and schema
//! - [`InlineFunction`] - Inline function definition without metadata
//! - **Scalar** - Produces a single score in [0, 1]
//! - **Vector** - Produces a vector of scores that sums to 1
//!
//! # Task Types
//!
//! - [`ScalarFunctionTask`] - Calls a scalar function
//! - [`VectorFunctionTask`] - Calls a vector function
//! - [`VectorCompletionTask`] - Runs a vector completion
//!
//! # Client-Side Compilation
//!
//! Functions use JMESPath expressions for dynamic behavior. The SDK can compile
//! these expressions client-side to preview results during Function authoring:
//!
//! - [`Function::compile_tasks`] - Resolves task expressions to show final tasks for a given input
//! - [`Function::compile_output`] - Computes the final output given input and task outputs
//!
//! # Submodules
//!
//! - [`executions`] - Function execution request/response types
//! - [`expression`] - JMESPath expression evaluation engine
//! - [`profiles`] - Profile management and computation
pub use *;
pub use *;
pub use *;
pub use *;