Skip to content

42-AI/FeatherlessAI

Repository files navigation

Featherless Vision


Requirements


Setup

git clone https://github.com/your-org/featherless-vision-app.git
cd featherless-vision-app
cp packages/server/.env.example packages/server/.env   # then edit the file
npm install
npm run dev

Configuration

Edit packages/server/.env:

FEATHERLESS_API_KEY=your-key-here
PORT=3001
Variable Required Default
FEATHERLESS_API_KEY Yes
PORT No 3001

Scripts

Command What it does
npm run dev Start backend + frontend (watch mode)
npm run build Compile server TS + bundle client
npm run start Run compiled server (after build)

API Reference

POST /api/vision

Body

{
  "prompt": "Describe the image in one paragraph.",
  "imageUrl": "https://example.com/photo.jpg"
}

Use imageBase64 instead of imageUrl for local files (data:image/jpeg;base64,...).
One of the two is required — omitting both returns 400.

Response

{ "content": "The image shows..." }

cURL — remote URL

curl -X POST http://localhost:3001/api/vision \
  -H "Content-Type: application/json" \
  -d '{"prompt": "What is in this image?", "imageUrl": "https://example.com/photo.jpg"}'

cURL — local file

IMAGE=$(base64 -w 0 photo.jpg)
curl -X POST http://localhost:3001/api/vision \
  -H "Content-Type: application/json" \
  -d "{\"imageBase64\": \"data:image/jpeg;base64,${IMAGE}\"}"

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors