Improve the public API for use with plugins