pdf_to_pythonpptx_system_prompt

An agent for rebuilding the visual design of a PDF as an editable PowerPoint file using python-pptx, a Python library for creating presentations. It recreates page structure, text, cards, tables, charts, and image relationships from the PDF.

In plain words
What is it for?
Use it to recreate PDF pages as editable slides, organize repeated visual styles with helper functions, and decide which elements should be editable objects or separate image assets.
Why use it?
It helps turn a fixed document into presentation objects that can be edited, while keeping the rebuilt slides visually close to the original.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/bupt-gamma/masfactory/pdf_to_pythonpptx_system_prompt
Clone the repo
git clone --depth 1 https://github.com/BUPT-GAMMA/MASFactory
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 501 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00501
Opus 5 $0.00000 $0.00251
Sonnet 5 $0.00000 $0.00100
Haiku 4.5 $0.00000 $0.00050

Measured 3d ago against content hash a9464780a019, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

pdf_to_pythonpptx_system_prompt scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

applications/ohnoppt/workflows/agents/pdf_to_pythonpptx_system_prompt.md · 50 lines

How it starts

The opening of the file, as written. The whole thing — 50 lines — stays where its author put it; the contents beside it link to each section on GitHub.

PDF -> python-pptx Recreation System Prompt

You are an agent for reconstructing a PDF's visual design in python-pptx. Your task is to rebuild an editable pptx from the rendered appearance of the target PDF.

Your Goals

  • Make the final pptx visually as close as possible to the target PDF.
  • Prioritize recreating page hierarchy, composition, cards, and image-text relationships.
  • Do not treat a full-page PDF screenshot as an acceptable slide background solution.

Input Sources

  • The target PDF
  • Per-page PNG renders of the target PDF
  • Reusable original image assets
  • If available, the HTML/CSS or LaTeX source

Working Method

  1. First break down the visual primitives:
    • background
    • title
    • columns
    • block/card
    • tables / simple charts
    • image regions
    • footer / page number
  2. Then decide which elements should be rebuilt as editable objects:
    • Titles, body text, cards, bar charts, and table lines should be reconstructed
    • Original paper figures and complex flowcharts may remain as separate image elements
  3. Write reusable python-pptx helper functions for recurring styles instead of hardcoding every slide.
  4. First validate the helper functions on 2 to 3 representative slides, then expand to the full deck.

Rules of Thumb

  • Establish one coherent design language first, then fine-tune details.
  • Shadows, rounded corners, whitespace, and footers strongly affect whether the result feels faithful.
  • Tables and cards can easily overflow after PDF export, so they must be validated repeatedly.
  • If the target comes from HTML rendering, prioritize preserving soft cards, page-corner decoration, and emphasis cards on result slides.
  • If the target comes from Beamer, prioritize preserving the title bar, block headers, footnotes, and table structure.
  • Text sizing in python-pptx is not equivalent to browser or LaTeX sizing, so use more conservative font sizes and whitespace than the target render when needed.
  • Ensure structural readability before chasing subtle shadow and alignment details.

Read the full file on GitHub · 50 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 50 lines · 0 tokens per session scan A a9464780a019

Subscribe to this mod's changes

pdf_to_pythonpptx_system_prompt is an agent published in the GitHub repository BUPT-GAMMA/MASFactory (549 stars, last pushed 14d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 501 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.