Commit af6c676a364fbced2adb7dcf1ba316e671b90198

Authored by Andrew Kane
1 parent c52dbd0f

Improved intelligent search section [skip ci]

Showing 1 changed file with 5 additions and 13 deletions   Show diff stats
README.md
... ... @@ -590,11 +590,7 @@ end
590 590  
591 591 ## Intelligent Search
592 592  
593   -### Analytics
594   -
595   -The best starting point to improve your search **by far** is to track searches and conversions.
596   -
597   -[Searchjoy](https://github.com/ankane/searchjoy) makes it easy.
  593 +The best starting point to improve your search **by far** is to track searches and conversions. [Searchjoy](https://github.com/ankane/searchjoy) makes it easy.
598 594  
599 595 ```ruby
600 596 Product.search "apple", track: {user_id: current_user.id}
... ... @@ -607,15 +603,9 @@ Focus on:
607 603 - top searches with low conversions
608 604 - top searches with no results
609 605  
610   -### Conversions
611   -
612   -Searchkick can use conversion data to learn what users are looking for. If a user searches for “ice cream” and adds Ben & Jerry’s Chunky Monkey to the cart (our conversion metric at Instacart), that item gets a little more weight for similar searches.
  606 +Searchkick can then use the conversion data to learn what users are looking for. If a user searches for “ice cream” and adds Ben & Jerry’s Chunky Monkey to the cart (our conversion metric at Instacart), that item gets a little more weight for similar searches.
613 607  
614   -The first step is to define your conversion metric and start tracking conversions. The database works well for low volume, but feel free to use Redis or another datastore.
615   -
616   -Searchkick automatically treats `apple` and `APPLE` the same.
617   -
618   -Next, add conversions to the index.
  608 +Add conversion data with:
619 609  
620 610 ```ruby
621 611 class Product < ApplicationRecord
... ... @@ -639,6 +629,8 @@ Reindex and set up a cron job to add new conversions daily.
639 629 rake searchkick:reindex CLASS=Product
640 630 ```
641 631  
  632 +This can make a huge difference on the quality of your search.
  633 +
642 634 **Note:** For a more performant (but more advanced) approach, check out [performant conversions](#performant-conversions).
643 635  
644 636 ## Personalized Results
... ...