Text this: Logical foundations for cognitive agents :