Hi, i read sourse code and could not understand how to use custom metrics? Does exist way do it, or i should rewrite this library?