Spaces:
Sleeping
Sleeping
Commit
•
ac07e9d
1
Parent(s):
e3ca06d
Update app.py
Browse files
app.py
CHANGED
@@ -8,11 +8,12 @@ import requests
|
|
8 |
key = os.getenv("baixing_key")
|
9 |
|
10 |
# 如果你只打算通过 prompt 来定制机器人的行为,只需要修改这段 prompt 就够了。
|
11 |
-
prompt = """
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
|
|
|
16 |
"""
|
17 |
|
18 |
url = "https://gpt.baixing.com/"
|
@@ -30,10 +31,6 @@ def chat(p, qid, uid):
|
|
30 |
iface = gr.Interface(fn=chat,
|
31 |
inputs=["text", "text", "text"],
|
32 |
outputs=["text", "text"],
|
33 |
-
description="""
|
34 |
-
注意:duplicate 本项目后,需要将你自己的 baixingai 的 apikey 设置到 settings 的 Repository Secrets 里,否则运行会报错。[了解详情](https://huggingface.co/spaces/baixing/hackathon_chatbot_openai_api/blob/main/%E6%B7%BB%E5%8A%A0%20secret%20%E7%9A%84%E6%96%B9%E6%B3%95.jpg)
|
35 |
-
|
36 |
-
[对话测试](https://huggingface.co/spaces/BaixingAI/hackathon_test) [参考文档](https://huggingface.co/spaces/baixing/hackathon_test/blob/main/bot-api.md) [Q & A](https://huggingface.co/spaces/baixing/hackathon_test/blob/main/qna.md)
|
37 |
-
"""
|
38 |
)
|
39 |
iface.launch()
|
|
|
8 |
key = os.getenv("baixing_key")
|
9 |
|
10 |
# 如果你只打算通过 prompt 来定制机器人的行为,只需要修改这段 prompt 就够了。
|
11 |
+
prompt = """接下来无论我问什么问题,您都将对问题进行任务拆解。
|
12 |
+
1、您会告诉我所问问题的任务拆解思路,任务拆解思路需简洁清晰。
|
13 |
+
2、基于拆解思路,给出每项拆解思路的详细解释。
|
14 |
+
3、对拆解思路,进行关注点分离,将分离后的关注点之间的关系明确出来,以概念图的方式展示,概念图不要是图片。
|
15 |
|
16 |
+
我的问题是:
|
17 |
"""
|
18 |
|
19 |
url = "https://gpt.baixing.com/"
|
|
|
31 |
iface = gr.Interface(fn=chat,
|
32 |
inputs=["text", "text", "text"],
|
33 |
outputs=["text", "text"],
|
34 |
+
description="""古时候的庖丁解牛,今天的庖丁解问题。把你的问题给庖丁,它来帮你分解,降低解决问题的复杂度"""
|
|
|
|
|
|
|
|
|
35 |
)
|
36 |
iface.launch()
|