ashutoshzade commited on
Commit
c4888e0
·
verified ·
1 Parent(s): 6f56999

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -28,7 +28,8 @@ text_generation_pipeline = pipeline(
28
  llm = HuggingFacePipeline(pipeline=text_generation_pipeline)
29
 
30
  # Load and process documents
31
- loader = TextLoader("https://en.wikipedia.org/wiki/Cheetah")
 
32
  documents = loader.load()
33
  text_splitter = CharacterTextSplitter(chunk_size=1000, chunk_overlap=0)
34
  texts = text_splitter.split_documents(documents)
@@ -60,7 +61,8 @@ qa_chain = RetrievalQA.from_chain_type(
60
  )
61
 
62
  # Example query
63
- query = "How fast cheetah can run?"
 
64
  result = qa_chain({"query": query})
65
 
66
  print("Question:", query)
 
28
  llm = HuggingFacePipeline(pipeline=text_generation_pipeline)
29
 
30
  # Load and process documents
31
+ #loader = TextLoader("https://en.wikipedia.org/wiki/Cheetah")
32
+ loader = TextLoader("https://en.wikipedia.org/wiki/Artificial_neuron")
33
  documents = loader.load()
34
  text_splitter = CharacterTextSplitter(chunk_size=1000, chunk_overlap=0)
35
  texts = text_splitter.split_documents(documents)
 
61
  )
62
 
63
  # Example query
64
+ #query = "How fast cheetah can run?"
65
+ query = "What is an artifical neuron?"
66
  result = qa_chain({"query": query})
67
 
68
  print("Question:", query)