Skip to content

Return partial results if task errors #123

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
tomhonour opened this issue Mar 14, 2025 · 1 comment
Open

Return partial results if task errors #123

tomhonour opened this issue Mar 14, 2025 · 1 comment

Comments

@tomhonour
Copy link

tomhonour commented Mar 14, 2025

Hi, thanks for evalite - it's fantastic!

I just ran a long eval and forgot to include error handling in the task. The task ran successfully for most of the inputs, but errored on some. This meant that no table was printed.

In relation to a solution, I think tasks that error should be excluded from the partial table as to not improperly lower the overall score.

You can test it like this:

evalite("My Eval", {
	data: async () => {
		return [
			{ input: "hello", expected: "hello, world" },
			{ input: "fail", expected: "hello, world" },
		];
	},
	task: async (input) => {
		if (input === "fail") {
			throw new Error();
		}
		return input + ", world";
	},
	scorers: [],
});
@mattpocock
Copy link
Owner

Gotcha, makes total sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants