Skip to main content
Glama
Alpha-Park

genpark-html-dom-semantic-tree-pruner-skill

by Alpha-Park

genpark-html-dom-semantic-tree-pruner-skill

Python 3.9+ License MIT MCP Compatible GenPark AI Zero Dependencies


⚡ Overview & Architectural Significance

genpark-html-dom-semantic-tree-pruner-skill delivers zero-dependency, low-latency web automation, DOM semantic pruning, and execution trajectory evaluation primitives engineered strictly using Python 3.9+ standard library.

🌟 Key Architectural Capabilities

  • Zero External Dependencies: Operates exclusively via pure Python (html.parser, urllib.parse, re, math, json). Zero pip install overhead, zero headless browser crashes.

  • Enterprise Web Agent Invariants: Implements formal token-pruning algorithms, form auto-mapping, anti-crawler trap normalization, Markdown-to-JSON type inference, and trajectory Levenshtein distance evaluation.

  • Native Anthropic MCP Protocol: Compliant with standard JSON-RPC 2.0 stdio MCP specifications for Claude Desktop, Cursor, and Windsurf.


Related MCP server: genpark-web-form-input-schema-auto-mapper-skill

🏗️ Architectural Topology & State Machine

flowchart TD
    RawWeb["Raw Web Page / DOM Ingress"] --> TrapFilter["URL Canonicalization & Anti-Crawler Trap Guard"]
    TrapFilter --> DOMPruner["HTML DOM Semantic Tree Pruner
(80%+ Token Reduction, Strips Scripts/Styles/SVG)"]
    
    DOMPruner --> FormMapper["Web Form Input Schema Auto-Mapper
(Attribute & Heuristic Profile Field Binding)"]
    DOMPruner --> TableParser["Markdown & HTML Table to JSON Transformer
(Type-Inferred Structured Record Generation)"]
    
    FormMapper --> AgentExecution["Autonomous Agent Browser Interaction"]
    TableParser --> AgentExecution
    
    AgentExecution --> TrajectoryEval["Synthetic Trajectory Evaluator
(Action Precision, Recall & Levenshtein Edit Distance)"]
    TrajectoryEval --> VerifiedTaskDone["Verified Benchmark Task Completion"]

🚀 Quickstart & Standalone Execution

Local Python Client Usage

from client import HtmlDomSemanticTreePruner

# Initialize engine
engine = HtmlDomSemanticTreePruner()

# Execute self-testing benchmark suite
result = engine.run_benchmark_dom_pruner()
print("Execution Result:", result)

🔌 One-Click MCP Integration (Claude Desktop / Cursor)

Add to your claude_desktop_config.json or cursor.json:

{
  "mcpServers": {
    "genpark-html-dom-semantic-tree-pruner-skill": {
      "command": "python",
      "args": ["-u", "/path/to/genpark-html-dom-semantic-tree-pruner-skill/mcp_server.py"]
    }
  }
}

📦 Smithery.ai & PyPI Deployment

This skill contains pre-configured smithery.yaml and pyproject.toml manifests. Install directly via pip:

pip install git+https://github.com/alphaparkinc/genpark-html-dom-semantic-tree-pruner-skill.git

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    B
    maintenance
    Agent-native headless browser for AI agents. Converts web pages to a Semantic Object Model (SOM) instead of raw HTML — 17x average token reduction across real-world sites (up to 117x on complex pages). Native MCP server with fetch_page, extract_text, extract_links, and full browser automation. No API key required.
    35 npm
    Apache 2.0
  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables autonomous agents to inspect live web pages, prune noisy DOM content down to semantic essentials, and bind each form field to agent state by matching input attributes, autocomplete hints, and regex validations. It also converts HTML/Markdown tables into type-inferred JSON records and scores agent action trajectories for precision, recall, and edit distance.
    7
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables autonomous web agents to prune DOM trees, canonicalize URLs against anti-crawler traps, auto-map form input schemas, and convert HTML/Markdown tables into typed JSON records. It also scores agent execution trajectories against gold benchmarks using action-level precision, recall, and Levenshtein sequence edit distance.
    7
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables autonomous web agents to prune DOM trees, canonicalize URLs, auto-map form inputs, and convert HTML/Markdown tables into typed JSON, then score execution trajectories with action-level precision, recall, and Levenshtein edit distance against gold benchmarks. Runs as a zero-dependency, stdlib-only MCP server over JSON-RPC 2.0 stdio for Claude Desktop, Cursor, and Windsurf.
    7
    MIT