Skip to main content
Glama
Zenobia000

VibeCoding System

by Zenobia000

generate-prd

Create and save project PRDs (Product Requirements Documents) directly within your project structure using AI-driven dialogue. Designed for rapid MVP and POC development within the VibeCoding System.

Instructions

Generate a project PRD and save it to the project structure

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Core handler function that loads the current project, reads the PRD template from a prompt file, replaces the project name placeholder, creates the necessary directory, writes the PRD to '0_discovery/requirements/PRODUCT_REQUIREMENTS_DOCUMENT.md', and returns a success message.
    async generateProjectPRD(): Promise<string> {
      const project = this.loadCurrentProject();
      if (!project) {
        throw new Error('No active project found. Please start clarification first.');
      }
    
      const promptPath = resolve(__dirname, '../../../.vibecoding/prompts/workflows/discovery-phase.md');
      let prdContent = `Failed to load PRD template.`;
      if (existsSync(promptPath)) {
        prdContent = readFileSync(promptPath, 'utf-8');
      }
      
      prdContent = prdContent.replace(/{{projectName}}/g, project.name);
    
      const outputPath = join(project.path, '0_discovery', 'requirements', 'PRODUCT_REQUIREMENTS_DOCUMENT.md');
      
      mkdirSync(path.dirname(outputPath), { recursive: true });
      writeFileSync(outputPath, prdContent);
    
      return `✅ PRD document generated and saved to: ${outputPath}`;
    }
  • Tool registration in the ListTools response, including name, description, and empty input schema.
    {
      name: 'generate-prd',
      description: 'Generate a project PRD and save it to the project structure',
      inputSchema: {
        type: 'object',
        properties: {},
        required: []
      }
    },
  • Dispatch handler in the CallToolRequestSchema that invokes the generateProjectPRD method and formats the response.
    case 'generate-prd': {
      const resultMessage = await contextManager.generateProjectPRD();
      return {
        content: [
          {
            type: 'text',
            text: resultMessage
          }
        ]
      };
    }
  • Input schema for the tool, which is an empty object (no required parameters).
    inputSchema: {
      type: 'object',
      properties: {},
      required: []
    }
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions generating and saving a PRD, implying a write operation, but doesn't specify permissions needed, whether it overwrites existing files, or the format/location of the saved output. This leaves significant gaps for a tool that modifies project structure.

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

Conciseness5/5

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

The description is a single, efficient sentence that front-loads the core action and outcome with zero waste. It uses clear language and avoids unnecessary elaboration, making it easy to parse quickly.

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

Completeness2/5

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

Given the complexity of generating and saving a document (a write operation with potential side effects), no annotations, and no output schema, the description is insufficient. It doesn't explain what a PRD entails, how it's structured, or what 'save it to the project structure' means in practice, leaving the agent with unclear expectations.

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

Parameters4/5

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

There are 0 parameters, and schema description coverage is 100%, so the schema fully documents the lack of inputs. The description doesn't need to add parameter details, and it appropriately focuses on the tool's purpose without redundant information, meeting the baseline for no parameters.

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

Purpose4/5

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

The description clearly states the action ('generate a project PRD') and the outcome ('save it to the project structure'), which is specific and actionable. However, it doesn't explicitly differentiate from sibling tools like 'generate-impl-plan' or 'provide-clarification', which might involve similar documentation tasks.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives like 'generate-impl-plan' or 'provide-clarification'. It lacks context about prerequisites, such as whether a project must be initialized first, or exclusions for when not to use it.

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

Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Zenobia000/vibeCoding-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server