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 seq start position when applying RoPE encoding #1796

Merged
merged 1 commit into from
May 22, 2024

Conversation

laggui
Copy link
Member

@laggui laggui commented May 22, 2024

Pull Request Template

Checklist

  • Confirmed that run-checks all script has been executed.

Changes

Added apply(x, start) method to compute the rotary positional encoding with a start position, which is required for autoregressive LLMs (e.g., Llama) where the encoding is not always applied from the start of the sequence.

Copy link

codecov bot commented May 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.41%. Comparing base (8c01444) to head (aa42cef).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1796   +/-   ##
=======================================
  Coverage   86.41%   86.41%           
=======================================
  Files         737      737           
  Lines       86009    86016    +7     
=======================================
+ Hits        74326    74333    +7     
  Misses      11683    11683           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@nathanielsimard nathanielsimard merged commit b466fd7 into main May 22, 2024
15 checks passed
@nathanielsimard nathanielsimard deleted the fix/rope/start-pos branch May 22, 2024 17:18
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

2 participants