We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/0xsaju/mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
install.shβ’2.35 KiB
#!/bin/bash
# Installation script for MCP Server on GPU server
set -e # Exit on any error
echo "π Installing MCP Server dependencies on GPU server..."
# Check if we're in a virtual environment
if [[ "$VIRTUAL_ENV" == "" ]]; then
echo "β οΈ Warning: Not in a virtual environment"
echo " Consider running: python -m venv .venv && source .venv/bin/activate"
read -p "Continue anyway? (y/N): " -n 1 -r
echo
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
exit 1
fi
fi
# Install core dependencies first
echo "π¦ Installing core dependencies..."
pip install --upgrade pip setuptools wheel
pip install -r requirements-core.txt
echo "β Core dependencies installed successfully"
# Test if PyTorch is working with CUDA
echo "π Testing PyTorch CUDA availability..."
python -c "
import torch
print(f'PyTorch version: {torch.__version__}')
print(f'CUDA available: {torch.cuda.is_available()}')
if torch.cuda.is_available():
print(f'CUDA devices: {torch.cuda.device_count()}')
print(f'Current device: {torch.cuda.get_device_name(0)}')
else:
print('β οΈ CUDA not available - will use CPU mode')
"
# Ask about optional dependencies
echo ""
read -p "π Install optional dependencies (flash-attn, dev tools)? (y/N): " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]; then
echo "π¦ Installing optional dependencies..."
# Try to install flash-attn with better error handling
echo "π₯ Installing Flash Attention (this may take a while)..."
if pip install flash-attn>=2.0.0; then
echo "β Flash Attention installed successfully"
else
echo "β οΈ Flash Attention installation failed - continuing without it"
echo " This is normal if your GPU doesn't support it"
fi
# Install other optional dependencies
pip install pytest>=7.0.0 black>=23.0.0 isort>=5.12.0
echo "β Development tools installed"
else
echo "βοΈ Skipping optional dependencies"
fi
# Create .env if it doesn't exist
if [ ! -f .env ]; then
echo "π Creating .env configuration file..."
cp config.env .env
echo "β Configuration file created (.env)"
echo " Edit .env to customize your settings"
fi
echo ""
echo "π Installation completed successfully!"
echo ""
echo "Next steps:"
echo "1. Edit .env file for your configuration"
echo "2. Test: python test_server.py"
echo "3. Run: python mcp_server.py"