Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -111,7 +111,7 @@ def render_sidebar(df: pd.DataFrame):
|
|
| 111 |
st.sidebar.divider()
|
| 112 |
st.sidebar.header("AI")
|
| 113 |
summary_mode = st.sidebar.radio("Summary", options=["Concise", "Detailed"], index=0, horizontal=True)
|
| 114 |
-
engine = st.sidebar.selectbox("Engine", options=["
|
| 115 |
|
| 116 |
st.sidebar.divider()
|
| 117 |
st.sidebar.header("Anomalies & Highlights")
|
|
@@ -222,7 +222,7 @@ def render_ai_summary(agg: dict, mode: str, engine: str):
|
|
| 222 |
placeholder = st.empty()
|
| 223 |
placeholder.markdown("<div class='ai-card'>Generating summary…</div>", unsafe_allow_html=True)
|
| 224 |
|
| 225 |
-
if engine == "
|
| 226 |
prompt = (
|
| 227 |
f"Generate a {mode.lower()} human-readable spending summary in clear sentences. "
|
| 228 |
f"Use only the pound symbol (£) for all amounts. Ensure proper spacing between words and numbers and correct date formatting (YYYY-MM-DD). "
|
|
|
|
| 111 |
st.sidebar.divider()
|
| 112 |
st.sidebar.header("AI")
|
| 113 |
summary_mode = st.sidebar.radio("Summary", options=["Concise", "Detailed"], index=0, horizontal=True)
|
| 114 |
+
engine = st.sidebar.selectbox("Engine", options=["swiss-ai/apertus-8b-instruct"], index=0)
|
| 115 |
|
| 116 |
st.sidebar.divider()
|
| 117 |
st.sidebar.header("Anomalies & Highlights")
|
|
|
|
| 222 |
placeholder = st.empty()
|
| 223 |
placeholder.markdown("<div class='ai-card'>Generating summary…</div>", unsafe_allow_html=True)
|
| 224 |
|
| 225 |
+
if engine == "swiss-ai/apertus-8b-instruct":
|
| 226 |
prompt = (
|
| 227 |
f"Generate a {mode.lower()} human-readable spending summary in clear sentences. "
|
| 228 |
f"Use only the pound symbol (£) for all amounts. Ensure proper spacing between words and numbers and correct date formatting (YYYY-MM-DD). "
|