-
Notifications
You must be signed in to change notification settings - Fork 4
API for Relationships widget #33
Comments
@kordianbruck just for final confirmation - is elasticsearch / API in scope of the visualization group? |
@Henni the query we're sending won't be an id, but a plain text from the search bar, I think Yes, so, if object couldn't be Getting Drunk, but only musicians, composers and pieces - that's OK. I only described ideal world, but you decide what to give as response (or what to save in the DB) |
@lustoykov we are not doing elastic at all. Instead you guys are going to utilize PostregreSQL Fulltext search capabilities by implementing the search api (which is then basically almost the same as the autocomplete endpoint) |
OK then, so
Is that the agreement? |
Question regarding the Don't we need two parameters there? One is the Also I think |
|
Yes, I understand their meaning, but both of them are calculated from the number of occurrences of the said relations in the data we have. This makes them dependent on one another. Unless we use another metric for the confidence such as tracking user feedback on said relations. In that case you might go with something simpler such as a field that contains an integer with the number of times the relation has been flagged by someone. |
@lustoykov db schemata are currently discussed over here #28 |
@lustoykov
|
I don't mind, will adjust the frontend once the final API is there. Then the relations should be nested as well, because otherwise if I'd want to access the 3rd relation for instruments I'd need the count of artists. |
@lustoykov What is the use case of that? |
it is just more consistent design in my opinion, the split in entities and non-split in relations seems a bit arbitrary to me. anyways, I don't mind here much - whatever you prefer. |
Entities have different types and underlying models hence the need for a split. If you prefer a more consistent look, an alternative structure would be to drop entities altogether.
Those correspond to actual models in the backend. |
no worries, do whatever you feel like is best, just let me know when it is final so I can adjust the frontend. |
What's the status here? Can you ping me in MusicConnectionMachine/VisualizationG5#80 when done? Thanks |
See MusicConnectionMachine/RelationshipsG3#27
I don't have rights, so please add Assigness and Deadline: 02.04.2017
so yesterdey me, @martomi and @vviro had a meeting and here is what came out of the discussion
The basic idea is that we want to display in a somewhat-table view non-trivial relationships (almost like a surprise-fun-fact table - Mozart | Liked | Getting Drunk)
Entity | Relation | Entity
When a user on the IMSLP site and exploring our widget, one of the entities is always fixed (for instance Mozart).
Now we want to have a search bar, where user can type in. The search bar should be very smart and display autosuggestions in form of:
Relations Suggestions
...
Entities Suggestions
...
Whenever a user clicks one of the suggestions, we'd make an api call with
Entity | Entity
expectingrelations
as response orEntity | Relations
expectingentities
as response to display the table viewEntity | Relation | Entity
Requirement: for the autosuggestions
the API
GET /autosuggest
should accept:a single param
query: { primaryEntity, searchInput, }
the API should deliver:
at least
title
is required,importance
andconfidence
would be nice.Requirement: for data display
GET /relations
should accept:a single param
query: { primaryEntity: String, secondaryEntity: String, }
and return
/entities
should accept:a single param
query: { primaryEntity: String, relation: String, }
and return
@martomi can you double check if the API as defined is OK? Please edit the post directly if I missed something.
@vviro also encourages us to talk to him more often.
The text was updated successfully, but these errors were encountered: