Replies: 1 comment 1 reply
-
turns out there is small bug in autoeval that does not pass through azure option. created PR for it. meanwhile i am having hard time creating ts helper function to wrap autoeval scorer to make it work the evalite. could you please help? scorers: [
(options) =>
Factuality({
...options,
azureOpenAi: {
apiKey: process.env.AZURE_API_KEY!,
endpoint: `https://${process.env.AZURE_RESOURCE_NAME}.openai.azure.com/`,
apiVersion: process.env.AZURE_API_VERSION!,
},
model: 'gpt-4o-mini',
}),
Levenshtein,
containsParis,
], helper function: const azureScorer = <Output, Extra>(
autoevalScorer: ScorerWithPartial<Output, Extra>
) => {
return createScorer<string>({
name: autoevalScorer.name,
scorer: async (options) => {
return autoevalScorer({
...options,
azureOpenAi: {
apiKey: process.env.AZURE_API_KEY!,
endpoint: `https://${process.env.AZURE_RESOURCE_NAME}.openai.azure.com/`,
apiVersion: process.env.AZURE_API_VERSION!,
},
model: 'gpt-4o-mini',
});
},
});
}; having issue making it do perfect types usage example:
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
hey @mattpocock . very great library. how to please explain or maybe add docs on how to use autoeval with custom provider. for example azure. especially theirs llm scorers. thanks!
Beta Was this translation helpful? Give feedback.
All reactions