playwright-compress

Compress verbose Playwright MCP tool outputs using Haiku summarization.

1|Updated May 21, 2026
One-click install
npx skills add https://github.com/hiddink-ai/hiddink-harness --skill playwright-compress
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: playwright-compress
Source: https://github.com/hiddink-ai/hiddink-harness/tree/main/templates/skills/playwright-compress
Command: npx skills add https://github.com/hiddink-ai/hiddink-harness --skill playwright-compress

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This skill addresses the issue of excessive token consumption caused by verbose Playwright MCP tool outputs, which can quickly exhaust context windows during browser automation tasks.

Core Features & Use Cases

  • Intelligent Summarization: Uses Haiku to condense large MCP tool responses by up to 96% while retaining critical navigation references.
  • Context Preservation: Automatically extracts and preserves all ref= attribute values to ensure interactive flow continuity.
  • Use Case: When performing complex web scraping or automated testing, use this skill to keep your agent's context window clean and focused on the most relevant browser state data.

Quick Start

Enable the playwright-compress hook in your configuration to automatically summarize browser tool outputs during your next automation session.

Frequently Asked Questions about playwright-compress

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I reduce Playwright MCP token consumption during browser automation?

You can reduce Playwright MCP token consumption by applying Haiku summarization to compress verbose tool outputs. This approach condenses large DOM snapshots and interaction logs by up to 96%, maintaining context window efficiency during complex browser automation tasks.

How does Haiku summarization work for compressing Playwright browser outputs?

Haiku summarization compresses Playwright browser outputs by condensing large MCP tool responses while extracting and preserving all ref= attribute values. This ensures interactive flow continuity and context preservation without exhausting the context window.

Do I need an external API key to summarize MCP tool responses locally?

No, you do not need an external API key to summarize MCP tool responses locally. The process requires local Claude CLI authentication to perform Haiku summarization without external API key exposure.

Can I preserve interactive element references when compressing Playwright DOM snapshots?

Yes, you can preserve interactive element references when compressing Playwright DOM snapshots. The summarization process automatically extracts and preserves all ref= attribute values to ensure interactive flow continuity for browser automation tasks.

What is the best way to keep an agent's context window clean during web scraping?

The best way to keep an agent's context window clean during web scraping is to use a PostToolUse hook for intelligent summarization. This compresses verbose browser state data, keeping the context focused on the most relevant information.

When should I avoid using automated summarization for browser testing logs?

You should avoid using automated summarization for browser testing logs when you require the complete, unabridged interaction history for debugging. Summarization condenses outputs by up to 96%, which may remove verbose details needed for strict audit trails.