human
Here's a good function header given the following:
I wrote the below code

    def _encode_body(message):
        if isinstance(message, Response):
            encoder.writeElement(message.body)
            return
        stream.write('\n')
        stream.write_ulong(len(message.body))
        for x in message.body:
            encoder.writeElement(x)
    if (not isinstance(message, (Request, Response))):
        raise TypeError('Unknown    message    type')
    target = None
    if isinstance(message, Request):
        target = unicode(message.target)
    else:
        target = (u'%s%s' % (name, _get_status(message.status)))
    target = target.encode('utf8')
    stream.write_ushort(len(target))
    stream.write_utf8_string(target)
    response = 'null'
    if isinstance(message, Request):
        response = name
    stream.write_ushort(len(response))
    stream.write_utf8_string(response)
    if (not strict):
        stream.write_ulong(0)
        _encode_body(message)
        return
    write_pos = stream.tell()
    stream.write_ulong(0)
    old_pos = stream.tell()
    _encode_body(message)
    new_pos = stream.tell()
    stream.seek(write_pos)
    stream.write_ulong((new_pos - old_pos))
    stream.seek(new_pos)

What's a good function header?
assistant
#Here's a good function header.

def _write_body(name, message, stream, encoder, strict=False):