Usually LSTMs are used for inputs with varying length, for exactly 3 inputs with a total vector size of 300 you can just use a few nn.Linear layers.
Nevertheless, if you want to use an LSTM, you want the following:


input_dim is 100

embed_dim can be anything you want, let’s say 128 here. (This will be the size of your output)
You only want one output but you are getting 3 (as of now). The simplest idea is just to take the last output (StackOverflow answer here.)[https://stackoverflow.com/questions/62204109/return-sequences-false-equivalent-in-pytorch-lstm 49].

Your final code will look like this:
model = torch.nn.LSTM(input_size=100, hidden_size=128, num_layers=1)
output = model(input)[-1]