PPT生成与修改

v1.0.0

Generate and edit PowerPoint files with python-pptx, including slide creation, text replacement, and image replacement while preserving layout. Use when the...

2· 69·0 current·0 all-time

Install

OpenClaw Prompt Flow

Install with OpenClaw

Best for remote or guided setup. Copy the exact prompt, then paste it into OpenClaw for zicheng354-tech/ppt-generate-and-edit.

Previewing Install & Setup.
Prompt PreviewInstall & Setup
Install the skill "PPT生成与修改" (zicheng354-tech/ppt-generate-and-edit) from ClawHub.
Skill page: https://clawhub.ai/zicheng354-tech/ppt-generate-and-edit
Keep the work scoped to this skill only.
After install, inspect the skill metadata and help me finish setup.
Use only the metadata you can verify from ClawHub; do not invent missing requirements.
Ask before making any broader environment changes.

Command Line

CLI Commands

Use the direct CLI path if you want to install manually and keep every step visible.

OpenClaw CLI

Bare skill slug

openclaw skills install ppt-generate-and-edit

ClawHub CLI

Package manager switcher

npx clawhub@latest install ppt-generate-and-edit
Security Scan
Capability signals
CryptoCan make purchases
These labels describe what authority the skill may exercise. They are separate from suspicious or malicious moderation verdicts.
VirusTotalVirusTotal
Pending
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description (PPT generation & editing) match the code and SKILL.md. The modules implement create_ppt, update_ppt, image generation (mock), and utilities. Required dependencies (python-pptx in requirements.txt) are appropriate for manipulating PPTX files.
Instruction Scope
SKILL.md and public APIs only describe creating/updating PPTs, and the code follows that: text replacement, image replacement preserving layout, and returning output paths and logs. The instructions and code read and write files under local directories (e.g., ppt_skill/output, ppt_skill/generated_images) which is expected for this functionality. No instructions attempt to read unrelated system files, environment variables, or contact external endpoints.
Install Mechanism
This is an instruction/code bundle with no install spec; it includes requirements.txt listing python-pptx only. That dependency is proportionate and expected. There are no downloads from arbitrary URLs or extract/install steps that would write arbitrary code to disk.
Credentials
The skill requests no environment variables, no credentials, and accesses no external secrets. Image backends for DALL·E/Stable Diffusion are noted as TODO and currently raise NotImplementedError; the default mock backend is deterministic and local. No disproportionate access to unrelated services is requested.
Persistence & Privilege
always is false and model invocation is allowed (platform default). The skill writes output PPTX, generated images, and a JSON replace log to local directories under the package workspace; it uses non-overwriting filenames. It does not modify other skills or system-wide configuration.
Assessment
This skill appears coherent and limited to local PPT creation/editing. Things to consider before installing: (1) It writes files to local dirs (ppt_skill/output and ppt_skill/generated_images) and saves replace logs — run it in a sandbox or workspace you control. (2) Image generation is a harmless mock by default (a 1x1 PNG); integrating real backends (DALL·E/Stable Diffusion) is not implemented and would require adding API credentials — review that code and any added env vars carefully if you enable those backends. (3) Installation requires python-pptx via pip; review and vet dependencies in your environment. (4) If you need stricter guarantees, inspect the code locally (it’s small and readable) or run it with limited filesystem permissions. Overall, there are no signals of credential exfiltration, network calls, or unexpected behavior in the provided code and instructions.

Like a lobster shell, security has layers — review code before you run it.

latestvk977b2jtjjtr1fwrhpwt62rq2d84w7d5
69downloads
2stars
1versions
Updated 1w ago
v1.0.0
MIT-0

PPT Generate And Edit

Purpose

Provide a reusable Python skill for AI agents to:

  • Create PPT files from structured input.
  • Update existing PPT files with text/image replacement.
  • Keep image layout stable (same position and size) during replacement.

Inputs

create_ppt

  • title: presentation title.
  • slides: array of slide objects:
    • title: slide title.
    • content: string or list of paragraphs.
    • image_prompt (optional): prompt for image generation.

update_ppt

  • ppt_path: source .pptx path.
  • replace_rules:
    • text_replace: dictionary for text replacement.
    • image_replace: dictionary for image replacement strategy.

Outputs

create_ppt

  • Returns generated .pptx file path.

update_ppt

  • Returns:
    • new_ppt_path: new .pptx output path.
    • replace_log: replacement details grouped by slide.

Module Structure

  • main.py: external API for agent calls and demo entry.
  • ppt_generator.py: PPT creation.
  • ppt_editor.py: PPT text/image replacement.
  • image_service.py: image generation abstraction (mock + extension points).
  • utils.py: logging and path helpers.

Usage

from ppt_skill.main import create_ppt, update_ppt

slides = [
    {
        "title": "Brazil Overview",
        "content": ["Brazil is the largest country in South America."],
        "image_prompt": "Brazil skyline and national flag",
    }
]

ppt_path = create_ppt(title="Brazil Briefing", slides=slides)

result = update_ppt(
    ppt_path=ppt_path,
    replace_rules={
        "text_replace": {"Brazil": "Chile"},
        "image_replace": {"__all__": {"prompt": "Chile skyline and national flag"}},
    },
)
print(result["new_ppt_path"])

Notes

  • Current generate_image() uses mock backend by default.
  • DALL·E and Stable Diffusion integration points are reserved as TODO.
  • Keep API fields stable for downstream agent compatibility.

Comments

Loading comments...