<commit_before>#Seed users
user_list = [
  ['scooby', '<EMAIL>', 'doo'],
  ['scrappy', '<EMAIL>', 'doo'],
  ['velma', '<EMAIL>', 'freddy'],
  ['derek', '<EMAIL>', 'baseball'],
  ['mark', '<EMAIL>', 'steroids'],
  ['Patrick', '<EMAIL>', 'Scoobz'],
  ['WolfJob', '<EMAIL>', 'WolfJob'],
  ['Barry', '<EMAIL>', 'steroids'],
  ['sonic', '<EMAIL>', 'hedgehog']
]

user_list.each do |name, email, password|
    User.create(name: name, email: email, password: password)
end

User.create(name:"Jeff", email: "jeff", password: "<PASSWORD>", admin: true)


#Seed Restaurants from yelp API
results_soma = [
  ["mourad-restaurant-san-francisco","Mourad Restaurant" ],
  ["the-flying-falafel-san-francisco-3", "The Flying Falafel"],
  ["marlowe-san-francisco-2", "Marlowe"],
  ["cockscomb-san-francisco", "Cockscomb"],
  ["garaje-san-francisco", "Garaje"],
  ["zero-zero-san-francisco", "Zero Zero"],
  ["box-kitchen-san-francisco", "Box Kitchen"],
  ["so-san-francisco-4","SO" ],
  ["tropisueño-san-francisco-3", "Tropisueño"],
  ["the-pink-elephant-san-francisco-3", "The Pink Elephant"],
  ["citizens-band-san-francisco", "Citizen's Band"],
  ["little-skillet-san-francisco-2", "Little Skillet"],
  ["jamber-san-francisco", "Jamber"],
  ["picnic-on-third-san-francisco", "Picnic on Third"],
  ["hrd-san-francisco-2", "HRD"],
  ["dragoneats-san-francisco-3", "DragonEats"],
  ["freshroll-vietnamese-rolls-and-bowls-san-francisco", "Freshroll Vietnamese Rolls & Bowls"],
  ["red-dog-restaurant-and-bar-san-francisco", "Red Dog Restaurant & Bar"],
  ["bluestem-brasserie-san-francisco", "Bluestem Brasserie"],
  ["archive-bar-and-kitchen-san-francisco", "Crepe-Madame"]
]

results_mission = [
  ["sous-beurre-kitchen-san-francisco-2", "Sous Beurre Kitchen"],
  ["thistle-san-francisco-8", "<NAME>"],
  ["bistro-l-aviateur-san-francisco-2", "<NAME> & Rotisserie"],
  ["hoffmanns-grill-and-rotisserie-san-francisco", "Loló"],
  ["loló-san-francisco-4", "20 Spot"],
  ["20-spot-san-francisco", "Stuffed"],
  ["stuffed-san-francisco", "Beretta"],
  ["beretta-san-francisco", "<NAME>"],
  ["el-farolito-san-francisco-2", "The Tradesman"],
  ["californios-san-francisco", "Californios"],
  ["kazan-san-francisco", "Kazan"],
  ["the-tradesman-san-francisco-2", "Al's Place"],
  ["prubechu-san-francisco", "Prubechu"],
  ["als-place-san-francisco", "<NAME>"],
  ["limón-rotisserie-san-francisco-3", "Lazy Bear"],
  ["lazy-bear-san-francisco-5", "Local Mission Eatery"],
  ["local-mission-eatery-san-francisco", "The Front Porch"],
  ["the-front-porch-san-francisco", "Paprika"],
  ["paprika-san-francisco", "Hog & Rocks"],
  ["hog-and-rocks-san-francisco", "Lolinda"]]

results_embarcadero = [["coqueta-san-francisco", "Coqueta"],
 ["hog-island-oyster-co-san-francisco", "Hog Island Oyster Co"],
 ["roli-roti-gourmet-rotisserie-san-francisco", "<NAME>"],
 ["il-cane-rosso-san-francisco", "il Cane Rosso"],
 ["primavera-san-francisco", "Primavera"],
 ["la-mar-cebichería-peruana-san-francisco-4", "<NAME>"],
 ["waterbar-san-francisco", "Waterbar"],
 ["palomino-san-francisco-3", "Palomino"],
 ["chaya-brasserie-san-francisco", "<NAME>"],
 ["4505-meats-san-francisco-7", "4505 Meats"],
 ["frog-hollow-farm-market-and-cafe-san-francisco", "Frog Hollow Farm Market & Cafe"],
 ["perrys-san-francisco-6", "Perry's"],
 ["delica-san-francisco", "Delica"],
 ["boccalone-san-francisco-2", "Boccalone"],
 ["the-slanted-door-san-francisco", "The Slanted Door"],
 ["el-porteño-empanadas-san-francisco-4", "El Porteño Empanadas"],
 ["hillstone-san-francisco-4", "Hillstone"],
 ["pier-23-cafe-san-francisco", "Pier 23 Cafe"],
 ["fog-city-san-francisco-2", "Fog City"],
 ["gotts-roadside-san-francisco-2", "Gott's Roadside"]]

results_soma.map {
  |result| Restaurant.create(yelp_id: result[0], title: result[1], wait_time: 30)
}

results_mission.map {
  |result| Restaurant.create(yelp_id: result[0], title: result[1], wait_time: 30)
}

results_embarcadero.map {
  |result| Restaurant.create(yelp_id: result[0], title: result[1], wait_time: 30)
}


# Add owners for some restaurants
dragon_eats = Restaurant.where(yelp_id: "dragoneats-san-francisco-3").first
dragon_eats.user_id = 10

dragon_eats.save



lazy_bear = Restaurant.where(yelp_id: "lazy-bear-san-francisco-5").first
lazy_bear.user_id = 2
lazy_bear.save

hrd = Restaurant.where(yelp_id: "hrd-san-francisco-2").first
hrd.user_id = 3
hrd.save


#Seed reservations
users = [5,6,7,8,9]

users.each do |user|
  dragon_eats.reservations.create(user_id: user, number_in_party: 3, name: "Person #{user}", timer: 25)
end
dragon_eats.update_wait_time
<commit_msg>Change seedfile to have real names<commit_after>#Seed users
user_list = [
  ['scooby', '<EMAIL>', 'doo'],
  ['scrappy', '<EMAIL>', 'doo'],
  ['velma', '<EMAIL>', 'freddy'],
  ['derek', '<EMAIL>', 'baseball'],
  ['mark', '<EMAIL>', 'steroids'],
  ['Patrick', '<EMAIL>', 'Scoobz'],
  ['WolfJob', '<EMAIL>', 'WolfJob'],
  ['Barry', '<EMAIL>', 'steroids'],
  ['sonic', '<EMAIL>', 'hedgehog'],
  ['diana', '<EMAIL>', 'waitless']
]

user_list.each do |name, email, password|
    User.create(name: name, email: email, password: password)
end

User.create(name:"Jeff", email: "jeff", password: "<PASSWORD>", admin: true)


#Seed Restaurants from yelp API
results_soma = [
  ["mourad-restaurant-san-francisco","Mourad Restaurant" ],
  ["the-flying-falafel-san-francisco-3", "The Flying Falafel"],
  ["marlowe-san-francisco-2", "Marlowe"],
  ["cockscomb-san-francisco", "Cockscomb"],
  ["garaje-san-francisco", "Garaje"],
  ["zero-zero-san-francisco", "Zero Zero"],
  ["box-kitchen-san-francisco", "Box Kitchen"],
  ["so-san-francisco-4","SO" ],
  ["tropisueño-san-francisco-3", "Tropisueño"],
  ["the-pink-elephant-san-francisco-3", "The Pink Elephant"],
  ["citizens-band-san-francisco", "Citizen's Band"],
  ["little-skillet-san-francisco-2", "Little Skillet"],
  ["jamber-san-francisco", "Jamber"],
  ["picnic-on-third-san-francisco", "Picnic on Third"],
  ["hrd-san-francisco-2", "HRD"],
  ["dragoneats-san-francisco-3", "DragonEats"],
  ["freshroll-vietnamese-rolls-and-bowls-san-francisco", "Freshroll Vietnamese Rolls & Bowls"],
  ["red-dog-restaurant-and-bar-san-francisco", "Red Dog Restaurant & Bar"],
  ["bluestem-brasserie-san-francisco", "Bluestem Brasserie"],
  ["archive-bar-and-kitchen-san-francisco", "Crepe-Madame"]
]

results_mission = [
  ["sous-beurre-kitchen-san-francisco-2", "Sous Beurre Kitchen"],
  ["thistle-san-francisco-8", "Bistro L'Aviateur"],
  ["bistro-l-aviateur-san-francisco-2", "<NAME>ill & Rotisserie"],
  ["hoffmanns-grill-and-rotisserie-san-francisco", "Loló"],
  ["loló-san-francisco-4", "20 Spot"],
  ["20-spot-san-francisco", "Stuffed"],
  ["stuffed-san-francisco", "Beretta"],
  ["beretta-san-francisco", "<NAME>"],
  ["el-farolito-san-francisco-2", "The Tradesman"],
  ["californios-san-francisco", "Californios"],
  ["kazan-san-francisco", "Kazan"],
  ["the-tradesman-san-francisco-2", "Al's Place"],
  ["prubechu-san-francisco", "Prubechu"],
  ["als-place-san-francisco", "<NAME>"],
  ["limón-rotisserie-san-francisco-3", "Lazy Bear"],
  ["lazy-bear-san-francisco-5", "Local Mission Eatery"],
  ["local-mission-eatery-san-francisco", "The Front Porch"],
  ["the-front-porch-san-francisco", "Paprika"],
  ["paprika-san-francisco", "Hog & Rocks"],
  ["hog-and-rocks-san-francisco", "Lolinda"]]

results_embarcadero = [["coqueta-san-francisco", "Coqueta"],
 ["hog-island-oyster-co-san-francisco", "Hog Island Oyster Co"],
 ["roli-roti-gourmet-rotisserie-san-francisco", "<NAME>"],
 ["il-cane-rosso-san-francisco", "il Cane Rosso"],
 ["primavera-san-francisco", "Primavera"],
 ["la-mar-cebichería-peruana-san-francisco-4", "<NAME>"],
 ["waterbar-san-francisco", "Waterbar"],
 ["palomino-san-francisco-3", "Palomino"],
 ["chaya-brasserie-san-francisco", "<NAME>"],
 ["4505-meats-san-francisco-7", "4505 Meats"],
 ["frog-hollow-farm-market-and-cafe-san-francisco", "Frog Hollow Farm Market & Cafe"],
 ["perrys-san-francisco-6", "Perry's"],
 ["delica-san-francisco", "Delica"],
 ["boccalone-san-francisco-2", "Boccalone"],
 ["the-slanted-door-san-francisco", "The Slanted Door"],
 ["el-porteño-empanadas-san-francisco-4", "El Porteño Empanadas"],
 ["hillstone-san-francisco-4", "Hillstone"],
 ["pier-23-cafe-san-francisco", "Pier 23 Cafe"],
 ["fog-city-san-francisco-2", "Fog City"],
 ["gotts-roadside-san-francisco-2", "Gott's Roadside"]]

results_soma.map {
  |result| Restaurant.create(yelp_id: result[0], title: result[1], wait_time: 30)
}

results_mission.map {
  |result| Restaurant.create(yelp_id: result[0], title: result[1], wait_time: 30)
}

results_embarcadero.map {
  |result| Restaurant.create(yelp_id: result[0], title: result[1], wait_time: 30)
}


# Add owners for some restaurants
dragon_eats = Restaurant.where(yelp_id: "dragoneats-san-francisco-3").first
dragon_eats.user_id = 10

dragon_eats.save



lazy_bear = Restaurant.where(yelp_id: "lazy-bear-san-francisco-5").first
lazy_bear.user_id = 2
lazy_bear.save

hrd = Restaurant.where(yelp_id: "hrd-san-francisco-2").first
hrd.user_id = 3
hrd.save


#Seed reservations
users = [5,6,7,8,9]
names = [0,1,2,3,4,"Masha","Brick","Hunter","Jen","Jordan"]

users.each do |user|
  dragon_eats.reservations.create(user_id: user, number_in_party: 3, name: names[user], timer: 25)
end
dragon_eats.update_wait_time

{'fraction_non_alphanumeric': 0.21907327586206896, 'fraction_numerical': 0.015193965517241378, 'mean_word_length': 5.427285318559557, 'pattern_counts': {'":': 0, '<': 37, '<?xml version=': 0, '>': 37, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7604315', 'n_tokens_mistral': 3972, 'n_tokens_neox': 3844, 'n_words': 586}