each-sense

v2026.09.24

each::sense is the intelligent layer for generative media. A unified AI agent that generates marketing assets, ads, product images, videos, and creative content. It knows all AI models and automatically selects the best one for your task. Use for any creative content generation request.

GitHub
Install command
npx skhub add eachlabs/each-sense
Markdown
SKILL.md

each::sense - Intelligent Layer for Generative Media

each::sense is an OpenAI-compatible AI agent that can generate images, videos, audio, 3D models, build workflows, search the web, and hold conversational interactions. It orchestrates 500+ AI models through a single unified interface.

each::sense itself is completely free. You only get charged for the models it uses.

Use each::sense when the user needs:

  • Marketing assets and ad creatives
  • Product images and e-commerce visuals
  • Video content (ads, UGC, social media)
  • Audio and music generation
  • Any creative content generation
  • Multi-step workflows combining multiple AI models

Authentication

Header: X-API-Key: <your-api-key>

Also supports OpenAI SDK compatible authentication:

Header: Authorization: Bearer <your-api-key>

Get your API key at eachlabs.ai.

Set the EACHLABS_API_KEY environment variable.

Base URL

https://eachsense-agent.core.eachlabs.run

Endpoints

MethodPathPurpose
POST/v1/chat/completionsPrimary chat endpoint
POST/workflowWorkflow builder
GET/v1/modelsList available models
GET/memory?session_id={id}Retrieve session memory
DELETE/memory?session_id={id}Clear session memory
GET/sessionsList all sessions

Quick Start

Using curl

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Generate a portrait of a woman with golden hour lighting"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

Using Python (OpenAI SDK)

from openai import OpenAI

client = OpenAI(
    api_key="YOUR_EACHLABS_API_KEY",
    base_url="https://eachsense-agent.core.eachlabs.run/v1"
)

# Non-streaming
response = client.chat.completions.create(
    model="eachsense/beta",
    messages=[{"role": "user", "content": "Generate a sunset landscape"}],
    stream=False
)
print(response.generations)  # List of media URLs

# Streaming
stream = client.chat.completions.create(
    model="eachsense/beta",
    messages=[{"role": "user", "content": "Generate a sunset landscape"}],
    stream=True
)
for chunk in stream:
    eachlabs_data = chunk.model_extra.get("eachlabs")
    if eachlabs_data:
        event_type = eachlabs_data.get("type")
        if event_type == "generation_response":
            print(eachlabs_data["generations"])

Using JavaScript (OpenAI SDK)

import OpenAI from "openai";

const client = new OpenAI({
  apiKey: "YOUR_EACHLABS_API_KEY",
  baseURL: "https://eachsense-agent.core.eachlabs.run/v1"
});

// Non-streaming
const response = await client.chat.completions.create({
  model: "eachsense/beta",
  messages: [{ role: "user", content: "Generate a sunset landscape" }],
  stream: false
});
console.log(response.generations);

// Streaming
const stream = await client.chat.completions.create({
  model: "eachsense/beta",
  messages: [{ role: "user", content: "Generate a sunset landscape" }],
  stream: true
});
for await (const chunk of stream) {
  const eachlabs = chunk.eachlabs;
  if (eachlabs?.type === "generation_response") {
    console.log(eachlabs.generations);
  }
}

Request Schema

{
  "messages": [{"role": "user", "content": "string (required) - User's request"}],
  "model": "string (optional, default: 'eachsense/beta')",
  "stream": "boolean (optional, default: true) - Enable SSE streaming",
  "session_id": "string (optional) - Session ID for conversation history and multi-turn chats",
  "mode": "string (optional, default: 'max') - Quality mode: 'max' or 'eco'",
  "behavior": "string (optional, default: 'agent') - Behavior: 'agent', 'plan', or 'ask'",
  "image_urls": "array[string] (optional) - Image URLs for editing/processing (max 4)",
  "workflow_id": "string (optional) - Execute specific workflow",
  "version_id": "string (optional) - Workflow version",
  "web_search": "boolean (optional, default: true) - Enable/disable web search",
  "enable_safety_checker": "boolean (optional, default: true) - Set to false to allow NSFW content generation"
}

Parameter Details

ParameterTypeDefaultDescription
messagesarrayrequiredChat messages with role and content
modelstring"eachsense/beta"Model identifier
streambooleantrueEnable SSE streaming
session_idstringnullSession ID for conversation history. Use to continue previous chats, handle clarifications, and iteratively refine outputs
modestring"max"max = best quality (premium models), eco = fastest/cheapest
behaviorstring"agent"agent = auto-execute, plan = show plan first, ask = clarify first
image_urlsarraynullURLs of images to process/edit (max 4)
workflow_idstringnullExecute a specific workflow
version_idstringnullWorkflow version, used with workflow_id
web_searchbooleantrueAllow web search for information
enable_safety_checkerbooleantrueSet to false to allow NSFW content generation

OpenAI SDK extra parameters: When using the OpenAI SDK, pass non-standard parameters via extra_body:

response = client.chat.completions.create(
    model="eachsense/beta",
    messages=[{"role": "user", "content": "Generate a quick sketch"}],
    extra_body={"mode": "eco", "session_id": "my-session"},
    stream=False
)

Non-Streaming Response

{
  "id": "chatcmpl-123",
  "object": "chat.completion",
  "choices": [{"message": {"role": "assistant", "content": "Here's your image..."}}],
  "generations": ["https://cdn.example.com/image.png"],
  "task_id": "task-456",
  "session_id": "my-session"
}

Modes

MAX Mode (Default)

Uses premium quality models (flux-2-max, veo-3, etc.). Best for final outputs, client-facing work, and when quality matters most. Processing time: 10-300 seconds.

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create a product shot"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

ECO Mode

Uses fast, cost-effective models (flux-2-pro, veo3-1-fast, etc.). Best for prototyping, drafts, and high-volume generation. Processing time: 5-180 seconds.

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create a product shot"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "eco"
  }'

Behaviors

Agent (Default)

Automatically executes the request, selecting the best model and generating output immediately.

{
  "messages": [{"role": "user", "content": "Generate a sunset video"}],
  "model": "eachsense/beta",
  "behavior": "agent"
}

Plan

Shows execution plan with time/cost estimates before executing. Good for complex requests where you want to review the approach.

{
  "messages": [{"role": "user", "content": "Create a marketing video for my bakery"}],
  "model": "eachsense/beta",
  "behavior": "plan"
}

Ask

Always asks clarifying questions before proceeding. Good when you want maximum control.

{
  "messages": [{"role": "user", "content": "Generate a portrait"}],
  "model": "eachsense/beta",
  "behavior": "ask"
}

Session Management

Use session_id to maintain conversation history and context across multiple requests. This enables:

  • Multi-turn conversations: Follow-up on previous requests without repeating context
  • Iterative refinement: Ask for modifications to previously generated content
  • Clarification flows: Respond to clarification_needed events and continue the conversation
  • Context awareness: The AI remembers previous generations, preferences, and instructions

Session Limits

MetricLimit
Idle timeout15 minutes
Session TTL30 days
Messages per session50

Sessions are scoped by API key + session_id combination. Different API keys cannot access each other's sessions.

Session Management Endpoints

# Retrieve session memory
curl https://eachsense-agent.core.eachlabs.run/memory?session_id=my-session \
  -H "X-API-Key: $EACHLABS_API_KEY"

# Clear session memory
curl -X DELETE https://eachsense-agent.core.eachlabs.run/memory?session_id=my-session \
  -H "X-API-Key: $EACHLABS_API_KEY"

# List all sessions
curl https://eachsense-agent.core.eachlabs.run/sessions \
  -H "X-API-Key: $EACHLABS_API_KEY"

Example: Iterative Generation

# First request - generate initial image
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Generate a logo for a coffee shop called Brew Lab"}],
    "model": "eachsense/beta",
    "stream": true,
    "session_id": "logo-project-001"
  }'

# Follow-up - modify the result (same session_id)
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Make it more minimalist and change the color to dark green"}],
    "model": "eachsense/beta",
    "stream": true,
    "session_id": "logo-project-001"
  }'

# Another follow-up - request variation (same session_id)
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create 3 variations of this logo"}],
    "model": "eachsense/beta",
    "stream": true,
    "session_id": "logo-project-001"
  }'

Example: Handling Clarifications

# Ambiguous request - AI will ask for clarification
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Edit this image"}],
    "model": "eachsense/beta",
    "stream": true,
    "session_id": "edit-task-001",
    "image_urls": ["https://example.com/photo.jpg"]
  }'
# Response: clarification_needed event asking what edit to make

# Respond to clarification (same session_id)
curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Remove the background and make it transparent"}],
    "model": "eachsense/beta",
    "stream": true,
    "session_id": "edit-task-001",
    "image_urls": ["https://example.com/photo.jpg"]
  }'

Use Case Examples

1. Image Generation

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Generate a professional headshot of a business executive, studio lighting"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

2. Video Generation

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create a 5 second video of a sunset over the ocean"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

3. Image Editing (with uploaded image)

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Remove the background from this image"}],
    "model": "eachsense/beta",
    "stream": true,
    "image_urls": ["https://example.com/my-photo.jpg"]
  }'

4. Image-to-Video Animation

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Animate this image with gentle camera movement"}],
    "model": "eachsense/beta",
    "stream": true,
    "image_urls": ["https://example.com/landscape.jpg"]
  }'

5. Product Photography

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Generate a product shot of a coffee mug on a wooden table with morning light"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

6. Marketing Assets

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create a social media ad for a fitness app, show someone working out with energetic vibes"}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

7. Complex Workflow (UGC Video)

curl -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create a 30 second UGC video with a consistent presenter explaining why fitness is important. The presenter is a 30-year-old fit woman with brown hair in workout clothes, gym background."}],
    "model": "eachsense/beta",
    "stream": true,
    "mode": "max"
  }'

8. Workflow Builder

curl -X POST https://eachsense-agent.core.eachlabs.run/workflow \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -d '{
    "message": "Create a workflow that generates an image and then upscales it",
    "stream": true,
    "session_id": "my-session"
  }'

SSE Response Format

The endpoint returns Server-Sent Events (SSE) wrapped in OpenAI chat.completion.chunk format with an eachlabs extension field.

Each event has the format:

data: {"id":"chatcmpl-123","object":"chat.completion.chunk","choices":[{"delta":{"content":""}}],"eachlabs":{"type":"event_type",...}}\n\n

Stream ends with:

data: [DONE]\n\n

Event Types (18 Total)

AI Reasoning:

EventDescription
thinking_deltaAI reasoning in real-time
text_responseText content (explanations, answers)

Tool Operations:

EventDescription
statusCurrent operation being executed (includes tool_name, parameters)
tool_callDetails of tool being called
messageInformational message
progressProgress update with percent

Generation:

EventDescription
generation_responseGenerated media URL (url, generations[], model, execution_time_ms)

Interaction:

EventDescription
clarification_neededAI needs more information (question, options[], context)

Web Search:

EventDescription
web_search_queryWeb search being executed
web_search_citationsCitations with title, url, snippet

Workflow:

EventDescription
workflow_createdNew workflow created
workflow_fetchedExisting workflow loaded
workflow_builtWorkflow definition constructed
workflow_updatedWorkflow pushed to API

Execution:

EventDescription
execution_startedWorkflow execution began
execution_progressStep progress (step_id, completed_steps, total_steps)
execution_completedWorkflow done (output, all_outputs, total_time_ms)

Terminal:

EventDescription
completeTask finished (status: ok/error/clarification_needed, generations[])
errorError occurred (message, error_code)

Typical Event Flow

thinking_delta → status → status → text_response → generation_response → complete → [DONE]

Key Event Examples

generation_response

{
  "type": "generation_response",
  "url": "https://storage.eachlabs.ai/outputs/abc123.png",
  "generations": ["https://storage.eachlabs.ai/outputs/abc123.png"],
  "model": "flux-2-max",
  "execution_time_ms": 8500
}

clarification_needed

{
  "type": "clarification_needed",
  "question": "What type of edit would you like to make to this image?",
  "options": ["Remove the background", "Apply a style transfer", "Upscale to higher resolution"],
  "context": "I can see your image but need to know the specific edit you want."
}

complete

{
  "type": "complete",
  "task_id": "chat_1708345678901",
  "status": "ok",
  "generations": ["https://storage.eachlabs.ai/outputs/abc123.png"],
  "model": "flux-2-max"
}

Agent Tools

ToolTypePurpose
search_modelsNon-terminalFind models by use case
get_model_detailsNon-terminalGet model input schema
web_searchNon-terminalWeb search
vision_preprocessorNon-terminalAnalyze image content
execute_modelTerminalRun model prediction
generate_textTerminalGenerate text response
create_workflowNon-terminalCreate workflow
trigger_workflowNon-terminalExecute workflow
build_workflowNon-terminalBuild workflow definition
check_executionNon-terminalCheck execution status
ask_clarificationTerminalRequest clarification

Model Quick Reference

Use CaseModel SlugSpeed
Best image qualityflux-2-maxMedium
Fast image generationflux-2-proFast
Text/logos in imagesflux-kontext-proFast
Rapid prototypingnano-banana-proVery Fast
Photorealistic imagesgemini-imagen-4Medium
Artistic/creativeseedream-v4-5Medium
Best video (with audio)veo-3Slow
Fast videoveo3-1-fastFast
High-quality videokling-3-0Medium
Image to videokling-2-1-image-to-videoMedium
Instruction editingflux-2-editFast
Background removaleachlabs-bg-remover-v1Very Fast
Image upscalingtopaz-upscale-imageFast
Face swapkling-face-swapFast
Text-to-speechelevenlabs-ttsVery Fast
Music generationmureka-generate-musicMedium

Model Aliases

Common shorthand names that are automatically resolved:

AliasResolves To
Flux Maxflux-2-max
Flux Proflux-2-pro
Flux Editflux-2-edit
Flux Fillflux-fill-pro
Flux Kontextflux-kontext-pro
Imagen 4gemini-imagen-4
Veo 3veo-3
Kling 3kling-3-0
Sorasora-2-pro
ElevenLabselevenlabs-tts

Error Handling

HTTP Errors

CodeResponseCause
401{"error": "Invalid or missing API key"}Missing or invalid API key
422{"error": "..."}Missing required fields or invalid parameters
429{"error": "..."}Rate limited - implement exponential backoff
500{"error": "..."}Internal server error - retry with backoff

Streaming Errors

{"type": "error", "message": "Failed to execute model: Invalid parameters", "error_code": "..."}
Error MessageCauseSolution
Model execution failedUnderlying model errorCheck model parameters
Session not foundInvalid or expired sessionCreate new session
Workflow execution timeoutExceeded 15 minute limitSplit into smaller workflows

Retry strategy: Use exponential backoff for 429 and 500 errors. Wait 2^attempt seconds, maximum 3 retries.

Timeouts

Client timeout recommendation: Set your HTTP client timeout to minimum 10 minutes. Complex use cases may require running multiple AI models sequentially (e.g., 10+ model executions for UGC videos).

OperationTimeout
HTTP request300 seconds
Streaming idle15 minutes
Image generation10-60 seconds
Video generation60-600 seconds
Workflow execution15 minutes
# curl example with 10 minute timeout
curl --max-time 600 -X POST https://eachsense-agent.core.eachlabs.run/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -H "Accept: text/event-stream" \
  -d '{
    "messages": [{"role": "user", "content": "Create a complex UGC video..."}],
    "model": "eachsense/beta",
    "stream": true
  }'

Rate Limits

PlanRequests/MinuteConcurrent
Free102
Pro6010
Enterprise30050

Rate limit headers: X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset

Input Validation Limits

Input TypeConstraint
Images per requestMax 4
Image formatsJPEG, PNG, WebP, GIF
Image sizeMax 20MB, 64-8192px
Video formatsMP4, WebM, MOV
Video sizeMax 500MB, 10 min
Audio formatsMP3, WAV, M4A, OGG
Audio sizeMax 50MB, 5 min
Prompt lengthMax 10,000 characters
Session memoryMax 50 messages

Best Practices

  1. Use session_id for multi-turn conversations to maintain context
  2. Use ECO mode for prototyping and cost-sensitive applications
  3. Handle clarification events - respond with requested information in the same session
  4. Provide clear prompts - be specific about style, mood, and composition
  5. Monitor SSE events - use thinking_delta for progress, generation_response for output
  6. Use OpenAI SDK for easier integration - just point to the each::sense base URL
  7. Implement retry logic - use exponential backoff for transient errors
Discovery
Tags

No tags published for this skill.

Version
Latest version metadata

Version

v2026.09.24

Published

Sep 24, 2026

Category

Uncategorized

License

Not specified

Source path

skills/each-sense

Default branch

main

Latest commit

dbd25b7

Tree SHA

8611943