-
Notifications
You must be signed in to change notification settings - Fork 321
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/master'
- Loading branch information
Showing
11 changed files
with
213 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Data Science Assistant with Streamlit ⭐ | ||
Data Science Assistant (hereinafter referred to as DS Assistant) is a Data Science Assistant developed based on the modelscope-agent framework, which can automatically perform exploratory Data analysis (EDA) in Data Science tasks according to user needs, Data preprocessing, feature engineering, model training, model evaluation and other steps are fully automated. | ||
|
||
Detailed information can be found in the [documentation](../../docs/source/agents/data_science_assistant.md). | ||
|
||
## Quick Start | ||
Streamlit is a Python library that makes it easy to create and share beautiful, custom web apps for machine learning and data science. | ||
|
||
To run the DS Assistant in streamlit, you need to install the Streamlit library. You can install it using pip: | ||
```bash | ||
pip install streamlit streamlit-jupyter | ||
``` | ||
Then, you need to set | ||
Then, you can run the DS Assistant using the following command: | ||
```bash | ||
streamlit run app.py | ||
``` | ||
|
||
After running the command, a new tab will open in your default web browser with the DS Assistant running. | ||
The following are screenshots of the DS Assistant running in the browser: | ||
|
||
![img_2.png](../../resources/data_science_assistant_streamlit_1.png) | ||
you can view all of the codes and in streamlit | ||
![img_3.png](../../resources/data_science_assistant_streamlit_2.png) | ||
After you have finished using the DS Assistant, you can directly convert the running process to a pdf | ||
![img_5.png](../../resources/data_science_assistant_streamlit_3.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import os | ||
|
||
import streamlit as st | ||
from modelscope_agent.agents.data_science_assistant import DataScienceAssistant | ||
from modelscope_agent.tools.metagpt_tools.tool_recommend import \ | ||
TypeMatchToolRecommender | ||
|
||
llm_config = { | ||
'model': 'qwen2-72b-instruct', | ||
'model_server': 'dashscope', | ||
} | ||
os.environ['DASHSCOPE_API_KEY'] = input( | ||
'Please input your dashscope api key: ') | ||
data_science_assistant = DataScienceAssistant( | ||
llm=llm_config, tool_recommender=TypeMatchToolRecommender(tools=['<all>'])) | ||
st.title('Data Science Assistant') | ||
st.write( | ||
'This is a data science assistant that can help you with your data science tasks.' | ||
) | ||
st.write('Please input your request below and click the submit button.') | ||
user_request = st.text_input('User Request') | ||
if st.button('submit'): | ||
data_science_assistant.run(user_request=user_request, streamlit=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.