跳到正文
TakoAPI
返回技能列表

materials-cli

由 cai-zhuo 提供

DevOps & Cloud
573下载量由 clawskills.sh 提供
0浏览量
0 个赞登录后即可为这个技能点赞
—暂无评分
你的评分

简介

Render JSON schemas to images and generate schemas from prompts using declare-render and AI.

描述

该技能的功能

Materials CLI renders JSON schemas to PNG or JPG images, validates schemas against the declare-render format, and generates schemas from natural-language prompts using OpenAI. It exposes three subcommands: render, generate, and validate.

Combines schema validation, AI-driven schema generation, and image rendering in one CLI, avoiding the need to wire together separate utilities.

何时使用

  • Render a JSON layout schema to a PNG for design review
  • Generate an image from a text description using OpenAI
  • Validate a declare-render schema before passing it to a pipeline
  • Export layered JSON compositions to JPG files
  • Prototype visual layouts from natural language without writing schema by hand

示例工作流

输入

User asks: Generate an image of a blue rectangle with the text 'Hello World' and save it as hello.png

智能体
  1. 1

    Run materials generate "A blue rectangle with text Hello World" -o hello.png

  2. 2

    CLI sends the prompt to OpenAI, which returns a declare-render JSON schema

  3. 3

    Schema is validated against the declare-render format

  4. 4

    CLI renders the schema layers to hello.png

输出

hello.png written to disk containing the rendered blue rectangle with 'Hello World' text

前置要求

  • OPENAI_API_KEY environment variable, obtained from an OpenAI account

安装

clawhub install cai-zhuo/materials-cli

运行 CLI 命令,或把这段提示词粘贴到 Claude Code、Cursor、Codex 或你在用的任意编程智能体里。

链接