Skip to content
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

option to track avg logit per token type #6

Merged
merged 5 commits into from
Oct 30, 2023
Merged

option to track avg logit per token type #6

merged 5 commits into from
Oct 30, 2023

Conversation

IanMagnusson
Copy link
Contributor

This PR is ported from the old LLM repo at allenai/OLMo#334.

This PR makes use of new features in Catwalk's perplexity evaluations in allenai/catwalk#155 that report avg logits for tokens. It makes WriteOutputsAsRowsMultipleMetrics and PredictAndCalculateMetricsStep capable of surfacing these "token_count_avg_logits_by_domain" results within the new "extra_output" field.

To use this one must have the following task kwargs:

task_kwargs: {
    keep_all_instance_fields_except: ["text", "tokens"],
    detailed_output: true
}

You need to use keep_all_instance_fields_except because this depends on a lot of instance level information. And the detailed_output flag indicates that the aggregated results of this instance level data should be surfaced.

@IanMagnusson IanMagnusson marked this pull request as ready for review October 26, 2023 00:49
@IanMagnusson IanMagnusson marked this pull request as draft October 27, 2023 20:41
@IanMagnusson IanMagnusson marked this pull request as ready for review October 27, 2023 22:51
@IanMagnusson IanMagnusson merged commit e324a88 into main Oct 30, 2023
9 checks passed
@IanMagnusson IanMagnusson deleted the token-ppls branch October 30, 2023 18:44
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

Successfully merging this pull request may close these issues.

2 participants