[build][bug] graph builder: many bugs fixed