proper left/right delims, more docs, handle html entities, better env var parsing