pdf-text-replace
Replace text in fillable PDF forms by updating form field values. This skill should be used when users need to update names, addresses, dates, or other text in PDF form fields.
pinned to #6480335updated 2 months ago
Ask your AI client: “install skills/pdf-text-replace”.
Requires the metahub MCP server installed in your client. Set up MCP.
mh install skills/pdf-text-replacemetahub onboarded this repo on the author's behalf.
If you own github.com/instavm/open-skills on GitHub, claim the listing to take over publishing. Your claim preserves the existing eval history and badges; only the curator label is replaced with verified-publisher on your next publish.
Stars
445
Last commit
2 months ago
Latest release
published
- #ai
- #claude
- #gemini-cli
- #mcp
- #ollama
- #opencode
- #privacy
- #qwen-cli
- #skills
About this skill
Pulled from SKILL.md at publish time.
Replace text in fillable PDF forms by updating form field values.
Automated checks the publisher passed at publish time — structure, docs, safety, and whether the artifact behaves as claimed.6480335· 2 months ago
Behavioral checks ran but aren't published for this artifact; the static checks above ran at publish time.
Kind-specific
3 passed1 warningSkill: triggers declaredwarn
No `trigger` phrases in SKILL.md frontmatter
Add `trigger:` lines so Claude knows when to activate this skill — e.g. `when building MCP servers` or `for diagram creation`.
Skill: SKILL.md present
found at skills/public/pdf-text-replace/SKILL.md · frontmatter source: SKILL.md
Skill: body content present
284 words · 1,921 chars · 10 sections · 2 code blocks
Skill: allowed-tools scope
no allowed-tools restriction (Claude may use anything)
Release history
1- releasecurrent6480335warn2 months ago
Contents
Replace text in fillable PDF forms by updating form field values.
Description
This skill allows you to search and replace text in PDF files that have fillable form fields. It scans all form fields in the PDF, finds fields containing the search text, and replaces it with the replacement text.
Use Cases
- Update names in filled tax forms
- Replace addresses in PDF documents
- Update dates or reference numbers
- Batch update form field values
Requirements
- PDF must have fillable form fields (not flattened)
- Python 3.7+
- pypdf library
Usage
Basic Usage
python /app/uploads/skills/public/pdf-text-replace/scripts/replace_text_in_pdf.py \
/app/uploads/input.pdf \
"OLD TEXT" \
"NEW TEXT" \
/app/uploads/output.pdf
Example: Replace Name in Tax Form
python /app/uploads/skills/public/pdf-text-replace/scripts/replace_text_in_pdf.py \
/app/uploads/f5472.pdf \
"MANISH KUMAR" \
"MANNU KUMAR" \
/app/uploads/f5472_updated.pdf
Script Details
Script: scripts/replace_text_in_pdf.py
Arguments:
input_pdf- Path to input PDF filesearch_text- Text to search for in form fieldsreplace_text- Text to replace withoutput_pdf- Path to save the updated PDF
Output:
- Creates a new PDF with updated field values
- Preserves all form fields (not flattened)
- Reports number of fields modified
Limitations
- Only works with fillable PDF forms (not scanned/image PDFs)
- Replaces text in form field values, not static text
- Case-sensitive search by default
- Cannot modify flattened PDFs
Dependencies
The script requires the pypdf library, which is included in the container requirements.
Error Handling
The script will report errors if:
- Input PDF doesn't exist
- PDF doesn't have fillable form fields
- Search text is not found
- Output path is not writable
Reviews
No reviews yet. Be the first.
Related
Verification Before Completion
Evidence before assertions, always
Writing Plans
Turn specs into phased implementation plans
Test-Driven Development
Red → green → refactor discipline for any feature or bugfix
mh install skills/pdf-text-replace