Issue 276-Modify the search API

Refer to #276