Skip to main content
Glama
williamzujkowski

Strudel MCP Server

humanize

Add natural timing variations to music patterns by adjusting humanization amount from 0 to 1, creating more organic-sounding rhythms in Strudel music generation.

Instructions

Add human timing variation

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
amountNoHumanization amount (0-1)

Implementation Reference

  • Handler for 'humanize' tool: gets current pattern, appends .nudge() with random timing variation based on amount (0-1), writes back the modified pattern.
    case 'humanize':
      if (args.amount !== undefined) {
        InputValidator.validateNormalizedValue(args.amount, 'amount');
      }
      const toHumanize = await this.getCurrentPatternSafe();
      const humanized = toHumanize + `.nudge(rand.range(-${args.amount || 0.01}, ${args.amount || 0.01}))`;
      await this.writePatternSafe(humanized);
      return 'Added human timing';
  • Registration of 'humanize' tool in getTools() array, including name, description, and input schema.
    {
      name: 'humanize',
      description: 'Add human timing variation',
      inputSchema: {
        type: 'object',
        properties: {
          amount: { type: 'number', description: 'Humanization amount (0-1)' }
        }
      }
    },
  • Input schema definition for 'humanize' tool: optional 'amount' number between 0-1.
    inputSchema: {
      type: 'object',
      properties: {
        amount: { type: 'number', description: 'Humanization amount (0-1)' }
      }
    }
  • Helper function validateNormalizedValue used to validate the 'amount' parameter for humanize (and similar normalized params).
    static validateNormalizedValue(value: number, fieldName: string): void {
      if (typeof value !== 'number') {
        throw new Error(`${fieldName} must be a number`);
      }
    
      if (isNaN(value) || !isFinite(value)) {
        throw new Error(`${fieldName} must be a valid number`);
      }
    
      if (value < 0 || value > 1.0) {
        throw new Error(`${fieldName} must be between 0 and 1.0, got ${value}`);
      }
    }
Behavior2/5

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

With no annotations, the description carries full burden but only states the action without behavioral details. It doesn't disclose if this is a read-only or destructive operation, what permissions are needed, rate limits, or how it interacts with other tools like 'play' or 'stop', leaving significant gaps.

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 phrase with no wasted words. It's front-loaded and appropriately sized for a simple tool, earning full marks for conciseness.

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 tool's potential complexity in a musical context and lack of annotations or output schema, the description is incomplete. It doesn't explain what 'human timing variation' entails, what it returns, or how it fits with siblings like 'quantize', making it inadequate for informed use.

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?

Schema description coverage is 100% for the single parameter 'amount', documented as 'Humanization amount (0-1)'. The description adds no extra parameter details, but with 0 parameters needing compensation and high schema coverage, the baseline is appropriately high as the schema handles semantics adequately.

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

Purpose2/5

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

The description 'Add human timing variation' restates the tool name 'humanize' without clarifying what resource or context it operates on. It's a tautology that doesn't specify whether it modifies audio, MIDI, patterns, or another musical element, making the purpose vague despite the clear verb.

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?

No guidance is provided on when to use this tool versus alternatives like 'quantize' or 'add_swing', which might also affect timing. The description lacks context about prerequisites, musical scenarios, or exclusions, leaving usage unclear.

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

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/williamzujkowski/strudel-mcp-server'

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