Spaces:
Paused
Paused
dtrejopizzo
commited on
Commit
·
03b394c
1
Parent(s):
6c83497
Update app.py
Browse files
app.py
CHANGED
@@ -9,14 +9,14 @@ import os
|
|
9 |
os.environ["OPENAI_API_KEY"]
|
10 |
|
11 |
def construct_index(directory_path):
|
12 |
-
max_input_size =
|
13 |
-
num_outputs =
|
14 |
max_chunk_overlap = 0.2
|
15 |
chunk_size_limit = 600
|
16 |
|
17 |
prompt_helper = PromptHelper(max_input_size, num_outputs, max_chunk_overlap, chunk_size_limit=chunk_size_limit)
|
18 |
|
19 |
-
llm_predictor = LLMPredictor(llm=ChatOpenAI(temperature=0.7, model_name="gpt-3.5-turbo
|
20 |
|
21 |
documents = SimpleDirectoryReader(directory_path).load_data()
|
22 |
|
|
|
9 |
os.environ["OPENAI_API_KEY"]
|
10 |
|
11 |
def construct_index(directory_path):
|
12 |
+
max_input_size = 4096
|
13 |
+
num_outputs = 512
|
14 |
max_chunk_overlap = 0.2
|
15 |
chunk_size_limit = 600
|
16 |
|
17 |
prompt_helper = PromptHelper(max_input_size, num_outputs, max_chunk_overlap, chunk_size_limit=chunk_size_limit)
|
18 |
|
19 |
+
llm_predictor = LLMPredictor(llm=ChatOpenAI(temperature=0.7, model_name="gpt-3.5-turbo", max_tokens=num_outputs))
|
20 |
|
21 |
documents = SimpleDirectoryReader(directory_path).load_data()
|
22 |
|