{
  "id": "task_libraries:powerpoint/python",
  "path": "/exapedia/python-powerpoint-libraries",
  "template": {
    "id": "task_libraries",
    "version": 4
  },
  "title": "Python PowerPoint libraries",
  "answer": [
    {
      "t": "text",
      "text": "Python PowerPoint libraries create, read, and edit PowerPoint presentations from code. A file library edits the PPTX format directly rather than driving an installed copy of PowerPoint through COM automation. These libraries let report generators and AI agents turn data and drafts into slide decks."
    }
  ],
  "breadcrumb": [
    {
      "label": "Tools"
    },
    {
      "label": "Python PowerPoint libraries"
    }
  ],
  "sections": [
    {
      "id": "libraries_popularity",
      "anchor": "popularity",
      "heading": "Popularity",
      "blocks": [
        {
          "b": "table",
          "columns": [
            "Library",
            "Monthly downloads",
            "Stars",
            "Last release",
            "License"
          ],
          "rows": [
            [
              [
                {
                  "t": "link",
                  "href": "#python-pptx",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F140"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F141"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F147"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F144"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F142"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#pywinthreetwo",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F159"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F160"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F168"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F163"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F161"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#pypandoc",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F175"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F176"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F184"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F179"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F177"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#comtypes",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F196"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F197"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F205"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F200"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F198"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#pandoc",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F212"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F213"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F221"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F216"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F214"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#aspose-slides-for-python",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F228"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F229"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F235"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F232"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F230"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#spire-presentation",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F249"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F250"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F256"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F253"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F251"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#python-pptx-text-replacer",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F269"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F270"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F278"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F273"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F271"
                }
              ]
            ]
          ],
          "variant": "pop",
          "caption": [
            {
              "t": "text",
              "text": "Downloads: "
            },
            {
              "t": "text",
              "text": "PyPI"
            },
            {
              "t": "text",
              "text": ", last thirty days. Stars and releases: GitHub. Amber: no release in over a year."
            }
          ]
        }
      ],
      "note": [
        {
          "t": "link",
          "href": "#python-pptx",
          "label": [
            {
              "t": "text",
              "text": "python-pptx"
            }
          ]
        },
        {
          "t": "text",
          "text": " has the most monthly downloads in this comparison, at "
        },
        {
          "t": "fact",
          "fact": "F141"
        },
        {
          "t": "text",
          "text": "."
        }
      ]
    },
    {
      "id": "libraries_capabilities",
      "anchor": "capabilities",
      "heading": "Capabilities",
      "blocks": [
        {
          "b": "table",
          "columns": [
            "Library",
            "Shape object model",
            "Slide image export"
          ],
          "rows": [
            [
              [
                {
                  "t": "link",
                  "href": "#python-pptx",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F140"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F148"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F149"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#pywinthreetwo",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F159"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F169"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F170"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#pypandoc",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F175"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F185"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F186"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#comtypes",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F196"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F206"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F207"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#pandoc",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F212"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F222"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F223"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#aspose-slides-for-python",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F228"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F236"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F237"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#spire-presentation",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F249"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F257"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F258"
                }
              ]
            ],
            [
              [
                {
                  "t": "link",
                  "href": "#python-pptx-text-replacer",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F269"
                    }
                  ]
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F279"
                }
              ],
              [
                {
                  "t": "fact",
                  "fact": "F280"
                }
              ]
            ]
          ],
          "variant": "cap"
        }
      ]
    },
    {
      "id": "libraries_entries",
      "anchor": "libraries",
      "heading": "Libraries",
      "blocks": [
        {
          "b": "entry",
          "anchor": "python-pptx",
          "name": [
            {
              "t": "fact",
              "fact": "F140"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/scanny/python-pptx"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/python-pptx"
            },
            {
              "label": "Docs",
              "href": "https://python-pptx.readthedocs.io/"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F12"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F141"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F147"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F143"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F142"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://python-pptx.readthedocs.io/",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F140"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F13"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F14"
                }
              ]
            },
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F15"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F16"
                }
              ]
            }
          ],
          "cons": [
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F17"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F18"
                }
              ]
            },
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F19"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F20"
                }
              ]
            }
          ],
          "tabs": [
            {
              "label": [
                {
                  "t": "fact",
                  "fact": "F157"
                }
              ],
              "stars": [
                {
                  "t": "fact",
                  "fact": "F158"
                }
              ],
              "usedBy": [
                {
                  "t": "link",
                  "href": "https://github.com/camel-ai/camel",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F157"
                    }
                  ]
                },
                {
                  "t": "text",
                  "text": " "
                }
              ],
              "language": "python",
              "code": "def _write_pptx_file(\n    self,\n    file_path: Path,\n    content: List[Dict[str, Any]],\n    template: Optional[str] = None,\n) -> None:\n    r\"\"\"Write text content to a PPTX file with enhanced formatting.\n\n    Args:\n        file_path (Path): The target file path.\n        content (List[Dict[str, Any]]): The content to write to the PPTX\n            file. Must be a list of dictionaries where:\n            - First element: Title slide with keys 'title' and 'subtitle'\n            - Subsequent elements: Content slides with keys 'title', 'text'\n        template (Optional[str]): The name of the template to use. If not\n            provided, the default template will be used. (default: :obj:\n            `None`)\n    \"\"\"\n    from pptx import Presentation\n\n    # Use template if provided, otherwise create new presentation\n    if template is not None:\n        template_path = Path(template).resolve()\n        if not template_path.exists():\n            logger.warning(\n                f\"Template file not found: {template_path}, using \"\n                \"default template\"\n            )\n            presentation = Presentation()\n        else:\n            presentation = Presentation(str(template_path))\n            # Clear all existing slides by removing them from the slide\n            # list\n            while len(presentation.slides) > 0:\n                rId = presentation.slides._sldIdLst[-1].rId\n                presentation.part.drop_rel(rId)\n                del presentation.slides._sldIdLst[-1]\n    else:\n        presentation = Presentation()\n\n    slide_width_inch, slide_height_inch = (\n        self._get_slide_width_height_inches(presentation)\n    )\n\n    # Process slides\n    if content:\n        # Title slide (first element)\n        title_slide_data = content.pop(0) if content else {}\n        title_layout = presentation.slide_layouts[0]\n        title_slide = presentation.slides.add_slide(title_layout)\n\n        # Set title and subtitle\n        if title_slide.shapes.title:\n            title_slide.shapes.title.text_frame.clear()\n            self._format_text(\n                title_slide.shapes.title.text_frame.paragraphs[0],\n                title_slide_data.get(\"title\", \"\"),\n            )\n\n        if len(title_slide.placeholders) > 1:\n            subtitle = title_slide.placeholders[1]\n            subtitle.text_frame.clear()\n            self._format_text(\n                subtitle.text_frame.paragraphs[0],\n                title_slide_data.get(\"subtitle\", \"\"),\n            )\n\n        # Content slides\n        for slide_data in content:\n            if not isinstance(slide_data, dict):\n                continue\n\n            # Handle different slide types\n            if 'table' in slide_data:\n                self._handle_table(\n                    presentation,\n                    slide_data,\n                )\n            elif 'bullet_points' in slide_data:\n                if any(\n                    step.startswith(STEP_BY_STEP_PROCESS_MARKER)\n                    for step in slide_data['bullet_points']\n                ):\n                    self._handle_step_by_step_process(\n                        presentation,\n                        slide_data,\n                        slide_width_inch,\n                        slide_height_inch,\n                    )\n                else:\n                    self._handle_default_display(\n                        presentation,\n                        slide_data,\n                    )\n\n    # Save the presentation\n    presentation.save(str(file_path))\n    logger.debug(f\"Wrote PPTX to {file_path} with enhanced formatting\")\n",
              "prov": [
                {
                  "t": "link",
                  "href": "https://github.com/camel-ai/camel/blob/c619d1fe5aa2182395d02aadddc71b818c1b6c9f/camel/toolkits/pptx_toolkit.py#L258-L355",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F156"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=Python%20projects%20using%20python-pptx%20for%20PowerPoint%20slide%20creation%20editing%20and%20conversion&filters=%7B%22type%22%3A%20%22auto%22%2C%20%22numResults%22%3A%2010%2C%20%22includeDomains%22%3A%20%5B%22github.com%22%5D%7D",
                  "label": [
                    {
                      "t": "text",
                      "text": "More projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F140"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            },
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "from pptx import Presentation\n\nprs = Presentation()\ntitle_slide_layout = prs.slide_layouts[0]\nslide = prs.slides.add_slide(title_slide_layout)\ntitle = slide.shapes.title\nsubtitle = slide.placeholders[1]\n\ntitle.text = \"Hello, World!\"\nsubtitle.text = \"python-pptx was here!\"\n\nprs.save('test.pptx')\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/scanny/python-pptx/blob/master/docs/user/quickstart.rst",
                  "label": [
                    {
                      "t": "text",
                      "text": "quickstart.rst"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F145"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "pywinthreetwo",
          "name": [
            {
              "t": "fact",
              "fact": "F159"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/mhammond/pywin32"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/pywin32"
            },
            {
              "label": "Docs",
              "href": "https://mhammond.github.io/pywin32/"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F166"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F160"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F168"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F162"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F161"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://mhammond.github.io/pywin32/",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F159"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [],
          "cons": [],
          "tabs": [
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "from win32com.client import Dispatch\n\npowerpoint = Dispatch(\"PowerPoint.Application\")\npresentation = powerpoint.Presentations.Add()\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/mhammond/pywin32/blob/main/com/win32com/client/__init__.py",
                  "label": [
                    {
                      "t": "text",
                      "text": "__init__.py"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=pywin32%20GitHub%20projects",
                  "label": [
                    {
                      "t": "text",
                      "text": "Find projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F159"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F164"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "pypandoc",
          "name": [
            {
              "t": "fact",
              "fact": "F175"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/JessicaTegner/pypandoc"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/pypandoc"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F182"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F176"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F184"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F178"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F177"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://github.com/JessicaTegner/pypandoc",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F175"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [],
          "cons": [],
          "tabs": [
            {
              "label": [
                {
                  "t": "fact",
                  "fact": "F194"
                }
              ],
              "stars": [
                {
                  "t": "fact",
                  "fact": "F195"
                }
              ],
              "usedBy": [
                {
                  "t": "link",
                  "href": "https://github.com/vivekVells/mcp-pandoc",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F194"
                    }
                  ]
                },
                {
                  "t": "text",
                  "text": " "
                }
              ],
              "language": "python",
              "code": "async def handle_call_tool(\n    name: str, arguments: dict | None\n) -> list[types.TextContent | types.ImageContent | types.EmbeddedResource]:\n    \"\"\"Handle tool execution requests.\n\n    Tools can modify server state and notify clients of changes.\n    \"\"\"\n    if name not in [\"convert-contents\"]:\n        raise ValueError(f\"Unknown tool: {name}\")\n\n    if not arguments:\n        raise ValueError(\"Missing arguments\")\n\n    # Extract all possible arguments\n    contents = arguments.get(\"contents\")\n    input_file = arguments.get(\"input_file\")\n    output_file = arguments.get(\"output_file\")\n    output_format = arguments.get(\"output_format\", \"markdown\").lower()\n    input_format = arguments.get(\"input_format\", \"markdown\").lower()\n    # The public MCP schema uses \"txt\"; Pandoc names the equivalent writer \"plain\".\n    pandoc_output_format = \"plain\" if output_format == \"txt\" else output_format\n    reference_doc = arguments.get(\"reference_doc\")\n    filters = arguments.get(\"filters\", [])\n    defaults_file = arguments.get(\"defaults_file\")\n\n    # Validate input parameters\n    if not contents and not input_file:\n        raise ValueError(\"Either 'contents' or 'input_file' must be provided\")\n\n    # Validate reference_doc if provided\n    if reference_doc:\n        if output_format not in REFERENCE_DOC_FORMATS:\n            raise ValueError(\n                f\"reference_doc is not supported for '{output_format}' output format. \"\n                f\"Supported formats: {_join_with_and(REFERENCE_DOC_FORMATS)}\"\n            )\n        if not os.path.exists(reference_doc):\n            raise ValueError(f\"Reference document not found: {reference_doc}\")\n        if not os.path.isfile(reference_doc):\n            raise ValueError(f\"Reference document is not a file: {reference_doc}\")\n\n        # Pandoc does not verify that the reference document matches the writer. A\n        # mismatch is silently ignored for docx output, and produces an unreadable\n        # file for odt output. Both exit 0 with no warning, so we reject it here.\n        expected_extension = f\".{output_format}\"\n        actual_extension = os.path.splitext(reference_doc)[1].lower()\n        if actual_extension != expected_extension:\n            raise ValueError(\n                f\"reference_doc must be a '{expected_extension}' file when output_format is \"\n                f\"'{output_format}', but '{os.path.basename(reference_doc)}' was given. Pandoc \"\n                f\"does not reject a mismatched reference document; it silently produces an \"\n                f\"unstyled or unreadable file. Create a matching template with: \"\n                f\"pandoc -o reference{expected_extension} \"\n                f\"--print-default-data-file reference{expected_extension}\"\n            )\n\n    # Validate defaults_file if provided\n    if defaults_file:\n        if not os.path.exists(defaults_file):\n            raise ValueError(f\"Defaults file not found: {defaults_file}\")\n\n        # Check if it's a valid YAML file and readable\n        try:\n            with open(defaults_file) as f:\n                yaml_content = yaml.safe_load(f)\n\n            # Validate the YAML structure\n            if not isinstance(yaml_content, dict):\n                raise ValueError(f\"Invalid defaults file format: {defaults_file} - must be a YAML dictionary\")\n\n            # Check if the defaults file specifies an output format that conflicts with the requested format\n            if 'to' in yaml_content and yaml_content['to'] != output_format:\n                print(\n                    f\"Warning: Defaults file specifies output format '{yaml_content['to']}' \"\n                    f\"but requested format is '{output_format}'. Using requested format.\"\n                )\n\n        except yaml.YAMLError as e:\n            raise ValueError(f\"Error parsing defaults file {defaults_file}: {str(e)}\") from e\n        except PermissionError as e:\n            raise ValueError(f\"Permission denied when reading defaults file: {defaults_file}\") from e\n        except Exception as e:\n            raise ValueError(f\"Error reading defaults file {defaults_file}: {str(e)}\") from e\n\n    # Validate the output format against the single list the schema also advertises, so\n    # the runtime check and the enum cannot drift apart.\n    if output_format not in OUTPUT_FORMATS:\n        raise ValueError(\n            f\"Unsupported output format: '{output_format}'. Supported formats are: {', '.join(OUTPUT_FORMATS)}\"\n        )\n\n    if input_format not in INPUT_FORMATS:\n        raise ValueError(\n            f\"Unsupported input format: '{input_format}'. Supported input formats are: \"\n            f\"{', '.join(INPUT_FORMATS)}. Pandoc writes some formats it cannot read, so the \"\n            f\"input list is shorter than the output list.\"\n        )\n\n    # Validate output_file requirement for advanced formats\n    if output_format in ADVANCED_FORMATS and not output_file:\n        raise ValueError(f\"output_file path is required for {output_format} format\")\n\n    # Validate filters if provided\n    if filters:\n        if not isinstance(filters, list):\n            raise ValueError(\"filters parameter must be an array of strings\")\n\n        for filter_path in filters:\n            if not isinstance(filter_path, str):\n                raise ValueError(\"Each filter must be a string path\")\n\n    def resolve_filter_path(filter_path, defaults_file=None):\n        \"\"\"Resolve a filter path by trying multiple possible locations.\n\n        Args:\n        ----\n            filter_path: The original filter path (absolute or relative)\n            defaults_file: Optional path to the defaults file for context\n\n        Returns:\n        -------\n            Resolved absolute path to the filter if found, or None if not found\n\n        \"\"\"\n        # If it's already an absolute path, just use it\n        if os.path.isabs(filter_path):\n            paths = [filter_path]\n        else:\n            # Try multiple locations for relative paths\n            paths = [\n                # 1. Relative to current working directory\n                os.path.abspath(filter_path),\n\n                # 2. Relative to the defaults file directory (if provided)\n                os.path.join(os.path.dirname(os.path.abspath(defaults_file)), filter_path) if defaults_file else None,\n\n                # 3. Relative to the .pandoc/filters directory\n                os.path.join(os.path.expanduser(\"~\"), \".pandoc\", \"filters\", os.path.basename(filter_path))\n            ]\n            # Remove None entries\n            paths = [p for p in paths if p]\n\n        # Try each path\n        for path in paths:\n            if os.path.exists(path):\n                # Check if executable and try to make it executable if not\n                if not os.access(path, os.X_OK):\n                    try:\n                        os.chmod(path, os.stat(path).st_mode | 0o111)\n                        print(f\"Made filter executable: {path}\")\n                    except Exception as e:\n                        print(f\"Warning: Could not make filter executable: {path} - {str(e)}\")\n                        continue\n\n                print(f\"Using filter: {path}\")\n                return path\n\n        return None\n\n    def validate_filters(filters, defaults_file=None):\n        \"\"\"Validate filter paths and ensure they exist and are executable.\"\"\"\n        validated_filters = []\n\n        for filter_path in filters:\n            resolved_path = resolve_filter_path(filter_path, defaults_file)\n            if resolved_path:\n                validated_filters.append(resolved_path)\n            else:\n                raise ValueError(f\"Filter not found in any of the searched locations: {filter_path}\")\n\n        return validated_filters\n\n    def format_result_info(filters=None, defaults_file=None, validated_filters=None):\n        \"\"\"Format filter and defaults file information for result messages.\"\"\"\n        filter_info = \"\"\n        defaults_info = \"\"\n\n        if filters and validated_filters:\n            filter_names = [os.path.basename(f) for f in validated_filters]\n            filter_info = f\" with filters: {', '.join(filter_names)}\"\n\n        if defaults_file:\n            defaults_basename = os.path.basename(defaults_file)\n            defaults_info = f\" using defaults file: {defaults_basename}\"\n\n        return filter_info, defaults_info\n\n    try:\n        # Prepare conversion arguments\n        extra_args = []\n\n        # Add defaults file if provided - ensure it's properly formatted for Pandoc\n        if defaults_file:\n            # Make sure the path is absolute\n            defaults_file_abs = os.path.abspath(defaults_file)\n            extra_args.extend([\"--defaults\", defaults_file_abs])\n\n        # Set environment variables for filters\n        env = os.environ.copy()\n        if output_file:\n            # Set PANDOC_OUTPUT_DIR to the directory of the output file\n            output_dir = os.path.dirname(os.path.abspath(output_file))\n            env[\"PANDOC_OUTPUT_DIR\"] = output_dir\n        else:\n            output_dir = None\n\n        # Validate filters once and reuse the result\n        validated_filters = validate_filters(filters, defaults_file) if filters else []\n\n        # Handle filter arguments\n        for filter_path in validated_filters:\n            extra_args.extend([\"--filter\", filter_path])\n\n        # Handle PDF-specific conversion if needed\n        if output_format == \"pdf\":\n            extra_args.extend([\n                \"--pdf-engine=xelatex\",\n                \"-V\", \"geometry:margin=1in\"\n            ])\n\n        # Handle reference doc for the formats pandoc accepts --reference-doc for\n        if reference_doc and output_format in REFERENCE_DOC_FORMATS:\n            extra_args.extend([\"--reference-doc\", reference_doc])\n\n        # No special processing needed for content\n\n        # Convert content using pypandoc\n        if input_file:\n            if not os.path.exists(input_file):\n                raise ValueError(f\"Input file not found: {input_file}\")\n\n\n            if output_file:\n                # Convert file to file\n                converted_output = pypandoc.convert_file(\n                    input_file,\n                    pandoc_output_format,\n                    outputfile=output_file,\n                    extra_args=extra_args\n                )\n\n                # Create result message with filter and defaults information\n                filter_info, defaults_info = format_result_info(filters, defaults_file, validated_filters)\n                result_message = f\"File successfully converted{filter_info}{defaults_info} and saved to: {output_file}\"\n            else:\n                # Convert file to string\n                converted_output = pypandoc.convert_file(\n                    input_file,\n                    pandoc_output_format,\n                    extra_args=extra_args\n                )\n        else:\n            # No special processing needed for content\n\n            if output_file:\n                # Convert content to file\n                pypandoc.convert_text(\n                    contents,\n                    pandoc_output_format,\n                    format=input_format,\n                    outputfile=output_file,\n                    extra_args=extra_args\n                )\n\n                # Create result message with filter and defaults information\n                filter_info, defaults_info = format_result_info(filters, defaults_file, validated_filters)\n                result_message = (\n                    f\"Content successfully converted{filter_info}{defaults_info} and saved to: {output_file}\"\n                )\n            else:\n                # Convert content to string\n                converted_output = pypandoc.convert_text(\n                    contents,\n                    pandoc_output_format,\n                    format=input_format,\n                    extra_args=extra_args\n                )\n\n        if output_file:\n            notify_with_result = result_message\n        else:\n            if not converted_output:\n                raise ValueError(\"Conversion resulted in empty output\")\n\n            # Add filter and defaults information to the notification\n            filter_info, defaults_info = format_result_info(filters, defaults_file, validated_filters)\n            # Adjust format for inline display\n            if filter_info:\n                filter_info = f\" (with filters: {', '.join([os.path.basename(f) for f in validated_filters])})\"\n            if defaults_info:\n                defaults_info = f\" (using defaults file: {os.path.basename(defaults_file)})\"\n\n            notify_with_result = (\n                f'Following are the converted contents in {output_format} format{filter_info}{defaults_info}.\\n'\n                f'Ask user if they expect to save this file. If so, provide the output_file parameter with '\n                f'complete path.\\n'\n                f'Converted Contents:\\n\\n{converted_output}'\n            )\n\n        return [\n            types.TextContent(\n                type=\"text\",\n                text=notify_with_result\n            )\n        ]\n\n    except Exception as e:\n        # Handle Pandoc conversion errors\n        error_prefix = \"Error converting\"\n        error_details = str(e)\n\n        if \"Filter not found\" in error_details or \"Filter is not executable\" in error_details:\n            error_prefix = \"Filter error during conversion\"\n        elif \"defaults\" in error_details and defaults_file:\n            error_prefix = \"Defaults file error during conversion\"\n            # Add more context about the defaults file\n            error_details += f\" (defaults file: {defaults_file})\"\n        elif \"pandoc\" in error_details.lower() and \"not found\" in error_details.lower():\n            error_prefix = \"Pandoc executable not found\"\n            error_details = \"Please ensure Pandoc is installed and available in your PATH\"\n\n        error_msg = (\n            f\"{error_prefix} {'file' if input_file else 'contents'} from {input_format} to \"\n            f\"{output_format}: {error_details}\"\n        )\n        raise ValueError(error_msg) from e\n",
              "prov": [
                {
                  "t": "link",
                  "href": "https://github.com/vivekVells/mcp-pandoc/blob/7df0519cd7d976d7c3be978852f6178da5a37035/src/mcp_pandoc/server.py#L188-L513",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F193"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=pypandoc%20GitHub%20projects",
                  "label": [
                    {
                      "t": "text",
                      "text": "More projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F175"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            },
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "import pypandoc\n\npypandoc.convert_text(\"# Example\\n\\nContent\", \"pptx\", format=\"md\", outputfile=\"example.pptx\")\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/JessicaTegner/pypandoc/blob/master/pypandoc/__init__.py",
                  "label": [
                    {
                      "t": "text",
                      "text": "__init__.py"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F180"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "comtypes",
          "name": [
            {
              "t": "fact",
              "fact": "F196"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/enthought/comtypes"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/comtypes"
            },
            {
              "label": "Docs",
              "href": "https://comtypes.readthedocs.io/"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F203"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F197"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F205"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F199"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F198"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://comtypes.readthedocs.io/",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F196"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [],
          "cons": [],
          "tabs": [
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "from comtypes.client import CreateObject\n\npowerpoint = CreateObject(\"PowerPoint.Application\")\npresentation = powerpoint.Presentations.Add()\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/enthought/comtypes/blob/main/comtypes/client/_create.py",
                  "label": [
                    {
                      "t": "text",
                      "text": "_create.py"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=comtypes%20GitHub%20projects",
                  "label": [
                    {
                      "t": "text",
                      "text": "Find projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F196"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F201"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "pandoc",
          "name": [
            {
              "t": "fact",
              "fact": "F212"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/boisgera/pandoc"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/pandoc"
            },
            {
              "label": "Docs",
              "href": "https://boisgera.github.io/pandoc/"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F219"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F213"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F221"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F215"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F214"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://boisgera.github.io/pandoc/",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F212"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [],
          "cons": [],
          "tabs": [
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "import pandoc\n\ndocument = pandoc.read(\"# Example\\n\\nContent\", format=\"markdown\")\npandoc.write(document, file=\"example.pptx\", format=\"pptx\")\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/boisgera/pandoc/blob/fab5f10f8ac08a87b480a91e0d1eaa37c468e1ac/src/pandoc/__init__.py",
                  "label": [
                    {
                      "t": "text",
                      "text": "__init__.py"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=pandoc%20GitHub%20projects",
                  "label": [
                    {
                      "t": "text",
                      "text": "Find projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F212"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F217"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "aspose-slides-for-python",
          "name": [
            {
              "t": "fact",
              "fact": "F228"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/aspose-slides/Aspose.Slides-for-Python-via-.NET"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/aspose-slides"
            },
            {
              "label": "Docs",
              "href": "https://docs.aspose.com/slides/python-net/"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F39"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F229"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F235"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F231"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F230"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://docs.aspose.com/slides/python-net/",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F228"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F40"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F41"
                }
              ]
            },
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F42"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F43"
                }
              ]
            }
          ],
          "cons": [
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F44"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F45"
                }
              ]
            },
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F46"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F47"
                }
              ]
            }
          ],
          "tabs": [
            {
              "label": [
                {
                  "t": "fact",
                  "fact": "F247"
                }
              ],
              "stars": [
                {
                  "t": "fact",
                  "fact": "F248"
                }
              ],
              "usedBy": [
                {
                  "t": "link",
                  "href": "https://github.com/Fergana-Labs/stash",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F247"
                    }
                  ]
                },
                {
                  "t": "text",
                  "text": " "
                }
              ],
              "language": "python",
              "code": "def add_text_shape(\n    pres: slides.Presentation,\n    slide_index: int,\n    req: TextShapeRequest,\n    canvas_w_px: float,\n    canvas_h_px: float,\n) -> int:\n    slide = pres.slides[slide_index]\n    slide_w_pt = float(pres.slide_size.size.width)\n    slide_h_pt = float(pres.slide_size.size.height)\n\n    x, y, w, h = _bbox_to_pt(req.bbox, canvas_w_px, canvas_h_px, slide_w_pt, slide_h_pt)\n    shape = slide.shapes.add_auto_shape(slides.ShapeType.RECTANGLE, x, y, w, h)\n    shape.line_format.fill_format.fill_type = slides.FillType.NO_FILL\n\n    if req.bg_color:\n        shape.fill_format.fill_type = slides.FillType.SOLID\n        shape.fill_format.solid_fill_color.color = _hex_to_color(req.bg_color)\n    else:\n        shape.fill_format.fill_type = slides.FillType.NO_FILL\n\n    tf = shape.text_frame\n    tf.text_frame_format.autofit_type = slides.TextAutofitType.NONE\n    tf.text_frame_format.wrap_text = slides.NullableBool.TRUE\n\n    top_pad, right_pad, bottom_pad, left_pad = req.padding_px\n    tf.text_frame_format.margin_top = _px_to_pt(top_pad, canvas_h_px, slide_h_pt)\n    tf.text_frame_format.margin_right = _px_to_pt(right_pad, canvas_w_px, slide_w_pt)\n    tf.text_frame_format.margin_bottom = _px_to_pt(bottom_pad, canvas_h_px, slide_h_pt)\n    tf.text_frame_format.margin_left = _px_to_pt(left_pad, canvas_w_px, slide_w_pt)\n\n    # Strip the default placeholder paragraph Aspose seeds in every text frame.\n    while tf.paragraphs.count > 0:\n        tf.paragraphs.remove_at(0)\n\n    for para_model in req.paragraphs:\n        para = _build_paragraph(para_model, canvas_h_px, slide_h_pt)\n        tf.paragraphs.add(para)\n\n    return slide.shapes.index_of(shape)\n",
              "prov": [
                {
                  "t": "link",
                  "href": "https://github.com/Fergana-Labs/stash/blob/419efb4599fdafb648c036a5f31aeee220d363a7/powerpoint-mcp/src/builder.py#L137-L176",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F246"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=Python%20projects%20using%20aspose-slides%20for%20PowerPoint%20slide%20creation%20editing%20and%20conversion&filters=%7B%22type%22%3A%20%22auto%22%2C%20%22numResults%22%3A%2010%2C%20%22includeDomains%22%3A%20%5B%22github.com%22%5D%7D",
                  "label": [
                    {
                      "t": "text",
                      "text": "More projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F228"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            },
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "import aspose.slides as slides\n\n# Instantiates a Presentation object that represents a presentation file\nwith slides.Presentation() as presentation:\n    slide = presentation.slides[0]\n    # Adds an autoshape with type set to line\n    slide.shapes.add_auto_shape(slides.ShapeType.LINE, 50, 150, 300, 0)\n    presentation.save(\"NewPresentation_out.pptx\", slides.export.SaveFormat.PPTX)\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/aspose-slides/Aspose.Slides-for-Python-via-.NET/blob/master/README.md",
                  "label": [
                    {
                      "t": "text",
                      "text": "README.md"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F233"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "spire-presentation",
          "name": [
            {
              "t": "fact",
              "fact": "F249"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/eiceblue/Spire.Presentation-for-Python"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/Spire.Presentation"
            },
            {
              "label": "Docs",
              "href": "https://www.e-iceblue.com/Introduce/presentation-for-python.html"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F66"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F250"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F256"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F252"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F251"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://www.e-iceblue.com/Introduce/presentation-for-python.html",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F249"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F67"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F68"
                }
              ]
            },
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F69"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F70"
                }
              ]
            }
          ],
          "cons": [
            {
              "lead": [
                {
                  "t": "fact",
                  "fact": "F71"
                }
              ],
              "body": [
                {
                  "t": "fact",
                  "fact": "F72"
                }
              ]
            }
          ],
          "tabs": [
            {
              "label": [
                {
                  "t": "fact",
                  "fact": "F267"
                }
              ],
              "stars": [
                {
                  "t": "fact",
                  "fact": "F268"
                }
              ],
              "usedBy": [
                {
                  "t": "link",
                  "href": "https://github.com/elliottzheng/NotebookLM2PPT",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F267"
                    }
                  ]
                },
                {
                  "t": "text",
                  "text": " "
                }
              ],
              "language": "python",
              "code": "def combine_ppt_files_with_spire(source_folder, output_file, png_names=None):\n    \"\"\"\n    使用 Spire.Presentation 合并PPT文件，每个PPT只保留第一页，并保留原始设计\n\n    Args:\n        source_folder: 源PPT文件所在的文件夹路径\n        output_file: 输出的合并PPT文件路径\n    \"\"\"\n    # 获取所有pptx文件并按字典序排序\n\n    ppt_files = sorted([f for f in os.listdir(source_folder) if f.endswith('.pptx')])\n\n    ppt_names = [png_name.replace(\".png\", \".pptx\") for png_name in png_names] if png_names else None\n\n    if not ppt_files:\n        print(\"未找到任何PPT文件\")\n        return\n\n    print(f\"找到 {len(ppt_files)} 个PPT文件:\")\n    valid_ppt_files = []\n    for idx, file in enumerate(ppt_files, 1):\n        print(f\"  {idx}. {file}\")\n        if ppt_names and file in ppt_names:\n            valid_ppt_files.append(file)\n    if ppt_names:\n        ppt_files = valid_ppt_files\n        print(f\"\\n根据提供的PNG名称过滤后，剩余 {len(ppt_files)} 个PPT文件:\")\n\n    # 创建主演示文稿对象，使用第一个PPT作为基础\n    first_ppt_path = os.path.join(source_folder, ppt_files[0])\n    main_pres = Presentation()\n    main_pres.LoadFromFile(first_ppt_path)\n\n    # 删除第一个PPT的多余页面，只保留第一页\n    while main_pres.Slides.Count > 1:\n        main_pres.Slides.RemoveAt(1)\n\n    print(f\"  已添加: {ppt_files[0]} (第1页)\")\n\n    # 遍历剩余的PPT文件\n    for ppt_file in ppt_files[1:]:\n        file_path = os.path.join(source_folder, ppt_file)\n\n        # 加载当前PPT文件\n        temp_pres = Presentation()\n        temp_pres.LoadFromFile(file_path)\n\n        if temp_pres.Slides.Count > 0:\n            # 使用 AppendBySlide 方法追加第一页，保留原始设计\n            main_pres.Slides.AppendBySlide(temp_pres.Slides[0])\n            print(f\"  已添加: {ppt_file} (第1页)\")\n        else:\n            print(f\"  跳过: {ppt_file} (无幻灯片)\")\n\n        # 释放临时演示文稿资源\n        temp_pres.Dispose()\n\n    # 保存合并后的PPT\n    main_pres.SaveToFile(output_file, FileFormat.Pptx2016)\n    print(f\"\\n合并完成！输出文件: {output_file}\")\n    print(f\"总共合并了 {main_pres.Slides.Count} 页幻灯片\")\n\n    # 释放资源\n    main_pres.Dispose()\n\n    valid_png_names = [ppt_name.replace(\".pptx\", \".png\") for ppt_name in ppt_files] # 返回真正存在的png names\n\n    return valid_png_names\n",
              "prov": [
                {
                  "t": "link",
                  "href": "https://github.com/elliottzheng/NotebookLM2PPT/blob/c8b1991f693b1242a702b562c9c360c2b832e941/notebooklm2ppt/utils/ppt_combiner.py#L13-L80",
                  "label": [
                    {
                      "t": "fact",
                      "fact": "F266"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=Python%20projects%20using%20Spire.Presentation%20for%20PowerPoint%20slide%20creation%20editing%20and%20conversion&filters=%7B%22type%22%3A%20%22auto%22%2C%20%22numResults%22%3A%2010%2C%20%22includeDomains%22%3A%20%5B%22github.com%22%5D%7D",
                  "label": [
                    {
                      "t": "text",
                      "text": "More projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F249"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            },
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "from spire.presentation import *\n\noutputFile =\"HelloWorld.pptx\"\npresentation = Presentation()\npresentation.SaveToFile(outputFile, FileFormat.Pptx2010)\npresentation.Dispose()\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://github.com/eiceblue/Spire.Presentation-for-Python/blob/main/README.md",
                  "label": [
                    {
                      "t": "text",
                      "text": "README.md"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F254"
            }
          ]
        },
        {
          "b": "entry",
          "anchor": "python-pptx-text-replacer",
          "name": [
            {
              "t": "fact",
              "fact": "F269"
            }
          ],
          "links": [
            {
              "label": "GitHub",
              "href": "https://github.com/fschaeck/python-pptx-text-replacer"
            },
            {
              "label": "PyPI",
              "href": "https://pypi.org/project/python-pptx-text-replacer"
            }
          ],
          "what": [
            {
              "t": "fact",
              "fact": "F276"
            }
          ],
          "facts": [
            {
              "label": "Downloads / mo",
              "value": [
                {
                  "t": "fact",
                  "fact": "F270"
                }
              ]
            },
            {
              "label": "Stars",
              "value": [
                {
                  "t": "fact",
                  "fact": "F278"
                }
              ]
            },
            {
              "label": "Last release",
              "value": [
                {
                  "t": "fact",
                  "fact": "F272"
                }
              ]
            },
            {
              "label": "License",
              "value": [
                {
                  "t": "fact",
                  "fact": "F271"
                }
              ]
            },
            {
              "label": "Capabilities",
              "value": [
                {
                  "t": "link",
                  "href": "https://github.com/fschaeck/python-pptx-text-replacer",
                  "label": [
                    {
                      "t": "text",
                      "text": "From the "
                    },
                    {
                      "t": "fact",
                      "fact": "F269"
                    },
                    {
                      "t": "text",
                      "text": " docs"
                    }
                  ]
                }
              ]
            }
          ],
          "pros": [],
          "cons": [],
          "tabs": [
            {
              "label": [
                {
                  "t": "text",
                  "text": "Quickstart"
                }
              ],
              "language": "python",
              "code": "from python_pptx_text_replacer import TextReplacer\nreplacer = TextReplacer(\"original.pptx\", slides='',\n tables=True, charts=True, textframes=True)\nreplacer.replace_text( [ ('FY2021','FY2122') ] )\nreplacer.write_presentation_to_file(\"./changed.pptx\")\n",
              "prov": [
                {
                  "t": "text",
                  "text": "From "
                },
                {
                  "t": "link",
                  "href": "https://pypi.org/pypi/python-pptx-text-replacer/0.0.6/json#/info/description",
                  "label": [
                    {
                      "t": "text",
                      "text": "README.md"
                    }
                  ]
                }
              ],
              "more": [
                {
                  "t": "link",
                  "href": "https://dashboard.exa.ai/playground/search?q=python-pptx-text-replacer%20GitHub%20projects",
                  "label": [
                    {
                      "t": "text",
                      "text": "Find projects using "
                    },
                    {
                      "t": "fact",
                      "fact": "F269"
                    },
                    {
                      "t": "text",
                      "text": " →"
                    }
                  ]
                }
              ]
            }
          ],
          "install": [
            {
              "t": "fact",
              "fact": "F274"
            }
          ]
        }
      ]
    }
  ],
  "questions": [
    {
      "q": "Which Python PowerPoint library should I use?",
      "a": [
        {
          "t": "link",
          "href": "#python-pptx",
          "label": [
            {
              "t": "text",
              "text": "python-pptx"
            }
          ]
        },
        {
          "t": "text",
          "text": " suits creating and editing PPTX files on any platform. "
        },
        {
          "t": "link",
          "href": "#aspose-slides-for-python",
          "label": [
            {
              "t": "text",
              "text": "Aspose.Slides"
            }
          ]
        },
        {
          "t": "text",
          "text": " and "
        },
        {
          "t": "link",
          "href": "#spire-presentation",
          "label": [
            {
              "t": "text",
              "text": "Spire.Presentation"
            }
          ]
        },
        {
          "t": "text",
          "text": " suit teams that need a commercial SDK that also renders slides as images. "
        },
        {
          "t": "link",
          "href": "#pywinthreetwo",
          "label": [
            {
              "t": "fact",
              "fact": "F159"
            }
          ]
        },
        {
          "t": "text",
          "text": " suits Windows machines that automate an installed copy of PowerPoint."
        }
      ]
    },
    {
      "q": "What is python-pptx?",
      "a": [
        {
          "t": "link",
          "href": "#python-pptx",
          "label": [
            {
              "t": "text",
              "text": "python-pptx"
            }
          ]
        },
        {
          "t": "text",
          "text": " creates, reads, and updates PowerPoint files through slide and shape objects. It does not render slides as images."
        }
      ]
    },
    {
      "q": "How do I create a PowerPoint presentation in Python?",
      "a": [
        {
          "t": "link",
          "href": "#python-pptx",
          "label": [
            {
              "t": "text",
              "text": "python-pptx"
            }
          ]
        },
        {
          "t": "text",
          "text": " builds a presentation from slide layouts and adds text boxes, pictures, and shapes to each slide before saving the file."
        }
      ]
    },
    {
      "q": "Can Python convert slides to images?",
      "a": [
        {
          "t": "link",
          "href": "#python-pptx",
          "label": [
            {
              "t": "text",
              "text": "python-pptx"
            }
          ]
        },
        {
          "t": "text",
          "text": " cannot render slides. "
        },
        {
          "t": "link",
          "href": "#aspose-slides-for-python",
          "label": [
            {
              "t": "text",
              "text": "Aspose.Slides"
            }
          ]
        },
        {
          "t": "text",
          "text": " and "
        },
        {
          "t": "link",
          "href": "#spire-presentation",
          "label": [
            {
              "t": "text",
              "text": "Spire.Presentation"
            }
          ]
        },
        {
          "t": "text",
          "text": " export slide images through their own renderers. On Windows, "
        },
        {
          "t": "link",
          "href": "#pywinthreetwo",
          "label": [
            {
              "t": "fact",
              "fact": "F159"
            }
          ]
        },
        {
          "t": "text",
          "text": " can call the export function of an installed copy of PowerPoint."
        }
      ]
    }
  ],
  "facts": {
    "F1": {
      "label": "Library name, python-pptx",
      "display": "python-pptx",
      "asOf": "2026-11-17"
    },
    "F2": {
      "label": "Monthly downloads, python-pptx",
      "display": "139.9M",
      "asOf": "2026-11-17"
    },
    "F3": {
      "label": "License, python-pptx",
      "display": "MIT",
      "asOf": "2026-11-17"
    },
    "F4": {
      "label": "Package release, python-pptx",
      "display": "1.0.2, Aug 2024",
      "asOf": "2024-08-07"
    },
    "F5": {
      "label": "Package release date, python-pptx",
      "display": "Aug 2024",
      "asOf": "2024-08-07"
    },
    "F6": {
      "label": "Repository stars, python-pptx",
      "display": "3.6K",
      "asOf": "2026-11-17"
    },
    "F7": {
      "label": "Create slides, python-pptx",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F8": {
      "label": "Read legacy PPT, python-pptx",
      "display": "Unsupported",
      "asOf": "2026-11-17"
    },
    "F9": {
      "label": "Render slide images, python-pptx",
      "display": "Unsupported",
      "asOf": "2026-11-17"
    },
    "F10": {
      "label": "PDF export, python-pptx",
      "display": "Unsupported",
      "asOf": "2026-11-17"
    },
    "F11": {
      "label": "Install, python-pptx",
      "display": "pip install python-pptx",
      "asOf": "2026-11-17"
    },
    "F12": {
      "label": "What it does, python-pptx",
      "display": "Creates, reads, and updates PowerPoint presentation files.",
      "asOf": "2026-11-17"
    },
    "F13": {
      "label": "strengths lead, python-pptx",
      "display": "Builds slides from existing layouts",
      "asOf": "2026-11-17"
    },
    "F14": {
      "label": "strengths, python-pptx",
      "display": "Add slides using a presentation’s existing slide layouts.",
      "asOf": "2026-11-17"
    },
    "F15": {
      "label": "strengths lead, python-pptx",
      "display": "Supports in-memory presentation files",
      "asOf": "2026-11-17"
    },
    "F16": {
      "label": "strengths, python-pptx",
      "display": "Open or save a presentation through a file-like object.",
      "asOf": "2026-11-17"
    },
    "F17": {
      "label": "limitations lead, python-pptx",
      "display": "Expects newer PowerPoint files",
      "asOf": "2026-11-17"
    },
    "F18": {
      "label": "limitations, python-pptx",
      "display": "Convert legacy PPT files to PPTX before opening them.",
      "asOf": "2026-11-17"
    },
    "F19": {
      "label": "limitations lead, python-pptx",
      "display": "Needs another tool for rendering",
      "asOf": "2026-11-17"
    },
    "F20": {
      "label": "limitations, python-pptx",
      "display": "Use a separate renderer for PDF or slide-image output.",
      "asOf": "2026-11-17"
    },
    "F21": {
      "label": "Quickstart, python-pptx",
      "display": "from pptx import Presentation\n\nprs = Presentation()\ntitle_slide_layout = prs.slide_layouts[0]\nslide = prs.slides.add_slide(title_slide_layout)\ntitle = slide.shapes.title\nsubtitle = slide.placeholders[1]\n\ntitle.text = \"Hello, World!\"\nsubtitle.text = \"python-pptx was here!\"\n\nprs.save('test.pptx')\n",
      "asOf": "2026-11-17"
    },
    "F22": {
      "label": "Project function, python-pptx",
      "display": "def _write_pptx_file(\n    self,\n    file_path: Path,\n    content: List[Dict[str, Any]],\n    template: Optional[str] = None,\n) -> None:\n    r\"\"\"Write text content to a PPTX file with enhanced formatting.\n\n    Args:\n        file_path (Path): The target file path.\n        content (List[Dict[str, Any]]): The content to write to the PPTX\n            file. Must be a list of dictionaries where:\n            - First element: Title slide with keys 'title' and 'subtitle'\n            - Subsequent elements: Content slides with keys 'title', 'text'\n        template (Optional[str]): The name of the template to use. If not\n            provided, the default template will be used. (default: :obj:\n            `None`)\n    \"\"\"\n    from pptx import Presentation\n\n    # Use template if provided, otherwise create new presentation\n    if template is not None:\n        template_path = Path(template).resolve()\n        if not template_path.exists():\n            logger.warning(\n                f\"Template file not found: {template_path}, using \"\n                \"default template\"\n            )\n            presentation = Presentation()\n        else:\n            presentation = Presentation(str(template_path))\n            # Clear all existing slides by removing them from the slide\n            # list\n            while len(presentation.slides) > 0:\n                rId = presentation.slides._sldIdLst[-1].rId\n                presentation.part.drop_rel(rId)\n                del presentation.slides._sldIdLst[-1]\n    else:\n        presentation = Presentation()\n\n    slide_width_inch, slide_height_inch = (\n        self._get_slide_width_height_inches(presentation)\n    )\n\n    # Process slides\n    if content:\n        # Title slide (first element)\n        title_slide_data = content.pop(0) if content else {}\n        title_layout = presentation.slide_layouts[0]\n        title_slide = presentation.slides.add_slide(title_layout)\n\n        # Set title and subtitle\n        if title_slide.shapes.title:\n            title_slide.shapes.title.text_frame.clear()\n            self._format_text(\n                title_slide.shapes.title.text_frame.paragraphs[0],\n                title_slide_data.get(\"title\", \"\"),\n            )\n\n        if len(title_slide.placeholders) > 1:\n            subtitle = title_slide.placeholders[1]\n            subtitle.text_frame.clear()\n            self._format_text(\n                subtitle.text_frame.paragraphs[0],\n                title_slide_data.get(\"subtitle\", \"\"),\n            )\n\n        # Content slides\n        for slide_data in content:\n            if not isinstance(slide_data, dict):\n                continue\n\n            # Handle different slide types\n            if 'table' in slide_data:\n                self._handle_table(\n                    presentation,\n                    slide_data,\n                )\n            elif 'bullet_points' in slide_data:\n                if any(\n                    step.startswith(STEP_BY_STEP_PROCESS_MARKER)\n                    for step in slide_data['bullet_points']\n                ):\n                    self._handle_step_by_step_process(\n                        presentation,\n                        slide_data,\n                        slide_width_inch,\n                        slide_height_inch,\n                    )\n                else:\n                    self._handle_default_display(\n                        presentation,\n                        slide_data,\n                    )\n\n    # Save the presentation\n    presentation.save(str(file_path))\n    logger.debug(f\"Wrote PPTX to {file_path} with enhanced formatting\")\n",
      "asOf": "2026-11-17"
    },
    "F23": {
      "label": "Project function reference, python-pptx",
      "display": "pptx_toolkit.py · _write_pptx_file()",
      "asOf": "2026-11-17"
    },
    "F24": {
      "label": "Project repository, python-pptx",
      "display": "camel-ai/camel",
      "asOf": "2026-11-17"
    },
    "F25": {
      "label": "Project stars, camel-ai/camel",
      "display": "18.0K",
      "asOf": "2026-11-17"
    },
    "F26": {
      "label": "Project push date, camel-ai/camel",
      "display": "Nov 2026",
      "asOf": "2026-11-16"
    },
    "F27": {
      "label": "Library name, aspose-slides",
      "display": "Aspose.Slides for Python",
      "asOf": "2026-11-17"
    },
    "F28": {
      "label": "Monthly downloads, aspose-slides",
      "display": "172.4K",
      "asOf": "2026-11-17"
    },
    "F29": {
      "label": "License, aspose-slides",
      "display": "Proprietary",
      "asOf": "2026-11-17"
    },
    "F30": {
      "label": "Package release, aspose-slides",
      "display": "26.11.0, Nov 2026",
      "asOf": "2026-11-14"
    },
    "F31": {
      "label": "Package release date, aspose-slides",
      "display": "Nov 2026",
      "asOf": "2026-11-14"
    },
    "F32": {
      "label": "Repository stars, aspose-slides",
      "display": "12",
      "asOf": "2026-11-17"
    },
    "F33": {
      "label": "Create slides, aspose-slides",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F34": {
      "label": "Read legacy PPT, aspose-slides",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F35": {
      "label": "Render slide images, aspose-slides",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F36": {
      "label": "PDF export, aspose-slides",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F37": {
      "label": "Output formats, aspose-slides",
      "display": "PDF, PNG",
      "asOf": "2026-11-17"
    },
    "F38": {
      "label": "Install, aspose-slides",
      "display": "pip install aspose-slides",
      "asOf": "2026-11-17"
    },
    "F39": {
      "label": "What it does, aspose-slides",
      "display": "Reads, edits, and renders PowerPoint and OpenDocument presentations through the commercial SDK.",
      "asOf": "2026-11-17"
    },
    "F40": {
      "label": "strengths lead, aspose-slides",
      "display": "Reads legacy presentation formats",
      "asOf": "2026-11-17"
    },
    "F41": {
      "label": "strengths, aspose-slides",
      "display": "Open PPT files alongside newer PowerPoint and OpenDocument presentations.",
      "asOf": "2026-11-17"
    },
    "F42": {
      "label": "strengths lead, aspose-slides",
      "display": "Renders presentation previews",
      "asOf": "2026-11-17"
    },
    "F43": {
      "label": "strengths, aspose-slides",
      "display": "Export presentations to PDF or supported image formats.",
      "asOf": "2026-11-17"
    },
    "F44": {
      "label": "limitations lead, aspose-slides",
      "display": "Unlicensed output contains watermarks",
      "asOf": "2026-11-17"
    },
    "F45": {
      "label": "limitations, aspose-slides",
      "display": "Evaluation mode adds a watermark to every saved presentation slide.",
      "asOf": "2026-11-17"
    },
    "F46": {
      "label": "limitations lead, aspose-slides",
      "display": "Evaluation truncates extracted text",
      "asOf": "2026-11-17"
    },
    "F47": {
      "label": "limitations, aspose-slides",
      "display": "Text read in evaluation mode is shortened and marked with a notice.",
      "asOf": "2026-11-17"
    },
    "F48": {
      "label": "Quickstart, aspose-slides",
      "display": "import aspose.slides as slides\n\n# Instantiates a Presentation object that represents a presentation file\nwith slides.Presentation() as presentation:\n    slide = presentation.slides[0]\n    # Adds an autoshape with type set to line\n    slide.shapes.add_auto_shape(slides.ShapeType.LINE, 50, 150, 300, 0)\n    presentation.save(\"NewPresentation_out.pptx\", slides.export.SaveFormat.PPTX)\n",
      "asOf": "2026-11-17"
    },
    "F49": {
      "label": "Project function, aspose-slides",
      "display": "def add_text_shape(\n    pres: slides.Presentation,\n    slide_index: int,\n    req: TextShapeRequest,\n    canvas_w_px: float,\n    canvas_h_px: float,\n) -> int:\n    slide = pres.slides[slide_index]\n    slide_w_pt = float(pres.slide_size.size.width)\n    slide_h_pt = float(pres.slide_size.size.height)\n\n    x, y, w, h = _bbox_to_pt(req.bbox, canvas_w_px, canvas_h_px, slide_w_pt, slide_h_pt)\n    shape = slide.shapes.add_auto_shape(slides.ShapeType.RECTANGLE, x, y, w, h)\n    shape.line_format.fill_format.fill_type = slides.FillType.NO_FILL\n\n    if req.bg_color:\n        shape.fill_format.fill_type = slides.FillType.SOLID\n        shape.fill_format.solid_fill_color.color = _hex_to_color(req.bg_color)\n    else:\n        shape.fill_format.fill_type = slides.FillType.NO_FILL\n\n    tf = shape.text_frame\n    tf.text_frame_format.autofit_type = slides.TextAutofitType.NONE\n    tf.text_frame_format.wrap_text = slides.NullableBool.TRUE\n\n    top_pad, right_pad, bottom_pad, left_pad = req.padding_px\n    tf.text_frame_format.margin_top = _px_to_pt(top_pad, canvas_h_px, slide_h_pt)\n    tf.text_frame_format.margin_right = _px_to_pt(right_pad, canvas_w_px, slide_w_pt)\n    tf.text_frame_format.margin_bottom = _px_to_pt(bottom_pad, canvas_h_px, slide_h_pt)\n    tf.text_frame_format.margin_left = _px_to_pt(left_pad, canvas_w_px, slide_w_pt)\n\n    # Strip the default placeholder paragraph Aspose seeds in every text frame.\n    while tf.paragraphs.count > 0:\n        tf.paragraphs.remove_at(0)\n\n    for para_model in req.paragraphs:\n        para = _build_paragraph(para_model, canvas_h_px, slide_h_pt)\n        tf.paragraphs.add(para)\n\n    return slide.shapes.index_of(shape)\n",
      "asOf": "2026-11-17"
    },
    "F50": {
      "label": "Project function reference, aspose-slides",
      "display": "builder.py · add_text_shape()",
      "asOf": "2026-11-17"
    },
    "F51": {
      "label": "Project repository, aspose-slides",
      "display": "Fergana-Labs/stash",
      "asOf": "2026-11-17"
    },
    "F52": {
      "label": "Project stars, Fergana-Labs/stash",
      "display": "343",
      "asOf": "2026-11-17"
    },
    "F53": {
      "label": "Project push date, Fergana-Labs/stash",
      "display": "Nov 2026",
      "asOf": "2026-11-14"
    },
    "F54": {
      "label": "Library name, Spire.Presentation",
      "display": "Spire.Presentation",
      "asOf": "2026-11-17"
    },
    "F55": {
      "label": "Monthly downloads, Spire.Presentation",
      "display": "36.3K",
      "asOf": "2026-11-17"
    },
    "F56": {
      "label": "License, Spire.Presentation",
      "display": "Proprietary",
      "asOf": "2026-11-17"
    },
    "F57": {
      "label": "Package release, Spire.Presentation",
      "display": "11.8.1, Aug 2026",
      "asOf": "2026-08-25"
    },
    "F58": {
      "label": "Package release date, Spire.Presentation",
      "display": "Aug 2026",
      "asOf": "2026-08-25"
    },
    "F59": {
      "label": "Repository stars, Spire.Presentation",
      "display": "10",
      "asOf": "2026-11-17"
    },
    "F60": {
      "label": "Create slides, Spire.Presentation",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F61": {
      "label": "Read legacy PPT, Spire.Presentation",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F62": {
      "label": "Render slide images, Spire.Presentation",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F63": {
      "label": "PDF export, Spire.Presentation",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F64": {
      "label": "Output formats, Spire.Presentation",
      "display": "PDF, HTML, SVG",
      "asOf": "2026-11-17"
    },
    "F65": {
      "label": "Install, Spire.Presentation",
      "display": "pip install Spire.Presentation",
      "asOf": "2026-11-17"
    },
    "F66": {
      "label": "What it does, Spire.Presentation",
      "display": "Creates, edits, and converts PowerPoint presentations through the professional Python SDK.",
      "asOf": "2026-11-17"
    },
    "F67": {
      "label": "strengths lead, Spire.Presentation",
      "display": "Reads older PowerPoint formats",
      "asOf": "2026-11-17"
    },
    "F68": {
      "label": "strengths, Spire.Presentation",
      "display": "Open legacy PPT presentations alongside newer PPTX files.",
      "asOf": "2026-11-17"
    },
    "F69": {
      "label": "strengths lead, Spire.Presentation",
      "display": "Exports slide previews",
      "asOf": "2026-11-17"
    },
    "F70": {
      "label": "strengths, Spire.Presentation",
      "display": "Render slides to images or export a presentation as PDF.",
      "asOf": "2026-11-17"
    },
    "F71": {
      "label": "limitations lead, Spire.Presentation",
      "display": "Evaluation output shows a message",
      "asOf": "2026-11-17"
    },
    "F72": {
      "label": "limitations, Spire.Presentation",
      "display": "Use a temporary license to evaluate conversion without the message.",
      "asOf": "2026-11-17"
    },
    "F73": {
      "label": "Quickstart, Spire.Presentation",
      "display": "from spire.presentation.common import *\nimport math\nfrom spire.presentation import *\n\n\noutputFile =\"HelloWorld.pptx\"\n\n#Create a PPT document\npresentation = Presentation()\n\n#Add a new shape to the PPT document\nleft = math.trunc(presentation.SlideSize.Size.Width / float(2))-250\nrec = RectangleF.FromLTRB(left, 80, left+500, 150+80)\nshape = presentation.Slides[0].Shapes.AppendShape(ShapeType.Rectangle, rec)\nshape.ShapeStyle.LineColor.Color = Color.get_White()\nshape.Fill.FillType = FillFormatType.none\n\n#Add text to the shape\nshape.AppendTextFrame(\"Hello World!\")\n\n#Set the font and fill style of the text\ntextRange = shape.TextFrame.TextRange\ntextRange.Fill.FillType = FillFormatType.Solid\ntextRange.Fill.SolidColor.Color = Color.get_CadetBlue()\ntextRange.FontHeight = 66\ntextRange.LatinFont = TextFont(\"Lucida Sans Unicode\")\n\n#Save the document\npresentation.SaveToFile(outputFile, FileFormat.Pptx2010)\npresentation.Dispose()\n",
      "asOf": "2026-11-17"
    },
    "F74": {
      "label": "Project function, Spire.Presentation",
      "display": "def combine_ppt_files_with_spire(source_folder, output_file, png_names=None):\n    \"\"\"\n    使用 Spire.Presentation 合并PPT文件，每个PPT只保留第一页，并保留原始设计\n\n    Args:\n        source_folder: 源PPT文件所在的文件夹路径\n        output_file: 输出的合并PPT文件路径\n    \"\"\"\n    # 获取所有pptx文件并按字典序排序\n\n    ppt_files = sorted([f for f in os.listdir(source_folder) if f.endswith('.pptx')])\n\n    ppt_names = [png_name.replace(\".png\", \".pptx\") for png_name in png_names] if png_names else None\n\n    if not ppt_files:\n        print(\"未找到任何PPT文件\")\n        return\n\n    print(f\"找到 {len(ppt_files)} 个PPT文件:\")\n    valid_ppt_files = []\n    for idx, file in enumerate(ppt_files, 1):\n        print(f\"  {idx}. {file}\")\n        if ppt_names and file in ppt_names:\n            valid_ppt_files.append(file)\n    if ppt_names:\n        ppt_files = valid_ppt_files\n        print(f\"\\n根据提供的PNG名称过滤后，剩余 {len(ppt_files)} 个PPT文件:\")\n\n    # 创建主演示文稿对象，使用第一个PPT作为基础\n    first_ppt_path = os.path.join(source_folder, ppt_files[0])\n    main_pres = Presentation()\n    main_pres.LoadFromFile(first_ppt_path)\n\n    # 删除第一个PPT的多余页面，只保留第一页\n    while main_pres.Slides.Count > 1:\n        main_pres.Slides.RemoveAt(1)\n\n    print(f\"  已添加: {ppt_files[0]} (第1页)\")\n\n    # 遍历剩余的PPT文件\n    for ppt_file in ppt_files[1:]:\n        file_path = os.path.join(source_folder, ppt_file)\n\n        # 加载当前PPT文件\n        temp_pres = Presentation()\n        temp_pres.LoadFromFile(file_path)\n\n        if temp_pres.Slides.Count > 0:\n            # 使用 AppendBySlide 方法追加第一页，保留原始设计\n            main_pres.Slides.AppendBySlide(temp_pres.Slides[0])\n            print(f\"  已添加: {ppt_file} (第1页)\")\n        else:\n            print(f\"  跳过: {ppt_file} (无幻灯片)\")\n\n        # 释放临时演示文稿资源\n        temp_pres.Dispose()\n\n    # 保存合并后的PPT\n    main_pres.SaveToFile(output_file, FileFormat.Pptx2016)\n    print(f\"\\n合并完成！输出文件: {output_file}\")\n    print(f\"总共合并了 {main_pres.Slides.Count} 页幻灯片\")\n\n    # 释放资源\n    main_pres.Dispose()\n\n    valid_png_names = [ppt_name.replace(\".pptx\", \".png\") for ppt_name in ppt_files] # 返回真正存在的png names\n\n    return valid_png_names\n",
      "asOf": "2026-11-17"
    },
    "F75": {
      "label": "Project function reference, Spire.Presentation",
      "display": "ppt_combiner.py · combine_ppt_files_with_spire()",
      "asOf": "2026-11-17"
    },
    "F76": {
      "label": "Project repository, Spire.Presentation",
      "display": "elliottzheng/NotebookLM2PPT",
      "asOf": "2026-11-17"
    },
    "F77": {
      "label": "Project stars, elliottzheng/NotebookLM2PPT",
      "display": "499",
      "asOf": "2026-11-17"
    },
    "F78": {
      "label": "Project push date, elliottzheng/NotebookLM2PPT",
      "display": "Feb 2026",
      "asOf": "2026-02-03"
    },
    "F79": {
      "label": "Library name, aspose-slides-foss",
      "display": "Aspose.Slides FOSS",
      "asOf": "2026-11-17"
    },
    "F80": {
      "label": "Monthly downloads, aspose-slides-foss",
      "display": "436",
      "asOf": "2026-11-17"
    },
    "F81": {
      "label": "License, aspose-slides-foss",
      "display": "MIT",
      "asOf": "2026-11-17"
    },
    "F82": {
      "label": "Package release, aspose-slides-foss",
      "display": "26.8.0, Jul 2026",
      "asOf": "2026-07-28"
    },
    "F83": {
      "label": "Package release date, aspose-slides-foss",
      "display": "Jul 2026",
      "asOf": "2026-07-28"
    },
    "F84": {
      "label": "Repository stars, aspose-slides-foss",
      "display": "17",
      "asOf": "2026-11-17"
    },
    "F85": {
      "label": "Create slides, aspose-slides-foss",
      "display": "Built-in",
      "asOf": "2026-11-17"
    },
    "F86": {
      "label": "Read legacy PPT, aspose-slides-foss",
      "display": "Unsupported",
      "asOf": "2026-11-17"
    },
    "F87": {
      "label": "Render slide images, aspose-slides-foss",
      "display": "Unsupported",
      "asOf": "2026-11-17"
    },
    "F88": {
      "label": "PDF export, aspose-slides-foss",
      "display": "Unsupported",
      "asOf": "2026-11-17"
    },
    "F89": {
      "label": "Output formats, aspose-slides-foss",
      "display": "Markdown",
      "asOf": "2026-11-17"
    },
    "F90": {
      "label": "Install, aspose-slides-foss",
      "display": "pip install aspose-slides-foss",
      "asOf": "2026-11-17"
    },
    "F91": {
      "label": "What it does, aspose-slides-foss",
      "display": "Creates, reads, and edits PowerPoint files through an open-source Python implementation.",
      "asOf": "2026-11-17"
    },
    "F92": {
      "label": "strengths lead, aspose-slides-foss",
      "display": "Exports presentation text as Markdown",
      "asOf": "2026-11-17"
    },
    "F93": {
      "label": "strengths, aspose-slides-foss",
      "display": "Export text, tables, lists, headings, comments, and chart data as Markdown.",
      "asOf": "2026-11-17"
    },
    "F94": {
      "label": "strengths lead, aspose-slides-foss",
      "display": "Retains unfamiliar XML parts",
      "asOf": "2026-11-17"
    },
    "F95": {
      "label": "strengths, aspose-slides-foss",
      "display": "Retain unknown XML parts when saving an existing presentation.",
      "asOf": "2026-11-17"
    },
    "F96": {
      "label": "limitations lead, aspose-slides-foss",
      "display": "Needs another tool for rendering",
      "asOf": "2026-11-17"
    },
    "F97": {
      "label": "limitations, aspose-slides-foss",
      "display": "Use another tool for PDF, HTML, or slide-image export.",
      "asOf": "2026-11-17"
    },
    "F98": {
      "label": "limitations lead, aspose-slides-foss",
      "display": "SmartArt editing remains unimplemented",
      "asOf": "2026-11-17"
    },
    "F99": {
      "label": "limitations, aspose-slides-foss",
      "display": "SmartArt, OLE objects, and mathematical text raise NotImplementedError.",
      "asOf": "2026-11-17"
    },
    "F100": {
      "label": "limitations lead, aspose-slides-foss",
      "display": "Published release excludes hyperlink editing",
      "asOf": "2026-11-17"
    },
    "F101": {
      "label": "limitations, aspose-slides-foss",
      "display": "Use the newer source build for hyperlink implementation changes.",
      "asOf": "2026-11-17"
    },
    "F102": {
      "label": "Quickstart, aspose-slides-foss",
      "display": "from aspose.slides_foss import ShapeType, NullableBool, FillType\nfrom aspose.slides_foss.drawing import Color\nimport aspose.slides_foss as slides\nfrom aspose.slides_foss.export import SaveFormat\n\nwith slides.Presentation() as prs:\n    shape = prs.slides[0].shapes.add_auto_shape(ShapeType.RECTANGLE, 50, 50, 400, 150)\n    tf = shape.add_text_frame(\"Formatted text\")\n    fmt = tf.paragraphs[0].portions[0].portion_format\n    fmt.font_height = 24\n    fmt.font_bold = NullableBool.TRUE\n    fmt.fill_format.fill_type = FillType.SOLID\n    fmt.fill_format.solid_fill_color.color = Color.from_argb(255, 0, 70, 127)\n    prs.save(\"text.pptx\", SaveFormat.PPTX)\n",
      "asOf": "2026-11-17"
    },
    "F103": {
      "label": "Developer need",
      "display": "Creating slides from an existing layout",
      "asOf": "2026-11-17"
    },
    "F104": {
      "label": "Why choose python-pptx",
      "display": "layout-based slide creation",
      "asOf": "2026-11-17"
    },
    "F105": {
      "label": "Developer need in introduction",
      "display": "creating slides from an existing layout",
      "asOf": "2026-11-17"
    },
    "F106": {
      "label": "When to consider aspose-slides",
      "display": "PDF or image rendering is required",
      "asOf": "2026-11-17"
    },
    "F107": {
      "label": "Developer need",
      "display": "Exporting presentation text as Markdown",
      "asOf": "2026-11-17"
    },
    "F108": {
      "label": "Why choose aspose-slides-foss",
      "display": "text, tables, comments, and chart data in Markdown",
      "asOf": "2026-11-17"
    },
    "F109": {
      "label": "Developer need in introduction",
      "display": "exporting presentation text as Markdown",
      "asOf": "2026-11-17"
    },
    "F110": {
      "label": "When to consider aspose-slides",
      "display": "the integration needs native rendered previews",
      "asOf": "2026-11-17"
    },
    "F111": {
      "label": "Developer need",
      "display": "Rendering legacy presentations",
      "asOf": "2026-11-17"
    },
    "F112": {
      "label": "Why choose aspose-slides",
      "display": "PDF and supported image conversion",
      "asOf": "2026-11-17"
    },
    "F113": {
      "label": "Developer need in introduction",
      "display": "rendering legacy presentations",
      "asOf": "2026-11-17"
    },
    "F114": {
      "label": "When to consider aspose-slides-foss",
      "display": "text-oriented Markdown export covers the downstream task",
      "asOf": "2026-11-17"
    },
    "F115": {
      "label": "Developer need",
      "display": "Creating image previews in Python",
      "asOf": "2026-11-17"
    },
    "F116": {
      "label": "Why choose Spire.Presentation",
      "display": "slide images and presentation PDF conversion",
      "asOf": "2026-11-17"
    },
    "F117": {
      "label": "Developer need in introduction",
      "display": "creating image previews in Python",
      "asOf": "2026-11-17"
    },
    "F118": {
      "label": "When to consider python-pptx",
      "display": "creating editable files from layouts is sufficient",
      "asOf": "2026-11-17"
    },
    "F119": {
      "label": "Page introduction",
      "display": "Python PowerPoint libraries let application developers read or create presentation files.",
      "asOf": "2026-11-17"
    },
    "F120": {
      "label": "FAQ: Which Python library should I use to edit a PowerPoint file?",
      "display": "python-pptx creates, reads, and updates PowerPoint files.",
      "asOf": "2026-11-17"
    },
    "F121": {
      "label": "FAQ: Which Python library should I use to edit a PowerPoint file?",
      "display": "The separately packaged Aspose.Slides FOSS implementation also creates, reads, and edits presentation files.",
      "asOf": "2026-11-17"
    },
    "F122": {
      "label": "FAQ: Can python-pptx open legacy PPT files?",
      "display": "Legacy PPT files from older PowerPoint versions cannot be opened through its documented presentation loader.",
      "asOf": "2026-11-17"
    },
    "F123": {
      "label": "FAQ: Can python-pptx render a presentation as PDF or images?",
      "display": "Its maintainer explicitly places rendering outside the library’s scope.",
      "asOf": "2026-11-17"
    },
    "F124": {
      "label": "FAQ: Can python-pptx render a presentation as PDF or images?",
      "display": "The commercial Aspose SDK explicitly converts presentations to PDF and images.",
      "asOf": "2026-11-17"
    },
    "F125": {
      "label": "FAQ: Is Aspose.Slides FOSS the same package as the commercial SDK?",
      "display": "The FOSS package imports aspose.slides_foss.",
      "asOf": "2026-11-17"
    },
    "F126": {
      "label": "FAQ: Is Aspose.Slides FOSS the same package as the commercial SDK?",
      "display": "The commercial Python SDK imports aspose.slides.",
      "asOf": "2026-11-17"
    },
    "F127": {
      "label": "FAQ: Does the FOSS package render slide previews?",
      "display": "The tagged FOSS release lists PDF, HTML, SVG, and image export as unimplemented.",
      "asOf": "2026-11-17"
    },
    "F128": {
      "label": "FAQ: Can presentation text be exported as Markdown?",
      "display": "The FOSS release supports Markdown text export including tables, lists, headings, comments, and chart data.",
      "asOf": "2026-11-17"
    },
    "F129": {
      "label": "FAQ: Can presentation text be exported as Markdown?",
      "display": "Its Markdown export is text-only and skips images, media and SmartArt.",
      "asOf": "2026-11-17"
    },
    "F130": {
      "label": "FAQ: What happens to unknown XML parts in a FOSS presentation?",
      "display": "The release README states unknown XML parts are preserved when saving an opened file.",
      "asOf": "2026-11-17"
    },
    "F131": {
      "label": "FAQ: Are all features on the FOSS repository page in the published package?",
      "display": "The repository explicitly says its published release predates current source changes, including hyperlinks.",
      "asOf": "2026-11-17"
    },
    "F132": {
      "label": "FAQ: Are all features on the FOSS repository page in the published package?",
      "display": "The tagged release lists hyperlinks and action settings as unimplemented.",
      "asOf": "2026-11-17"
    },
    "F133": {
      "label": "FAQ: What changes in unlicensed Aspose evaluation mode?",
      "display": "Each saved slide receives an evaluation watermark.",
      "asOf": "2026-11-17"
    },
    "F134": {
      "label": "FAQ: What changes in unlicensed Aspose evaluation mode?",
      "display": "Read text is truncated and marked, while text written by the application is saved in full.",
      "asOf": "2026-11-17"
    },
    "F135": {
      "label": "FAQ: Is Spire.Presentation the same as its Free distribution?",
      "display": "This comparison uses the professional Spire.Presentation package.",
      "asOf": "2026-11-17"
    },
    "F136": {
      "label": "FAQ: Is Spire.Presentation the same as its Free distribution?",
      "display": "The Free distribution is published separately as Spire.Presentation.Free.",
      "asOf": "2026-11-17"
    },
    "F137": {
      "label": "FAQ: Can python-pptx work without writing a temporary presentation file?",
      "display": "Its documented loader/saver accepts file-like objects as well as filesystem paths.",
      "asOf": "2026-11-17"
    },
    "F138": {
      "label": "FAQ: Do presentation templates affect generated slide appearance?",
      "display": "Presentation themes, masters, and layouts determine much of a slide’s appearance.",
      "asOf": "2026-11-17"
    },
    "F139": {
      "label": "FAQ: Do presentation templates affect generated slide appearance?",
      "display": "The toolkit loads a supplied template, then removes its existing slides before building replacements.",
      "asOf": "2026-11-17"
    },
    "F140": {
      "label": "Library name, python-pptx",
      "display": "python-pptx",
      "asOf": "2026-11-20"
    },
    "F141": {
      "label": "Monthly downloads, python-pptx",
      "display": "142.1M",
      "asOf": "2026-11-20"
    },
    "F142": {
      "label": "License, python-pptx",
      "display": "MIT",
      "asOf": "2026-11-20"
    },
    "F143": {
      "label": "Package release, python-pptx",
      "display": "1.0.2",
      "asOf": "2026-11-20"
    },
    "F144": {
      "label": "Package release date, python-pptx",
      "display": "Aug 2024",
      "asOf": "2026-11-20"
    },
    "F145": {
      "label": "Install, python-pptx",
      "display": "pip install python-pptx",
      "asOf": "2026-11-20"
    },
    "F146": {
      "label": "Quickstart, python-pptx",
      "display": "from pptx import Presentation\n\nprs = Presentation()\ntitle_slide_layout = prs.slide_layouts[0]\nslide = prs.slides.add_slide(title_slide_layout)\ntitle = slide.shapes.title\nsubtitle = slide.placeholders[1]\n\ntitle.text = \"Hello, World!\"\nsubtitle.text = \"python-pptx was here!\"\n\nprs.save('test.pptx')\n",
      "asOf": "2026-11-20"
    },
    "F147": {
      "label": "Repository stars, python-pptx",
      "display": "3.6K",
      "asOf": "2026-11-20"
    },
    "F148": {
      "label": "Shape object model, python-pptx",
      "display": "Yes",
      "asOf": "2026-11-20"
    },
    "F149": {
      "label": "Slide image export, python-pptx",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F150": {
      "label": "Presentation API and backend role, python-pptx",
      "display": "Portable OOXML presentation creation/read/update with native slide and shape objects.",
      "asOf": "2026-11-20"
    },
    "F151": {
      "label": "Python metadata requirement, python-pptx",
      "display": ">=3.8",
      "asOf": "2026-11-20"
    },
    "F152": {
      "label": "First-call prerequisites, python-pptx",
      "display": "[\"Official basic create/save example. No SDK/Office/rendering execution during research.\", \"Requires compatible Python/dependencies but not an installed PowerPoint application.\"]",
      "asOf": "2026-11-20"
    },
    "F153": {
      "label": "Original project API contract, python-pptx",
      "display": "{\"status\": \"verified\", \"arguments\": \"Camel imports the current public pptx.Presentation factory. Calls construct a default presentation or open an existing .pptx path as string; loaded templates must provide layout0 and the expected title/subtitle placeholders. The title helper assumes placeholder index1 exists when more than one placeholder is present; arbitrary custom templates are not guaranteed. Current1.0.2 Slides.add_slide accepts a SlideLayout; TextFrame.clear leaves one empty paragraph for paragraphs[0]. Template reset deliberately uses private slides._sldIdLst,slide-ID.rId,and Part.drop_rel. Exact1.0.2 release source proves these current fields/arguments,not a stable public slide-deletion guarantee. Host _format_text/table/bullet helpers remain required and are not extra direct SDK calls.\", \"used_return_shapes\": \"Factory returns Presentation; add_slide returns Slide; title/text_frame/paragraph objects remain typed native objects. save writes the OPC .pptx file and returns None; this whole helper returns None. Original content.pop(0) mutates the caller list. Private relationship deletion removes slide IDs from the chosen template; no general custom-show/relationship normalization or image rendering is claimed.\"}",
      "asOf": "2026-11-20"
    },
    "F154": {
      "label": "Template reset and mutation, python-pptx",
      "display": "Selected source clears template slide IDs using current private XML/relationship members and pops the first content item from the caller list. Layout0 and expected title/subtitle placeholder indexes must exist.",
      "asOf": "2026-11-20"
    },
    "F155": {
      "label": "Project function, python-pptx",
      "display": "def _write_pptx_file(\n    self,\n    file_path: Path,\n    content: List[Dict[str, Any]],\n    template: Optional[str] = None,\n) -> None:\n    r\"\"\"Write text content to a PPTX file with enhanced formatting.\n\n    Args:\n        file_path (Path): The target file path.\n        content (List[Dict[str, Any]]): The content to write to the PPTX\n            file. Must be a list of dictionaries where:\n            - First element: Title slide with keys 'title' and 'subtitle'\n            - Subsequent elements: Content slides with keys 'title', 'text'\n        template (Optional[str]): The name of the template to use. If not\n            provided, the default template will be used. (default: :obj:\n            `None`)\n    \"\"\"\n    from pptx import Presentation\n\n    # Use template if provided, otherwise create new presentation\n    if template is not None:\n        template_path = Path(template).resolve()\n        if not template_path.exists():\n            logger.warning(\n                f\"Template file not found: {template_path}, using \"\n                \"default template\"\n            )\n            presentation = Presentation()\n        else:\n            presentation = Presentation(str(template_path))\n            # Clear all existing slides by removing them from the slide\n            # list\n            while len(presentation.slides) > 0:\n                rId = presentation.slides._sldIdLst[-1].rId\n                presentation.part.drop_rel(rId)\n                del presentation.slides._sldIdLst[-1]\n    else:\n        presentation = Presentation()\n\n    slide_width_inch, slide_height_inch = (\n        self._get_slide_width_height_inches(presentation)\n    )\n\n    # Process slides\n    if content:\n        # Title slide (first element)\n        title_slide_data = content.pop(0) if content else {}\n        title_layout = presentation.slide_layouts[0]\n        title_slide = presentation.slides.add_slide(title_layout)\n\n        # Set title and subtitle\n        if title_slide.shapes.title:\n            title_slide.shapes.title.text_frame.clear()\n            self._format_text(\n                title_slide.shapes.title.text_frame.paragraphs[0],\n                title_slide_data.get(\"title\", \"\"),\n            )\n\n        if len(title_slide.placeholders) > 1:\n            subtitle = title_slide.placeholders[1]\n            subtitle.text_frame.clear()\n            self._format_text(\n                subtitle.text_frame.paragraphs[0],\n                title_slide_data.get(\"subtitle\", \"\"),\n            )\n\n        # Content slides\n        for slide_data in content:\n            if not isinstance(slide_data, dict):\n                continue\n\n            # Handle different slide types\n            if 'table' in slide_data:\n                self._handle_table(\n                    presentation,\n                    slide_data,\n                )\n            elif 'bullet_points' in slide_data:\n                if any(\n                    step.startswith(STEP_BY_STEP_PROCESS_MARKER)\n                    for step in slide_data['bullet_points']\n                ):\n                    self._handle_step_by_step_process(\n                        presentation,\n                        slide_data,\n                        slide_width_inch,\n                        slide_height_inch,\n                    )\n                else:\n                    self._handle_default_display(\n                        presentation,\n                        slide_data,\n                    )\n\n    # Save the presentation\n    presentation.save(str(file_path))\n    logger.debug(f\"Wrote PPTX to {file_path} with enhanced formatting\")\n",
      "asOf": "2026-11-20"
    },
    "F156": {
      "label": "Project source file, python-pptx",
      "display": "camel/toolkits/pptx_toolkit.py",
      "asOf": "2026-11-20"
    },
    "F157": {
      "label": "Project full_name, python-pptx",
      "display": "camel-ai/camel",
      "asOf": "2026-11-20"
    },
    "F158": {
      "label": "Project stargazers_count, python-pptx",
      "display": "18.0K",
      "asOf": "2026-11-20"
    },
    "F159": {
      "label": "Library name, pywin32",
      "display": "pywin32",
      "asOf": "2026-11-20"
    },
    "F160": {
      "label": "Monthly downloads, pywin32",
      "display": "19.5M",
      "asOf": "2026-11-20"
    },
    "F161": {
      "label": "License, pywin32",
      "display": "PSF",
      "asOf": "2026-11-20"
    },
    "F162": {
      "label": "Package release, pywin32",
      "display": "312",
      "asOf": "2026-11-20"
    },
    "F163": {
      "label": "Package release date, pywin32",
      "display": "Jun 2026",
      "asOf": "2026-11-20"
    },
    "F164": {
      "label": "Install, pywin32",
      "display": "pip install pywin32",
      "asOf": "2026-11-20"
    },
    "F165": {
      "label": "Quickstart, pywin32",
      "display": "from win32com.client import Dispatch\n\npowerpoint = Dispatch(\"PowerPoint.Application\")\npresentation = powerpoint.Presentations.Add()\n",
      "asOf": "2026-11-20"
    },
    "F166": {
      "label": "Official description, pywin32",
      "display": "Provides Python extensions for Windows.",
      "asOf": "2026-11-20"
    },
    "F167": {
      "label": "Quickstart source file, pywin32",
      "display": "com/win32com/client/__init__.py",
      "asOf": "2026-11-20"
    },
    "F168": {
      "label": "Repository stars, pywin32",
      "display": "5.6K",
      "asOf": "2026-11-20"
    },
    "F169": {
      "label": "Shape object model, pywin32",
      "display": "Via plugin",
      "asOf": "2026-11-20"
    },
    "F170": {
      "label": "Slide image export, pywin32",
      "display": "Via plugin",
      "asOf": "2026-11-20"
    },
    "F171": {
      "label": "Presentation API and backend role, pywin32",
      "display": "Windows APIs including COM automation; PowerPoint capability comes from the registered native Office application.",
      "asOf": "2026-11-20"
    },
    "F172": {
      "label": "Python metadata requirement, pywin32",
      "display": ">=3.9",
      "asOf": "2026-11-20"
    },
    "F173": {
      "label": "First-call prerequisites, pywin32",
      "display": "[\"Disclosed COM API recipe,not an upstream Python PowerPoint starter. Windows and an installed,registered Microsoft PowerPoint COM server are required. The basic call creates an in-memory presentation through Office; no file is saved. COM objects/application lifecycle belong to the actual caller; this research does not launch Office.\"]",
      "asOf": "2026-11-20"
    },
    "F174": {
      "label": "COM versus file SDK scope, pywin32",
      "display": "The Python package exposes a registered COM application object; slide,shape,and rendering methods originate Microsoft PowerPoint. Windows and an available application registration are required for these specific capabilities.",
      "asOf": "2026-11-20"
    },
    "F175": {
      "label": "Library name, pypandoc",
      "display": "PyPandoc",
      "asOf": "2026-11-20"
    },
    "F176": {
      "label": "Monthly downloads, pypandoc",
      "display": "4.5M",
      "asOf": "2026-11-20"
    },
    "F177": {
      "label": "License, pypandoc",
      "display": "MIT",
      "asOf": "2026-11-20"
    },
    "F178": {
      "label": "Package release, pypandoc",
      "display": "1.17",
      "asOf": "2026-11-20"
    },
    "F179": {
      "label": "Package release date, pypandoc",
      "display": "Mar 2026",
      "asOf": "2026-11-20"
    },
    "F180": {
      "label": "Install, pypandoc",
      "display": "pip install pypandoc",
      "asOf": "2026-11-20"
    },
    "F181": {
      "label": "Quickstart, pypandoc",
      "display": "import pypandoc\n\npypandoc.convert_text(\"# Example\\n\\nContent\", \"pptx\", format=\"md\", outputfile=\"example.pptx\")\n",
      "asOf": "2026-11-20"
    },
    "F182": {
      "label": "Official description, pypandoc",
      "display": "Wraps Pandoc in a thin Python layer.",
      "asOf": "2026-11-20"
    },
    "F183": {
      "label": "Quickstart source file, pypandoc",
      "display": "pypandoc/__init__.py",
      "asOf": "2026-11-20"
    },
    "F184": {
      "label": "Repository stars, pypandoc",
      "display": "1.2K",
      "asOf": "2026-11-20"
    },
    "F185": {
      "label": "Shape object model, pypandoc",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F186": {
      "label": "Slide image export, pypandoc",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F187": {
      "label": "Presentation API and backend role, pypandoc",
      "display": "String/file converter frontend to an external Pandoc executable; supports PPTX output without a Python slide object model.",
      "asOf": "2026-11-20"
    },
    "F188": {
      "label": "Python metadata requirement, pypandoc",
      "display": ">=3.7",
      "asOf": "2026-11-20"
    },
    "F189": {
      "label": "First-call prerequisites, pypandoc",
      "display": "[\"Disclosed minimal Markdown-to-PPTX API recipe. An available compatible Pandoc executable is required; ordinary pypandoc does not bundle it. Binary PPTX output needs outputfile and returns an empty string. pypandoc_binary is the same Python API with a bundled engine,not a separate library choice.\"]",
      "asOf": "2026-11-20"
    },
    "F190": {
      "label": "Original project API contract, pypandoc",
      "display": "{\"status\": \"verified\", \"arguments\": \"The original MCP server imports pypandoc and explicitly includes pptx in output and file-required formats. Current1.17 accepts input file/text,to format,optional input format,outputfile,and extra_args. The complete326line tool handler validates output paths and delegates file and in-memory sources through two distinct documented APIs on mutually exclusive paths; it does not run both APIs for every conversion. PowerPoint usage here requires a supported source format (for example Markdown),pptx output,and a complete output filename. Pandoc CLI,requested filters,reference templates,and fonts must exist in the actual host. The host intentionally disallows pptx input even when a newer installed Pandoc reader supports it.\", \"used_return_shapes\": \"With outputfile,the native conversion returns an empty string after writing the file. Original code returns its own success/path message and does not mistake that empty string for failure in file-output branches. Without outputfile,it consumes converted text. Binary PPTX output requires a filename; no byte-string decoding or native slide geometry model is assumed. Input-format availability and writer details come from the installed Pandoc executable,not the Python package version alone.\"}",
      "asOf": "2026-11-20"
    },
    "F191": {
      "label": "Pandoc version and presentation model, pypandoc",
      "display": "Pandoc3.8.3 added a PPTX reader; backend version and wrapper configuration determine input support. Python wrappers are not intrinsically write-only. Conversion uses a semantic document model,not a native PowerPoint geometry/roundtrip renderer.",
      "asOf": "2026-11-20"
    },
    "F192": {
      "label": "Project function, pypandoc",
      "display": "async def handle_call_tool(\n    name: str, arguments: dict | None\n) -> list[types.TextContent | types.ImageContent | types.EmbeddedResource]:\n    \"\"\"Handle tool execution requests.\n\n    Tools can modify server state and notify clients of changes.\n    \"\"\"\n    if name not in [\"convert-contents\"]:\n        raise ValueError(f\"Unknown tool: {name}\")\n\n    if not arguments:\n        raise ValueError(\"Missing arguments\")\n\n    # Extract all possible arguments\n    contents = arguments.get(\"contents\")\n    input_file = arguments.get(\"input_file\")\n    output_file = arguments.get(\"output_file\")\n    output_format = arguments.get(\"output_format\", \"markdown\").lower()\n    input_format = arguments.get(\"input_format\", \"markdown\").lower()\n    # The public MCP schema uses \"txt\"; Pandoc names the equivalent writer \"plain\".\n    pandoc_output_format = \"plain\" if output_format == \"txt\" else output_format\n    reference_doc = arguments.get(\"reference_doc\")\n    filters = arguments.get(\"filters\", [])\n    defaults_file = arguments.get(\"defaults_file\")\n\n    # Validate input parameters\n    if not contents and not input_file:\n        raise ValueError(\"Either 'contents' or 'input_file' must be provided\")\n\n    # Validate reference_doc if provided\n    if reference_doc:\n        if output_format not in REFERENCE_DOC_FORMATS:\n            raise ValueError(\n                f\"reference_doc is not supported for '{output_format}' output format. \"\n                f\"Supported formats: {_join_with_and(REFERENCE_DOC_FORMATS)}\"\n            )\n        if not os.path.exists(reference_doc):\n            raise ValueError(f\"Reference document not found: {reference_doc}\")\n        if not os.path.isfile(reference_doc):\n            raise ValueError(f\"Reference document is not a file: {reference_doc}\")\n\n        # Pandoc does not verify that the reference document matches the writer. A\n        # mismatch is silently ignored for docx output, and produces an unreadable\n        # file for odt output. Both exit 0 with no warning, so we reject it here.\n        expected_extension = f\".{output_format}\"\n        actual_extension = os.path.splitext(reference_doc)[1].lower()\n        if actual_extension != expected_extension:\n            raise ValueError(\n                f\"reference_doc must be a '{expected_extension}' file when output_format is \"\n                f\"'{output_format}', but '{os.path.basename(reference_doc)}' was given. Pandoc \"\n                f\"does not reject a mismatched reference document; it silently produces an \"\n                f\"unstyled or unreadable file. Create a matching template with: \"\n                f\"pandoc -o reference{expected_extension} \"\n                f\"--print-default-data-file reference{expected_extension}\"\n            )\n\n    # Validate defaults_file if provided\n    if defaults_file:\n        if not os.path.exists(defaults_file):\n            raise ValueError(f\"Defaults file not found: {defaults_file}\")\n\n        # Check if it's a valid YAML file and readable\n        try:\n            with open(defaults_file) as f:\n                yaml_content = yaml.safe_load(f)\n\n            # Validate the YAML structure\n            if not isinstance(yaml_content, dict):\n                raise ValueError(f\"Invalid defaults file format: {defaults_file} - must be a YAML dictionary\")\n\n            # Check if the defaults file specifies an output format that conflicts with the requested format\n            if 'to' in yaml_content and yaml_content['to'] != output_format:\n                print(\n                    f\"Warning: Defaults file specifies output format '{yaml_content['to']}' \"\n                    f\"but requested format is '{output_format}'. Using requested format.\"\n                )\n\n        except yaml.YAMLError as e:\n            raise ValueError(f\"Error parsing defaults file {defaults_file}: {str(e)}\") from e\n        except PermissionError as e:\n            raise ValueError(f\"Permission denied when reading defaults file: {defaults_file}\") from e\n        except Exception as e:\n            raise ValueError(f\"Error reading defaults file {defaults_file}: {str(e)}\") from e\n\n    # Validate the output format against the single list the schema also advertises, so\n    # the runtime check and the enum cannot drift apart.\n    if output_format not in OUTPUT_FORMATS:\n        raise ValueError(\n            f\"Unsupported output format: '{output_format}'. Supported formats are: {', '.join(OUTPUT_FORMATS)}\"\n        )\n\n    if input_format not in INPUT_FORMATS:\n        raise ValueError(\n            f\"Unsupported input format: '{input_format}'. Supported input formats are: \"\n            f\"{', '.join(INPUT_FORMATS)}. Pandoc writes some formats it cannot read, so the \"\n            f\"input list is shorter than the output list.\"\n        )\n\n    # Validate output_file requirement for advanced formats\n    if output_format in ADVANCED_FORMATS and not output_file:\n        raise ValueError(f\"output_file path is required for {output_format} format\")\n\n    # Validate filters if provided\n    if filters:\n        if not isinstance(filters, list):\n            raise ValueError(\"filters parameter must be an array of strings\")\n\n        for filter_path in filters:\n            if not isinstance(filter_path, str):\n                raise ValueError(\"Each filter must be a string path\")\n\n    def resolve_filter_path(filter_path, defaults_file=None):\n        \"\"\"Resolve a filter path by trying multiple possible locations.\n\n        Args:\n        ----\n            filter_path: The original filter path (absolute or relative)\n            defaults_file: Optional path to the defaults file for context\n\n        Returns:\n        -------\n            Resolved absolute path to the filter if found, or None if not found\n\n        \"\"\"\n        # If it's already an absolute path, just use it\n        if os.path.isabs(filter_path):\n            paths = [filter_path]\n        else:\n            # Try multiple locations for relative paths\n            paths = [\n                # 1. Relative to current working directory\n                os.path.abspath(filter_path),\n\n                # 2. Relative to the defaults file directory (if provided)\n                os.path.join(os.path.dirname(os.path.abspath(defaults_file)), filter_path) if defaults_file else None,\n\n                # 3. Relative to the .pandoc/filters directory\n                os.path.join(os.path.expanduser(\"~\"), \".pandoc\", \"filters\", os.path.basename(filter_path))\n            ]\n            # Remove None entries\n            paths = [p for p in paths if p]\n\n        # Try each path\n        for path in paths:\n            if os.path.exists(path):\n                # Check if executable and try to make it executable if not\n                if not os.access(path, os.X_OK):\n                    try:\n                        os.chmod(path, os.stat(path).st_mode | 0o111)\n                        print(f\"Made filter executable: {path}\")\n                    except Exception as e:\n                        print(f\"Warning: Could not make filter executable: {path} - {str(e)}\")\n                        continue\n\n                print(f\"Using filter: {path}\")\n                return path\n\n        return None\n\n    def validate_filters(filters, defaults_file=None):\n        \"\"\"Validate filter paths and ensure they exist and are executable.\"\"\"\n        validated_filters = []\n\n        for filter_path in filters:\n            resolved_path = resolve_filter_path(filter_path, defaults_file)\n            if resolved_path:\n                validated_filters.append(resolved_path)\n            else:\n                raise ValueError(f\"Filter not found in any of the searched locations: {filter_path}\")\n\n        return validated_filters\n\n    def format_result_info(filters=None, defaults_file=None, validated_filters=None):\n        \"\"\"Format filter and defaults file information for result messages.\"\"\"\n        filter_info = \"\"\n        defaults_info = \"\"\n\n        if filters and validated_filters:\n            filter_names = [os.path.basename(f) for f in validated_filters]\n            filter_info = f\" with filters: {', '.join(filter_names)}\"\n\n        if defaults_file:\n            defaults_basename = os.path.basename(defaults_file)\n            defaults_info = f\" using defaults file: {defaults_basename}\"\n\n        return filter_info, defaults_info\n\n    try:\n        # Prepare conversion arguments\n        extra_args = []\n\n        # Add defaults file if provided - ensure it's properly formatted for Pandoc\n        if defaults_file:\n            # Make sure the path is absolute\n            defaults_file_abs = os.path.abspath(defaults_file)\n            extra_args.extend([\"--defaults\", defaults_file_abs])\n\n        # Set environment variables for filters\n        env = os.environ.copy()\n        if output_file:\n            # Set PANDOC_OUTPUT_DIR to the directory of the output file\n            output_dir = os.path.dirname(os.path.abspath(output_file))\n            env[\"PANDOC_OUTPUT_DIR\"] = output_dir\n        else:\n            output_dir = None\n\n        # Validate filters once and reuse the result\n        validated_filters = validate_filters(filters, defaults_file) if filters else []\n\n        # Handle filter arguments\n        for filter_path in validated_filters:\n            extra_args.extend([\"--filter\", filter_path])\n\n        # Handle PDF-specific conversion if needed\n        if output_format == \"pdf\":\n            extra_args.extend([\n                \"--pdf-engine=xelatex\",\n                \"-V\", \"geometry:margin=1in\"\n            ])\n\n        # Handle reference doc for the formats pandoc accepts --reference-doc for\n        if reference_doc and output_format in REFERENCE_DOC_FORMATS:\n            extra_args.extend([\"--reference-doc\", reference_doc])\n\n        # No special processing needed for content\n\n        # Convert content using pypandoc\n        if input_file:\n            if not os.path.exists(input_file):\n                raise ValueError(f\"Input file not found: {input_file}\")\n\n\n            if output_file:\n                # Convert file to file\n                converted_output = pypandoc.convert_file(\n                    input_file,\n                    pandoc_output_format,\n                    outputfile=output_file,\n                    extra_args=extra_args\n                )\n\n                # Create result message with filter and defaults information\n                filter_info, defaults_info = format_result_info(filters, defaults_file, validated_filters)\n                result_message = f\"File successfully converted{filter_info}{defaults_info} and saved to: {output_file}\"\n            else:\n                # Convert file to string\n                converted_output = pypandoc.convert_file(\n                    input_file,\n                    pandoc_output_format,\n                    extra_args=extra_args\n                )\n        else:\n            # No special processing needed for content\n\n            if output_file:\n                # Convert content to file\n                pypandoc.convert_text(\n                    contents,\n                    pandoc_output_format,\n                    format=input_format,\n                    outputfile=output_file,\n                    extra_args=extra_args\n                )\n\n                # Create result message with filter and defaults information\n                filter_info, defaults_info = format_result_info(filters, defaults_file, validated_filters)\n                result_message = (\n                    f\"Content successfully converted{filter_info}{defaults_info} and saved to: {output_file}\"\n                )\n            else:\n                # Convert content to string\n                converted_output = pypandoc.convert_text(\n                    contents,\n                    pandoc_output_format,\n                    format=input_format,\n                    extra_args=extra_args\n                )\n\n        if output_file:\n            notify_with_result = result_message\n        else:\n            if not converted_output:\n                raise ValueError(\"Conversion resulted in empty output\")\n\n            # Add filter and defaults information to the notification\n            filter_info, defaults_info = format_result_info(filters, defaults_file, validated_filters)\n            # Adjust format for inline display\n            if filter_info:\n                filter_info = f\" (with filters: {', '.join([os.path.basename(f) for f in validated_filters])})\"\n            if defaults_info:\n                defaults_info = f\" (using defaults file: {os.path.basename(defaults_file)})\"\n\n            notify_with_result = (\n                f'Following are the converted contents in {output_format} format{filter_info}{defaults_info}.\\n'\n                f'Ask user if they expect to save this file. If so, provide the output_file parameter with '\n                f'complete path.\\n'\n                f'Converted Contents:\\n\\n{converted_output}'\n            )\n\n        return [\n            types.TextContent(\n                type=\"text\",\n                text=notify_with_result\n            )\n        ]\n\n    except Exception as e:\n        # Handle Pandoc conversion errors\n        error_prefix = \"Error converting\"\n        error_details = str(e)\n\n        if \"Filter not found\" in error_details or \"Filter is not executable\" in error_details:\n            error_prefix = \"Filter error during conversion\"\n        elif \"defaults\" in error_details and defaults_file:\n            error_prefix = \"Defaults file error during conversion\"\n            # Add more context about the defaults file\n            error_details += f\" (defaults file: {defaults_file})\"\n        elif \"pandoc\" in error_details.lower() and \"not found\" in error_details.lower():\n            error_prefix = \"Pandoc executable not found\"\n            error_details = \"Please ensure Pandoc is installed and available in your PATH\"\n\n        error_msg = (\n            f\"{error_prefix} {'file' if input_file else 'contents'} from {input_format} to \"\n            f\"{output_format}: {error_details}\"\n        )\n        raise ValueError(error_msg) from e\n",
      "asOf": "2026-11-20"
    },
    "F193": {
      "label": "Project source file, pypandoc",
      "display": "src/mcp_pandoc/server.py",
      "asOf": "2026-11-20"
    },
    "F194": {
      "label": "Project full_name, pypandoc",
      "display": "vivekVells/mcp-pandoc",
      "asOf": "2026-11-20"
    },
    "F195": {
      "label": "Project stargazers_count, pypandoc",
      "display": "588",
      "asOf": "2026-11-20"
    },
    "F196": {
      "label": "Library name, comtypes",
      "display": "comtypes",
      "asOf": "2026-11-20"
    },
    "F197": {
      "label": "Monthly downloads, comtypes",
      "display": "2.4M",
      "asOf": "2026-11-20"
    },
    "F198": {
      "label": "License, comtypes",
      "display": "MIT",
      "asOf": "2026-11-20"
    },
    "F199": {
      "label": "Package release, comtypes",
      "display": "1.5.0",
      "asOf": "2026-11-20"
    },
    "F200": {
      "label": "Package release date, comtypes",
      "display": "Nov 2026",
      "asOf": "2026-11-20"
    },
    "F201": {
      "label": "Install, comtypes",
      "display": "pip install comtypes",
      "asOf": "2026-11-20"
    },
    "F202": {
      "label": "Quickstart, comtypes",
      "display": "from comtypes.client import CreateObject\n\npowerpoint = CreateObject(\"PowerPoint.Application\")\npresentation = powerpoint.Presentations.Add()\n",
      "asOf": "2026-11-20"
    },
    "F203": {
      "label": "Official description, comtypes",
      "display": "Implements COM in pure Python.",
      "asOf": "2026-11-20"
    },
    "F204": {
      "label": "Quickstart source file, comtypes",
      "display": "comtypes/client/_create.py",
      "asOf": "2026-11-20"
    },
    "F205": {
      "label": "Repository stars, comtypes",
      "display": "351",
      "asOf": "2026-11-20"
    },
    "F206": {
      "label": "Shape object model, comtypes",
      "display": "Via plugin",
      "asOf": "2026-11-20"
    },
    "F207": {
      "label": "Slide image export, comtypes",
      "display": "Via plugin",
      "asOf": "2026-11-20"
    },
    "F208": {
      "label": "Presentation API and backend role, comtypes",
      "display": "Pure-Python ctypes COM client exposing registered Office interfaces on Windows.",
      "asOf": "2026-11-20"
    },
    "F209": {
      "label": "Python metadata requirement, comtypes",
      "display": ">=3.9",
      "asOf": "2026-11-20"
    },
    "F210": {
      "label": "First-call prerequisites, comtypes",
      "display": "[\"Disclosed COM API recipe. Windows,an installed registered PowerPoint application,and a compatible COM client environment are required. The returned pointer exposes Office interfaces; comtypes itself is not a portable presentation parser or renderer. This first call creates an unsaved presentation; no Office process is launched during research.\"]",
      "asOf": "2026-11-20"
    },
    "F211": {
      "label": "COM versus file SDK scope, comtypes",
      "display": "The Python package exposes a registered COM application object; slide,shape,and rendering methods originate Microsoft PowerPoint. Windows and an available application registration are required for these specific capabilities.",
      "asOf": "2026-11-20"
    },
    "F212": {
      "label": "Library name, pandoc",
      "display": "Pandoc Python Library",
      "asOf": "2026-11-20"
    },
    "F213": {
      "label": "Monthly downloads, pandoc",
      "display": "871.4K",
      "asOf": "2026-11-20"
    },
    "F214": {
      "label": "License, pandoc",
      "display": "MIT",
      "asOf": "2026-11-20"
    },
    "F215": {
      "label": "Package release, pandoc",
      "display": "2.4",
      "asOf": "2026-11-20"
    },
    "F216": {
      "label": "Package release date, pandoc",
      "display": "Aug 2024",
      "asOf": "2026-11-20"
    },
    "F217": {
      "label": "Install, pandoc",
      "display": "pip install pandoc",
      "asOf": "2026-11-20"
    },
    "F218": {
      "label": "Quickstart, pandoc",
      "display": "import pandoc\n\ndocument = pandoc.read(\"# Example\\n\\nContent\", format=\"markdown\")\npandoc.write(document, file=\"example.pptx\", format=\"pptx\")\n",
      "asOf": "2026-11-20"
    },
    "F219": {
      "label": "Official description, pandoc",
      "display": "Represents Pandoc documents in Python.",
      "asOf": "2026-11-20"
    },
    "F220": {
      "label": "Quickstart source file, pandoc",
      "display": "src/pandoc/__init__.py",
      "asOf": "2026-11-20"
    },
    "F221": {
      "label": "Repository stars, pandoc",
      "display": "188",
      "asOf": "2026-11-20"
    },
    "F222": {
      "label": "Shape object model, pandoc",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F223": {
      "label": "Slide image export, pandoc",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F224": {
      "label": "Presentation API and backend role, pandoc",
      "display": "Pandoc document AST access/transformation and binary PPTX writing through an external compatible Pandoc process.",
      "asOf": "2026-11-20"
    },
    "F225": {
      "label": "Python metadata requirement, pandoc",
      "display": "Not declared in selected registry release",
      "asOf": "2026-11-20"
    },
    "F226": {
      "label": "First-call prerequisites, pandoc",
      "display": "[\"Disclosed native AST read/write recipe verified against the current2.4 release source. Requires an external Pandoc executable compatible with the binding configuration/document schema. The source writes bytes for PPTX and can write them to a filename; no UTF8 text assumption. This creates from Markdown and does not claim native PowerPoint shape-level roundtrip fidelity.\"]",
      "asOf": "2026-11-20"
    },
    "F227": {
      "label": "Pandoc version and presentation model, pandoc",
      "display": "Pandoc3.8.3 added a PPTX reader; backend version and wrapper configuration determine input support. Python wrappers are not intrinsically write-only. Conversion uses a semantic document model,not a native PowerPoint geometry/roundtrip renderer.",
      "asOf": "2026-11-20"
    },
    "F228": {
      "label": "Library name, aspose-slides",
      "display": "Aspose.Slides",
      "asOf": "2026-11-20"
    },
    "F229": {
      "label": "Monthly downloads, aspose-slides",
      "display": "176.8K",
      "asOf": "2026-11-20"
    },
    "F230": {
      "label": "License, aspose-slides",
      "display": "Proprietary",
      "asOf": "2026-11-20"
    },
    "F231": {
      "label": "Package release, aspose-slides",
      "display": "26.11.0",
      "asOf": "2026-11-20"
    },
    "F232": {
      "label": "Package release date, aspose-slides",
      "display": "Nov 2026",
      "asOf": "2026-11-20"
    },
    "F233": {
      "label": "Install, aspose-slides",
      "display": "pip install aspose-slides",
      "asOf": "2026-11-20"
    },
    "F234": {
      "label": "Quickstart, aspose-slides",
      "display": "import aspose.slides as slides\n\n# Instantiates a Presentation object that represents a presentation file\nwith slides.Presentation() as presentation:\n    slide = presentation.slides[0]\n    # Adds an autoshape with type set to line\n    slide.shapes.add_auto_shape(slides.ShapeType.LINE, 50, 150, 300, 0)\n    presentation.save(\"NewPresentation_out.pptx\", slides.export.SaveFormat.PPTX)\n",
      "asOf": "2026-11-20"
    },
    "F235": {
      "label": "Repository stars, aspose-slides",
      "display": "12",
      "asOf": "2026-11-20"
    },
    "F236": {
      "label": "Shape object model, aspose-slides",
      "display": "Yes",
      "asOf": "2026-11-20"
    },
    "F237": {
      "label": "Slide image export, aspose-slides",
      "display": "Yes",
      "asOf": "2026-11-20"
    },
    "F238": {
      "label": "Presentation API and backend role, aspose-slides",
      "display": "Proprietary presentation object model and renderer; official public GitHub repository contains examples rather than the proprietary engine.",
      "asOf": "2026-11-20"
    },
    "F239": {
      "label": "Python metadata requirement, aspose-slides",
      "display": "<3.16,>=3.5",
      "asOf": "2026-11-20"
    },
    "F240": {
      "label": "First-call prerequisites, aspose-slides",
      "display": "[\"Official basic create/save example. No SDK/Office/rendering execution during research.\", \"Use vendor-supported platform/native prerequisites. Unlicensed evaluation adds watermarks and truncates text read from presentations; a valid license removes those evaluation limits.\"]",
      "asOf": "2026-11-20"
    },
    "F241": {
      "label": "Original project API contract, aspose-slides",
      "display": "{\"status\": \"verified\", \"arguments\": \"Fergana original builder imports aspose.slides and accepts an actual Presentation plus an in-range slide index. Current26.11 supports RECTANGLE auto-shape creation at point-coordinate x/y/width/height,TextFrame format properties,and ParagraphCollection remove_at/add. Positive canvas dimensions and valid finite bounding boxes are required by the retained pixel-to-point helpers. Current count is a read-only int. _hex_to_color must return the native drawing Color; _build_paragraph constructs a current slides.Paragraph with the supplied request text/format. Those original host helpers,models,and finite-size assumptions remain explicit,not counted as SDK calls. The source sets fill types,autofit NONE,wrap TRUE,and margins on their native property contracts.\", \"used_return_shapes\": \"add_auto_shape returns AutoShape with a TextFrame. remove_at/add update native paragraphs; index_of returns a zero-based int for the shape just added. The whole function returns that shape index,not an ID or rendered image. Current proprietary package licensing/evaluation applies separately from the public integration project grant.\"}",
      "asOf": "2026-11-20"
    },
    "F242": {
      "label": "SDK license versus sample-project grant, aspose-slides",
      "display": "Runtime package is proprietary. Official licensing page states unlicensed evaluation adds a watermark to every saved slide and truncates text read from presentations; written text is saved in full. Public GitHub sample licensing is separate.",
      "asOf": "2026-11-20"
    },
    "F243": {
      "label": "Bundled runtime and image default, aspose-slides",
      "display": "{\"dotnet_runtime\": \"Bundled; a separate .NET installation is not required.\", \"linux_native_libraries\": [\"libgdiplus\", \"ICU\"], \"parameterless_get_image_scale\": 0.2, \"macos_note\": \"Vendor installation page says its macOS installation has not been verified,although the release publishes Intel and ARM64 macOS wheels.\"}",
      "asOf": "2026-11-20"
    },
    "F244": {
      "label": "Published release wheels, aspose-slides",
      "display": "[\"aspose_slides-26.11.0-py3-none-macosx_10_14_x86_64.whl\", \"aspose_slides-26.11.0-py3-none-macosx_11_0_arm64.whl\", \"aspose_slides-26.11.0-py3-none-manylinux1_x86_64.whl\", \"aspose_slides-26.11.0-py3-none-manylinux2014_aarch64.whl\", \"aspose_slides-26.11.0-py3-none-win32.whl\", \"aspose_slides-26.11.0-py3-none-win_amd64.whl\"]",
      "asOf": "2026-11-20"
    },
    "F245": {
      "label": "Project function, aspose-slides",
      "display": "def add_text_shape(\n    pres: slides.Presentation,\n    slide_index: int,\n    req: TextShapeRequest,\n    canvas_w_px: float,\n    canvas_h_px: float,\n) -> int:\n    slide = pres.slides[slide_index]\n    slide_w_pt = float(pres.slide_size.size.width)\n    slide_h_pt = float(pres.slide_size.size.height)\n\n    x, y, w, h = _bbox_to_pt(req.bbox, canvas_w_px, canvas_h_px, slide_w_pt, slide_h_pt)\n    shape = slide.shapes.add_auto_shape(slides.ShapeType.RECTANGLE, x, y, w, h)\n    shape.line_format.fill_format.fill_type = slides.FillType.NO_FILL\n\n    if req.bg_color:\n        shape.fill_format.fill_type = slides.FillType.SOLID\n        shape.fill_format.solid_fill_color.color = _hex_to_color(req.bg_color)\n    else:\n        shape.fill_format.fill_type = slides.FillType.NO_FILL\n\n    tf = shape.text_frame\n    tf.text_frame_format.autofit_type = slides.TextAutofitType.NONE\n    tf.text_frame_format.wrap_text = slides.NullableBool.TRUE\n\n    top_pad, right_pad, bottom_pad, left_pad = req.padding_px\n    tf.text_frame_format.margin_top = _px_to_pt(top_pad, canvas_h_px, slide_h_pt)\n    tf.text_frame_format.margin_right = _px_to_pt(right_pad, canvas_w_px, slide_w_pt)\n    tf.text_frame_format.margin_bottom = _px_to_pt(bottom_pad, canvas_h_px, slide_h_pt)\n    tf.text_frame_format.margin_left = _px_to_pt(left_pad, canvas_w_px, slide_w_pt)\n\n    # Strip the default placeholder paragraph Aspose seeds in every text frame.\n    while tf.paragraphs.count > 0:\n        tf.paragraphs.remove_at(0)\n\n    for para_model in req.paragraphs:\n        para = _build_paragraph(para_model, canvas_h_px, slide_h_pt)\n        tf.paragraphs.add(para)\n\n    return slide.shapes.index_of(shape)\n",
      "asOf": "2026-11-20"
    },
    "F246": {
      "label": "Project source file, aspose-slides",
      "display": "powerpoint-mcp/src/builder.py",
      "asOf": "2026-11-20"
    },
    "F247": {
      "label": "Project full_name, aspose-slides",
      "display": "Fergana-Labs/stash",
      "asOf": "2026-11-20"
    },
    "F248": {
      "label": "Project stargazers_count, aspose-slides",
      "display": "343",
      "asOf": "2026-11-20"
    },
    "F249": {
      "label": "Library name, Spire.Presentation",
      "display": "Spire.Presentation",
      "asOf": "2026-11-20"
    },
    "F250": {
      "label": "Monthly downloads, Spire.Presentation",
      "display": "37.3K",
      "asOf": "2026-11-20"
    },
    "F251": {
      "label": "License, Spire.Presentation",
      "display": "Proprietary",
      "asOf": "2026-11-20"
    },
    "F252": {
      "label": "Package release, Spire.Presentation",
      "display": "11.8.1",
      "asOf": "2026-11-20"
    },
    "F253": {
      "label": "Package release date, Spire.Presentation",
      "display": "Aug 2026",
      "asOf": "2026-11-20"
    },
    "F254": {
      "label": "Install, Spire.Presentation",
      "display": "pip install Spire.Presentation",
      "asOf": "2026-11-20"
    },
    "F255": {
      "label": "Quickstart, Spire.Presentation",
      "display": "from spire.presentation import *\n\noutputFile =\"HelloWorld.pptx\"\npresentation = Presentation()\npresentation.SaveToFile(outputFile, FileFormat.Pptx2010)\npresentation.Dispose()\n",
      "asOf": "2026-11-20"
    },
    "F256": {
      "label": "Repository stars, Spire.Presentation",
      "display": "10",
      "asOf": "2026-11-20"
    },
    "F257": {
      "label": "Shape object model, Spire.Presentation",
      "display": "Yes",
      "asOf": "2026-11-20"
    },
    "F258": {
      "label": "Slide image export, Spire.Presentation",
      "display": "Yes",
      "asOf": "2026-11-20"
    },
    "F259": {
      "label": "Presentation API and backend role, Spire.Presentation",
      "display": "Proprietary professional presentation object model and renderer; Free is a separate distribution/edition.",
      "asOf": "2026-11-20"
    },
    "F260": {
      "label": "Python metadata requirement, Spire.Presentation",
      "display": ">=3.7",
      "asOf": "2026-11-20"
    },
    "F261": {
      "label": "First-call prerequisites, Spire.Presentation",
      "display": "[\"Disclosed minimal create/save/lifecycle recipe from the full official Hello World sample,omitting optional shape/font styling. Uses professional package; separate Free distribution is a constrained variant,not an interchangeable dependency assumption. Vendor licensing/evaluation terms apply.\"]",
      "asOf": "2026-11-20"
    },
    "F262": {
      "label": "Original project API contract, Spire.Presentation",
      "display": "{\"status\": \"verified\", \"arguments\": \"NotebookLM2PPT imports professional spire.presentation and separately aliases python-pptx Presentation; native factory calls here resolve to Spire. Current11.8.1 supports loading paths,Slides.Count/indexing,RemoveAt(1),AppendBySlide(ISlide),SaveToFile with Pptx2016,and Dispose. Source folder/output filename must be valid strings and presentations readable. Its optional PNG basenames filter may produce an empty ppt_files list after the initial guard; caller must ensure at least one matching input. For an exact one-slide-per-returned-name mapping,each selected input must contain a first slide. Input paths are lexically sorted; png_names controls selection,not output ordering.\", \"used_return_shapes\": \"AppendBySlide clones the supplied source slide into the destination while retaining its design per the native documentation; return is ignored. Source presentations are disposed after cloning,then the combined presentation is saved/disposed. Method returns a Python list of mapped PNG basenames,not Slide objects or a guaranteed count when some source decks are empty. Professional package selection is backed by same-commit manifests rather than an assumption that the Free variant has identical capabilities.\"}",
      "asOf": "2026-11-20"
    },
    "F263": {
      "label": "Professional versus Free edition, Spire.Presentation",
      "display": "Selected professional package has its own proprietary/restricted licensing. Spire.Presentation.Free is a related distribution with the same namespace family,not an extra independent engine row; neither count is summed. Selected project manifests explicitly request the professional package.",
      "asOf": "2026-11-20"
    },
    "F264": {
      "label": "Published release wheels, Spire.Presentation",
      "display": "[\"spire_presentation-11.8.1-py3-none-macosx_10_7_universal.whl\", \"spire_presentation-11.8.1-py3-none-macosx_11_0_arm64.whl\", \"spire_presentation-11.8.1-py3-none-manylinux2014_aarch64.whl\", \"spire_presentation-11.8.1-py3-none-manylinux_2_34_x86_64.whl\", \"spire_presentation-11.8.1-py3-none-win_amd64.whl\"]",
      "asOf": "2026-11-20"
    },
    "F265": {
      "label": "Project function, Spire.Presentation",
      "display": "def combine_ppt_files_with_spire(source_folder, output_file, png_names=None):\n    \"\"\"\n    使用 Spire.Presentation 合并PPT文件，每个PPT只保留第一页，并保留原始设计\n\n    Args:\n        source_folder: 源PPT文件所在的文件夹路径\n        output_file: 输出的合并PPT文件路径\n    \"\"\"\n    # 获取所有pptx文件并按字典序排序\n\n    ppt_files = sorted([f for f in os.listdir(source_folder) if f.endswith('.pptx')])\n\n    ppt_names = [png_name.replace(\".png\", \".pptx\") for png_name in png_names] if png_names else None\n\n    if not ppt_files:\n        print(\"未找到任何PPT文件\")\n        return\n\n    print(f\"找到 {len(ppt_files)} 个PPT文件:\")\n    valid_ppt_files = []\n    for idx, file in enumerate(ppt_files, 1):\n        print(f\"  {idx}. {file}\")\n        if ppt_names and file in ppt_names:\n            valid_ppt_files.append(file)\n    if ppt_names:\n        ppt_files = valid_ppt_files\n        print(f\"\\n根据提供的PNG名称过滤后，剩余 {len(ppt_files)} 个PPT文件:\")\n\n    # 创建主演示文稿对象，使用第一个PPT作为基础\n    first_ppt_path = os.path.join(source_folder, ppt_files[0])\n    main_pres = Presentation()\n    main_pres.LoadFromFile(first_ppt_path)\n\n    # 删除第一个PPT的多余页面，只保留第一页\n    while main_pres.Slides.Count > 1:\n        main_pres.Slides.RemoveAt(1)\n\n    print(f\"  已添加: {ppt_files[0]} (第1页)\")\n\n    # 遍历剩余的PPT文件\n    for ppt_file in ppt_files[1:]:\n        file_path = os.path.join(source_folder, ppt_file)\n\n        # 加载当前PPT文件\n        temp_pres = Presentation()\n        temp_pres.LoadFromFile(file_path)\n\n        if temp_pres.Slides.Count > 0:\n            # 使用 AppendBySlide 方法追加第一页，保留原始设计\n            main_pres.Slides.AppendBySlide(temp_pres.Slides[0])\n            print(f\"  已添加: {ppt_file} (第1页)\")\n        else:\n            print(f\"  跳过: {ppt_file} (无幻灯片)\")\n\n        # 释放临时演示文稿资源\n        temp_pres.Dispose()\n\n    # 保存合并后的PPT\n    main_pres.SaveToFile(output_file, FileFormat.Pptx2016)\n    print(f\"\\n合并完成！输出文件: {output_file}\")\n    print(f\"总共合并了 {main_pres.Slides.Count} 页幻灯片\")\n\n    # 释放资源\n    main_pres.Dispose()\n\n    valid_png_names = [ppt_name.replace(\".pptx\", \".png\") for ppt_name in ppt_files] # 返回真正存在的png names\n\n    return valid_png_names\n",
      "asOf": "2026-11-20"
    },
    "F266": {
      "label": "Project source file, Spire.Presentation",
      "display": "notebooklm2ppt/utils/ppt_combiner.py",
      "asOf": "2026-11-20"
    },
    "F267": {
      "label": "Project full_name, Spire.Presentation",
      "display": "elliottzheng/NotebookLM2PPT",
      "asOf": "2026-11-20"
    },
    "F268": {
      "label": "Project stargazers_count, Spire.Presentation",
      "display": "499",
      "asOf": "2026-11-20"
    },
    "F269": {
      "label": "Library name, python-pptx-text-replacer",
      "display": "python-pptx-text-replacer",
      "asOf": "2026-11-20"
    },
    "F270": {
      "label": "Monthly downloads, python-pptx-text-replacer",
      "display": "13.7K",
      "asOf": "2026-11-20"
    },
    "F271": {
      "label": "License, python-pptx-text-replacer",
      "display": "GPLv3",
      "asOf": "2026-11-20"
    },
    "F272": {
      "label": "Package release, python-pptx-text-replacer",
      "display": "0.0.6",
      "asOf": "2026-11-20"
    },
    "F273": {
      "label": "Package release date, python-pptx-text-replacer",
      "display": "Sep 2022",
      "asOf": "2026-11-20"
    },
    "F274": {
      "label": "Install, python-pptx-text-replacer",
      "display": "pip install python-pptx-text-replacer",
      "asOf": "2026-11-20"
    },
    "F275": {
      "label": "Quickstart, python-pptx-text-replacer",
      "display": "from python_pptx_text_replacer import TextReplacer\nreplacer = TextReplacer(\"original.pptx\", slides='',\n tables=True, charts=True, textframes=True)\nreplacer.replace_text( [ ('FY2021','FY2122') ] )\nreplacer.write_presentation_to_file(\"./changed.pptx\")\n",
      "asOf": "2026-11-20"
    },
    "F276": {
      "label": "Official description, python-pptx-text-replacer",
      "display": "Replaces text in PowerPoint files in PPTX format.",
      "asOf": "2026-11-20"
    },
    "F277": {
      "label": "Quickstart source file, python-pptx-text-replacer",
      "display": "README.md",
      "asOf": "2026-11-20"
    },
    "F278": {
      "label": "Repository stars, python-pptx-text-replacer",
      "display": "15",
      "asOf": "2026-11-20"
    },
    "F279": {
      "label": "Shape object model, python-pptx-text-replacer",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F280": {
      "label": "Slide image export, python-pptx-text-replacer",
      "display": "No",
      "asOf": "2026-11-20"
    },
    "F281": {
      "label": "Presentation API and backend role, python-pptx-text-replacer",
      "display": "Focused presentation text replacement across shapes,chart categories,and table cells while preserving character formatting.",
      "asOf": "2026-11-20"
    },
    "F282": {
      "label": "Python metadata requirement, python-pptx-text-replacer",
      "display": ">=2.7",
      "asOf": "2026-11-20"
    },
    "F283": {
      "label": "First-call prerequisites, python-pptx-text-replacer",
      "display": "[\"Exact published0.0.6 README API starter. Provide original.pptx; output is written to changed.pptx. This is focused text replacement across configured objects,not a new-slide or image-rendering example. Package metadata declares>=2.7,but current python-pptx1.0.2 dependency requires>=3.8; declared metadata is not a guarantee for an arbitrary latest dependency stack.\"]",
      "asOf": "2026-11-20"
    },
    "F284": {
      "label": "Focused public API and dependency scope, python-pptx-text-replacer",
      "display": "Constructor loads an existing presentation; replace_text accepts a list of match/replacement tuples and write_presentation_to_file saves it. Internal _presentation belongs to the underlying python-pptx engine.",
      "asOf": "2026-11-20"
    }
  },
  "dataCheckedAt": "2026-11-20",
  "agent": {
    "exaCall": {
      "endpoint": "/search",
      "body": {
        "query": "Best Python PowerPoint libraries python-pptx Aspose Slides FOSS Spire code examples",
        "numResults": 5
      },
      "docsUrl": "https://exa.ai/docs/reference/search"
    },
    "calls": []
  }
}
