This correspondence studies slotted ALOHA (SA) operated with q-ary compute-forward (CF) for grant-free random access. At the transmitters, a practical q-ary channel code and repetition SA (RSA) protocol are utilized, where users send replicas of their coded-modulated packets in randomly selected slots. At the receiver, practical q-ary linear physical-layer network coding is employed to compute and stores a number of network-coding (NC) message streams per slot. Upon collecting a sufficient amount of NC message streams from a number of consecutive slots, the receiver carries out generalized matrix inversion (GMI) to recover the users' messages. We demonstrate that the developed scheme exhibits dramatically increased throughput by as much as 80%. Furthermore, thanks to GMI, there is no need to wait till the end of the frame for decoding, leading to slashed processing delay in RSA.