Update app.py
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ from langchain.text_splitter import RecursiveCharacterTextSplitter
|
|
6 |
from langchain import OpenAI, VectorDBQA
|
7 |
|
8 |
import os
|
9 |
-
os.environ["OPENAI_API_KEY"]
|
10 |
|
11 |
|
12 |
def pdf_to_text(pdf_file, query):
|
@@ -47,4 +47,4 @@ outputs = gr.outputs.Textbox(label="Chatbot Response")
|
|
47 |
interface = gr.Interface(fn=pdf_to_text, inputs=[pdf_input, query_input], outputs=outputs)
|
48 |
|
49 |
# Run the interface
|
50 |
-
interface.launch()
|
|
|
6 |
from langchain import OpenAI, VectorDBQA
|
7 |
|
8 |
import os
|
9 |
+
openai_api_key = os.environ["OPENAI_API_KEY"]
|
10 |
|
11 |
|
12 |
def pdf_to_text(pdf_file, query):
|
|
|
47 |
interface = gr.Interface(fn=pdf_to_text, inputs=[pdf_input, query_input], outputs=outputs)
|
48 |
|
49 |
# Run the interface
|
50 |
+
interface.launch(debug = True)
|