This guide will help you set up and run the Sola AI application locally.
Before you begin, ensure you have the following installed:
- Node.js (v18 or higher)
- Yarn package manager
- Git
- A code editor of your choice (VS Code recommended)
- A Solana wallet with SOL tokens for testing
- Clone the repository:
git clone https://github.com/TheSolaAI/sola-application.git
- Navigate to the project directory:
cd sola-application
- Install dependencies:
yarn install
-
Set up environment variables (see env configuration and details section below)
-
Start the development server:
yarn dev
- Open your browser and navigate to
http://localhost:5173
Create a .env
file in the root directory with the following environment variables:
# OpenAI Configuration
VITE_OPENAI_API_URL= # GPT-4.0 realtime/realtime mini model url
# Authentication
VITE_PRIVY_APP_ID= # Privy application ID
VITE_SENTRY_AUTH_TOKEN= # Sentry authentication token (optional for development)
# Solana Configuration
VITE_HELIUS_API_KEY= # Your Helius API key
VITE_SOLANA_RPC= # Solana RPC endpoint URL
VITE_ATA_PRIV_KEY= # Solana private key for validation
# Microservices URLs (privy Whitelisted Access Required to interact with these endpoints)
VITE_WALLET_SERVICE_URL=https://wallet-service.solaai.tech/ # Wallet service endpoint
VITE_DATA_SERVICE_URL=https://data-stream-service.solaai.tech/ # Data stream service endpoint
VITE_AUTH_SERVICE_URL=https://user-service.solaai.tech/api/v1/ # User authentication service endpoint
# Environment
VITE_ENVIORNMENT= # 'development' or 'production'
- VITE_OPENAI_API_URL: Use GPT-4.0 realtime or realtime mini model url
- VITE_PRIVY_APP_ID: Use
cm5m351oa03ij5a8yrrj64qcv
if you have a whitelisted wallet, or your own Privy ID - VITE_HELIUS_API_KEY: Your Helius API key for Solana data access
- VITE_SOLANA_RPC: Your Solana RPC endpoint (Helius RPC recommended)
- VITE_ATA_PRIV_KEY: Solana private key for general validation (not used in transactions)
- VITE_SENTRY_AUTH_TOKEN: Can use dummy value for development
For production deployments:
- Use Cloudflare Workers or similar service to secure sensitive keys
- Never commit the
.env
file to version control - Implement proper key rotation and management
- Use environment-specific configuration
Start the development server:
yarn dev
The application will be available at http://localhost:5173
If you encounter issues during setup:
-
Node.js Version
- Ensure you're using Node.js v18 or higher
- Use nvm to manage Node.js versions:
nvm install 18 nvm use 18
-
Dependencies Issues
- Clear dependency cache and reinstall:
rm -rf node_modules yarn.lock yarn cache clean yarn install
- Clear dependency cache and reinstall:
-
Environment Variables
- Verify all required variables are set in
.env
- Check for typos in variable names
- Ensure service endpoints are accessible
- Verify all required variables are set in
-
Network Issues
- Check your internet connection
- Verify Solana RPC endpoint is responsive
- Ensure you have access to required microservices
-
Application Access and Configuration
- Ensure your
.env
file is properly configured in the project root directory - For microservices access:
- Option 1 (Recommended): Use our hosted services
- Requires a whitelisted wallet with our default Privy App ID
- Must use
VITE_PRIVY_APP_ID=cm5m351oa03ij5a8yrrj64qcv
- Server performs authentication and validation checks
- Option 2 (Self-hosted): Run your own infrastructure
- Deploy microservices locally or on your infrastructure
- Use your own Privy App ID
- Implement custom service logic as needed
- Option 1 (Recommended): Use our hosted services
- Note: The application will have limited functionality without proper microservice access
- Ensure your
If you continue to experience issues:
- Check existing GitHub Issues
- Review the Documentation
- Open a new GitHub issue with:
- Detailed error description
- Environment details (OS, Node version)
- Steps to reproduce
- Relevant error logs
Please read our Contributing Guidelines before submitting pull requests.