def persist_instances(metamodel, path, mode='<STR_LIT:w>'):
with open(path, mode) as f:<EOL><INDENT>for inst in metamodel.instances:<EOL><INDENT>s = serialize_instance(inst)<EOL>f.write(s)<EOL><DEDENT><DEDENT>
Persist all instances in a *metamodel* by serializing them and saving to a 
*path* on disk.