NLP: find the best preposition for connecting parts of a sentence My task is to connect 2-3 parts of the sentence into one whole using a  preposition

the first part is some  kind of action. Ex. &quot;take pictures&quot;
the second part is an object  that can consist of  only one noun or a noun with  adjectives and additions dependent on it. Ex. &quot;juicy cherry pie&quot;, &quot;squirrel&quot;
the third part is a place. Ex. &quot;room&quot;, &quot;London&quot;

To solve this task I've already tried some options  such as generation using GPT-2 (or other networks like LSTM) and using grammar rules, but both of them didn't work as well as I want.
Using GPT-2 needs  a lot of resources and performance, which is very expensive on the server. Ordinary neural networks aren't good enough and often generate bad results. And it is also impossible to describe all cases using only grammar rules.
Are there any approaches how you can implement a solution to this problem without using transformers or grammatical rules, so that the model isn't too heavy and at the same time effective?
There may be several options for prepositions, the main thing is that they are used.
P.s. a good option was to use n-grams, but it is not clear how to work with it when the second part is long.
Examples:
[Pour, juice, boiler room]     -&gt;  Pour the juice into the boiler room
[Go, theater]                  -&gt;  Go to the theater
[Learn the history, ballet]    -&gt;  Learn the history of ballet
The traditional approach for this kind of problem would be an n-gram language model. The language model is trained on a large corpus, then it's reasonably simple to calculate the most likely missing tokens for any incomplete sentence. SRILM was one of the most common toolkits, but there are probably many other libraries.