Files
cim_summary/backend/fix-env-config.sh
Jon c67dab22b4 Add comprehensive CIM processing features and UI improvements
- Add new database migrations for analysis data and job tracking
- Implement enhanced document processing service with LLM integration
- Add processing progress and queue status components
- Create testing guides and utility scripts for CIM processing
- Update frontend components for better user experience
- Add environment configuration and backup files
- Implement job queue service and upload progress tracking
2025-07-27 20:25:46 -04:00

41 lines
1.1 KiB
Bash
Executable File

#!/bin/bash
echo "🔧 Fixing LLM Configuration..."
echo "================================"
# Check if .env file exists
if [ ! -f .env ]; then
echo "❌ .env file not found!"
exit 1
fi
echo "📝 Current configuration:"
echo "------------------------"
grep -E "LLM_PROVIDER|LLM_MODEL|OPENAI_API_KEY|ANTHROPIC_API_KEY" .env
echo ""
echo "🔧 Updating configuration to use Anthropic..."
echo "---------------------------------------------"
# Create a backup
cp .env .env.backup
echo "✅ Backup created: .env.backup"
# Update the configuration
sed -i 's/LLM_PROVIDER=openai/LLM_PROVIDER=anthropic/' .env
sed -i 's/LLM_MODEL=gpt-4/LLM_MODEL=claude-3-5-sonnet-20241022/' .env
sed -i 's/OPENAI_API_KEY=sk-ant.*/OPENAI_API_KEY=/' .env
echo "✅ Configuration updated!"
echo ""
echo "📝 New configuration:"
echo "-------------------"
grep -E "LLM_PROVIDER|LLM_MODEL|OPENAI_API_KEY|ANTHROPIC_API_KEY" .env
echo ""
echo "🎉 Configuration fixed!"
echo "📋 Next steps:"
echo "1. The backend should now use Anthropic Claude"
echo "2. Try uploading a new document"
echo "3. The enhanced BPCP CIM Review Template should be generated"