Skip to main content
Glama

set_tempo_tool

Control Ableton Live's session tempo directly via the MCP server, enabling precise tempo adjustments for AI-assisted music production workflows.

Instructions

Set the tempo of the Ableton session.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tempoYes

Implementation Reference

  • MCP tool handler for 'set_tempo_tool' that delegates to the set_tempo helper function.
    @mcp.tool() def set_tempo_tool(ctx: Context, tempo: float) -> str: """Set the tempo of the Ableton session.""" return set_tempo(ctx, tempo)
  • Server-side helper that sends the 'set_tempo' command over the connection to the Ableton remote script.
    def set_tempo(ctx: Context, tempo: float) -> str: """ Set the tempo of the Ableton session. Parameters: - tempo: The new tempo in BPM """ try: ableton = get_ableton_connection() result = ableton.send_command("set_tempo", {"tempo": tempo}) return f"Set tempo to {tempo} BPM" except Exception as e: logger.error(f"Error setting tempo: {str(e)}") return f"Error setting tempo: {str(e)}"
  • Remote script handler that executes the actual Ableton Live API call to set the song tempo.
    def set_tempo(self, tempo: float) -> dict[str, Any]: """Set the tempo of the session""" try: # Validate tempo value validate_tempo(tempo) self._song.tempo = tempo result = {"tempo": self._song.tempo} return result except Exception as e: self.log_message("Error setting tempo: " + str(e)) raise

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/chaudepark/ableton-mcp'

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