walidsobhie-code
reorganize: consolidate root level to 20 folders
b8e3e42
.PHONY: help install test train deploy clean lint format check check-types lint-ci
help: ## Show this help message
@echo "Stack 2.9 - Makefile Commands"
@echo ""
@echo "Setup:"
@echo " install Install Python and Node dependencies"
@echo ""
@echo "Training:"
@echo " train Run full training pipeline"
@echo " prepare-data Prepare training dataset"
@echo ""
@echo "Deployment:"
@echo " deploy-local Deploy vLLM server locally with Docker"
@echo " deploy-runpod Deploy to RunPod"
@echo " deploy-vast Deploy to Vast.ai"
@echo ""
@echo "Voice:"
@echo " voice-up Start voice integration service"
@echo " voice-down Stop voice service"
@echo ""
@echo "Evaluation:"
@echo " eval Run full benchmark suite"
@echo " eval-tool-use Run tool-use evaluation"
@echo " eval-code Run code quality evaluation"
@echo ""
@echo "Utilities:"
@echo " test Run unit tests"
@echo " lint Run linters"
@echo " clean Remove build artifacts and temporary files"
@echo " docs Generate documentation"
install: ## Install dependencies
@echo "πŸ“¦ Installing dependencies..."
pip install -r requirements.txt
cd stack-2.9-training && pip install -r requirements.txt
cd stack-2.9-voice && pip install -r requirements.txt 2>/dev/null || true
npm install 2>/dev/null || true
@echo "βœ… Installation complete"
train: ## Run full training pipeline
@echo "πŸ€– Starting training pipeline..."
cd stack-2.9-training && ./run_training.sh
deploy-local: ## Deploy locally with Docker Compose
@echo "πŸš€ Deploying to local Docker..."
cd stack-2.9-deploy && ./local_deploy.sh
deploy-runpod: ## Deploy to RunPod
@echo "☁️ Deploying to RunPod..."
cd stack-2.9-deploy && ./runpod_deploy.sh
deploy-vast: ## Deploy to Vast.ai
@echo "☁️ Deploying to Vast.ai..."
cd stack-2.9-deploy && ./vastai_deploy.sh
voice-up: ## Start voice integration service
@echo "🎀 Starting voice service..."
cd stack-2.9-voice && docker-compose up -d
@echo "βœ… Voice service running on http://localhost:8001"
voice-down: ## Stop voice service
@echo "🎀 Stopping voice service..."
cd stack-2.9-voice && docker-compose down
eval: ## Run full benchmark suite
@echo "πŸ“Š Running evaluation suite..."
cd stack-2.9-eval && ./benchmark_suite.sh
eval-tool-use: ## Run tool-use evaluation
@echo "πŸ”§ Running tool-use evaluation..."
cd stack-2.9-eval && python tool_use_eval.py
eval-code: ## Run code quality evaluation
@echo "✨ Running code quality evaluation..."
cd stack-2.9-eval && python code_quality_eval.py
test: ## Run unit tests
@echo "πŸ§ͺ Running tests..."
pytest -xvs 2>/dev/null || echo "No pytest tests found"
cd stack-2.9-voice && python -m pytest test_integration.py 2>/dev/null || true
lint: ## Run ruff linter
@echo "πŸ” Running ruff linter..."
ruff check .
@echo "βœ… Lint complete"
format: ## Run black formatter
@echo "🎨 Running black formatter..."
black .
@echo "βœ… Format complete"
check: ## Run all quality checks
@echo "πŸ” Running all checks (lint + format check + type check)..."
@echo ""
@echo "--- Lint (ruff) ---"
ruff check . || true
@echo ""
@echo "--- Format check (black) ---"
black --check . || true
@echo ""
@echo "--- Type check (mypy) ---"
bash scripts/check_types.sh
@echo ""
@echo "βœ… All checks complete"
check-types: ## Run mypy type checks
@echo "πŸ” Running mypy type checks..."
bash scripts/check_types.sh
@echo "βœ… Type check complete"
lint-ci: ## Run linters (CI-friendly, fail on errors)
@echo "πŸ” Running linters (CI mode)..."
ruff check . --exit-non-zero-on-error
clean: ## Clean build artifacts
@echo "🧹 Cleaning..."
rm -rf data/ output/ models/ logs/
find . -name "*.pyc" -delete
find . -name "__pycache__" -delete
find . -name ".pytest_cache" -delete
@echo "βœ… Clean complete"
docs: ## Generate documentation
@echo "πŸ“š Generating documentation..."
cd stack-2.9-docs && cp -R ../README.md . 2>/dev/null || true
@echo "βœ… Docs ready in stack-2.9-docs/"
status: ## Show deployment status
@echo "πŸ“‹ Stack 2.9 Status"
@echo "=================="
@if docker ps | grep -q stack; then \
echo "βœ… vLLM server: running"; \
else \
echo "❌ vLLM server: stopped"; \
fi
@if docker ps | grep -q voice; then \
echo "βœ… Voice service: running"; \
else \
echo "❌ Voice service: stopped"; \
fi
@echo ""
@echo "Directories:"
@ls -ld training-data/ stack-2.9-*/ 2>/dev/null | awk '{print " " $$NF}'