semi-working chosen implementation