mirror of
https://gitea.toothfairyai.com/ToothFairyAI/tf_code.git
synced 2026-04-02 23:23:45 +00:00
real life totally configurabl ai subasians
This commit is contained in:
@@ -25,8 +25,8 @@ export namespace Tool {
|
||||
}
|
||||
|
||||
export function define<Parameters extends StandardSchemaV1, Result extends Metadata>(
|
||||
input: Info<Parameters, Result>,
|
||||
): Info<Parameters, Result> {
|
||||
return input
|
||||
input: Info<Parameters, Result> | (() => Promise<Info<Parameters, Result>>),
|
||||
): () => Promise<Info<Parameters, Result>> {
|
||||
return input instanceof Function ? input : async () => input
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user