NaimaAqeel commited on
Commit
2364a93
·
verified ·
1 Parent(s): 087637b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -8
app.py CHANGED
@@ -43,7 +43,7 @@ if not api_token:
43
 
44
  # Initialize the HuggingFace LLM
45
  llm = HuggingFaceEndpoint(
46
- endpoint_url="https://api-inference.huggingface.co/models/gpt2",
47
  model_kwargs={"api_key": api_token}
48
  )
49
 
@@ -112,13 +112,6 @@ def upload_files(files):
112
  print(f"Error processing files: {e}")
113
  return f"Error processing files: {e}"
114
 
115
- # Consolidated and simplified context for transfer learning
116
- transfer_learning_context = """
117
- Transfer learning means using what we've learned from one thing to help us do another thing.
118
- For example, learning to play the piano can help you learn to play the guitar, because both involve understanding musical concepts.
119
- Similarly, understanding mathematics can help you learn physics, because both involve analytical skills.
120
- """
121
-
122
  # Single prompt for multiple questions
123
  prompt_template = """
124
  Answer the question based on the provided context.
@@ -204,6 +197,7 @@ demo.launch()
204
 
205
 
206
 
 
207
 
208
 
209
 
 
43
 
44
  # Initialize the HuggingFace LLM
45
  llm = HuggingFaceEndpoint(
46
+ endpoint_url="https://api-inference.huggingface.co/models/gpt-3.5-turbo", # Use a more advanced model
47
  model_kwargs={"api_key": api_token}
48
  )
49
 
 
112
  print(f"Error processing files: {e}")
113
  return f"Error processing files: {e}"
114
 
 
 
 
 
 
 
 
115
  # Single prompt for multiple questions
116
  prompt_template = """
117
  Answer the question based on the provided context.
 
197
 
198
 
199
 
200
+
201
 
202
 
203