Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Development

Notices

Reply
 
Thread Tools Search this Thread
Old 06-04-2014, 03:59 AM   #1
Ramblurr
Member
Ramblurr began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Apr 2010
Device: Kindle
Avoiding metadata identify results merge

My metadata source plugin is creating identical results that differ only on the publisher field (so title, authors, id, are the same). But the ISBNMerge algorithm in identify.py is merging them all into one result with only the first publisher added getting chosen.

Can I affect this algorithm somehow? Is there some hijinx I can play with my Metadata object to get this algorithm not to perform the merge? It seems changing the title, author, or identifiers field would work, but, naturally, I want these to remain the same, correct, values.

This is because the webservice I'm writing a metadata source plugin for unfortunately conflates the various publishers for all editions of an item.

Example:
See this entry: http://rpggeek.com/rpgitem/44383/trail-of-cthulhu (XML)

The primary publisher is Pelgrane Press, and the two other publishers are responsible for other language translations.

In my metadata source plugin I'm adding three results, one for each publisher. The idea is the user can choose which publisher matches the version they have.

Any advice?
Ramblurr is offline   Reply With Quote
Old 06-05-2014, 12:10 AM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,858
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No there's no way a plugin can influence that algorithm. That algorthm exists so that a user with a lot of plugins enabled is not overwhelmed by lots of very similar results. Generally speaking, the metadata download process is not really conducive to allowing a user to pick and choose between slighlty differing individual results as that would be a mess for the most common use cases.

If you really want to allow users to choose individual publishers and the like, your best bet is to to create a user interface plugin that bypasses the normal metadata download process altogether and has its own UI for browsing results. The downside to this approach is that your plugin will not be useable from the edit metadata dialog.
kovidgoyal is offline   Reply With Quote
Advert
Reply

Tags
metadata, plugin development


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Bulk metadata download and merge tags and select larger cover(s) hiperlink Calibre 2 03-26-2014 03:58 AM
Download metadata merge result ? abuck Library Management 1 10-11-2013 08:49 AM
Merge books with Edit Metadata bulk option? Nialls Calibre 1 02-07-2013 11:35 AM
Merge Formats library into Metadata library? Or, Add Format in bulk? Sabardeyn Library Management 5 01-23-2013 06:00 AM
Merge metadata from other lib drMerry Library Management 6 05-04-2011 06:41 PM


All times are GMT -4. The time now is 06:38 PM.


MobileRead.com is a privately owned, operated and funded community.