Skip to content

vivekdevaa124/AlgoTrade_stock-tracker-app

Repository files navigation

💹 AlphaStream: Risk-Aware Trading Engine A high-performance trading dashboard built with Next.js 15, powered by Inngest for event-driven risk analysis and MongoDB for flexible financial data modeling.

🏗️ The Stack Frontend: Next.js (App Router) with Tailwind CSS.

Database: MongoDB (using Mongoose/Prisma) for user portfolios and report storage.

Background Jobs: Inngest to handle complex, long-running risk calculations without blocking the UI.

Charts: TradingView Lightweight Charts for high-performance canvas rendering.

Real-time: WebSockets for live ticker updates.

🌟 Key Features

  1. Real-Time Risk Profiling Using Inngest, the app triggers background functions every time a trade is placed or a price moves significantly.

Calculates Value at Risk (VaR) and Sharpe Ratio asynchronously.

Automatically generates "Risk Drift" alerts when a portfolio exceeds user-defined volatility.

  1. Personalized Smart Reports MongoDB stores granular historical data, allowing the app to generate custom PDF/Markdown reports.

Sector Exposure: Visualize how much of your capital is in Tech vs. Energy.

AI Summaries: Integration-ready for LLM-based portfolio summaries.

  1. Interactive Trading Widgets Embedded TradingView widgets provide professional-grade technical analysis tools directly in the dashboard, supporting:

Multi-timeframe analysis (1m, 5m, 1D).

Overlaying personalized "Risk Zones" on top of live price action.

🚀 Getting Started Installation Clone the Repository

Bash

git clone https://github.com/your-username/trading-app.git cd trading-app Install Dependencies

Bash

npm install Configure Environment Create a .env.local file:

Code snippet

MONGODB_URI=your_mongodb_atlas_uri INNGEST_EVENT_KEY=your_inngest_key NEXT_PUBLIC_TRADINGVIEW_API=your_api_key Launch Dev Servers

Bash

Run the Next.js app

npm run dev

Run the Inngest Dev Server (to test background functions)

npx inngest-cli@latest dev 🛡️ Architecture Client interacts with the TradingView Widget.

Next.js API Route sends a "Trade Executed" event to Inngest.

Inngest runs a workflow to recalculate the user's risk profile in the background.

Resulting analytics are saved back to MongoDB and pushed to the UI via WebSockets.

🤝 Contributing Fork the Project

Create your Feature Branch (git checkout -b feature/AmazingFeature)

Commit your Changes (git commit -m 'Add some AmazingFeature')

Push to the Branch (git push origin feature/AmazingFeature)

Open a Pull Request

Screenshot 2025-12-18 172921 Screenshot 2025-12-18 172956 Screenshot 2025-12-18 173015

This is a Next.js project bootstrapped with create-next-app.

Getting Started

First, run the development server:

npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.

This project uses next/font to automatically optimize and load Geist, a new font family for Vercel.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

About

Track Real-Time Stock prices,get personalized alerts and explore detailed company insights.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors