browser4-coding

Scaffold, validate, and modify Browser4 plugins, skills, scripts, and Kotlin modules.

1.1k|151|Updated Mar 12, 2018
One-click install
npx skills add https://github.com/platonai/Browser4 --skill browser4-coding
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: browser4-coding
Source: https://github.com/platonai/Browser4/tree/main/skills/browser4-coding
Command: npx skills add https://github.com/platonai/Browser4 --skill browser4-coding

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Creating Browser4 plugins, skills, and scripts by hand is error-prone, and modifying Browser4's own Kotlin/Rust codebase requires knowing module dependencies, build commands, and CDP pitfalls that are easy to miss.

Core Features & Use Cases

  • Artifact Scaffolding & Validation: Generate plugins, SKILL.md files, browser JS, and shell scripts from templates or live examples, then validate them against repo rules (pom structure, plugin.json schema, frontmatter checks).
  • Self-Development Toolset: Inspect the live Maven module graph, run impact analysis before edits, compile modules with structured diagnostics, and check Kotlin symbols, references, and inheritance without an LSP server.
  • Governance & Safety: Enforce repo-consistency checks, block edits to protected files (VERSION, BOM, CI), and scan browser-driver code for known CDP pitfalls.
  • Use Case: Ask the agent to create a new Browser4 plugin for media detection; it scaffolds the module, writes the files, validates the plugin structure, and compiles it with Maven to confirm it builds.

Quick Start

Ask the agent to scaffold and validate a new Browser4 plugin named browser4-weather with a tool method that extracts weather data from the page.

Frequently Asked Questions about browser4-coding

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

FAQPage Schema
How do I create a new Browser4 plugin?

Call coding.scaffold with type plugin, providing pluginName, domain, basePackage, toolMethod, and toolDescription. Write the generated files, then run coding.validate on the plugin directory and coding.mvnBuild to confirm it compiles.

How do I validate a SKILL.md file for Browser4?

Run coding.validate with type skill and the path to the SKILL.md file. It checks the YAML frontmatter for name and description, verifies the name matches the directory name, and cross-checks allowed-tools references.

Can I modify Browser4's own Kotlin code safely?

Yes. Run coding.impact on the target file first to see the owning module and affected dependents, make the edit, then compile with coding.mvnBuild and run coding.trapCheck if the file is browser-driver code.

What files are protected from editing in the Browser4 repo?

VERSION, AGENTS.md, CLAUDE.md, the root pom.xml, the BOM pom, and the CI workflow are always protected from delete, replace, and line-edit operations. You can add session-level protections with coding.protect.

Why does coding.mvnBuild fail after scaffolding a plugin?

Build failures usually come from compile errors in the generated Kotlin code. Read the structured diagnostics from mvnBuild, open the faulty file with coding.read, fix it with coding.replace, and recompile.