Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -32,11 +32,13 @@ def run_workflow(message,language='en'):
|
|
32 |
loader = OnlinePDFLoader(text_message)
|
33 |
docs = loader.load()
|
34 |
raw_text = docs[0].page_content
|
35 |
-
|
36 |
# それ以外の場合
|
37 |
loader = WebBaseLoader(text_message)
|
38 |
docs = loader.load()
|
39 |
raw_text = docs[0].page_content
|
|
|
|
|
40 |
|
41 |
|
42 |
# APIリクエストのための入力データを準備
|
|
|
32 |
loader = OnlinePDFLoader(text_message)
|
33 |
docs = loader.load()
|
34 |
raw_text = docs[0].page_content
|
35 |
+
elif text_message.startswith("http") or text_message.startswith("https"):
|
36 |
# それ以外の場合
|
37 |
loader = WebBaseLoader(text_message)
|
38 |
docs = loader.load()
|
39 |
raw_text = docs[0].page_content
|
40 |
+
else:
|
41 |
+
raw_text = text_message
|
42 |
|
43 |
|
44 |
# APIリクエストのための入力データを準備
|