Skip to content

UNIPELT, UNIPELT (AP) and UNIPELT (APL) #696

Answered by calpt
keyuchen21 asked this question in Q&A
Discussion options

You must be logged in to vote

Hey, the UniPELT AP and APL variants in the paper compose different types of adapters. Specifically:

UniPELT APL combines bottleneck adapters (A), prefix tuning (P) and LoRA (L). This is the default version in Adapters if you use UniPELTConfig():

config = UniPELTConfig()
model.add_adapter("unipelt_apl", config=config)

To make this clearer, we can define the same config via ConfigUnion():

config = ConfigUnion(
    PrefixTuningConfig(prefix_length=10, use_gating=True),
    SeqBnConfig(reduction_factor=16, use_gating=True),
    LoRAConfig(r=8, alpha=2, use_gating=True)
)
model.add_adapter("unipelt_apl", config=config)

This is identical to using UniPELTConfig()

UniPELT AP combines bottleneck …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@keyuchen21
Comment options

Answer selected by calpt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #683 on May 07, 2024 20:10.