lgfunderburk commited on
Commit
d07a63b
1 Parent(s): adb9421
Files changed (2) hide show
  1. app.py +3 -2
  2. pyproject.toml +3 -2
app.py CHANGED
@@ -1,3 +1,6 @@
 
 
 
1
  # Imports and Initializations for Chainlit
2
  import chainlit as cl
3
  from dotenv import load_dotenv
@@ -9,8 +12,6 @@ from haystack.nodes import BM25Retriever, PromptTemplate, AnswerParser, PromptNo
9
  import os
10
  from haystack.pipelines import Pipeline
11
 
12
- os.environ["CUDA_VISIBLE_DEVICES"] = "-1"
13
-
14
  # Load environment variables (if any)
15
  load_dotenv(".env")
16
  load_dotenv()
 
1
+ import torch
2
+ torch.device('cpu')
3
+
4
  # Imports and Initializations for Chainlit
5
  import chainlit as cl
6
  from dotenv import load_dotenv
 
12
  import os
13
  from haystack.pipelines import Pipeline
14
 
 
 
15
  # Load environment variables (if any)
16
  load_dotenv(".env")
17
  load_dotenv()
pyproject.toml CHANGED
@@ -7,8 +7,9 @@ license = "Apache 2.0"
7
  readme = "README.md"
8
 
9
  [tool.poetry.dependencies]
10
- python = "^3.9"
11
- farm-haystack = "^1.20.1"
 
12
  chainlit = "^0.7.0"
13
  openai = "^0.28.0"
14
  jupyter = "^1.0.0"
 
7
  readme = "README.md"
8
 
9
  [tool.poetry.dependencies]
10
+ python = "^3.10"
11
+ torch = "1.11.0+cpu"
12
+ farm-haystack = {extras = ["inference"], version = "^1.20.1"}
13
  chainlit = "^0.7.0"
14
  openai = "^0.28.0"
15
  jupyter = "^1.0.0"