Skip to content

KlingTeam/kling-waic-express

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Kling WAIC Event Equipment Setup Guide

This project was originally designed for the World Artificial Intelligence Conference (WAIC 2025) in Shanghai and has since been expanded to support multiple events (Kuaishou 2025 Creator Conference, Kuaishou Campus Recruitment).

The project is now open source, allowing anyone to build their own events based on this project. It provides comprehensive documentation for Kling WAIC event equipment, including event gameplay, management backend, pages and programs used, on-site equipment requirements, connection methods, printer configuration, and troubleshooting.

Table of Contents

  1. Event Gameplay
  2. Management Backend
  3. Page Routes
  4. Program Components
  5. On-site Equipment
  6. Screen Connection
  7. Printer Configuration
  8. Troubleshooting
  9. Project Setup

1. Event Gameplay

1.1 Restyle Collage

Process Flow:

  1. Users scan QR code to access upload page (URL: /qr/image)
  2. Upload portrait photo
  3. Click "Generate Now", restyled 9-grid image generated in ~30 seconds
  4. Users can choose to:
    • Long press to save image
    • Print image (on-site printer automatically prints, queue by number to collect)
  5. Generated images are displayed on screen carousel (URL: /screen/image)

Interface Screenshots:

QR Entry Upload Photo Photo Preview
KlingAI-image-RestyleCollage.png KlingAI-image-UploadPhoto.jpeg KlingAI-image-UploadedPhoto.jpeg
Generating Generated Result Screen Display
KlingAI-image-Generating.jpeg KlingAI-image-Generated.jpeg KlingAI-image-ScreenImage.png

1.2 Effect Mystery Box

Process Flow:

  1. Users scan QR code to access upload page (URL: /qr/video)
  2. Upload portrait photo
  3. Click "Generate Now", effect mystery box video generated in ~3 minutes
  4. Users can download video file in browser
  5. Generated videos are displayed on screen carousel (URL: /screen/video)

Interface Screenshots:

QR Entry Upload Photo Photo Preview
KlingAI-video-EffectBox.png KlingAI-video-UploadPhoto.jpeg KlingAI-video-UploadedPhoto.jpeg
Generating Generated Result Screen Display
KlingAI-video-Generating.jpeg KlingAI-video-Generated.jpeg KlingAI-video-ScreenVideo.png

2. Management Backend

Access URL: /admin

After login, you can switch activities (enter activity name and password), includes four functional modules:

2.1 Image Management

  • Function: Display all generated images, supports search by number
  • Operations:
    • πŸ–¨οΈ Print
    • πŸ“Œ Pin/Unpin (for screen group photos)
    • πŸ—‘οΈ Delete (remove from screen display)

KlingAI-admin-Image.png

2.2 Video Management

  • Function: Display all generated videos, supports search by number
  • Operations:
    • πŸ—‘οΈ Delete (remove from screen display)

KlingAI-admin-Video.png

2.3 Print Queue

  • Function: Display pending print tasks
  • Note: If tasks accumulate, printer may be malfunctioning

KlingAI-admin-Printing.png

2.4 System Configuration

  • Function: Modify system configuration (save to take effect)
  • Configuration Items:
    • βœ… Allow printing
    • πŸ”„ Image/video service switches
    • ⏰ Token validity time
    • πŸ“Š Printer task limit
    • πŸ“ Screen aspect ratio settings

KlingAI-admin-Config.png

Parameter Description:

API_SERVER_BASE_URL=                    # API service address
WAIC_MANAGEMENT_ACTIVITY=               # Activity name
WAIC_MANAGEMENT_TOKEN=                  # Activity password
PRINTER_PRINTING_MODE=PDF_BATCH         # Print mode: PDF_BATCH (batch, fast with borders) / EACH_ONE (single, slow without borders)
PRINTER_EXTRA_SCALE_FACTOR=1.00         # Print scale factor
DRAW_IMAGE_X=5.0                        # Print offset X (positive moves right after 90Β° rotation)
DRAW_IMAGE_Y=5.0                        # Print offset Y (positive moves up after 90Β° rotation)

πŸ’‘ Tip: To eliminate border issues, try adjusting the last three parameters


3. Page Routes

Function Route Description
πŸ”— QR - Restyle Collage /qr/image User QR code photo upload entry
πŸ”— QR - Effect Mystery Box /qr/video User QR code photo upload entry
πŸ“Ί Screen - Restyle Collage /screen/image Image carousel display page
πŸ“Ί Screen - Effect Mystery Box /screen/video Video carousel display page
βš™οΈ Management Backend /admin System management interface

4. Program Components

  • Printer Program
    • πŸ“¦ Packaged MacBook application provided
    • πŸ’» Or run from source code (requires Java17 + Maven3)

5. On-site Equipment

5.1 Equipment List

Equipment Type Quantity Model/Spec Purpose
πŸ–¨οΈ Printer 2 units DNP DS-620 Photo printing
πŸ“„ Photo Paper Several boxes 2 rolls + 2 ribbons per box, 400 sheets per roll Printing supplies
πŸ“± iPad 2 units - Display QR code entries
πŸ“Ί Large Screen 2 units Recommended 100 inches Display restyle collage/effect mystery box
πŸ’» MacBook 3 units - 2 for screens, 1 for printer
πŸͺ§ Promotional Banners 2 units - Event promotion
πŸ–ΌοΈ Photo Wall 1 unit - Display unclaimed photos

5.2 Network Equipment

Option 1: Wireless Network

  • 5G CPE + Wireless Router

Option 2: Wired Network

  • Downstream bandwidth: 200M+
  • Switch + 5 network cables

5.3 Accessories

  • 5 Type-C adapters (supporting HDMI, Ethernet, charging, USB printer connection)

5.4 Equipment Connection Diagram

KlingAI-image-Equipments.png


6. Screen Connection

6.1 Browser Settings

  • Recommended Browser: Chrome
  • Display Mode: Full-screen playback

6.2 Toolbar Handling

If toolbar obstruction occurs:

  1. Go to "View" menu
  2. Uncheck "Always Show Toolbar in Full Screen"

6.3 Display Configuration

  • MacBook external screen requires extended display setup
  • Adjust rotation angle: 90Β° or 270Β°

7. Printer Configuration

7.1 System Requirements

  • Device: MacBook Apple Silicon
  • Driver: DNP DP-DS620 printer driver

7.2 Installation Steps

  1. Download Driver

  2. Connect Device

    • Connect printer to MacBook via USB
    • Open "System Preferences" β†’ "Printers & Scanners"
    • Add printer
  3. Install Program

    • Download and extract Printer Program
    • Move to "Applications" folder
    • Or run from source code (requires Java17 + Maven3), please research on your own
  4. Configure Parameters

    • Open KlingExpressPrinter program
    • Fill in corresponding parameters to start printing

Kling-printing-Settings.png


8. Troubleshooting

Issue Solution
πŸ”„ Error persists after paper change Replace with different paper roll
πŸ–¨οΈ Printer not responding Delete and re-add printer
πŸ“Ί Screen playback stuttering Use M3 Pro chip MacBook, maintain 200M+ network, use Chrome
πŸ’» Windows compatibility Driver available, but program only tested on Mac
⏸️ Print queue accumulation Check if "Print Center" is paused, manually resume
πŸ“„ Blank photo paper Reinstall driver/check paper compatibility
🚦 High concurrency queue buildup Recommend ≀ 4-5 people submit tasks simultaneously
πŸ“€ Image upload failure Have users re-save image before uploading
πŸ”„ Image orientation error Have users re-save image before uploading

9. Project Setup

9.1 Prerequisites

  1. Register Kling Open Platform Account

  2. Get API Keys

    • Enable API Key and top up
    • Obtain Access Key and Secret Key

9.2 Docker Compose Deployment (Recommended)

Step 1: Create Project Directory

cd ~
mkdir kling-express
cd kling-express

Step 2: Configuration Files

Create .env file:

API_SERVER_BASE_URL=https://api.yourdomain.com  # Your API service address
WAIC_OPENAPI_ACCESS_KEY=AK_MinioXXXXXX          # S3 API Access Key
WAIC_OPENAPI_SECRET_KEY=SK_MinioXXXXXX          # S3 API Secret Key

Create redis.conf file:

requirepass your_redis_password  # Redis password
tcp-keepalive 60

Create application-env.properties file:

# Redis Configuration
REDIS_HOST_WAIC=172.17.0.1
REDIS_PORT_WAIC=6379
REDIS_PASSWORD_WAIC=your_redis_password
REDIS_CLUSTER_MODE_WAIC=false
REDISSON_PROTOCOL=redis

# S3 Configuration
S3_PATH_STYLE_ENABLED=true
S3_ENDPOINT=https://minio.yourdomain.com
S3_REGION=cn-north-1
S3_ACCESS_KEY=AK_MinioXXXXXXXXX
S3_SECRET_KEY=SK_MinioXXXXXXXXX

# Kling API Configuration
KLING_OPEN_BASE_URL=https://api-singapore.klingai.com  # Global address

# Activity Configuration
config.activity.map[default].token=your_activity_password
config.activity.map[default].accessKey=AK_KlingAIXXXXXX
config.activity.map[default].secretKey=SK_KlingAIXXXXXX

# Multiple activity configuration example
# config.activity.map[test].token=your_activity_password
# config.activity.map[test].accessKey=AK_KlingAIYYYYYY
# config.activity.map[test].secretKey=SK_KlingAIYYYYYY

Step 3: Start Services

Place the project's docker-compose.yml file in the directory, then start:

  • Note: Both kling-express-web and kling-express-api images only support arm64 architecture. For x86_64 architecture, please build images yourself.
  • Or instead of Docker Compose, run web and api services directly from source code, please research on your own.
docker-compose up -d

9.3 Existing Infrastructure Deployment

If you already have Redis and S3 services (e.g., AWS EC2 environment), use simplified configuration:

docker-compose.yml:

services:
  web:
    image: akang943578/kling-express-web:latest
    ports:
      - "3000:80"
    environment:
      - API_SERVER_BASE_URL=${API_SERVER_BASE_URL}
    restart: always
    container_name: kling-express-web
    depends_on:
      - api

  api:
    image: akang943578/kling-express-api:latest
    ports:
      - "8738:8538"
    volumes:
      - ./application-env.properties:/app/application-env.properties
      - ./api_logs:/app/logs
    restart: always
    container_name: kling-express-api

application-env.properties:

REDIS_CLUSTER_MODE_WAIC=true
REDIS_HOST_WAIC=your_redis_host
REDIS_PORT_WAIC=6379
REDISSON_PROTOCOL=rediss

KLING_OPEN_BASE_URL=https://api-beijing.klingai.com
S3_FILE_PREFIX=  # S3 file prefix or CDN address

config.activity.map[default].token=your_activity_password
config.activity.map[default].accessKey=AK_KlingAIXXXXXX
config.activity.map[default].secretKey=SK_KlingAIXXXXXX

9.4 Build Assets

If you need to build project assets yourself, use the following commands:

Docker Image Building

Build Web Image:

cd web
sh build_image.sh

Build API Image:

cd server
sh build_api_image.sh

Printer Program Building

Build KlingExpressPrinter Mac Application:

cd server/printer
sh create_app_bundled.sh

9.5 Security Recommendations

πŸ”’ HTTPS Recommended to ensure privacy and security of user uploaded images and videos:

  • Use Cloudflare free CDN and SSL services
  • Or use Nginx reverse proxy + Let's Encrypt free certificates

9.6 Custom Configuration

Customize styles and effects by mounting custom configuration files:

api:
  image: akang943578/kling-express-api:latest
  volumes:
    - ./style-image-prompts.txt:/app/style-image-prompts.txt      # Custom style image prompts
    - ./video-special-effects.txt:/app/video-special-effects.txt  # Custom video effects

πŸ“š Configuration Format: Please refer to Kling API Open Platform documentation

9.7 Development Roadmap

TODO:

  • Multi-language interface support
  • Dark mode interface adaptation
  • Interface theme configuration guide

About

This is the program for supporting KlingAI Express in WAIC 2025.

Resources

License

Stars

Watchers

Forks

Packages

No packages published