Skip to main content
Glama

trash_compare_profile

Compare your quality profile with TRaSH Guides recommendations to identify missing custom formats, scoring differences, and quality settings for Radarr or Sonarr services.

Instructions

Compare your quality profile against TRaSH Guides recommendations. Shows missing custom formats, scoring differences, and quality settings. Requires the corresponding *arr service to be configured.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serviceYesWhich service
profileIdYesYour quality profile ID to compare
trashProfileYesTRaSH profile name to compare against

Implementation Reference

  • src/index.ts:692-712 (registration)
    Registration of the 'trash_compare_profile' tool in the TOOLS array, including the name, description, and input schema for MCP tool discovery.
    name: "trash_compare_profile", description: "Compare your quality profile against TRaSH Guides recommendations. Shows missing custom formats, scoring differences, and quality settings. Requires the corresponding *arr service to be configured.", inputSchema: { type: "object" as const, properties: { service: { type: "string", enum: ["radarr", "sonarr"], description: "Which service", }, profileId: { type: "number", description: "Your quality profile ID to compare", }, trashProfile: { type: "string", description: "TRaSH profile name to compare against", }, }, required: ["service", "profileId", "trashProfile"], },
  • Input schema definition for the 'trash_compare_profile' tool, specifying parameters: service (radarr/sonarr), profileId (number), trashProfile (string).
    name: "trash_compare_profile", description: "Compare your quality profile against TRaSH Guides recommendations. Shows missing custom formats, scoring differences, and quality settings. Requires the corresponding *arr service to be configured.", inputSchema: { type: "object" as const, properties: { service: { type: "string", enum: ["radarr", "sonarr"], description: "Which service", }, profileId: { type: "number", description: "Your quality profile ID to compare", }, trashProfile: { type: "string", description: "TRaSH profile name to compare against", }, }, required: ["service", "profileId", "trashProfile"], },
  • Core handler implementation for 'trash_compare_profile'. Fetches user's *arr quality profile and TRaSH profile, compares allowed qualities and custom formats (matching, missing, extra), and returns structured comparison with recommendations.
    case "trash_compare_profile": { const { service, profileId, trashProfile } = args as { service: TrashService; profileId: number; trashProfile: string; }; // Get client const client = service === 'radarr' ? clients.radarr : clients.sonarr; if (!client) { return { content: [{ type: "text", text: JSON.stringify({ error: `${service} not configured. Cannot compare profiles.` }, null, 2), }], isError: true, }; } // Fetch both profiles const [userProfiles, trashProfileData] = await Promise.all([ client.getQualityProfiles(), trashClient.getProfile(service, trashProfile), ]); const userProfile = userProfiles.find(p => p.id === profileId); if (!userProfile) { return { content: [{ type: "text", text: JSON.stringify({ error: `Profile ID ${profileId} not found`, availableProfiles: userProfiles.map(p => ({ id: p.id, name: p.name })), }, null, 2), }], isError: true, }; } if (!trashProfileData) { return { content: [{ type: "text", text: JSON.stringify({ error: `TRaSH profile '${trashProfile}' not found`, hint: "Use trash_list_profiles to see available profiles", }, null, 2), }], isError: true, }; } // Compare qualities const userQualities = new Set<string>( userProfile.items .filter(i => i.allowed) .map(i => i.quality?.name || i.name) .filter((n): n is string => n !== undefined) ); const trashQualities = new Set<string>( trashProfileData.items .filter(i => i.allowed) .map(i => i.name) ); const qualityComparison = { matching: [...userQualities].filter(q => trashQualities.has(q)), missingFromYours: [...trashQualities].filter(q => !userQualities.has(q)), extraInYours: [...userQualities].filter(q => !trashQualities.has(q)), }; // Compare custom formats const userCFNames = new Set( (userProfile.formatItems || []) .filter(f => f.score !== 0) .map(f => f.name) ); const trashCFNames = new Set(Object.keys(trashProfileData.formatItems || {})); const cfComparison = { matching: [...userCFNames].filter(cf => trashCFNames.has(cf)), missingFromYours: [...trashCFNames].filter(cf => !userCFNames.has(cf)), extraInYours: [...userCFNames].filter(cf => !trashCFNames.has(cf)), }; return { content: [{ type: "text", text: JSON.stringify({ yourProfile: { name: userProfile.name, id: userProfile.id, upgradeAllowed: userProfile.upgradeAllowed, cutoff: userProfile.cutoff, }, trashProfile: { name: trashProfileData.name, upgradeAllowed: trashProfileData.upgradeAllowed, cutoff: trashProfileData.cutoff, }, qualityComparison, customFormatComparison: cfComparison, recommendations: [ ...(qualityComparison.missingFromYours.length > 0 ? [`Enable these qualities: ${qualityComparison.missingFromYours.join(', ')}`] : []), ...(cfComparison.missingFromYours.length > 0 ? [`Add these custom formats: ${cfComparison.missingFromYours.slice(0, 5).join(', ')}${cfComparison.missingFromYours.length > 5 ? ` and ${cfComparison.missingFromYours.length - 5} more` : ''}`] : []), ...(userProfile.upgradeAllowed !== trashProfileData.upgradeAllowed ? [`Set upgradeAllowed to ${trashProfileData.upgradeAllowed}`] : []), ], }, null, 2), }], }; }

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/aplaceforallmystuff/mcp-arr'

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