update01
Browse files
app.py
CHANGED
@@ -4,11 +4,11 @@ from typing import List
|
|
4 |
|
5 |
os.system('git lfs install')
|
6 |
os.system("pip install git+https://hf-mirror.com/Pluto0616/L2_Agent")
|
7 |
-
|
8 |
-
|
9 |
|
10 |
import streamlit as st
|
11 |
-
from lagent.actions import ArxivSearch
|
12 |
from lagent.prompts.parsers import PluginParser
|
13 |
from lagent.agents.stream import INTERPRETER_CN, META_CN, PLUGIN_CN, AgentForInternLM, get_plugin_prompt
|
14 |
from lagent.llms import GPTAPI
|
@@ -24,6 +24,7 @@ class SessionState:
|
|
24 |
# 初始化插件列表
|
25 |
action_list = [
|
26 |
ArxivSearch(),
|
|
|
27 |
]
|
28 |
st.session_state['plugin_map'] = {action.name: action for action in action_list}
|
29 |
st.session_state['model_map'] = {} # 存储模型实例
|
|
|
4 |
|
5 |
os.system('git lfs install')
|
6 |
os.system("pip install git+https://hf-mirror.com/Pluto0616/L2_Agent")
|
7 |
+
token='eyJ0eXBlIjoiSldUIiwiYWxnIjoiSFM1MTIifQ.eyJqdGkiOiIxNzAwOTgxMCIsInJvbCI6IlJPTEVfUkVHSVNURVIiLCJpc3MiOiJPcGVuWExhYiIsImlhdCI6MTczNDA5NTY3MCwiY2xpZW50SWQiOiJlYm1ydm9kNnlvMG5semFlazF5cCIsInBob25lIjoiMTM0NzI1MzIxMjgiLCJ1dWlkIjoiMDJhNGI1YTMtZGU0ZC00ZDcyLTkyNTYtZDhlZDNlOTdkYTg4IiwiZW1haWwiOiIiLCJleHAiOjE3NDk2NDc2NzB9.lB_domUqhSz-jD0O1VhrwMco5zEPpn13gHhk092-fmRNy04bq0HMd1jxid_FXzmgmS7Tsmh1hVEHvCZAoxx9JQ'
|
8 |
+
weather_token='eb6a6ad711f14601b344cd2a58c55079'
|
9 |
|
10 |
import streamlit as st
|
11 |
+
from lagent.actions import ArxivSearch, WeatherQuery
|
12 |
from lagent.prompts.parsers import PluginParser
|
13 |
from lagent.agents.stream import INTERPRETER_CN, META_CN, PLUGIN_CN, AgentForInternLM, get_plugin_prompt
|
14 |
from lagent.llms import GPTAPI
|
|
|
24 |
# 初始化插件列表
|
25 |
action_list = [
|
26 |
ArxivSearch(),
|
27 |
+
WeatherQuery(),
|
28 |
]
|
29 |
st.session_state['plugin_map'] = {action.name: action for action in action_list}
|
30 |
st.session_state['model_map'] = {} # 存储模型实例
|