I don't know if the divserity lottery specifically triggers the creation of an A-file, but its retention is permanent. See https://www.archives.gov/research/immigration/aliens
The United States Citizenship and Immigration Service (USCIS) and the National Archives and Records Administration (NARA) signed an agreement on June 3, 2009, to make the Alien Files (A-Files) a permanent series of records, eligible for transfer to NARA custody 100 years after the immigrant's year of birth.