Spaces:
Running
Running
Update modules/models/ChuanhuAgent.py
Browse files
modules/models/ChuanhuAgent.py
CHANGED
@@ -57,7 +57,7 @@ class ChuanhuAgent_Client(BaseLLMModel):
|
|
57 |
self.text_splitter = TokenTextSplitter(chunk_size=500, chunk_overlap=30)
|
58 |
self.api_key = openai_api_key
|
59 |
self.llm = ChatOpenAI(openai_api_key=openai_api_key, temperature=0, model_name=default_chuanhu_assistant_model, openai_api_base=os.environ.get("OPENAI_API_BASE", None))
|
60 |
-
self.cheap_llm = ChatOpenAI(openai_api_key=openai_api_key, temperature=0, model_name="gpt-
|
61 |
PROMPT = PromptTemplate(template=SUMMARIZE_PROMPT, input_variables=["text"])
|
62 |
self.summarize_chain = load_summarize_chain(self.cheap_llm, chain_type="map_reduce", return_intermediate_steps=True, map_prompt=PROMPT, combine_prompt=PROMPT)
|
63 |
self.index_summary = None
|
|
|
57 |
self.text_splitter = TokenTextSplitter(chunk_size=500, chunk_overlap=30)
|
58 |
self.api_key = openai_api_key
|
59 |
self.llm = ChatOpenAI(openai_api_key=openai_api_key, temperature=0, model_name=default_chuanhu_assistant_model, openai_api_base=os.environ.get("OPENAI_API_BASE", None))
|
60 |
+
self.cheap_llm = ChatOpenAI(openai_api_key=openai_api_key, temperature=0, model_name="gpt-4o", openai_api_base=os.environ.get("OPENAI_API_BASE", None))
|
61 |
PROMPT = PromptTemplate(template=SUMMARIZE_PROMPT, input_variables=["text"])
|
62 |
self.summarize_chain = load_summarize_chain(self.cheap_llm, chain_type="map_reduce", return_intermediate_steps=True, map_prompt=PROMPT, combine_prompt=PROMPT)
|
63 |
self.index_summary = None
|