feat: added voice assistant to the frontend

🌾 CropNest — Voice Assistant & Market Dashboard Integration

Overview

This MR introduces the core smart-search and market intelligence functionality for CropNest.

The update includes:

  • Voice Assistant integration
  • Market Dashboard improvements
  • Commodity search functionality
  • Dynamic API-based filtering
  • Live mandi data integration
  • Analytics and Nearby Market support

Currently, the voice assistant supports English language only using the Web Speech API.


Features Added

🎤 Voice Assistant (English Only)

Implemented a lightweight voice assistant integrated directly into the homepage search experience.

Features

  • Microphone-based voice input
  • Speech-to-text using Web Speech API
  • Single-click listening
  • Dynamic commodity search
  • Compact dropdown UI
  • Real-time transcript updates

Supported Commands

Examples:

  • "show tomato prices"
  • "cotton prices in telangana"
  • "nearby markets"
  • "open analytics"

🔍 Commodity Search

Implemented search functionality for mandi commodities.

Features

  • Commodity filtering
  • State filtering
  • Dynamic API requests
  • Search bar integration
  • Explore button functionality

📡 API Integration

Integrated mandi data APIs for dashboard and search functionality.

Endpoints Used

  • /api/mandi
  • /api/prices

Features

  • Fast JSON responses
  • Dynamic filtering
  • State-wise data handling

🎨 UI Improvements

Improved overall frontend interaction and dashboard experience.

Changes

  • Cleaner voice assistant UI
  • Improved search interaction
  • Better dashboard responsiveness
  • Fixed layout overlap issues
  • Improved navigation flow

️ Current Limitations

Language Support

Currently, the voice assistant supports:

  • English only (en-IN)

Hindi and Telugu multilingual support are NOT included in this MR.


🛠️ Technical Stack

  • Next.js
  • TypeScript
  • Tailwind CSS
  • Web Speech API
  • Framer Motion

Result

CropNest now supports:

  • voice-enabled commodity search
  • live mandi dashboard updates
  • dynamic state filtering
  • analytics integration
  • nearby market exploration

with a cleaner and more interactive user experience.

Merge request reports

Loading