new pattern and library use