Vlad I think you clearly want to limit the number of autocomplete suggestions. How to go about doing that is the question.
The simple way would be to limit the number of any given type. I would expect that different types would have different limits -- more for history, fewer for other types. Something along the lines of the following max number matches each type of: 2 top hits, 3 tabs, 3 bookmarks, 4 search suggestions, 6 history. Just throwing numbers out there. That may be too many.
Another approach would be to set a maximum number of total autocomplete results across all types and then limit the number of each type such that there are never more than the total max and as even a distribution as possible across the types.
If, for example, the maximum total was configured to 15, I typed "orion", and matched 1 top hit, 2 tabs, 8 bookmarks, 10 search suggestions, and 20 history entries. I think the results could look something like...
- Bookmark #1
- Bookmark #2
- Bookmark #3
- Suggestion #1
- Suggestion #2
- Suggestion #3
- History #1
- History #2
- History #3
I actually think the simpler approach is the right one because, to me, having more than a small number of matches for a given type is not helpful for an autocomplete interface and I would just keep typing to narrow it down.