Skip to content

Commit

Permalink
[UI] Clarify dataset requirement (#140)
Browse files Browse the repository at this point in the history
Co-authored-by: YUAN TIAN <[email protected]>
  • Loading branch information
tianyuanzoe and YUAN TIAN authored Nov 15, 2024
1 parent 68b9bdd commit 497dac4
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 8 deletions.
6 changes: 5 additions & 1 deletion src/autogluon/assistant/ui/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,9 +123,13 @@
DATASET_OPTIONS = ["Sample Dataset", "Upload Dataset"]

# Captions under DataSet Options
CAPTIONS = ["Run with sample dataset", "Upload Train, Test and Output (Optional) Dataset"]
CAPTIONS = ["Run with sample dataset", "Upload Train (Required), Test (Required) and Output (Optional) Dataset"]

DEMO_URL = "https://automl-mm-bench.s3.amazonaws.com/autogluon-assistant/aga-kaggle-demo.mp4"

SAMPLE_DATASET_DESCRIPTION = """You are solving this data science tasks:The dataset presented here (knot theory) comprises a lot of numerical features. Some of the features may be missing, with nan value. Your task is to predict the 'signature', which has 18 unique integers. The evaluation metric is the classification accuracy."""
LOGO_PATH = "static/page_icon.png"
SUCCESS_MESSAGE = """
🎉🎉Task completed successfully! If you found this useful, please consider:
⭐ [Starring our repository](https://github.com/autogluon/autogluon-assistant)
"""
7 changes: 4 additions & 3 deletions src/autogluon/assistant/ui/log_processor.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import re

import streamlit as st
from constants import STAGE_COMPLETE_SIGNAL, STAGE_MESSAGES, STATUS_BAR_STAGE, TIME_LIMIT_MAPPING
from constants import STAGE_COMPLETE_SIGNAL, STAGE_MESSAGES, STATUS_BAR_STAGE, SUCCESS_MESSAGE, TIME_LIMIT_MAPPING


def parse_model_path(log):
Expand Down Expand Up @@ -50,7 +50,7 @@ def show_logs():
if st.session_state.logs:
status_container = st.empty()
if st.session_state.return_code == 0:
status_container.success("Task completed successfully!")
status_container.success(SUCCESS_MESSAGE)
else:
status_container.error("Error detected in the process...Check the logs for more details")
tab1, tab2 = st.tabs(["Messages", "Logs"])
Expand Down Expand Up @@ -149,9 +149,10 @@ def messages():
if model_path:
st.session_state.model_path = model_path
if "Prediction complete" in line:
status_container.success("Task completed successfully!")
status_container.success(SUCCESS_MESSAGE)
progress.progress(100)
process_realtime_logs(line)
st.toast("Task completed successfully! 🎉", icon="✅")
break
else:
for stage, progress_value in STATUS_BAR_STAGE.items():
Expand Down
2 changes: 1 addition & 1 deletion src/autogluon/assistant/ui/pages/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ def display_description():

@st.fragment
def show_output_download_button(data, file_name):
st.download_button(label="💾&nbsp;&nbsp;Download Output", data=data, file_name=file_name, mime="text/csv")
st.download_button(label="💾&nbsp;&nbsp;Download Predictions", data=data, file_name=file_name, mime="text/csv")


def show_cancel_task_button():
Expand Down
5 changes: 3 additions & 2 deletions src/autogluon/assistant/ui/pages/tutorial.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,13 @@ def main():
</div>
<div class="right-section">
<div class="get-started-title">Get Started</div>
<div class="description">AutoGluon Assistant (AG-A) provides users a simple interface where they can upload their data, describe their problem, and receive a highly accurate and competitive ML solution — without writing any code. By leveraging the state-of-the-art AutoML capabilities of AutoGluon and integrating them with a Large Language Model (LLM), AG-A automates the entire data science pipeline. AG-A takes AutoGluon’s automation from three lines of code to zero, enabling users to solve new supervised learning tabular problems using only natural language descriptions.</div>
<div class="description">AutoGluon Assistant (AG-A) provides users a simple interface where they can upload their data, describe their problem, and receive a highly accurate and competitive ML solution — without writing any code. By leveraging the state-of-the-art AutoML capabilities of AutoGluon and integrating them with a Large Language Model (LLM), AG-A automates the entire data science pipeline.</div>
<div class="steps">
<ol>
<li>Upload dataset files (CSV,XLSX)</li>
<li>Provide dataset description</li>
<li>Define your machine learning task</li>
<li>Launch AutoGluon Assistant</li>
<li>Get accurate predictions</li>
</ol>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/autogluon/assistant/ui/utils/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def generate_output_filename():
timestamp = pd.Timestamp.now().strftime("%Y%m%d_%H%M%S")
directory_path = os.path.join(user_data_dir, timestamp)
os.makedirs(directory_path, exist_ok=True)
output_filepath = os.path.join(directory_path, "output.csv")
output_filepath = os.path.join(directory_path, "predictions.csv")
return output_filepath


Expand Down

0 comments on commit 497dac4

Please sign in to comment.