Disable the apply button while generating the knowledge base
Improve the code of KeyValueValidator object