Safe sandbox for longform agent prompts: spell-check, format, resolve ambiguity, token-optimize digs and spawned routines