Skip to content

feat: add AI-powered climate safety recommendations#226

Open
Aryan-0-07 wants to merge 1 commit into
thetechguardians:mainfrom
Aryan-0-07:feature/ai-climate-recommendations
Open

feat: add AI-powered climate safety recommendations#226
Aryan-0-07 wants to merge 1 commit into
thetechguardians:mainfrom
Aryan-0-07:feature/ai-climate-recommendations

Conversation

@Aryan-0-07

Copy link
Copy Markdown

What this PR does

  • Adds AI-powered safety recommendations using OpenRouter API
  • Replaces static generateRecommendations with getAIRecommendations
  • Generates 4 personalized safety tips based on:
    • Temperature, Humidity, Rainfall, Wind Speed
    • Primary detected risk (Flood/Heat/Wildfire/Cyclone/Drought)
  • Includes fallback static tips if AI call fails

How to test

  1. Open Analysis page
  2. Enter any city, state, country
  3. Click Analyze Climate Risk
  4. See AI-generated Safety Recommendations below results

API Used

  • OpenRouter API (free tier)
  • Model: mistralai/mistral-7b-instruct

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant