There is provided amino acid derivatives of formula I,
1
wherein p, q, R
1
, R
2
, R
3
, R
4
, Y, n and B have meanings given in the description which are useful as competitive inhibitors of trypsin-like proteases, such as thrombin, and in particular in the treatment of conditions where inhibition of thrombin is required (e.g. thrombosis) or as anticoagulants.