Refinement of rule table making code