01-01-2019, 12:47 PM | #1 |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
[GUI Plugin] Entities Manager
[GUI Plugin] Entities Manager
Summary:
Documentation:
Requires Calibre Version: 6.0.0+ Version History: Spoiler:
Last edited by DaltonST; 01-17-2023 at 12:17 PM. Reason: Version 1.0.19 |
01-01-2019, 12:48 PM | #2 |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
For future use
For future use.
|
Advert | |
|
01-01-2019, 06:46 PM | #3 |
null operator (he/him)
Posts: 20,593
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Trying to work out how to associate related works, e.g
IMO Associations need a Name, like Links and Notes, e.g. Mary Wollstonecraft and Mary Shelley are Mother and Daughter, whereas J.K. Rowling and Robert Galbraith are Joanne Rowling's pseudonyms. BR |
01-01-2019, 10:44 PM | #4 | |||
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Quote:
Quote:
Quote:
Version 1.0.2 has been released. DaltonST Last edited by DaltonST; 01-03-2019 at 01:42 PM. Reason: updated information |
|||
01-02-2019, 12:48 AM | #5 |
null operator (he/him)
Posts: 20,593
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Thanks, no hurry. I have several other potential uses of EM I want to explore over the next week or so.
How do I add multiple notes, each with a different name, to the same entity? I somehow managed to add two with the same name (Bibliography) which I didn't expect to work, but I can't see how to add two notes with different Names - e.g. Bibliography and Biographies. BR |
Advert | |
|
01-02-2019, 09:46 AM | #6 |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
To add additional notes, 'clear' the existing note editing box, put in a new name and a new note text, and click 'add note'. The dropdown box above with the names of all of the existing notes for the current entity will now include the new name. The names in the dropdown are sorted alphabetically, so you might have to click it to select what you just added if you need to review it after it was created.
Yes, you can have multiple notes and links with the same name. I allowed that since I figured if I disallowed it, someone would come up with a good reason to allow it. I skipped to the end. There is a "link id" and "note id" internally that makes each link and note unique, and permits you to "change" a specific note among many notes having the identical name. DaltonST |
01-03-2019, 01:35 PM | #7 |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Version 1.0.2 Arbitrary, user-defined "@" Entity Types.
Version 1.0.2 - 2019-01-03 Arbitrary, user-defined "@" Entity Types. @Association Entity Type special functionality.
Associations themselves may now be created as a proper Entity, with an Entity Type of "@Association" and a value that reflects the Entity Types and Values of the 2 other Associated Entities. @Association is automatically created by EM for this purpose. Refer to the image in the Original Post. DaltonST |
01-04-2019, 03:08 PM | #8 |
null operator (he/him)
Posts: 20,593
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
As far as I can see there is no way to see in the Book List, that something (e.g. Publisher:Random House) has been been selected as an Entity.
Any thoughts of making that available, I'm thinking of something which I could use in a Column icon rule to show the stylised purple 'e' on cells that are entities. The use of '@' to distinguish User Defined Entities could be confused with the use of '@' to distinguish User Categories. How about making it something else. BR |
01-04-2019, 04:52 PM | #9 | |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
@UserEntityTypes are very similar to @UserCategories, but just not in the Tag Browser. UETs are psuedo-columns, just like UCs. Look in table preferences key field_metadata, and you will see that UCs are next to Custom Columns that are next to Standard Columns. In theory (but not in practice since the book-level values would be missing), I could add UETs to the Tag Browser where all of the Standard/Custom Column ETs already are. That is why I like the "@".
Quote:
I am not a Template person, do not ever use them, and do not know if they are limited to the GUI Cache, or can read metadata.db directly via APSW. A Template function in general program mode that could read a SQLite database directly would work. EM is outside of the GUI Cache entirely, since book ID is not anywhere within EM. That is its point; it is designed to be "above" book-level. So, the general program mode function would be reading from the physical database instead of the in-memory Cache for every book and every potential ET column at startup. Slow for large Libraries with many ET columns. If Templates can do it, I will write the general program mode function and make it available to copy-and-paste. However, if they cannot access APSW, then I know of no way to do what you ask. I am interested to know if they can. DaltonST |
|
01-04-2019, 06:17 PM | #10 | ||
null operator (he/him)
Posts: 20,593
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Quote:
Quote:
BR Last edited by BetterRed; 01-05-2019 at 01:39 AM. |
||
01-04-2019, 11:01 PM | #11 |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
See the attached image for a yes/no column easily updated by an EM program manually and/or automatically at Startup if a particular book has any Entity Type with a matching Entity Value already created as an Entity.
#18 is the yes/no CC table. The code is just for Author, but checking for all Entity Types that exist in the the _entities table is trivial. Code:
UPDATE custom_column_18 SET value = 1 WHERE custom_column_18.book IN (SELECT book FROM books_authors_link WHERE author IN (SELECT id FROM authors WHERE authors.name IN (SELECT value FROM _entities WHERE type = 'Author'))); UPDATE custom_column_18 SET value = 0 WHERE custom_column_18.book NOT IN (SELECT book FROM books_authors_link WHERE author IN (SELECT id FROM authors WHERE authors.name IN (SELECT value FROM _entities WHERE type = 'Author'))) DaltonST |
01-05-2019, 01:59 AM | #12 |
null operator (he/him)
Posts: 20,593
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
I was looking for indication at the cell level rather than the book level.
Having a Y/N column for every column that might have entity-info would add a lot of clutter to Preference settings, the Book List, View Manager settings etc. And the Y/N column won't move with its corresponding value column when the latter's header is dragged around in the book list - which I do quite frequently. Whilst my preference would be to use column icon rules to indicate a cell has some entity-info, other folks might prefer to use column colour rules. Unfortunately icons and colour rules are not applied in the Book Details panels. That was one of the things that attracted me to having a single long text cell per book containing a list of column type:value pairs that have entity-info. BR Last edited by BetterRed; 01-05-2019 at 03:13 AM. |
01-05-2019, 03:08 AM | #13 |
null operator (he/him)
Posts: 20,593
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
This is the sort of thing I was aiming for
Imagine I have associated the four titles with the icon to a user entity named 'Search for Lost Time', and I've added a link to 'Princeton press', and a note defining what I mean by 'Medieval History'. For completeness sake these are the dummy Column icon rules I had to set up BR Last edited by BetterRed; 01-05-2019 at 03:35 PM. |
01-05-2019, 09:39 AM | #14 |
Deviser
Posts: 2,265
Karma: 2090983
Join Date: Aug 2013
Location: Texas
Device: none
|
Automating Column Rules
Perhaps automating the creation and maintenance of the various rules is the best way to go forward.
Could you Export your column rules and attach them to your previous post so I have a "control" data set to compare to while testing? DaltonST |
01-05-2019, 09:41 AM | #15 |
Guru
Posts: 919
Karma: 417282
Join Date: Jun 2015
Device: kobo aura h2o, kobo forma
|
If I try to use the tags column or author column for entities, the value pulldown essentially opens a full screen window, because both of these fields contain metadata imported from the books, and I've got at least one book for each that imported a full line of garbage with either no delimiter or an incorrect delimiter.
Rather than hunting through my library for extra long authors or tags, can you put a limit on the width of the pulldown or something? |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[GUI Plugin] View Manager | kiwidude | Plugins | 414 | 04-13-2024 01:41 PM |
[GUI Plugin] KindleUnpack - The Plugin | DiapDealer | Plugins | 492 | 10-25-2022 08:13 AM |
KindleExplorer - file manager program (GUI) | anakod | Kindle Developer's Corner | 203 | 04-17-2021 02:06 PM |
[GUI Plugin] Save Virtual Libraries To Column (GUI) | chaley | Plugins | 14 | 04-04-2021 05:25 AM |
[GUI Plugin] Plugin Updater **Deprecated** | kiwidude | Plugins | 159 | 06-19-2011 12:27 PM |