get_session_info
Retrieve current Ableton Live session details including tracks, devices, and settings to analyze and manage your music production project.
Instructions
Get detailed information about the current Ableton session
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- MCP_Server/server.py:262-270 (handler)MCP tool handler function that executes the 'get_session_info' tool by sending the command to the Ableton remote script via socket and returning the JSON-formatted result.def get_session_info(ctx: Context) -> str: """Get detailed information about the current Ableton session""" try: ableton = get_ableton_connection() result = ableton.send_command("get_session_info") return json.dumps(result, indent=2) except Exception as e: logger.error(f"Error getting session info from Ableton: {str(e)}") return f"Error getting session info: {str(e)}"
- Helper function in the Ableton remote script that retrieves and returns detailed session information using the Ableton Live API.def _get_session_info(self): """Get information about the current session""" try: result = { "tempo": self._song.tempo, "signature_numerator": self._song.signature_numerator, "signature_denominator": self._song.signature_denominator, "track_count": len(self._song.tracks), "return_track_count": len(self._song.return_tracks), "master_track": { "name": "Master", "volume": self._song.master_track.mixer_device.volume.value, "panning": self._song.master_track.mixer_device.panning.value } } return result except Exception as e: self.log_message("Error getting session info: " + str(e)) raise
- MCP_Server/server.py:187-190 (registration)Creation of the FastMCP server instance where tools like 'get_session_info' are registered via @mcp.tool() decorators.mcp = FastMCP( "AbletonMCP", description="Ableton Live integration through the Model Context Protocol", lifespan=server_lifespan