I have defined a callback like so:
#!/usr/bin/env python2.7
# -*- coding: utf-8 -*-
import sys
import pprint
from ansible.plugins.callback import CallbackB
If you want to replace Ansible standard output, you should set stdout_callback parameter to your callback.
Update: stdout_callback parameter will affect only ansible-playbook CLI output, as correctly noted in the comments.
I've investigated the code a bit, ansible CLI supports only minimal and oneline (if -o option is set) stdout callbacks.
The easiest way to change the output behavior is to place ./callback_plugins/minimal.py in your playbook folder and modify it to your needs.
Or you can patch adhoc.py to be able to accept other stdout plugins.