remove unneededed @dynamic and use AG as the prefix for keys for the assoc ref.