Claudio Ortolina
4be2330891
Fix prompt to avoid the result being returned in a code block
...
Not sure why this is needed, considering that the API call clearly
specifies the `json_object` response format.
2024-12-19 21:05:02 +00:00
Claudio Ortolina
53b89dc329
Extract Artists context
2024-12-18 11:12:06 +00:00
Claudio Ortolina
76605a1114
Add function to get similar artists
2024-12-17 20:44:31 +00:00
Claudio Ortolina
3c85f9e974
Extract OpenAI.Completion struct
2024-12-11 23:24:16 +03:00
Claudio Ortolina
b68a7ac734
Can fetch genres from OpenAI
2024-12-10 16:45:29 +03:00
Claudio Ortolina
f48372f7b3
Use MapSets for performance
...
Not noticeable with current database size, but lays a good foundation
for larger libraries.
For example, given a list of 300 artist IDs, checking if an ID is in the
list takes between 30 and 40 ms (for an ID towards the end of the list),
while the MapSet version takes consistently between 15 and 20 ms.
2024-12-10 14:21:57 +03:00
Claudio Ortolina
9e57103842
Where possible, link scrobbled artists to artist page
2024-12-10 14:13:50 +03:00
Claudio Ortolina
1c47473c11
Move SQLite extension loading to config/runtime.exs
...
Addresses deprecation mentioned at https://hexdocs.pm/ecto/Ecto.Repo.html#c:init/2
2024-12-07 20:29:33 +01:00
Claudio Ortolina
06fd591e5f
Use unicode extension to normalize sorting accented records
2024-12-07 19:38:10 +01:00
Claudio Ortolina
0f926ed86a
Load Sqlite unicode extension
2024-12-07 18:32:22 +01:00
Claudio Ortolina
8350ffd3a4
To get artist info, try mbid and then artist name
2024-12-04 21:07:56 +00:00
Claudio Ortolina
e1dc2bfc7f
Make MusicBrainz user agent configurable
2024-12-04 10:44:31 +00:00
Claudio Ortolina
7575e5978a
Extract config for MusicBrainz
2024-12-04 10:33:41 +00:00
Claudio Ortolina
9f2335cfa0
Use correct LastFm api module
2024-12-03 20:14:48 +00:00
Claudio Ortolina
2094c1cf7b
Use LastFm.Config where needed
2024-12-03 09:18:55 +00:00
Claudio Ortolina
b49434b789
Extract LastFm.Config module
2024-12-03 08:56:23 +00:00
Claudio Ortolina
18df3683fc
Render a minimal artist page
2024-12-02 17:35:47 +00:00
Claudio Ortolina
2d721774d6
Can fetch an artist info from Last.fm
2024-12-02 12:40:07 +00:00
Claudio Ortolina
b63b3a633a
Can fetch records by a specific artist
2024-12-02 10:55:12 +00:00
Claudio Ortolina
963b3c826f
Extract Records.Artist
2024-12-02 10:55:12 +00:00
Claudio Ortolina
eda0245c2c
Format code
2024-12-02 09:38:20 +00:00
Claudio Ortolina
3733ef74ba
Add batch function to remove artist IDs
2024-12-02 09:37:00 +00:00
Claudio Ortolina
228b4bc440
Use musicbrainz_id as a key for embedded artists
2024-12-02 09:23:13 +00:00
Claudio Ortolina
cf51cab7ce
Add basic test for Records.Cover module
2024-11-29 22:08:40 +00:00
Claudio Ortolina
010c769b55
Stream 50 rows at a time for batch operations
2024-11-29 10:00:18 +00:00
Claudio Ortolina
cb0e06d603
Add batch operation to resize covers with incorrect sizes
2024-11-28 17:15:12 +00:00
Claudio Ortolina
6339196b17
Search by genre
...
Can also click on genres in detail views.
2024-11-26 13:35:15 +00:00
Claudio Ortolina
f0212eeb6f
Consolidate cover resize logic
...
Moves resizing out of the MusicBrainz namespace to Records - which
improves division of responsibilities, and removes double resizing
during import.
2024-11-26 08:35:16 +00:00
Claudio Ortolina
148f68fbf3
Add function to resize cover data in place
2024-11-25 11:26:34 +00:00
Claudio Ortolina
bbfafbe519
Document search index schema
2024-11-23 12:28:06 +00:00
Claudio Ortolina
2e2000fe01
Introduce separate search index
...
Uses a fts5 virtual table, kept up to date via triggers on the records
table.
2024-11-22 19:37:13 +00:00
Claudio Ortolina
c97064fd70
Update fallback cover art
...
Track the file inside the Record module to aid recompilation
2024-11-21 18:33:44 +00:00
Claudio Ortolina
4581666282
Don't apply fallback cover when refreshing it
...
So that we don't accidentally override a user-uploaded cover with the
fallback one.
2024-11-21 17:57:49 +00:00
Claudio Ortolina
09f3563134
Can refresh cover for a record in the collection
2024-11-19 11:28:50 +00:00
Claudio Ortolina
cc1d2e3b0f
Increase stored cover size to 600px
...
Doesn't affect existing covers
2024-11-19 11:28:50 +00:00
Claudio Ortolina
87cd668a33
Populate release_ids and included_release_groups when record is created
2024-11-18 15:34:16 +00:00
Claudio Ortolina
659894aaee
Materialize included release group ids
2024-11-17 11:52:47 +00:00
Claudio Ortolina
e35e0894bf
When refreshing MusicBrainz Data, update the relevant release IDs
2024-11-16 14:56:15 +00:00
Claudio Ortolina
60b098785b
Can refresh musicbrainz_data for collection records
2024-11-15 10:01:53 +00:00
Claudio Ortolina
ac6b398afc
Improve ergonomics of batch operations on entire database
...
Use a stream for better memory management, and return IDs for records
which haven't been processed correctly.
2024-11-14 22:15:31 +00:00
Claudio Ortolina
d7fd14c7ab
Show included release groups in record show page
2024-11-14 19:11:41 +00:00
Claudio Ortolina
dbdb698ef3
Display count of child release groups
2024-11-14 15:16:19 +00:00
Claudio Ortolina
cd106fe34f
Can refresh musicbrainz_data of a single record
2024-11-14 14:29:16 +00:00
Claudio Ortolina
96b1b47a4a
Set default for record release_ids
2024-11-13 12:04:43 +00:00
Claudio Ortolina
80f945555c
Add status for each track in the scrobble activity
2024-11-13 11:55:58 +00:00
Claudio Ortolina
a0947b07f3
Add batch task to update release IDs
2024-11-12 15:01:17 +00:00
Claudio Ortolina
97c7be7b0c
Store release ids when importing a record
2024-11-12 15:01:17 +00:00
Claudio Ortolina
bd8f4cc979
Define essential record fields
2024-11-10 16:27:15 +00:00
Claudio Ortolina
0e05c3cfa9
Refactor record building into Record
2024-11-10 16:18:24 +00:00
Claudio Ortolina
6fa3e72a3f
Use a map instead of 4 arguments
2024-11-10 16:10:38 +00:00