I was not pinning any domains. Instead, I only raised the "github.com" domain in my preference. I consider it a bug because I believe that raised domains or pinned domains shouldn't make the search result irrelevant to the search terms.
This particular search doesn't bother me at all - I can get what I want by turning off personalization. I'm just reporting it so Kagi may adjust its algorithm if the bug can be reproduced and investigated on.