From 86d822f445375d7b259cb8b9371dced361f45bfa Mon Sep 17 00:00:00 2001 From: faradox Date: Wed, 28 Feb 2024 12:56:39 +0100 Subject: [PATCH] chore: prepare release 0.2.1 --- CHANGELOG.md | 20 +++++++++++++++++--- pyproject.toml | 2 +- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 83b9a7f..652225e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,16 +5,25 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## [0.2.1](https://github.com/okio-ai/nendo/releases/tag/0.2.1) - 2024-02-28 + +[Compare with 0.2.0](https://github.com/okio-ai/nendo/compare/0.2.0...0.2.1) + +### Bug Fixes + +- add_tracks should return a list of tracks (#19) ([78ba963](https://github.com/okio-ai/nendo/commit/78ba963e35453409e6a02c53438d8fc433a96a02) by Aaron Abebe). +- skip_duplicate doesn't respect user_id ([741babc](https://github.com/okio-ai/nendo/commit/741babc905d3fe2096baaa21d2193625799ce50a) by Felix Lorenz). + ## [0.2.0](https://github.com/okio-ai/nendo/releases/tag/0.2.0) - 2024-02-19 +### Features + - Added the first extension for the Nendo Library: The `NendoLibraryVectorExtension` is a mix-in class that can be used by implementations of the Nendo Library to add support for saving and retrieving embedding vectors. - Added a new class `NendoEmbedding` that represents an embedding of a `NendoTrack` and stores the vector together with the ID of the track from which it was computed, the text representation of the track that was used to compute the embedding, as well as the embedding plugin's name and version that were used to compute the embedding. -- Added a new subclass of the `NendoPlugin` called `EmbeddingPlugin` that accepts either a `NendoTrack`, a `NendoCollection`, a `signal` and a `text`, or only a `text` and computes corresponding `NendoEmbedding`(s), depending on whether a single object or a `NendoCollection` was provided. It also determines whether the currently used `NendoLibrary` implementation uses the `NendoLibraryVectorExtension` and, if so, saves the computed embeddings directly to the library. -- Fixed a problem with the way dictionaries (like `NendoTrack.meta` and `NendoTrack.resource`) were stored in the Nendo Library which resulted in them being stored as JSON strings instead of JSON dictionaries. **This means that upgrading Nendo will break any apps that use libraries that were created with previous versions of nendo.** Please make sure you understand the implications and either flush your DB or convert it to match the new data model. +- Added a new subclass of the `NendoPlugin` called `EmbeddingPlugin` that accepts either a `NendoTrack`, a `NendoCollection`, a `signal` and a `text`, or only a `text` and computes corresponding `NendoEmbedding`(s), depending on whether a single object or a `NendoCollection` was provided. It also determines whether the currently used `NendoLibrary` implementation uses the `NendoLibraryVectorExtension` and, if so, saves the computed embeddings directly to the library. - Added the global configuration variable `replace_plugin_data`, that specifies whether new plugin data will overwrite existing plugin data for the specific plugin name and version used to generate the data. - Reworked the way relationships between tracks are managed. Previously, Nendo would create bidirectional relationships, which caused problems with the retrieval of related tracks, especially when using paging (i.e. `offset` and `limit`). The new approach is to only store relationships _from_ a derivative track _to_ the original track from which it was derived. Accordingly, all functions for retrieving related tracks accept a new parameter, `direction: str`, which can assume either one of the values `"to"`, `"from"` and `"both"` and will change their retrieval behavior accordingly. Also, the method names for some methods were changed to reflect the new semantics more accurrately: `NendoTrack.has_relationship_to()` was replaced by `NendoTrack.has_related_track(direction=...)`. `collection.has_relationship_to()` was replaced by `collection.has_related_collection()`. - Added a new shortcut function `NendoTrack.relate_to_track()` that creates a relationship of the specified `relationship_type` and with the specified metadata from the given track _to_ another track. -- Fixed a bug where the length of a `NendoTrack` would not be correctly determined if the track had a mono signal. - Two new shortcut functions `NendoTrack.refresh()` and `collection.refresh()` were added that retrieve the latest version of the given object as it exists in the Nendo Library, effectively allowing to quickly pull the latest changes to an object from the database. - The `NendoTrack.get_plugin_data()` methods signature was extended to allow for filtering a track's plugin data also by `plugin_version` and `user_id` in addition to the existing filters. - Adjusted the `add_track()` function: @@ -37,6 +46,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Changed the signature of the `NendoLibrary.add_plugin_data()` function to make specifying of the `plugin_version` optional. If none is given, version will be inferred from the currently registered version of the plugin. - Extended the signature of the `NendoLibrary.filter_collections()` function by the `collection_types` parameter to also allow for filtering by a list of collection types. - Added the `NendoLibrary.library_size()` and `NendoLirary.collection_size()` functions to get the number of tracks in the library per user and the number of tracks in a collection, respectively. + +### Bug Fixes + +- Fixed a problem with the way dictionaries (like `NendoTrack.meta` and `NendoTrack.resource`) were stored in the Nendo Library which resulted in them being stored as JSON strings instead of JSON dictionaries. **This means that upgrading Nendo will break any apps that use libraries that were created with previous versions of nendo.** Please make sure you understand the implications and either flush your DB or convert it to match the new data model. +- Fixed a bug where the length of a `NendoTrack` would not be correctly determined if the track had a mono signal. - A bunch of small bugfixes, too many to mention them all here. [Compare with 0.1.3](https://github.com/okio-ai/nendo/compare/0.1.3...0.2.0) diff --git a/pyproject.toml b/pyproject.toml index 876c26f..dbe9edd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "nendo" -version = "0.1.3" +version = "0.2.1" authors = [ "Okio Team ", ]