Token导航 LogoToken导航TokenDH.com
开发需要联网github未标认证来源可访问许可证需确认审计提醒

gemini-watermarkGemini watermark 命令行

Agent Skill

gemini-watermark 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

245

周安装

10

GitHub Stars

4

下载量

79
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:gemini-watermark(Gemini watermark 命令行)
来源仓库:https://github.com/agiseek/agent-skills
仓库路径:skills/gemini-watermark
安装命令:
npx skills add https://github.com/agiseek/agent-skills --skill gemini-watermark
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/agiseek/agent-skills --skill gemini-watermark

简介

Gemini watermark remover 技能可离线移除 Gemini AI 生成图像中的可见水印标识。

  • 适用于批量清理 AI 生成图片、准备发布素材或集成到自动化图像处理流水线中。
  • 纯 Python 实现,无需外部依赖或网络连接,支持精确反向 alpha 混合算法。
  • 使用前需确认输入图像格式与尺寸兼容性,避免误处理非 Gemini 生成内容或触发版权争议。
  • gemini-watermark 属于开发类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Gemini Watermark Remover

Remove the visible Gemini AI watermark (star/sparkle logo) from generated images using mathematically accurate reverse alpha blending.

Fully offline — pure Python, no external binary downloads, no network access.

When to Use

  • Remove the Gemini watermark from AI-generated images
  • Batch process a directory of Gemini-generated images
  • Clean images before publishing or sharing
  • Automate watermark removal in pipelines

Quick Start

Install Dependencies (one-time)

pip install Pillow numpy

# Recommended: use uv for faster, isolated installs
uv pip install Pillow numpy

Requires: Python ≥ 3.9. No Rust toolchain, no compiled binaries, no downloads.

Basic Usage

# Single image (auto-detect watermark, save as photo_cleaned.jpg)
python3 scripts/remove_watermark.py photo.jpg

# Specify output path
python3 scripts/remove_watermark.py photo.jpg -o clean_photo.jpg

# Batch process directory
python3 scripts/remove_watermark.py ./input_dir -o ./output_dir

# Force removal without detection
python3 scripts/remove_watermark.py photo.jpg -o clean.jpg --force

How It Works

Gemini adds a semi-transparent white star/sparkle logo to generated images using alpha blending:

watermarked = alpha * 255 + (1 - alpha) * original

This tool reverses the equation to recover the original pixels:

original = (watermarked - alpha * 255) / (1 - alpha)

The alpha map (watermark transparency pattern) is generated mathematically as a 4-pointed star (central Gaussian core + 4 elongated cardinal rays) at two sizes:

  • 48×48 with 32 px margin — images where either dimension ≤ 1024 px
  • 96×96 with 64 px margin — images where both dimensions > 1024 px

For improved accuracy you can supply your own alpha map derived from a background capture of the Gemini watermark on a white background (--alpha-map).

Detection

Before removal, a three-stage algorithm checks whether a watermark is present:

  1. Spatial NCC (50% weight) — normalised cross-correlation with the alpha map
  2. Gradient NCC (30% weight) — edge signature matching via Sobel operators
  3. Variance Analysis (20% weight) — texture dampening detection

Images without detected watermarks are automatically skipped.

CLI Parameters

ParameterShortDefaultDescription
input(required)Input image file or directory
--output-o{name}_cleaned.{ext}Output file or directory
--force-ffalseSkip detection, process unconditionally
--threshold-t0.35Detection confidence threshold (0.0–1.0)
--force-smallfalseForce 48×48 watermark size
--force-largefalseForce 96×96 watermark size
--alpha-map(built-in)Custom grayscale alpha map image
--verbose-vfalseEnable detailed output
--quiet-qfalseSuppress all non-error output

Supported Formats

FormatReadWrite
JPEG (.jpg,.jpeg)YesYes (quality 100)
PNG (.png)YesYes
WebP (.webp)YesYes
BMP (.bmp)YesYes

Usage Examples

# Verbose output (shows detection confidence, watermark coordinates)
python3 scripts/remove_watermark.py photo.png -o clean.png -v

# Lower detection threshold (more sensitive)
python3 scripts/remove_watermark.py photo.jpg -t 0.15

# Force large watermark size regardless of image dimensions
python3 scripts/remove_watermark.py photo.jpg --force-large -o clean.jpg

# Batch process, quiet mode
python3 scripts/remove_watermark.py ./gemini_images/ -o ./cleaned/ -q

# Supply a custom alpha map for higher accuracy
python3 scripts/remove_watermark.py photo.jpg --alpha-map my_alpha.png

Deriving a Custom Alpha Map

For pixel-perfect removal, capture the Gemini watermark on a pure white background and compute:

alpha(x, y) = max(R, G, B) / 255

Save the result as a grayscale PNG and pass it via --alpha-map.

Output

  • Single file — saves to -o path, or {name}_cleaned.{ext} by default
  • Directory — saves all processed images to the output directory
  • Skipped images — images without detected watermarks are not modified (unless --force)
  • Exit code — 0 on success, 1 if any image fails

Troubleshooting

"No watermark detected" on a watermarked image

  • Try lowering the threshold: -t 0.1
  • Or bypass detection entirely: --force
  • Consider supplying a custom alpha map for your watermark variant

Image looks distorted after removal

  • The image may not have a Gemini watermark. Use detection (avoid --force)
  • Try --force-small or --force-large to match the correct size
  • Supply a custom alpha map for better precision

"Image too small" warning

The image dimensions are smaller than the watermark region. This typically means the image does not have a Gemini watermark.

ModuleNotFoundError: Pillow or numpy

pip install Pillow numpy
# or
uv pip install Pillow numpy

Limitations

  • Visible watermark only — this tool removes the visible star/sparkle logo watermark
  • Cannot remove SynthID — Google's invisible watermark (SynthID) is embedded at the pixel level during generation and cannot be reversed
  • Fixed position only — handles watermarks in the standard bottom-right position only
  • Built-in alpha map is approximate — use --alpha-map with a captured reference for exact results

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

35.61%
按下载量换算28

Claude

31.73%
按下载量换算25

Cursor

18.62%
按下载量换算15

Gemini CLI

8.12%
按下载量换算6

安全审计

Gen Agent Trust Hub

可疑

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills