renderpci / dedalo

Dédalo: Cultural Heritage & Oral History Management System
https://dedalo.dev
GNU Affero General Public License v3.0
32 stars 6 forks source link

Tools in Dedalo 6 #59

Closed pricua closed 1 year ago

pricua commented 1 year ago

Hi,

I wanted to ask you a question about the tools in Dedalo 6.

The fact is that we have a tool that we use in different ontologies to carry out the massive import of images and their association to elements of a section (tool_import_images). When updating to Dedalo 6 this tool has stopped working.

The same goes for other tools like tool_import_bibtex and tool_import_zotero from the generic rsc205 section.

We have seen that Dedalo 6 incorporates a new Tools section. We understand that the tools in this new section will have to be created or registered, but we don't quite understand how it works. Could you explain a bit about the process to create a new tool, in this case the image import tool?

We have also heard rumors that in Dedalo 6 everything was going to be unified to a single importer. Will it also be used for the massive import of images or will we have to keep the tool we currently use?

Thanks

renderpci commented 1 year ago

Hi Pricua

Yes, in the v6 the v5 tools will not work directly, we are changing all client/server interfaces to point it into new API calls. And all v5 tools will need to refractoryze to this new situation.

We will not update all v5 tools, only generic tools will be updated, and any specific tools for import images, or other specific code for specific institutions needs will need updated / maintained by the institution that promote it.

And yes, in v6 you will need to register the tools. The new tool system use a more dynamic and useful model to load and configure tools. With the new model, build tools by third-party will be more easy and the idea is to be compatible between developers. Note that the register it's not a 'central register', we do not want to centralise it, is a 'by installation register' to control what tools will be loaded and will be functional in your Dédalo system. If you want share your tool with other installations, you only will need to send the tool directory with the register file to others and register it in the other installation, it's more easy to shared, load, etc, and it's independent of other Dédalo parts than v5 model.

So, if you want to develop any new tool, or refractorize any v5 tool, you will need to create the tool in the development section, name and configure it, and register the result.

1.- Go to:

Development-> Tools-> Tool development

Screenshot 2023-01-14 at 13 03 45

2.- Create a new tool record using the 'New' button (as any other section in Dédalo).

3.- Fill the information about the new tool, name, label, scope, custom labels, etc. you can see samples of existing tools in the register section:

Development-> Tools-> Registered tools

Screenshot 2023-01-15 at 13 21 29

Important!: The name of the tool must start with 'tool' following with the tld or institution acronym as 'dev' following with the name of the tool and it can not contain any spaces, accents or non ASCII chars to prevent future errors with paths, etc. A good name could be 'tool_numisdataimport', where 'tool' is the mandatory prefix, 'numisdata_' is the mandatory TLD and 'import' is the main description of the tool. A wrong name could be 'my_tool_name' it's not compatible between installations and will be rejected to be shared. In label field, you could be more explicit as 'Tool to import Numismatic custom files... blah blah blah'.

When you will done, you could download the register file pressing the button "Download register file" in inspector:

Screenshot 2023-01-15 at 13 31 07

And it will download the register.json file. This file need to be placed in the root directory of your tool

Screenshot 2023-01-15 at 13 32 31

And finally you will need to register the tool, so, you will need to go to Development control:

Development

And use the Register tools to register your tool.

Screenshot 2023-01-15 at 13 35 33

For help to others developers to create new tools we are creating a template/sample tool named tool_dev_template to show the basic functionalities.

We have also heard rumors that in Dedalo 6 everything was going to be unified to a single importer. Will it also be used for the massive import of images or will we have to keep the tool we currently use?

Well, we will use unique import tool named tool_import_files to do massive import files as images, pdf, av, or any other media ( Feel free to use it, of course! ) this is because we do not want to create multiple import tools, v5 has too many import tools to maintain. And we will not support specific institutions needs with imports tools, if your installation need a specific filenames or specific directory structuration, or move the files to your own directories or proceses, you will need to create new one (you could use tool_import_files as template) or refactorize v5 versions.

Best