add basic rule mapper, now, it can work!

example see tools/test.py