STOCKPREDICTION

StockDirection AI

A beginner-friendly hackathon project that predicts whether a stock may close up or down tomorrow.

What It Does

Quick Start

pip install -r requirements.txt
streamlit run app.py

Demo Login

Username: demo
Password: demo123

Optional judge account:

Username: judge
Password: judge123

For deployment, create .streamlit/secrets.toml from .streamlit/secrets.toml.example and replace the demo password hashes.

Groq AI Assistant Setup

Create a local .streamlit/secrets.toml file. Do not commit this file.

[auth.users]
demo = "d3ad9315b7be5dd53b31a273b3b3aba5defe700808305aa16a3062b76658a791"
judge = "94358d5abe1d055c1ced4403bb0e397edf8c905b33e03b34ad1b1d3adf2d9cf4"

GROQ_API_KEY = "gsk_your_key_here"
GROQ_MODEL = "llama-3.3-70b-versatile"

The real .streamlit/secrets.toml file is ignored by Git, so your API key stays private.

Core Files

Example Backend Usage

from model_pipeline import predict_tomorrow

result = predict_tomorrow("AAPL")
print(result["prediction"], result["probability_up"])

Important Note

This project is for educational use only. It is not financial advice. Short-term stock prediction is difficult, and even strong models often only slightly beat random guessing.