abstract neural network pattern