ワンクリックで
Extract text and tables from PDF files. Use when a user uploads a PDF document that needs to be processed.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Extract text and tables from PDF files. Use when a user uploads a PDF document that needs to be processed.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Extract text and tables from PowerPoint (.pptx) files. Use when a user uploads a PPT or PPTX document that needs to be processed.
当用户请求生成、创建、制作 PPT、演示文稿、课件时使用此技能。这是教育场景中最常用的技能,适合老师备课、课程汇报、学术演讲等需求。
Extract text and tables from Word (.docx) files. Use when a user uploads a Word document that needs to be processed.
Extract text and tables from Markdown (.md) files. Use when a user uploads a Markdown document that needs to be processed.
Summarize and structure raw document text (PDF/Word/Markdown/PPT) into a format optimized for PPT generation. Use when the user uploads a document and wants to generate a presentation from it.
Use this skill any time a .pptx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or presentations; reading, parsing, or extracting text from any .pptx file (even if the extracted content will be used elsewhere, like in an email or summary); editing, modifying, or updating existing presentations; combining or splitting slide files; working with templates, layouts, speaker notes, or comments. Trigger whenever the user mentions "deck," "slides," "presentation," or references a .pptx filename, regardless of what they plan to do with the content afterward. If a .pptx file needs to be opened, created, or touched, use this skill.
| name | |
| description | Extract text and tables from PDF files. Use when a user uploads a PDF document that needs to be processed. |
Extract readable text and structured tables from PDF files. This skill is designed to feed extracted content into downstream processing (e.g., document summarization for PPT generation).
.pdf fileimport pdfplumber
text_parts = []
tables = []
with pdfplumber.open("document.pdf") as pdf:
for page in pdf.pages:
# Extract text (preserves layout better than pypdf)
t = page.extract_text()
if t:
text_parts.append(t.strip())
# Extract tables as 2D arrays
page_tables = page.extract_tables()
for pt in page_tables:
if pt and len(pt) >= 2:
tables.append(pt)
Why pdfplumber first:
from pypdf import PdfReader
reader = PdfReader("document.pdf")
text_parts = []
for page in reader.pages:
t = page.extract_text()
if t:
text_parts.append(t.strip())
Use pypdf when:
# Requires: pip install pytesseract pdf2image
import pytesseract
from pdf2image import convert_from_path
images = convert_from_path('scanned.pdf')
text = ""
for i, image in enumerate(images):
text += f"Page {i+1}:\n"
text += pytesseract.image_to_string(image)
text += "\n\n"
When to use OCR:
pdftotext or pdfplumber returns empty text# Fast plain text extraction
pdftotext input.pdf output.txt
# Preserve layout
pdftotext -layout input.pdf output.txt
# Specific page range
pdftotext -f 1 -l 5 input.pdf output.txt
| Problem | Solution |
|---|---|
| Empty text (scanned PDF) | Use OCR (Step 3) |
| Garbled text | Check if PDF is encrypted or uses non-standard encoding |
| Tables not extracting | Try page.extract_tables(settings={"vertical_strategy": "lines"}) |
| Memory issues on large PDFs | Process page-by-page in a loop |
| Images instead of text | OCR or skip if images are decorative |
For pptagent pipeline:
"\n\n".join(text_parts)len(pdf.pages)Return (raw_text: str, tables: list[list[list[str]]], page_count: int):
raw_text: all pages joined with double newlinestables: list of tables, each table is list[list[str]] (rows → cells)page_count: total number of pages