def METHOD_NAME(
    encounter: EncounterItemModel,
    world: WorldState,
) -> NPC:
    current_monster = monster.Monster()
    current_monster.load_from_db(encounter.monster)
    # Set the monster's level based on the specified level range
    if len(encounter.level_range) > 1:
        level = random.randrange(
            encounter.level_range[0],
            encounter.level_range[1],
        )
    else:
        level = encounter.level_range[0]
    # Set the monster's level
    current_monster.level = 1
    current_monster.set_level(level)
    current_monster.set_moves(level)
    current_monster.set_capture(formula.today_ordinal())
    current_monster.current_hp = current_monster.hp
    current_monster.experience_modifier = encounter.exp_req_mod
    # Create an NPC object which will be this monster's "trainer"
    npc = NPC("random_encounter_dummy", world=world)
    npc.add_monster(current_monster, len(npc.monsters))
    # NOTE: random battles are implemented as trainer battles.
    #       this is a hack. remove this once trainer/random battlers are fixed
    current_monster.owner = None
    npc.party_limit = 0
    return npc