macroforge-autofixer
Validate TypeScript code with @derive decorators and fix validation issues. Returns structured diagnostics with error locations and suggested fixes.
Instructions
Validates TypeScript code with @derive decorators using Macroforge's native validation.
Returns structured JSON diagnostics with:
level: error | warning | info
message: What's wrong
location: Line and column number (when available)
help: Suggested fix (when available)
notes: Additional context (when available)
summary: Count of errors, warnings, and info messages
This tool MUST be used before sending Macroforge code to the user. If require_another_tool_call_after_fixing is true, fix the issues and validate again.
Detects:
Invalid/unknown macro names
Malformed @derive decorators
@serde validator issues (email, url, length, etc.)
Macro expansion failures
Syntax errors in generated code
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | TypeScript code with @derive decorators to validate | |
| filename | No | Filename for the code (default: input.ts) |