Update main.py
Browse files
main.py
CHANGED
|
@@ -15,7 +15,7 @@ generation_config = genai.types.GenerateContentConfig(max_output_tokens=3000, te
|
|
| 15 |
|
| 16 |
# Retrieve the PDF
|
| 17 |
files = glob.glob('docs/*.pdf')
|
| 18 |
-
files_content = [client.files.upload(filepath) for filepath in files]
|
| 19 |
|
| 20 |
# 設定 Line Bot 的 API 金鑰和秘密金鑰
|
| 21 |
line_bot_api = LineBotApi(os.environ["CHANNEL_ACCESS_TOKEN"])
|
|
|
|
| 15 |
|
| 16 |
# Retrieve the PDF
|
| 17 |
files = glob.glob('docs/*.pdf')
|
| 18 |
+
files_content = [client.files.upload(file=filepath) for filepath in files]
|
| 19 |
|
| 20 |
# 設定 Line Bot 的 API 金鑰和秘密金鑰
|
| 21 |
line_bot_api = LineBotApi(os.environ["CHANNEL_ACCESS_TOKEN"])
|