Skip to main content
Glama

build_project

Convert a single-file HTML rebuild into a runnable Vite, Astro, or Next.js source project with section components, split CSS, rewired GSAP timelines, and carried assets.

Instructions

Convert a single-file exact rebuild (any local .html, e.g. the rebuild flow's full-page-exact.html) into a runnable Vite, Astro or Next.js project: sections become components, CSS splits per section, gsap timelines re-wire in the framework idiom (useEffect + gsap.context on Next), assets carried. Reads a local file and writes the project dir. The output is source, not a servable site: install and build it (npm install && npm run build) and serve the generated output (Vite/Astro dist, Next .next with next start), not the raw scaffold directory. Pairs with verify_build: build → convert → verify.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "htmlPath": "<htmlPath>",
      "target": "<target>",
      "out": "<out>"
    },
    "name": "build_project"
  }
}

Input Schema

NameRequiredDescriptionDefault
outYesDirectory to scaffold the project into (created as needed)
nameNopackage.json name (default rebuild-site)
targetYesFramework of the generated project
htmlPathYesLocal path to the single-file rebuild html to convert

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.14.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Changed1 schema field changedv1.13.0
    • removedInput schema / additionalProperties
      Removed value: -false
  3. Addedv1.12.0

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=false, openWorldHint=false, destructiveHint=false, so the write-vs-read question is partly covered; the description still adds real value by specifying it reads a local file and writes the project dir, and by warning that the output is source, not a servable site, with the exact install/build/serve commands. It leaves the non-idempotent behavior (what happens if 'out' already exists) unstated, which is the one meaningful gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the core verb and resource in the first clause, then layers detail in descending importance. Dense but nearly every sentence carries actionable information; the parenthetical 'useEffect + gsap.context on Next' is the one detail that borders on noise for tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description correctly compensates by explaining the nature of the return (generated source files, not a running site) and exactly how to consume it, plus its relationship to verify_build. For a four-parameter scaffolding tool this covers everything an agent needs to invoke it and act on the result.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter (htmlPath, target, out, name) is already documented in the schema; the description only echoes the htmlPath scope ('any local .html') and the three framework targets that the enum already lists. Baseline 3 is appropriate since the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and transformation: convert a single-file rebuild HTML into a runnable Vite/Astro/Next project, and enumerates what actually happens (sections to components, CSS split per section, gsap re-wiring, assets carried). It is unmistakably distinct from siblings like verify_build or build_motion_manifest.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives a concrete trigger input ('any local .html, e.g. the rebuild flow's full-page-exact.html') and positions itself in a pipeline: 'Pairs with verify_build: build → convert → verify.' It does not state explicit exclusions (e.g. multi-page or already-frameworked sources), so it falls short of a full 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.