Wright AI
DocsStart free
JavaScript · JSDoc

Auto-generate JavaScript JSDoc with AI

Wright AI writes JSDoc for every undocumented JavaScript function in your project — reading callers and callees for accurate context, not just the function body.

Start for free →pip install wright

See it in action

Before and after — JSDoc style

BEFORE
async function processWebhook(payload, signature, config) {
  if (!verifySignature(payload, signature, config.secret)) {
    throw new WebhookError("Invalid signature", 401);
  }
  const event = JSON.parse(payload);
  await queue.push({ event, retries: 0, receivedAt: Date.now() });
  return { accepted: true, eventId: event.id };
}
AFTER — wright generate
/**
 * Validates and enqueues an incoming webhook payload for async processing.
 *
 * Verifies the HMAC signature before parsing to prevent processing
 * forged payloads. On success, pushes the parsed event onto the retry
 * queue with an initial retry count of zero.
 *
 * @param {string} payload - Raw request body as a UTF-8 string.
 * @param {string} signature - HMAC-SHA256 signature from the request header.
 * @param {{ secret: string }} config - Webhook configuration containing
 *   the shared secret for signature verification.
 * @returns {Promise<{ accepted: boolean, eventId: string }>} Resolves
 *   with acceptance confirmation and the parsed event ID.
 * @throws {WebhookError} If the signature does not match (HTTP 401).
 */
async function processWebhook(payload, signature, config) {

How it works

More than a docstring generator

Call graph context
Wright builds a dependency graph before generating. It reads what calls your JavaScript function and what it calls — so docs describe purpose, not just mechanics.
📊
Coverage tracking
Know the exact percentage of documented functions across every file. Set a minimum threshold and enforce it in CI.
🔍
Drift detection
When a function signature changes, Wright flags the stale docstring automatically — as a VS Code warning and a CI failure.
🔌
MCP for AI tools
Exposes your indexed docs to Claude Code, Cursor, and Copilot via MCP so they always have live context about your codebase.

Comparison

How Wright differs from alternatives

Writing JSDoc manually
Repetitive and time-consuming. Skipped under pressure and never caught up later.
ESDoc / JSDoc CLI
Generates documentation sites from existing comments — does not write comments for you.
ChatGPT / Claude (ad-hoc)
No call graph context. No batch mode. No coverage report. No CI enforcement.

Start documenting your JavaScript codebase

Free VS Code extension · CLI · GitHub Action · MCP server. No credit card required.

Get started free →Read the docs