Skip to content

Disable caching for long strings.#1676

Merged
Narsil merged 1 commit intomainfrom
disable_caching_longstrings
Nov 7, 2024
Merged

Disable caching for long strings.#1676
Narsil merged 1 commit intomainfrom
disable_caching_longstrings

Conversation

@Narsil
Copy link
Copy Markdown
Contributor

@Narsil Narsil commented Nov 6, 2024

Fixes: #1539

@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Copy link
Copy Markdown
Collaborator

@ArthurZucker ArthurZucker left a comment

Choose a reason for hiding this comment

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

Sounds good, might be "breaking" a tad bit for performances (maybe huge system prompt case no?)

@Narsil
Copy link
Copy Markdown
Contributor Author

Narsil commented Nov 7, 2024

I don't think so, huge prompts are still usually followed by some kind of prompt. So caching never works unless it's exactly the same prompt.

I think the downside should be minimal, and it's not visibly breaking to users anyway.

@Narsil Narsil merged commit 5aa9f6c into main Nov 7, 2024
@Narsil Narsil deleted the disable_caching_longstrings branch November 7, 2024 13:36
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.

Memory leak for large strings

3 participants