Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide better user interface for adapter #4

Open
slobentanzer opened this issue Nov 10, 2022 · 2 comments
Open

Provide better user interface for adapter #4

slobentanzer opened this issue Nov 10, 2022 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@slobentanzer
Copy link
Collaborator

I started by introducing an Enum class for UniProt fields (2c6f5b9) which can be used to dynamically set the fields to download and pass to BioCypher in the crossbar build script. Not sure, however, if Enums are the best way from a user-friendliness perspective. The aim is to abstract the process of using any given adapter as someone who wants to build a database, particularly in the case when the user does not know about specifics of the API of the primary source. Enums offer autocomplete, so at least the "knowing about adapter contents" is facilitated a bit.

We can think about it and discuss alternatives.

@slobentanzer slobentanzer added the enhancement New feature or request label Nov 10, 2022
@bnymnsen
Copy link
Collaborator

As another option, maybe we can use some type of configuration file where users can choose which fields to download. I think this option has 2 advantages. First, since Uniprot has lots of fields to download (https://www.uniprot.org/help/return_fields), this can prevent fields from being crowded in the adapter script. Second one is, for non-specialist users, this method seems more user friendly option.

For example, configuration file might be something like this:

xref fields:
   entrez: true
   kegg: false
   ...

However, this feels like we are taking away that feeling of programming for other type of users.

@slobentanzer
Copy link
Collaborator Author

i think having both options is a good solution, then users can decide what to do. enums have the advantage of auto-complete (as you are typing, you see which fields are provided by the resource and how it is spelled), which prevents user input failures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants