Merge pull request #2554 from Erland366/fix/generation_config
Quick fix on the CompileConfig error
This commit is contained in:
commit
0d73478808
1 changed files with 3 additions and 1 deletions
|
|
@ -200,12 +200,14 @@ def unsloth_base_fast_generate(
|
|||
cache_implementation = "static"
|
||||
else:
|
||||
cache_implementation = "hybrid"
|
||||
|
||||
if "generation_config" in kwargs:
|
||||
kwargs["generation_config"].cache_implementation = cache_implementation
|
||||
kwargs["generation_config"].compile_config = _compile_config if cache_implementation is not None else None
|
||||
else:
|
||||
kwargs["cache_implementation"] = cache_implementation
|
||||
kwargs["compile_config"] = _compile_config if cache_implementation is not None else None
|
||||
if cache_implementation:
|
||||
kwargs["compile_config"] = _compile_config
|
||||
pass
|
||||
|
||||
try:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue