fixes to InternalAvg to make it extend the correct tag class