Spaces:
Configuration error
Configuration error
# iKnow - Image Recognition App
## Backend Setup
1. Install dependencies:
```bash
npm install express multer tesseract.js axios form-data
- Set up LLaMA.cpp:
- Clone and build LLaMA.cpp: https://github.com/ggerganov/llama.cpp
- Run the server:
./server -m models/ggml-model-q4_0.bin --ctx 2048
- Start the Node.js server:
node api.js
API Endpoints
- POST
/api/analyze- Processes an image and returns recognition results
Environment
- Node.js 16+
- Tesseract OCR
- LLaMA.cpp server running locally
The changes integrate a backend system that:
1. Uses Tesseract.js for OCR (text recognition)
2. Sends the image and extracted text to a local LLaMA.cpp server for analysis
3. Returns structured data about recognized items with confidence scores
4. Shows results in a modal dialog
5. Includes mock API for development without the backend
The backend expects a running LLaMA.cpp server which can be set up following their documentation. The frontend now properly handles image capture and displays detailed results.