Chinese model
The "Ritsuryō" (757) and "Engi shiki" (927) were legal codes on the Chinese model.