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

Add an option to reduce LLM features in LLLaplace #172

Merged
merged 7 commits into from
Jun 11, 2024
Merged

Conversation

wiseodd
Copy link
Collaborator

@wiseodd wiseodd commented Apr 25, 2024

Closes #169

Wait for #144 to be merged.

I noticed that for Huggingface LLMs, the feature reduction is not automatically detected by FeatureExtractor's hooks, unlike standard convnets. This is because HF actually reduces the logits themselves and not the features 😭

In any case, this feature is useful as a "catch-all", making LLLA more general.

@wiseodd wiseodd added the enhancement New feature or request label Apr 25, 2024
@wiseodd wiseodd added this to the 0.2 milestone Apr 25, 2024
@wiseodd wiseodd self-assigned this Apr 25, 2024
@wiseodd wiseodd changed the base branch from main to mc-subset2 April 27, 2024 17:26
Base automatically changed from mc-subset2 to main April 27, 2024 18:53
Copy link
Collaborator

@runame runame left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

tests/test_lllaplace.py Show resolved Hide resolved
laplace/utils/feature_extractor.py Outdated Show resolved Hide resolved
laplace/utils/feature_extractor.py Show resolved Hide resolved
@wiseodd wiseodd merged commit 83c5de7 into main Jun 11, 2024
@wiseodd wiseodd deleted the llla-feat-reduction branch June 11, 2024 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Handle feature reduction properly in LLLA
2 participants