Spaces:
Sleeping
Sleeping
Create app.py
Browse files123456789101112131415161718192021import streamlit as stimport yfinance as yf
st.set_page_config(page_title="Pocket Quant", page_icon="π")st.title("π€ AI ν¬μ μλ¬Έκ° (Docker ver)")
ticker = st.text_input("μ’
λͺ© μ½λ (μ: TSLA, 005930.KS)", "TSLA")
if st.button("λΆμ μ€ν"): try: stock = yf.Ticker(ticker) hist = stock.history(period="1mo")
if not hist.empty: current = hist['Close'].iloc[-1] st.metric("νμ¬ μ£Όκ°", f"{current:,.0f}") st.line_chart(hist['Close']) else: st.error("λ°μ΄ν° μμ! ν°μ»€ νμΈ λ°λ.") except Exception as e: st.error(f"μλ¬: {e}")app.pyAdded+21