SuperAPI AI 工具集

nano-banana

编程与开发

查看项目

更新于 10-15 21:39

技能介绍

用途:根据用户需求生成演示幻灯片(PPT)图像,以及论文、文档所需的高质量图表、架构图或概念插图。不适用于撰写学术论文或规划学术演讲叙事结构。

主要能力:分阶段工作流——内容规划对话、生成 slides_plan.json、选择风格并批量生成幻灯片、启动浏览器审阅服务器、按反馈逐页编辑、打包为 PPTX、清理。提供三种风格模板(Lineal Color、Gradient Glass、Vector Illustration)和三种模型(gemini-3-pro-image-preview、gemini-3.1-flash-image-preview、gemini-2.5-flash-image),支持 2K/4K 分辨率与并行生成。

使用方式:先安装依赖 pip install pillow google-genai python-pptx python-dotenv,并确认 GOOGLE_API_KEY 可用(可通过 EvoSci config set google_api_key <key> 设置或经 --api-key 传入)。生成命令:python scripts/generate_ppt.py --plan slides_plan.json --style styles/lineal-color.md --model gemini-3.1-flash-image-preview --output ppt_output。审阅:python scripts/serve_viewer.py --dir ppt_output --plan slides_plan.json --port 8080 --pid-file .viewer.pid。编辑:python scripts/edit_slide.py --input ppt_output/images/slide-{NUMBER}.png --instruction "{FEEDBACK_TEXT}" --output ppt_output/images/slide-{NUMBER}.png --model gemini-3.1-flash-image-preview。打包:python scripts/package_pptx.py --dir ppt_output/images --output presentation.pptx --kill-server .viewer.pid。

限制与注意:content 字段中不要写 Slogan、Visual、Points 等元标签,否则会渲染为可见文字;不要自行读取生成的 PNG 检查质量,应通过审阅服务器由用户反馈;每页只放一个观点,超过 4 个要点应拆分;草稿用 flash 模型,最终版再换 pro 模型;编辑优先于重新生成以保持视觉一致性。生成脚本退出码 0 表示全部成功,2 表示部分失败(stderr 会列出缺失页码),1 表示未生成任何幻灯片。其余细节资料未提供。