Complete the generate json, But still has bugs.

Signed-off-by: servanter <fengshang@126.com>