diff --git a/pkgs/sdk/server-ai/src/Interfaces/ILdAiConfigTracker.cs b/pkgs/sdk/server-ai/src/Interfaces/ILdAiConfigTracker.cs index 937afe8e..dce8dd9f 100644 --- a/pkgs/sdk/server-ai/src/Interfaces/ILdAiConfigTracker.cs +++ b/pkgs/sdk/server-ai/src/Interfaces/ILdAiConfigTracker.cs @@ -27,6 +27,10 @@ public interface ILdAiConfigTracker /// /// Tracks the duration of a task, and returns the result of the task. /// + /// If the provided task throws, then this method will also throw. + /// + /// In the case the provided function throws, this function will still + /// record the duration. /// /// the task /// type of the task's result @@ -54,6 +58,16 @@ public interface ILdAiConfigTracker /// Tracks a request to a provider. The request is a task that returns a , which /// contains information about the request such as token usage and metrics. /// + /// This function will track the duration of the operation, the token + /// usage, and the success or error status. + /// + /// If the provided function throws, then this method will also throw. + /// + /// In the case the provided function throws, this function will record the + /// duration and an error. + /// + /// A failed operation will not have any token usage data. + /// /// It is the responsibility of the caller to fill in the object with any details /// that should be tracked. ///