navidrome/core/agents
Kendall Garner 4621e9106f
support fetching artist bio from filesystem
2024-03-09 19:58:43 -08:00
..
filesystem support fetching artist bio from filesystem 2024-03-09 19:58:43 -08:00
lastfm Use new `slices` package from Go standard lib 2024-02-16 22:00:44 -05:00
listenbrainz Submit duration to ListenBrainz (#2405) 2023-06-17 12:27:00 -04:00
lrclib [enhancement]: Support fetching lyrics from external sources 2024-03-09 17:30:38 -08:00
spotify Add trace logs to calls to external services 2023-01-31 09:37:09 -05:00
README.md Add local agent, only for images 2023-01-13 22:18:34 -05:00
agents.go local > lrclib, do not duplicate local, test 2024-03-09 18:08:49 -08:00
agents_suite_test.go Rename log.LevelCritical to log.LevelFatal 2022-12-21 14:53:36 -05:00
agents_test.go local > lrclib, do not duplicate local, test 2024-03-09 18:08:49 -08:00
interfaces.go [enhancement]: Support fetching lyrics from external sources 2024-03-09 17:30:38 -08:00
local_agent.go support fetching artist bio from filesystem 2024-03-09 19:58:43 -08:00
session_keys.go Listenbrainz scrobbling (#1424) 2021-10-30 12:17:42 -04:00
session_keys_test.go Upgrade Ginkgo to V2 2022-07-26 16:53:17 -04:00

README.md

This folder abstracts metadata lookup into "agents". Each agent can be implemented to get as much info as the external source provides, by using a granular set of interfaces (see interfaces).

A new agent must comply with these simple implementation rules:

  1. Implement the AgentName() method. It just returns the name of the agent for logging purposes.
  2. Implement one or more of the *Retriever() interfaces. That's where the agent's logic resides.
  3. Register itself (in its init() function).

For an agent to be used it needs to be listed in the Agents config option (default is "lastfm,spotify"). The order dictates the priority of the agents

For a simple Agent example, look at the local_agent agent source code.