As ever in steam days, different railways used different expressions. Some said "assisting engine", others "pilot", and someone will probably be along soon with further expressions. Generally "pilot" can be taken as "not the main train engine", whether it is removing the stock at a terminus, standing by at a key point in case of need, or assisting on a gradient or overweight train. At Taunton the west end Station Pilot, which assisted with shunting the stock of terminating local trains, was commonly a Hall, which could be rapidly taken to assist any main line problem. It was a nice easy turn for main line men coming up to retirement, who nevertheless knew all the routes in case of sudden need.
This applies to having two locos on the front. One assisting from the rear was generally known as a "banker".
Commonly the pilot would be a smaller, less powerful loco than the main train engine. Instances where two equal locos, just like working a pilot right through from origin to final destination, were uncommon.
The GWR put the pilot as the second loco, whereas other railways commonly put it on the front for ease of attachment/detachment. Severn Tunnel Junction had a large stud of 41xx tanks which acted as bankers to eastbound freight trains on the long continuous climb from the bottom of the Severn Tunnel and up over an outlier of the Cotswolds to Stoke Gifford. But when they assisted an overweight passenger train, they were coupled inside the main train engine.