Bỏ qua tới nội dung
TakoAPI
Quay lại kỹ năng

color-palette

bởi qrost

Image & Video Generation
616Lượt tải do clawskills.sh công bố
1Sao
0Lượt xem
0 lượt thíchĐăng nhập để thích kỹ năng này
—Chưa có đánh giá
Đánh giá của bạn

Tóm tắt

Extract a color palette from an image and return HEX/RGB values with optional swatch image.

Mô tả

Kỹ năng này làm gì

Extracts dominant colors from an image file and returns HEX and RGB values per color. Supports up to 20 colors per extraction. Can optionally generate a swatch PNG showing the palette.

Returns both HEX and RGB values alongside an optional visual swatch in one step, removing the need to open an image editor just to pick colors.

Khi nào nên dùng

  • Pulling hex codes from a brand photo for a design project
  • Building a color mood board from a reference image
  • Matching CSS colors to tones found in a screenshot
  • Identifying dominant colors in product photos for an e-commerce listing
  • Generating a palette swatch from a painting or artwork

Quy trình ví dụ

ĐẦU VÀO

User asks: Extract 5 colors from this photo and show me the palette

AGENT
  1. 1

    Save the attached image to a temp path

  2. 2

    Run extract_palette.py with -n 5 and --output /tmp/palette.png

  3. 3

    Read the HEX/RGB values from the script output

  4. 4

    Send the swatch PNG and color list back to the user

ĐẦU RA

Five color entries (e.g. #2A4B7C RGB(42, 75, 124)) and a swatch PNG displayed in the conversation

Yêu cầu

  • Pillow Python package (pip install Pillow)
  • colorgram.py Python package for improved color extraction, optional (pip install colorgram.py)
  • matplotlib Python package for swatch image output, optional (pip install matplotlib)

Cài đặt

clawhub install qrost/color-palette

Chạy lệnh CLI, hoặc dán prompt vào Claude Code, Cursor, Codex hay coding agent bạn đang dùng.

Liên kết