Category Hierarchy
Category Hierarchy Algorithm Overview
In this module, you will improve navigation for business categories. Let’s first have a look at the part of the application that you will enhance.
We can search for businesses by name and category, but at the moment we have a list of over 100 categories to choose from! One way that we could make things easier for our user is if we let them navigate a taxonomy of categories, starting at the toplevel. To do this we’ll use the Overlap Similarity algorithm to identify a category hierarchy in the data. We’ll need to run the algorithm and make some updates to our data in Neo4j, then update the query used in the application to populate the category dropdown.
Exercise

In CodeSandbox Browser, click Business Search and then click the pane for selecting a category. You should see a very long list of categories. You will use the Overlap Similarity algorithm to create relationships in the graph that will be used to identify the toplevel categories.

In Neo4j Browser, complete the steps for Category Hierarchy (:play applied_graph_algorithms/02_category_hierarchy.html) to add category hierarchy to the graph using the Overlap Similarity algorithm.

In CodeSandbox, edit the Cypher query in
src/exercises/exercise1.js
to return only toplevel categories to populate the Category drop down in Business Search. 
Save your changes to exercise1.js.

In CodeSandbox Browser, click Business Search and then click the pane for selecting a category. Is the list of categories smaller?
Useful Resources
Tips

Solution
If you get stuck, watch this video for a walkthrough of the solution:
Category Hierarchy exercise solution
Check your understanding
Question 1
Algorithm Understanding: Overlap Similarity
Which of the following best describes what the Overlap Similarity algorithm computes?
Select the correct answer.

The size of the intersection divided by the size of the smaller of the two sets

The number of pairwise disagreements between two ranking lists

The size of the intersection divided by the size of the union of two sets

The minimum number of operations required to transform one string into the other
Need help? Ask in the Neo4j Community