```dart
// Tests only against the local state
Future<void> savePredicateLocally(Post post) async {
  if (post.title.startsWith('[Amplify]')) {
      await Amplify.DataStore.save(post);
  }
}

// Only applies the update if the data in the remote backend satisfies the criteria
Future<void> savePredicateRemotely(Post post) async {
  try {
    await Amplify.DataStore.save(
      post,
      where: Post.TITLE.beginsWith('[Amplify]'),
    );
  } catch (e) {
    ...
  }
}
```
