Rechercher

PythonReactSEOPDF
OpenClaw

grok-imagine-video

xAI Grok Imagine API integration for image generation, text-to-video, image-to-video, and editing via natural language. Use when you need to generate images or videos from text prompts, edit existing images, animate static images into videos, or edit existing videos with natural language instructions. Supports conversational generation across messaging platforms with async polling, progress updates, and automatic delivery.

devvgwardo0 installations selon la source☆ 0 Étoiles du dépôt

Installation

Suivez les instructions du dépôt pour votre agent. Consultez les fichiers et dépendances avant l’installation.

SkillHub CLI

skillhub install devvgwardo/grok-imagine-video

Examinez la source et la compatibilité, puis suivez les étapes d’installation.

Donnez le lien à votre agent et demandez-lui d’examiner instructions et dépendances avant d’expliquer les étapes.

Voir la source ↗Guides

Instructions

Grok Imagine Video

Generate videos using xAI's Grok Imagine API directly from your messaging interface.

Setup

Important: You need your own xAI API key. Get it from https://console.x.ai/

For full installation instructions, see README.md

Quick setup:

# Set your xAI API key (YOUR key, not pre-configured)
export XAI_API_KEY="your-api-key-here"

Capabilities

  • Text-to-image: Generate images from text descriptions (up to 10 variations)
  • Image editing: Modify images using natural language
  • Text-to-video: Create videos from text descriptions
  • Image-to-video: Animate static images into motion
  • Video editing: Modify videos using natural language
  • Async generation: Handles long-running video jobs with polling
  • Auto-delivery: Downloads and delivers images/videos via chat

Workflow

1. Image Generation

User says: "Create an image of a cyberpunk cityscape at night"

python3 - << 'EOF'
import os
import sys
sys.path.insert(0, 'scripts')
from grok_video_api import GrokImagineVideoClient

client = GrokImagineVideoClient(os.getenv("XAI_API_KEY"))
result = client.generate_image("A cyberpunk cityscape at night, neon lights reflecting on wet streets")
print(f"Image URL: {result}")
EOF

Images are generated instantly (no polling needed). Download promptly as URLs are temporary.

1b. Image Editing

User says: "Edit this image — make it look like a watercolor"

python3 - << 'EOF'
import os
import sys
sys.path.insert(0, 'scripts')
from grok_video_api import GrokImagineVideoClient

client = GrokImagineVideoClient(os.getenv("XAI_API_KEY"))
result = client.edit_image(
    image_url="https://example.com/photo.jpg",
    prompt="Make it look like a watercolor painting"
)
print(f"Edited image: {result}")
EOF
2. Text-to-Video

User says: "Generate a video of a sunset over the ocean"

# Use the Python client
python3 - << 'EOF'
import os
import sys
sys.path.insert(0, 'scripts')...

Informations sur la source

Source
github
Repository
openclaw/skills
Path
skills/devvgwardo/grok-imagine-video
Version
—
Commit
9c7da9016372aa2d5dfd5f42fcf77dc2882c3fd6
Source de classification
rules
Statut
active
Visibilité
public

Ces informations proviennent de l’analyse indexée et peuvent être anciennes. Vérifiez les fichiers actuels.

README

Grok Imagine Video & Image

GitHub stars License: MIT

A Python client and OpenClaw skill for generating images and videos using xAI's Grok Imagine APIs.

Features

  • Text-to-Image — Generate images from text (up to 10 variations)
  • Image Editing — Edit images with natural language instructions
  • Text-to-Video — Generate video clips from text descriptions
  • Image-to-Video — Animate static images into motion video
  • Video Editing — Apply filters, speed changes, color grading, and effects
  • Async Polling — Non-blocking job management with progress callbacks
  • OpenClaw Integration — Drop-in skill for Discord, Telegram, and WhatsApp bots

Quick Start

  1. Get an API key at console.x.ai

  2. Set your key

    export XAI_API_KEY="your-key-here"
    
  3. Run it

    from scripts.grok_video_api import GrokImagineVideoClient
    
    client = GrokImagineVideoClient(api_key="your-key")
    
    # Generate a video
    result = client.text_to_video("A golden retriever running through a sunny meadow", duration=10)
    final = client.wait_for_completion(result["request_id"])
    client.download_video(final, "output.mp4")
    

Usage

Image Generation
result = client.generate_image(
    prompt="A collage of London landmarks in a stenciled street-art style",
    n=4,                       # 1-10 variations
    aspect_ratio="16:9",
    response_format="b64_json" # or "url" (default)
)
Image Editing
result = client.edit_image(
    image_url="https://example.com/photo.jpg",
    prompt="Change the sky to a dramatic sunset"
)
Text-to-Video
result = client.text_to_vi...

Contenu extrait

SKILL.md
# Grok Imagine Video

Generate videos using xAI's Grok Imagine API directly from your messaging interface.

## Setup

**Important:** You need your own xAI API key. Get it from https://console.x.ai/

For full installation instructions, see [README.md](README.md)

Quick setup:
```bash
# Set your xAI API key (YOUR key, not pre-configured)
export XAI_API_KEY="your-api-key-here"
```

## Capabilities

- **Text-to-image**: Generate images from text descriptions (up to 10 variations)
- **Image editing**: Modify images using natural language
- **Text-to-video**: Create videos from text descriptions
- **Image-to-video**: Animate static images into motion
- **Video editing**: Modify videos using natural language
- **Async generation**: Handles long-running video jobs with polling
- **Auto-delivery**: Downloads and delivers images/videos via chat

## Workflow

### 1. Image Generation

User says: "Create an image of a cyberpunk cityscape at night"

```bash
python3 - << 'EOF'
import os
import sys
sys.path.insert(0, 'scripts')
from grok_video_api import GrokImagineVideoClient

client = GrokImagineVideoClient(os.getenv("XAI_API_KEY"))
result = client.generate_image("A cyberpunk cityscape at night, neon lights reflecting on wet streets")
print(f"Image URL: {result}")
EOF
```

Images are generated instantly (no polling needed). Download promptly as URLs are temporary.

### 1b. Image Editing

User says: "Edit this image — make it look like a watercolor"

```bash
python3 - << 'EOF'
import os
import sys
sys.path.insert(0, 'scripts')
from grok_video_api import GrokImagineVideoClient

client = GrokImagineVideoClient(os.getenv("XAI_API_KEY"))
result = client.edit_image(
    image_url="https://example.com/photo.jpg",
    prompt="Make it look like a watercolor painting"
)
print(f"Edited image: {result}")
EOF
```

### 2. Text-to-Video

User says: "Generate a video of a sunset over the ocean"

```bash
# Use the Python client
python3 - << 'EOF'
import os
import sys
sys.path.insert(0, 'scripts')...
README
# Grok Imagine Video & Image

[![GitHub stars](https://img.shields.io/github/stars/DevvGwardo/grok-imagine-video?style=flat&logo=github)](https://github.com/DevvGwardo/grok-imagine-video)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)

A Python client and [OpenClaw](https://docs.openclaw.ai) skill for generating images and videos using [xAI's Grok Imagine APIs](https://docs.x.ai/developers/model-capabilities).

## Features

- **Text-to-Image** — Generate images from text (up to 10 variations)
- **Image Editing** — Edit images with natural language instructions
- **Text-to-Video** — Generate video clips from text descriptions
- **Image-to-Video** — Animate static images into motion video
- **Video Editing** — Apply filters, speed changes, color grading, and effects
- **Async Polling** — Non-blocking job management with progress callbacks
- **OpenClaw Integration** — Drop-in skill for Discord, Telegram, and WhatsApp bots

## Quick Start

1. **Get an API key** at [console.x.ai](https://console.x.ai/)

2. **Set your key**
   ```bash
   export XAI_API_KEY="your-key-here"
   ```

3. **Run it**
   ```python
   from scripts.grok_video_api import GrokImagineVideoClient

   client = GrokImagineVideoClient(api_key="your-key")

   # Generate a video
   result = client.text_to_video("A golden retriever running through a sunny meadow", duration=10)
   final = client.wait_for_completion(result["request_id"])
   client.download_video(final, "output.mp4")
   ```

## Usage

### Image Generation

```python
result = client.generate_image(
    prompt="A collage of London landmarks in a stenciled street-art style",
    n=4,                       # 1-10 variations
    aspect_ratio="16:9",
    response_format="b64_json" # or "url" (default)
)
```

### Image Editing

```python
result = client.edit_image(
    image_url="https://example.com/photo.jpg",
    prompt="Change the sky to a dramatic sunset"
)
```

### Text-to-Video

```python
result = client.text_to_vi...

Skills associés

OpenClaw

laborany

laborany

基于 Claude Code 的桌面 AI 工作力平台 — 支持飞书/QQ 远程调度、技能创建、定时任务。OpenClaw 的桌面实现,零代码养好你的 AI 🦞 Desktop AI workforce platform built on Claude Code. Feishu/QQ bot integration, skill c...

OpenClaw

bambu-studio-ai

heyixuan2

Bambu Lab 3D printer control and automation. Activate when user mentions: printer status, 3D printing, slice, analyze model, generate 3D, AMS filament, print monitor, Bambu Lab, or any 3D printing task. Full pi...