This project demonstrates an Optical Character Recognition (OCR) application using Azure Computer Vision's Read API. It allows users to provide image URLs to recognize printed and handwritten text. The project consists of a Node.js backend and a React frontend, deployed via Vercel and Render.
- Recognize printed or handwritten text from URLs using Azure Computer Vision.
- Provide image URLs for text recognition.
- Displays recognized text on the frontend.
- Supports both backend CORS and frontend Axios requests.
- React
- Axios for HTTP requests
- Bootstrap for styling
- Node.js
- Express.js
- Azure Computer Vision API
- CORS for handling cross-origin requests
- Vercel for frontend deployment
- Render for backend deployment
- Azure Cognitive Services API Key: You need an Azure subscription and a Computer Vision resource. You can get your key and endpoint from the Azure portal.
- Node.js: Ensure that you have Node.js installed.
git clone https://github.com/your-username/azure-ocr-text-recognition.git
cd Azure-AI-Project
- For Backend:
cd Backend
npm install
- For Frontend:
cd Frontend
npm install
VISION_KEY=your_azure_computer_vision_key
VISION_ENDPOINT=your_azure_computer_vision_endpoint
PORT=5000
node index.js
The backend will run at http://localhost:5000.
The frontend is built with React and Axios to send requests to the backend.
In frontend/src/App.js, update the URLs to point to your backend's API endpoints. For local testing, make sure the API URLs look like this:
'http://localhost:5000/api/recognize-text'
To run the frontend locally, execute the following commands in the frontend directory:
npm start
The frontend will run at http://localhost:5173.
- Open the frontend application in your browser.
- Enter an image URL or upload an image file.
- Click the "Recognize Text" button.
- The recognized text will be displayed below the form once the request is processed.
Keep Grinding 👍