There are two main reasons why the certain keyword has post_id = 0 value.
1. Visitor came from search engine by clicking the link to the homepage of your site instead of clicking the link that redirect to the specific post in your site. If this situation happened, we cannot do anything since it came from the search engine.
2. Your site has custom content type; it means the type of the content page is outside of the post/page in WordPress. You can do a little trick how to solve this condition.
Actually, I am trying to find the solution regarding the reason number 2 above. It's a quite simple solution, I think. Of course, this will need modification in table structure and the script that used by this plugin.
I will write an article regarding the solution I found. So please be patient! :)