def METHOD_NAME(klazz, field_descriptions):
    inst = klazz()
    base_struct = inst.__seamless_struct__.raw
    fields = {}
    def do_document(path, struct, fields):
        example = {}
        # first do all the fields at this level
        for simple_field, instructions in struct.get('fields', {}).items():
            example[simple_field] = type_map(instructions.get("coerce"))
            fields[path + simple_field] = (field_descriptions.get(path + simple_field, ""), datatype(instructions.get("coerce")), form(instructions.get("coerce")), values_or_range(instructions.get("allowed_values"), instructions.get("allowed_range")))
        # now do all the objects at this level
        for obj in struct.get('objects', []):
            newpath = obj + "." if not path else path + obj + "."
            instructions = struct.get('structs', {}).get(obj, {})
            example[obj] = do_document(newpath, instructions, fields)
        # finally do all the lists at this level
        for l, instructions in struct.get('lists', {}).items():
            if instructions['contains'] == 'field':
                example[l] = [type_map(instructions.get("coerce"))]
                fields[path + l] = (field_descriptions.get(path + l, ""), datatype(instructions.get("coerce")), form(instructions.get("coerce")), values_or_range(instructions.get("allowed_values"), instructions.get("allowed_range")))
            elif instructions['contains'] == 'object':
                newpath = l + "." if not path else path + l + "."
                inst = struct.get('structs', {}).get(l, {})
                example[l] = [do_document(newpath, inst, fields)]
        return example
    example = do_document("", base_struct, fields)
    return example, fields