Co-authored-by: jamesgeorge007 <25279263+jamesgeorge007@users.noreply.github.com> Co-authored-by: amk-dev <akash.k.mohan98@gmail.com>
47 lines
1 KiB
TypeScript
47 lines
1 KiB
TypeScript
import * as E from "fp-ts/Either"
|
|
|
|
export type ExperimentsPlatformDef = {
|
|
aiExperiments?: {
|
|
enableAIExperiments: boolean
|
|
generateRequestName?: (
|
|
requestInfo: string,
|
|
namingStyle: string
|
|
) => Promise<
|
|
E.Either<
|
|
string,
|
|
{
|
|
request_name: string
|
|
trace_id: string
|
|
}
|
|
>
|
|
>
|
|
modifyRequestBody?: (
|
|
requestBody: string,
|
|
userPrompt: string
|
|
) => Promise<
|
|
E.Either<
|
|
string,
|
|
{
|
|
modified_body: string
|
|
trace_id: string
|
|
}
|
|
>
|
|
>
|
|
submitFeedback?: (
|
|
rating: -1 | 1,
|
|
traceID: string
|
|
) => Promise<E.Either<string, void>>
|
|
modifyPreRequestScript?: (
|
|
requestInfo: string,
|
|
userPrompt: string
|
|
) => Promise<
|
|
E.Either<string, { modified_script: string; trace_id: string }>
|
|
>
|
|
modifyTestScript?: (
|
|
requestInfo: string,
|
|
userPrompt: string
|
|
) => Promise<
|
|
E.Either<string, { modified_script: string; trace_id: string }>
|
|
>
|
|
}
|
|
}
|