ARI - moved encode/decode into default implementations of Model. Removed usage of Vec from the core. Changed asserts in the core to only trigger in debug.