✨

本地直连 Google AI,一键生成高清图像

Antigravity Image Generator · v2.0.0
入口已确认,内容待校验 文件树里有 SKILL.md,但正文还没采回,frontmatter 未核对。
专业技能 安全 A 级 作者 ipedrax 公开目录收录
12.1k 下载 20 安装 25.7k 收藏 133 浏览

简介

调用 Google Antigravity 内部 API 本地生成高质量图像,无需浏览器自动化,适合需要快速图像创作的用户。

原始描述

Generate images using the internal Google Antigravity API (Gemini 3 Pro Image). High quality, native generation without browser automation.

通过你的 Agent 添加

安装目录:antigravity-image-generator-10282/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。

点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。

或者手动安装

Claude Code~/.claude/skills/antigravity-image-generator-10282/
Codex CLI~/.codex/skills/antigravity-image-generator-10282/
DeepSeek Harness~/.agents/skills/antigravity-image-generator-10282/

包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可; 目录名不用换,也不要把包直接解压到 skills 根目录。 技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。

中文使用说明 来自收录源

核心用法

该 Skill 通过调用 daily-cloudcode-pa.sandbox.googleapis.com 端点,直接与 Google Antigravity API(Gemini 3 Pro Image)交互,实现本地命令行图像生成。用户需提供 --prompt 描述图像内容,可选 --output 指定保存路径、--aspect-ratio 设置画面比例(支持 1:1、16:9、9:16、4:3、3:4)。执行后脚本输出 MEDIA: <path> 标记,便于下游工具自动识别和展示图像。

显著优点

  • 零供应链依赖:完全基于 Node.js 内置模块(fs、https、path、buffer),无第三方 npm 包,彻底规避供应链攻击风险。
  • 原生 API 直连:绕过浏览器自动化方案,直接调用 Google 内部服务,响应更快、稳定性更高。
  • 安全合规设计:OAuth Token 从本地配置文件读取,非硬编码;全链路 HTTPS + TLS 1.2+ 加密传输;静态分析无危险函数、无混淆代码。
  • 输出标准化:自动生成 MEDIA: <path> 标记,与 Clawdbot 等工具无缝集成。

潜在缺点与局限性

  • T3 来源可信度:Skill 由个人开发者/社区维护(ClawHub Registry),非 Google 官方发布,需自行评估维护者信誉和代码变更。
  • OAuth 配置门槛:依赖本地 ~/.openclaw/agents/main/agent/auth-profiles.json 中的有效凭证,配置复杂且 Token 过期需手动刷新。
  • 配额与限流:存在 429 Resource Exhausted 风险,高频使用需关注 Google Cloud 项目配额。
  • 输出路径风险:虽使用 path.join,但未显式验证用户输入的 --output 路径,极端场景下存在目录遍历可能。
  • 内容安全审查:API 可能因安全策略拒绝特定提示词(prompt),返回 "No image data found" 而非明确错误信息。

适合人群

  • 已配置 Google Antigravity OAuth 凭证的开发者或高级用户
  • 追求零依赖、供应链安全优先的技术团队
  • 需要批量/自动化图像生成、集成到 CI/CD 或本地工作流的场景
  • 对浏览器自动化方案性能或稳定性不满意的用户

常规风险

风险类型 说明 缓解建议
凭证泄露 本地 OAuth Token 被其他进程读取 设置文件权限 600,定期轮换 Token
API 滥用 Token 被盗用后产生异常调用 监控 Google Cloud 日志,启用配额告警
内容合规 生成图像可能触发平台审核 遵守 Google 使用政策,避免敏感提示词
依赖漂移 未来版本可能引入外部依赖 升级前审查 package.json,锁定版本
服务变更 Google 内部 API 接口可能调整 关注上游更新,准备回退方案

技能正文


name: antigravity-image-gen description: Generate images using the internal Google Antigravity API (Gemini 3 Pro Image). High quality, native generation without browser automation. read_when:

  • User asks to generate an image
  • User wants to create visual content metadata: {"clawdbot":{"emoji":"🎨","requires":{"bins":["node"],"config":["auth.profiles"]},"description":"Generates images via internal Google API using local OAuth credentials."}}

Antigravity Image Generation

Generate high-quality images using the internal Google Antigravity API (Gemini 3 Pro Image). This skill bypasses the need for browser automation by using the daily-cloudcode-pa.sandbox endpoint directly with your OAuth credentials.

Prerequisites

  • Google Antigravity OAuth Profile: Must be present in your OpenClaw auth-profiles.json.
  • Node.js: Available in the environment.
  • Security Note: This skill reads local OAuth tokens from your profile to authenticate with Google's API. This is expected behavior for internal tool use.

Usage

Direct Script Execution

/home/ubuntu/clawd/skills/antigravity-image-gen/scripts/generate.js \
  --prompt "A futuristic city on Mars" \
  --output "/tmp/mars.png" \
  --aspect-ratio "16:9"

Arguments

  • --prompt (Required): The description of the image.
  • --output (Optional): Path to save the image (default: /tmp/antigravity_<ts>.png).
  • --aspect-ratio (Optional): 1:1 (default), 16:9, 9:16, 4:3, 3:4.

Output

  • The script writes the image to the specified path.
  • It prints MEDIA: <path> to stdout, which allows Clawdbot to automatically detect and display the image.

Troubleshooting

  • 429 Resource Exhausted: Quota limit reached. Wait or check your project limits.
  • No image data found: The model might have refused the prompt (safety) or the API structure changed. Check the "Model message" output.
  • Auth Error: Ensure you have logged in via google-antigravity provider.

正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。

标签

image-generationgoogle-apiai-artgeminioauthinternal-apicreative-toolsmedia-generation

同类 Skill