|
@@ -41,10 +41,12 @@ class LocalDocQA:
|
|
|
llm_model: str = LLM_MODEL,
|
|
|
llm_device=LLM_DEVICE,
|
|
|
top_k=VECTOR_SEARCH_TOP_K,
|
|
|
+ use_ptuning_v2: bool = USE_PTUNING_V2
|
|
|
):
|
|
|
self.llm = ChatGLM()
|
|
|
self.llm.load_model(model_name_or_path=llm_model_dict[llm_model],
|
|
|
- llm_device=llm_device)
|
|
|
+ llm_device=llm_device,
|
|
|
+ use_ptuning_v2=use_ptuning_v2)
|
|
|
self.llm.history_len = llm_history_len
|
|
|
|
|
|
self.embeddings = HuggingFaceEmbeddings(model_name=embedding_model_dict[embedding_model], )
|