def create_snapshot_dict(pair, revision_id, user_id, context_id):
  """Create dictionary representation of snapshot"""
  parent, child = pair.to_2tuple()
  return {
      "parent_type": parent.type,
      "parent_id": parent.id,
      "child_type": child.type,
      "child_id": child.id,
      "revision_id": revision_id,
      "modified_by_id": user_id,
      "context_id": context_id
  }