Open Net Worth
Open Net Worth는 직접 운영하는 오픈소스 개인 AI 자산 비서로, 전체 재무를 하나의 원장에 기록하고 사용자가 제어하는 AI가 관리
아직 감지된 업데이트가 없습니다. GitHub 릴리스가 나오면 여기에 보입니다.
개인 계정의 공개 저장소 소유자는 GitHub로 로그인해 운영자를 확인하고 소개를 직접 관리할 수 있습니다. 관리자 승인은 필요하지 않습니다.
로그인한 뒤 확인 파일을 만들어 이 저장소의 기본 브랜치에 30분 안에 커밋해 주세요. 다른 브랜치나 포크의 파일은 인정하지 않습니다. 파일을 올린 뒤 아래에서 확인하면 관리자 승인 없이 관리할 수 있습니다. 자격을 유지하려면 파일을 남겨 두세요.
로그인이 필요하면 로그인 화면으로 이동합니다. 로그인 후 이곳으로 돌아와 원하는 확인 버튼을 다시 눌러 주세요.
프로젝트 폴더에서 /nomorevibe verify를 실행하면 소유권을 확인하고 소개를 직접 관리할 수 있습니다.
1분 만에 확인하기메이커가 쓴 소개는 위의 한 줄이 전부입니다. 더 자세한 내용은 저장소 README에서 읽을 수 있습니다. 저장소 README ↗
README 전체를 불러오는 중입니다.
README 전문 보기 ↗Your automated minute view of the markets.
Mintalyze is a full-stack financial intelligence platform that combines real-time market data, AI-powered insights, and institutional-grade quantitative trading capabilities. Get instant market summaries, track custom watchlists, and leverage machine learning models for trading signals—all in one unified dashboard.
/chatget_quote_snapshot, get_top_movers, get_market_summaryget_watchlists, get_alerts, create_watchlist, edit_watchlistget_quant_signals, get_model_quality, get_top_signalsget_sentinel_report, get_insightsget_ticker_news, get_ticker_events, get_macro_eventsget_sentiment, get_ticker_alerts, get_explanationabout_mintalyze./services/redeploy_models.sh for model updatesVolatilityCard, MarketSignalsCard, MarketSummaryCard, RegimeComponentsCardSentinelExplainToday, WhatThisMeans, ProfessionalInsights, LambdaCronRunnerNewsItem model for storing ML-scored news (sentiment, relevance, category)LivePrediction with raw and news-adjusted fields for dual scoring
rawSignal, rawConfidence, rawProbUp, rawProbNeutral, rawProbDownnewsCount to track Bayesian update influenceSentinelReport model with structured narrative storageDistribionalForecast model for probabilistic forecasts (200+ tickers daily)whatThisMeans, context, keyDrivers)runId for efficient queryingMintalyze consists of three integrated systems:
Web Application - Modern Next.js dashboard for market monitoring and AI insights
Quant Lab System - ML-powered engine with movement predictions and forecasts
AWS Infrastructure - Serverless Lambda + SageMaker for automated daily analysis
System Architecture Diagram:
View System Architecture
Daily Cron Flow:
View Automated Daily Analysis Flow
The system uses a serverless architecture with three main components:
Daily Automated Flow:
{up: 0.52, down: 0.31} + bearish news → {up: 0.34, down: 0.51}Custom-trained sentiment and relevance classifiers deployed as FastAPI microservices on AWS EC2 (t3.medium):
Sentiment Model (Port 8001)
POST /score with {"text": "headline"}{"score": 0.73, "category": "bullish"}Relevance Model (Port 8002)
POST /score with {"headline": "text", "ticker": "AAPL"}{"score": 0.85, "category": "company"}Deployment Details:
News Processing Workflow:
POST /api/news/process-batch (220 tickers, today's news)/stable/news/stock)NewsItem in database (ticker, headline, sentiment, relevance, category)GET /api/news/get?ticker=X&days=2 (retrieve scored news)bayesian_update() to raw ML predictionsLivePredictionExample News Scoring:
Headline: "Apple announces record Q4 earnings, stock jumps 5%"
Ticker: AAPL
→ Sentiment: +0.85 (bullish)
→ Relevance: 0.95 (company)
→ Category weight: 1.0x
→ Bayesian impact: Shifts prob_up from 0.52 → 0.67
useScrollAnimation - Scroll-triggered animationsuseWindowSize - Responsive layout managementcacheManager - Server-side caching with revalidationfmpData - FMP API data fetchingmarketData - Market data fetching and transformationeventDetector - Macro event detection logicThe Sentinel AI Agent is an autonomous market intelligence system that provides real-time market analysis with human-readable narratives.
Multi-Stage Pipeline:
Generated AI narratives follow a consistent format:
{
whatHappened: string, // 2-3 sentence plain English summary
whyItMatters: string, // Significance explanation
whatCouldHappenNext: string, // Potential scenarios
whatToWatch: string[] // 3-5 specific monitoring points
}
Tone & Style:
All Sentinel reports are stored in PostgreSQL with:
/sentinel page with comprehensive viewsMarketMinute's Quant Lab employs four specialized models for market prediction:
Multiclass Triple-Barrier Method:
Classes:
-1 = Strong Down (sell signal)0 = Neutral (hold/no trade)1 = Strong Up (buy signal)Forward-Looking Period: 5 days (default)
Dynamic Volatility Adjustment:
Density Control:
Class Balancing:
MarketMinute/
├── .env # Environment variables
├── .gitignore # Git ignore rules
├── README.md # Project documentation
├── deploy.sh # Main deployment script
│
├── platform/ # AI Agent & MCP infrastructure
│ ├── agent/ # Lambda agent orchestrator
│ │ ├── scripts/
│ │ │ └── build-lambda.sh # Build and deploy script
│ │ ├── src/
│ │ │ ├── lambda/
│ │ │ │ ├── handler.ts # Lambda entry point
│ │ │ │ └── orchestrator.ts # Agentic loop with tool calling
│ │ │ └── tools/
│ │ │ └── registry.ts # Tool registry for Lambda
│ │ ├── Dockerfile # Lambda container
│ │ └── package.json
│ │
│ ├── mcp/ # Model Context Protocol tools
│ │ └── src/
│ │ ├── tools/ # Tool implementations
│ │ │ ├── market/ # get_quote_snapshot, get_top_movers, etc.
│ │ │ ├── user/ # get_watchlists, create_watchlist, etc.
│ │ │ ├── quantlab/ # get_quant_signals, get_model_quality, etc.
│ │ │ ├── sentinel/ # get_sentinel_report, get_insights
│ │ │ ├── news/ # get_ticker_news, get_ticker_events, etc.
│ │ │ ├── analysis/ # get_sentiment, get_explanation, etc.
│ │ │ └── info/ # about_marketminute
│ │ └── ops/ # Shared operations (db, time)
│ │
│ └── shared/ # Shared schemas and types
│ ├── schemas/
│ │ └── tools/ # Zod schemas for all tools
│ └── types/
│
├── services/ # ML microservices (EC2-hosted)
│ ├── redeploy_models.sh # Model redeployment script
│ ├── sentiment/ # Sentiment analysis service
│ │ ├── app.py # FastAPI application
│ │ ├── config.py # Service configuration
│ │ ├── Dockerfile # Container definition
│ │ ├── requirements.txt # Python dependencies
│ │ ├── model/ # Model artifacts
│ │ │ ├── sentiment_classifier.pkl # Trained model
│ │ │ └── sentiment_classifier.py # Model class
│ │ ├── training/ # Training scripts
│ │ │ └── train.py # Model training
│ │ └── data/ # Training data
│ │
│ └── relevance/ # Relevance scoring service
│ ├── app.py # FastAPI application
│ ├── config.py # Service configuration
│ ├── Dockerfile # Container definition
│ ├── requirements.txt # Python dependencies
│ ├── model/ # Model artifacts
│ │ ├── relevance_classifier.pkl # Trained model
│ │ └── relevance_scorer.py # Model class
│ ├── training/ # Training scripts
│ │ └── train.py # Model training
│ └── data/ # Training data
│
├── webapp/ # Next.js web application
│ ├── .env # Environment variables
│ ├── .gitignore # Git ignore rules
│ ├── auth.ts # NextAuth configuration
│ ├── next.config.ts # Next.js configuration
│ ├── package.json # Node dependencies
│ ├── tsconfig.json # TypeScript configuration
│ ├── tailwind.config.ts # Tailwind CSS configuration
│ ├── vercel.json # Vercel deployment config
│ │
│ ├── app/ # App router pages
│ │ ├── (auth)/ # Authentication pages
│ │ │ ├── login/ # Login page
│ │ │ └── signup/ # Signup page
│ │ ├── about/ # About page
│ │ ├── admin/ # Admin dashboard
│ │ ├── api/ # API routes (58 endpoints)
│ │ │ ├── auth/ # Authentication endpoints
│ │ │ ├── quant/ # Quant data endpoints
│ │ │ ├── sentinel/ # Sentinel agent endpoints
│ │ │ ├── watchlist/ # Watchlist endpoints
│ │ │ └── ... # Market data, news, etc.
│ │ ├── features/ # Features showcase page
│ │ ├── forecasts/ # ML forecasts page
│ │ ├── history/ # Historical data view
│ │ ├── how-it-works/ # How it works page
│ │ ├── privacy/ # Privacy policy
│ │ ├── quant/ # Quant lab interface
│ │ ├── sentinel/ # Sentinel AI dashboard
│ │ │ ├── page.tsx # Sentinel dashboard
│ │ │ └── [reportId]/ # Individual report view
│ │ ├── settings/ # User settings
│ │ ├── subscription/ # Subscription management
│ │ ├── support/ # Support pages
│ │ ├── terms/ # Terms of service
│ │ ├── use-cases/ # Use cases page
│ │ ├── watchlist/ # Watchlist management
│ │ │ ├── page.tsx # Watchlist dashboard
│ │ │ └── [symbol]/ # Individual stock view
│ │ ├── why-marketminute/ # Why MarketMinute page
│ │ ├── DashboardClient.tsx # Main dashboard client
│ │ ├── layout.tsx # Root layout
│ │ ├── page.tsx # Homepage
│ │ ├── sitemap.ts # Dynamic sitemap
│ │ └── globals.css # Global styles
│ │
│ ├── agents/ # AI agent systems
│ │ └── sentinel/ # Sentinel agent implementation
│ │ ├── agent/ # Core agent logic
│ │ │ ├── context.ts # Context builder
│ │ │ ├── drilldown.ts # Drilldown causation
│ │ │ ├── loop.ts # Main execution loop
│ │ │ ├── report.ts # Report generation
│ │ │ ├── triggers.ts # Anomaly trigger detection
│ │ │ └── types.ts # Type definitions
│ │ ├── config/ # Configuration
│ │ │ ├── prompts.ts # LLM prompts
│ │ │ └── types.ts # Config types
│ │ ├── llm/ # LLM integration
│ │ │ ├── openai.ts # OpenAI client
│ │ │ └── prompts/ # Prompt engineering templates
│ │ └── services/ # Market data fetchers
│ │ ├── macro/ # Macro event services
│ │ ├── market/ # Market snapshot (get_market_snapshot.ts)
│ │ ├── notify/ # Notification services
│ │ └── volatility/ # Volatility data services
│ │
│ ├── components/ # React components
│ │ ├── README.md # Component documentation
│ │ ├── atoms/ # Basic UI components (13)
│ │ │ ├── Badge.tsx
│ │ │ ├── Box.tsx
│ │ │ ├── Button.tsx
│ │ │ ├── Card.tsx
│ │ │ ├── Container.tsx
│ │ │ ├── Dialog.tsx
│ │ │ ├── EmptyState.tsx
│ │ │ ├── Label.tsx
│ │ │ ├── MiniSparkline.tsx
│ │ │ ├── SectionHeader.tsx
│ │ │ ├── SignOutButton.tsx
│ │ │ ├── Stack.tsx
│ │ │ └── StatusBadge.tsx
│ │ ├── molecules/ # Composite components (17)
│ │ │ ├── Accordion.tsx
│ │ │ ├── AlertCard.tsx
│ │ │ ├── EnhancedPredictionCard.tsx
│ │ │ ├── ForecastCard.tsx
│ │ │ ├── IconLabel.tsx
│ │ │ ├── MarketSignalsCard.tsx
│ │ │ ├── MarketSummaryCard.tsx
│ │ │ ├── NavLink.tsx
│ │ │ ├── QuantLabAvailableTickers.tsx
│ │ │ ├── QuantLabLimitations.tsx
│ │ │ ├── QuantLabMethodology.tsx
│ │ │ ├── RegimeComponentsCard.tsx
│ │ │ ├── TickerListClient.tsx
│ │ │ ├── TickerSearch.tsx
│ │ │ ├── TopSignalsView.tsx
│ │ │ ├── UserInfo.tsx
│ │ │ └── VolatilityCard.tsx
│ │ └── organisms/ # Complex feature components (18)
│ │ ├── AdminSettings.tsx
│ │ ├── DistributionalForecasts.tsx
│ │ ├── EmailVerificationBanner.tsx
│ │ ├── EventsTimeline.tsx
│ │ ├── InsightCards.tsx
│ │ ├── MarketForecastsClient.tsx
│ │ ├── MarketMinuteSummary.tsx
│ │ ├── MarketTicker.tsx
│ │ ├── MovementAlertsBar.tsx
│ │ ├── ProfessionalInsights.tsx
│ │ ├── QuantLabClient.tsx
│ │ ├── SentinelExplainToday.tsx
│ │ ├── SentinelPreferences.tsx
│ │ ├── SinceLastVisit.tsx
│ │ ├── WatchlistSelector.tsx
│ │ ├── WatchlistTimeline.tsx
│ │ ├── WhatThisMeans.tsx
│ │ └── sidebar.tsx
│ │
│ ├── hooks/ # Custom React hooks
│ │ ├── useMarketData.tsx
│ │ └── useWatchlist.tsx
│ │
│ ├── lib/ # Utilities and helpers
│ │ ├── cacheManager.ts # Redis caching
│ │ ├── eventDetector.ts # Market event detection
│ │ ├── eventsDb.ts # Event database
│ │ ├── explainCache.ts # Explanation caching
│ │ ├── macroNews.ts # Macro news fetcher
│ │ ├── marketData.ts # Market data utils (FMP API)
│ │ ├── news.ts # News aggregation
│ │ ├── openai.ts # OpenAI integration
│ │ ├── redis.ts # Redis caching client
│ │ ├── tickerCache.ts # Ticker data caching
│ │ ├── smartAlerts.ts # Alert system
│ │ ├── summary.ts # Market summaries
│ │ ├── summaryCache.ts # Summary caching
│ │ ├── tickerMappings.ts # Ticker utilities
│ │ └── utils.ts # General utilities
│ │
│ ├── prisma/ # Database schema and migrations
│ │ ├── migrations/ # Database migrations
│ │ └── schema.prisma # Prisma schema
│ │
│ └── public/ # Static assets
│ ├── icons/ # Icon files
│ └── images/ # Image assets
│
├── quant/ # Quantitative trading system
│ ├── .env # Environment variables
│ ├── .gitignore # Git ignore rules
│ ├── requirements.txt # Python dependencies
│ ├── setup.py # Package setup
│ ├── serverless.yml # Serverless config (legacy)
│ ├── SYSTEM_SPEC.yaml # System specifications
│ │
│ ├── lambda/ # AWS Lambda orchestrator
│ │ ├── .gitignore # Lambda ignore rules
│ │ ├── Dockerfile # Lambda container config
│ │ ├── requirements.txt # Lambda dependencies
│ │ ├── deploy_lambda.sh # Deployment script
│ │ ├── lambda_handler.py # Main orchestrator function
│ │ ├── predictions.py # Prediction generation logic
│ │ ├── forecasting.py # Distributional forecasts logic
│ │ └── tickers.py # Ticker list configuration
│ │
│ ├── logs/ # Log files (generated)
│ │
│ ├── models/ # Saved ML models (generated)
│ │
│ ├── outputs/ # Training outputs
│ │ ├── backtests/ # Backtest results
│ │ ├── predictions/ # Generated predictions
│ │ └── reports/ # Analysis reports
│ │
│ ├── sagemaker/ # SageMaker inference endpoint
│ │ ├── .gitignore # SageMaker ignore rules
│ │ ├── Dockerfile # SageMaker container config
│ │ ├── requirements.txt # SageMaker dependencies
│ │ ├── deploy.py # Deployment utility
│ │ ├── deploy_sagemaker.sh # Deployment script
│ │ ├── inference.py # Inference handler
│ │ ├── serve # Serve script
│ │ ├── wsgi.py # WSGI application
│ │ └── models/ # Model artifacts (copied at build)
│ │
│ ├── scripts/ # CLI utilities
│ │ ├── cleanup.py # Data cleanup
│ │ ├── compare_ensemble_strategies.py
│ │ ├── eval_multiclass_trading.py
│ │ ├── generate_distributional_forecasts.py
│ │ ├── generate_predictions.py
│ │ ├── prep_data.py # Data preparation (FMP API)
│ │ └── train_model.py # Model training
│ │
│ └── src/ # Core library
│ ├── data/ # Data processing
│ │ ├── __init__.py
│ │ ├── fmp_data.py # FMP API client
│ │ ├── features/ # Feature engineering
│ │ │ ├── __init__.py
│ │ │ ├── FEATURE_DICTIONARY.md
│ │ │ ├── curated_features.py
│ │ │ └── feature_engine.py
│ │ ├── labels/ # Label generation
│ │ │ ├── __init__.py
│ │ │ ├── binary_labeler.py
│ │ │ └── multiclass_labeler.py
│ │ └── preprocessing/ # Data preprocessing
│ │ ├── __init__.py
│ │ └── scaler.py
│ │
│ └── models/ # ML model implementations
│ ├── __init__.py
│ ├── ensemble_classifier.py # Ensemble model
│ ├── hyperparameter_tuner.py # Optuna tuning
│ ├── xgb_hyperparameter_tuner.py
│ ├── base/ # Base models
│ │ ├── __init__.py
│ │ ├── lgbm_classifier.py # LightGBM
│ │ └── xgb_classifier.py # XGBoost
│ └── deep_learning/ # Deep learning models
│ ├── __init__.py
│ ├── lstm_classifier.py # LSTM
│ └── transformer_classifier.py # Transformer
│
└── infrastructure/ # Cloud infrastructure
├── scripts/ # Management utilities
│ ├── deploy_ec2_ml_services.sh # EC2 ML services deployment
│ ├── deploy_lambda.sh # Lambda deployment
│ ├── manage_scheduler.sh # Cron job management
│ ├── setup.sh # Initial setup
│ ├── teardown.sh # Infrastructure teardown
│ └── view_cron_history.sh # View cron logs
│
└── terraform/ # Infrastructure as Code
├── main.tf # Main configuration
├── variables.tf # Variable definitions
├── terraform.tfvars # Variable values
├── outputs.tf # Output definitions
├── ecr.tf # ECR repositories
├── iam.tf # IAM roles and policies
├── ec2_ml_services.tf # EC2 instance for ML services
├── iam_ec2_ml.tf # IAM roles for EC2
├── user_data.sh # EC2 initialization script
├── docker-compose.yml # Docker Compose for ML services
├── lambda.tf # Lambda function config
├── sagemaker.tf # SageMaker endpoint config
├── scheduler.tf # EventBridge cron job
└── secrets.tf # Secrets Manager config
cd webapp
# Install dependencies
npm install
# Note: postinstall script automatically runs "prisma generate"
# Configure environment variables
cp .env.example .env.local
# Edit .env.local with your credentials:
# - DATABASE_URL (PostgreSQL)
# - NEXTAUTH_SECRET
# - OPENAI_API_KEY
# - FMP_API_KEY (Financial Modeling Prep - Premium tier for quotes, news, and events)
# - SENTIMENT_SERVICE_URL (e.g., http://100.31.239.246:8001)
# - RELEVANCE_SERVICE_URL (e.g., http://100.31.239.246:8002)
# - UPSTASH_REDIS_REST_URL (optional - Redis caching)
# - UPSTASH_REDIS_REST_TOKEN (optional - Redis caching)
# Initialize database
npx prisma migrate dev
# Latest migration includes SentinelReport model
# Run development server
npm run dev
# Access the app at http://localhost:3000
# Visit /sentinel for Sentinel AI dashboard
Visit http://localhost:3000
cd quant
# Install dependencies
pip install -r requirements.txt
# Set up environment
pip install -e .
# FMP requires only an API key (no authentication script needed)
# Prepare data
python3 scripts/prep_data.py
# Train initial models
python3 scripts/train_model.py
# Generate Predictions
python3 scripts/generate_predictions.py
# Generate Forecasts
python3 scripts/generate_distributional_forecasts.py
Deploy Sentiment & Relevance Models:
cd services
# Option 1: Deploy both services
./redeploy_models.sh both
# Option 2: Deploy individual services
./redeploy_models.sh sentiment
./redeploy_models.sh relevance
The script will:
.pkl files in model/ directories)--no-cache for AMD64 architectureTest the services:
# Sentiment analysis
curl -X POST http://<EC2_IP>:8001/score \
-H "Content-Type: application/json" \
-d '{"text": "Stock prices surge on positive earnings"}'
# Relevance scoring
curl -X POST http://<EC2_IP>:8002/score \
-H "Content-Type: application/json" \
-d '{"headline": "Apple unveils new iPhone", "ticker": "AAPL"}'
Train new models:
# Sentiment
cd services/sentiment/training
python3 train.py
# Relevance
cd services/relevance/training
python3 train.py
# Then redeploy
cd ../../
./redeploy_models.sh both
Prerequisites:
1. Configure Terraform Variables
cd infrastructure/terraform
# Create terraform.tfvars
cat > terraform.tfvars << 'EOF'
project_name = "marketminute"
environment = "dev"
aws_region = "us-east-1"
sagemaker_image_uri = "YOUR_ECR_URI/marketminute-sagemaker:latest"
lambda_image_uri = "YOUR_ECR_URI/marketminute-lambda:latest"
webapp_url = "https://market-minute.vercel.app"
EOF
2. Deploy SageMaker Model
cd ../../quant/sagemaker
# Build and push Docker image
./deploy_sagemaker.sh
# Copy the ECR URI and update terraform.tfvars
3. Deploy Lambda Function
cd ../lambda
# Build and push Docker image
./deploy_lambda.sh
# Copy the ECR URI and update terraform.tfvars
4. Apply Terraform
cd ../../infrastructure/terraform
# Initialize Terraform
terraform init
# Preview changes
terraform plan
# Apply infrastructure
terraform apply
# Note the Lambda Function URL output
5. Test the Integration
# Manual trigger test
cd ../scripts
./manage_scheduler.sh test
# Check logs
./manage_scheduler.sh logs
# Verify EventBridge schedule
./manage_scheduler.sh status
Automated Daily Schedule:
marketminute-dev-daily-analysisThe Lambda function will:
POST :8001/score - Sentiment analysis
{"text": "string"}{"score": -1.0 to 1.0, "category": "very_negative|negative|neutral|positive|very_positive"}POST :8002/score - Relevance scoring
{"headline": "string", "ticker": "string"}{"score": 0.0 to 1.0, "category": "not_relevant|marginally_relevant|somewhat_relevant|highly_relevant"}GET :8001/health - Sentiment service health checkGET :8002/health - Relevance service health checkGET /api/snapshots - Real-time stock quotesGET /api/market-ticker - Streaming market ticker dataGET /api/events - Upcoming earnings and eventsGET /api/ticker-search - Symbol search and lookupGET/POST /api/watchlist - Manage watchlistsPOST/DELETE/PATCH /api/watchlist/items - Manage watchlist itemsPATCH /api/watchlist/favorite - Toggle favorite statusPOST /api/summary - Generate AI market summariesPOST /api/explain - Get detailed explanations for market movementsGET /api/smart-alerts - Fetch triggered smart alertsGET /api/macro-news - Macro event detectionPOST /api/sentinel - Generate Sentinel AI market intelligence reportGET /api/quant/predictions - Fetch ML trading predictions (from database)GET /api/quant/forecasts - Get distributional forecasts (from database)POST /api/quant/save-results - Save Lambda predictions to database (internal)POST /api/quant/generate - Trigger new predictionsPOST /api/quant/run-script - Execute quant scriptsPOST /api/admin/trigger-cron - Manually trigger Lambda cron job (testing)PATCH /api/user/active-watchlist - Set active watchlistPOST /api/visit-snapshot - Create user visit snapshotsGET /api/daily-summary - Historical daily summariesPOST /api/admin/cache - Cache managementGET /api/admin/scripts - List available scriptsMarketMinute uses NextAuth.js v5 with OAuth providers:
Configure providers in webapp/auth.ts and set environment variables:
AUTH_GOOGLE_ID=your_google_client_id
AUTH_GOOGLE_SECRET=your_google_client_secret
Key models:
User
├── Watchlists (1-to-many)
│ ├── WatchlistItems (1-to-many)
│ └── Macros (1-to-many)
├── Accounts (OAuth providers)
├── Sessions (Auth)
├── DailyWatchlistSummaries (through watchlist)
└── SentinelReports (1-to-many)
NewsItem
├── id, ticker, headline
├── sentiment (Float) - ML model score (-1.0 to 1.0)
├── relevance (Float, nullable) - ML model score (0.0 to 1.0)
├── category (String, nullable) - Relevance category
├── summary (String, nullable)
└── createdAt (DateTime)
SentinelReport
├── summary (Text)
├── keyDrivers (JSON)
├── macroContext (Text, nullable)
├── whatThisMeans (JSON, nullable) - Structured narrative
├── anomaly flags (indexMove, sectorRotation, macroSurprise, volSpike)
├── volatility metrics (vix, vixChangePct, realizedVol)
└── context (JSON) - Full market context for reprocessing
LivePrediction
├── ticker, timestamp, currentPrice
├── Raw ML Model Outputs (before news):
│ ├── rawSignal, rawConfidence
│ └── rawProbUp, rawProbNeutral, rawProbDown
├── News-Adjusted Outputs (after Bayesian update):
│ ├── signal (BUY/SELL/NEUTRAL)
│ ├── confidence, probUp, probNeutral, probDown
│ └── newsCount (number of news items that influenced the update)
├── shouldTrade, takeProfit, stopLoss, atr
└── runId (groups predictions from same Lambda run)
NewsItem
├── ticker, headline
├── sentiment (-1 to +1, from EC2 ML model)
├── relevance (0 to 1, from EC2 ML model)
├── category (company/sector/macro/noise)
└── createdAt (for querying recent news)
DistribionalForecast
├── ticker, timestamp, currentPrice
├── expectedRangePct, upperBound, lowerBound
├── directionalBias, conviction, convictionScore
├── probability distribution (probLargeUp, probMildUp, probFlat, probMildDown, probLargeDown)
├── percentiles (p10, p50, p90)
└── runId (groups forecasts from same Lambda run)
Run migrations:
npx prisma migrate dev
Configure in webapp/.env.local:
Edit quant/SYSTEM_SPEC.yaml:
This project is private and proprietary.
This is a private project. For questions or access, contact the repository owner.
Important Configuration:
webapp in Vercel project settingsDATABASE_URL - Production PostgreSQL connection stringNEXTAUTH_SECRET - Authentication secretNEXTAUTH_URL - https://market-minute.vercel.appOPENAI_API_KEY - OpenAI API keyFMP_API_KEY - Financial Modeling Prep API keyLAMBDA_FUNCTION_URL - AWS Lambda function URLDeploy:
cd webapp
vercel deploy --prod
Build Configuration:
prisma generate && next build.nextnpm installSee AWS Infrastructure Setup section above for full deployment instructions.
Quick Deploy:
# 1. Deploy models
cd quant/sagemaker && ./deploy_sagemaker.sh
cd ../lambda && ./deploy_lambda.sh
# 2. Apply infrastructure
cd ../../infrastructure/terraform
terraform apply
# 3. Test
cd ../scripts && ./manage_scheduler.sh test
TypeScript errors after schema changes:
npx prisma generate
FMP API errors:
Ensure your FMP_API_KEY is valid and has sufficient quota. Free tier includes 250 requests/day.
Database connection issues:
npx prisma migrate reset
npx prisma migrate dev
Missing environment variables:
Check that all required variables are set in .env.local or .env
Built with ❤️ for traders and quants