Smart contracts on Ripple are limited. Ethereum provides you with a turning complete language called Solidity. This language allows you to create any kind of application. It provides complete flexibility. For example, we can make an autonomous lending and borrowing platform using solidity.
However, Ripple's escrow contracts are limited in functionality. Here, the contract is already written, and we would only be interfacing it through the APIs to create and release escrows.
There's some news about Ripple introducing a new type of smart contracts. Hopefully, they would provide us with greater flexibility.