Skip to content

Conversation

kirklandsign
Copy link
Contributor

@kirklandsign kirklandsign commented Oct 20, 2025

Summary

pos_ should advance by prefill and generated prompt size.

Test plan

CI

cc @larryliu0820 @mergennachin @cccclai @helunwencser @jackzhxng

Copy link

pytorch-bot bot commented Oct 20, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/15286

Note: Links to docs will display an error until the docs builds have been completed.

❗ 1 Active SEVs

There are 1 currently active SEVs. If your PR is affected, please view them below:

❌ 1 New Failure, 2 Unrelated Failures

As of commit 12545a3 with merge base 58bd91c (image):

NEW FAILURE - The following job has failed:

BROKEN TRUNK - The following jobs failed but were present on the merge base:

👉 Rebase onto the `viable/strict` branch to avoid these failures

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@kirklandsign kirklandsign marked this pull request as ready for review October 20, 2025 23:35
@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Oct 20, 2025
@kirklandsign kirklandsign changed the title Fix text_llm_runner kv cache pos count Fix text_llm_runner kv cache pos count and use it for generate() Oct 21, 2025
}
int64_t num_generated_tokens = generate_result.get();

pos_ += num_generated_tokens;
Copy link
Contributor

Choose a reason for hiding this comment

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

you don't need this anymore right? pos_ is being updated.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@kirklandsign kirklandsign added module: llm Issues related to LLM examples and apps, and to the extensions/llm/ code release notes: llm Changes to llm utilities labels Oct 21, 2025
@kirklandsign kirklandsign merged commit 8946d80 into main Oct 21, 2025
235 of 242 checks passed
@kirklandsign kirklandsign deleted the text-llm-pos branch October 21, 2025 05:09
@kirklandsign
Copy link
Contributor Author

@pytorchbot cherry-pick --onto release/1.0 -c critical

pytorchbot pushed a commit that referenced this pull request Oct 21, 2025
)

pos_ should advance by prefill and generated prompt size.

(cherry picked from commit 8946d80)
@pytorchbot
Copy link
Collaborator

Cherry picking #15286

The cherry pick PR is at #15295 and it is recommended to link a critical cherry pick PR with an issue. The following tracker issues are updated:

Details for Dev Infra team Raised by workflow job

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. module: llm Issues related to LLM examples and apps, and to the extensions/llm/ code release notes: llm Changes to llm utilities

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants