Using text classification for system calls
The problem seems to arise in this line.

predictions = Dense(N_CLASSES, activation='softmax')(average) 


Here, N_CLASSES has the value of 2. Meaning you have 2 classes. But the y_train vector has shape ( 1, ). 


You need to convert the y_train vector to a one hot vector. Here's any example.


If y_train = [ [ 0 ] , [ 1 ] ] then its one hot vector would be [ [ 1 , 0 ] , [ 0 , 1 ] ]. The one hot vector has shape ( 2 , ) which is needed in the above code snippet.
So make this edit.

y_train = keras.utils.to_categorical( y_train , N_CLASSES )