word segment with external dictionary