Krzysztof Krystian Jankowski commited on
Commit
c09f0b6
·
1 Parent(s): ca8913d
Files changed (2) hide show
  1. app.py +2 -3
  2. requirements.txt +1 -0
app.py CHANGED
@@ -4,10 +4,9 @@ from langchain_community.llms import CTransformers
4
  from transformers import AutoModel
5
 
6
  # load the model
7
-
8
- TinyLlamaModel = AutoModel.from_pretrained("NousResearch/Llama-2-7b-hf")
9
  def getLlamaResponse(input_text, no_words, blog_style):
10
- llm=CTransformers(model=TinyLlamaModel,
11
  model_type='llama',
12
  config={'max_new_tokens':256, 'temperature':0.2})
13
 
 
4
  from transformers import AutoModel
5
 
6
  # load the model
7
+ PretrainedModel = AutoModel.from_pretrained("TinyLlama/TinyLlama-1.1B-Chat-v1.0")
 
8
  def getLlamaResponse(input_text, no_words, blog_style):
9
+ llm=CTransformers(model=PretrainedModel,
10
  model_type='llama',
11
  config={'max_new_tokens':256, 'temperature':0.2})
12
 
requirements.txt CHANGED
@@ -1,5 +1,6 @@
1
  sentence-transformers
2
  uvicorn
 
3
  ctransformers
4
  langchain
5
  langchain-community
 
1
  sentence-transformers
2
  uvicorn
3
+ transformers
4
  ctransformers
5
  langchain
6
  langchain-community