improved keyword network now only uses key functions