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

added mlp and attn bias option to flash and paged llama models #85

Merged
merged 2 commits into from
May 6, 2024

Conversation

JRosenkranz
Copy link
Collaborator

Motivation

[Describe why this change is needed]

The Calico models currently set the mlp and attention bias to true, which was hard-coded to false in flash and paged llama implementations. This will use the config params set in huggingface/transformers#30031 to set those values properly.

Modifications

[Describe the code changes]

  • added attention_bias, mlp_bias to config for Flash and Paged Llama implementations (default is False)
  • set bias in attention and mlp to the config value

Result

[Describe how the changes affects existing behavior and how to test it]

Models should be able to load properly if containing attention and mlp bias

Related Issues

NA

Signed-off-by: Joshua Rosenkranz <jmrosenk@us.ibm.com>
@JRosenkranz JRosenkranz self-assigned this May 6, 2024
Signed-off-by: Joe Runde <Joseph.Runde@ibm.com>
Copy link
Member

@njhill njhill left a comment

Choose a reason for hiding this comment

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

@njhill njhill merged commit deb99f6 into main May 6, 2024
7 checks passed
@njhill njhill deleted the attn_mlp_bias branch May 6, 2024 21:18
heyselbi referenced this pull request in heyselbi/text-generation-inference May 7, 2024
…atahub-io#85)

#### Motivation

The `Calico` models currently set the mlp and attention bias to true,
which was hard-coded to false in flash and paged llama implementations.
This will use the config params set in
huggingface/transformers#30031 to set those
values properly.

#### Modifications

- added attention_bias, mlp_bias to config for Flash and Paged Llama
implementations (default is False)
- set bias in attention and mlp to the config value

#### Result

Models should be able to load properly if containing attention and mlp
bias

---------

Signed-off-by: Joshua Rosenkranz <jmrosenk@us.ibm.com>
Signed-off-by: Joe Runde <Joseph.Runde@ibm.com>
Co-authored-by: Joe Runde <Joseph.Runde@ibm.com>
openshift-merge-bot bot referenced this pull request in red-hat-data-services/text-generation-inference May 7, 2024
added mlp and attn bias option to flash and paged llama models (opendatahub-io#85)
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.

None yet

3 participants