The way to have faith in God to guide us in how to rightly live through His law is straightforwardly by obeying His law, which also straightforwardly refers to the set of laws that God has given.
We embody what we believe to be true about God through our works such as with James 2:18 saying that he would show his faith through his works, so everyone who is a doer of the same works as James believes in Jesus. In other words, the way to believe in God is by embodying His likeness through being a doer of His character traits. For example, by being a doer of good works in obedience to God's law we are embodying God's goodness, which is why our good works bring glory to Him (Matthew 5:16), and by embodying God's goodness we are also expressing the belief that God is good. Likewise, the way to believe that God is just is by embodying His likeness through being a doer of justice in obedience to His law, the way to believe that God is compassionate is by being compassionate, the way to believe that God is holy is by being a doer of His instructions for how to be holy as He is holy, and so forth. This is exactly the same as the way to believe in the Son, who is the radiance of God's glory and the exact likeness of His character (Hebrews 1:3), which he embodied through his works by setting a sinless example for us to follow of how to walk in obedience to God's law, and it is by this faith alone that we attain the character traits of God, which is how our faith upholds God's law.