[BUG] 简洁阐述[BUG] 当使用LLaMA-Factory 使用.bin格式训练合并之后的模型,然后使用langchain-chatchat,加载训练的模型出现TypeError: PeftConfig.__init__() got an unexpected keyword argument '_name_or_path'问题 / Concise description of the issue
[BUG] 简洁阐述[BUG] 当使用LLaMA-Factory 使用.bin格式训练合并之后的模型,然后使用langchain-chatchat,加载训练的模型出现TypeError: PeftConfig.init() got an unexpected keyword argument '_name_or_path'问题 / Concise description of the issue
To address the TypeError: PeftConfig.__init__() got an unexpected keyword argument '_name_or_path' error when loading a model with langchain-chatchat, follow these steps:
-
Verify Library Versions: Ensure the library version for loading the model matches the model's requirements. Incompatibilities often lead to such errors.
-
Inspect Model Loading Code: Check the code for loading the model to ensure the arguments passed match the expected parameters of
PeftConfig. -
Consult Documentation: Review the documentation for the model loading library to understand the correct way to load models and the expected arguments.
-
Update or Adjust Library Code: If using a custom or outdated library, update to the latest version or adjust the code to meet the model's loading requirements.
-
Community Support: If unresolved, seek advice from community forums or channels related to langchain-chatchat or the model loading library for specific guidance.
Sources
- lora训练合并后的模型无法像上个版本一样使用
- knowledge_base/samples/content/test_files/langchain-ChatGLM_open.jsonl
- configs/model_config.py.example
- configs/init.py
- requirements.txt
About Dosu
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.
Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.
If you want to continue the conversation, start your reply with @dosu-bot.
不能直接把config.json文件名字改成adapter_config.json