Compile scheme functions in rule engine