Playing External Samples in time with each other

Do you want the samples to start at the same time, and then restart together when the longer one finishes, or do you want them to be altered to take the same time to complete?

In the former case, play each one in a separate live_loop and sync the shorter one to the start of the longer loop. In the second case use beat_stretch option to alter the rate so that it occupies a known number of beats. eg
method 1 shorter loop synced to start of longer loop

  live_loop :short do
    sync :long #waits for loop_breakbeat to restart
    sample :loop_amen
    t=sample_duration :loop_amen
    puts "duration loop_amen is #{t}"
    #no need for sleep because of sync
  end
  
  live_loop :long,delay: 0.001 do #:delay makes sure short loop is primed before :long starts first time
    sample :loop_breakbeat,amp: 2
    t=sample_duration :loop_breakbeat
    puts "duration loop_breakbeat is #{t}"
    sleep t
  end

method 2 both loops adjusted to last 2 beats using beat_stretch option

live_loop :a do
  sample :loop_amen ,beat_stretch: 2
  puts "loop_amen"
  sleep 2
end
live_loop :b do
  puts "loop_breakbeat"
  sample :loop_breakbeat,beat_stretch: 2
  sleep 2
end