diff --git a/packages/tourmaline/src/lib/analysis/genres.ts b/packages/tourmaline/src/lib/analysis/genres.ts index ed82134..99acaf1 100644 --- a/packages/tourmaline/src/lib/analysis/genres.ts +++ b/packages/tourmaline/src/lib/analysis/genres.ts @@ -148,16 +148,10 @@ export function buildGenreProfile( artistInfos: Map, ): GenreEntry[] { const genreWeights = new Map(); - console.log( - `[tourmaline] building genre profile, artistCounts: ${data.artistPlayCounts.size}, artistInfos: ${artistInfos.size}`, - ); for (const [name, count] of data.artistPlayCounts) { const info = artistInfos.get(name); - if (!info) { - console.log(`[tourmaline] artist not in info: ${name}`); - continue; - } + if (!info) continue; const allRaw = [...info.genres, ...info.tags]; const seen = new Set(); @@ -170,12 +164,10 @@ export function buildGenreProfile( } } - const result = [...genreWeights.entries()] + return [...genreWeights.entries()] .map(([name, weight]) => ({ name, weight })) .sort((a, b) => b.weight - a.weight) .slice(0, 20); - console.log(`[tourmaline] genre result: ${result.length} genres`); - return result; } /**