def METHOD_NAME(subparsers: argparse._SubParsersAction, include_pubsub=True):
    fmt_parser = create_fmt_parser()
    subparsers.add_parser(
        'quit',
        parents=[fmt_parser],
    )
    help_parser = subparsers.add_parser(
        'help',
        parents=[fmt_parser],
    )
    help_parser.add_argument('cmdname')
    # The default value of these values should be None.
    # See set handler for more details.
    set_parser = subparsers.add_parser(
        'set',
        help='设置会话参数',
        parents=[fmt_parser],
    )
    set_parser.add_argument(
        '--rpc-version',
        type=str,
        choices=['1.0', '2.0'],
    )
    set_parser.add_argument(
        '--pubsub-version',
        type=str,
        choices=['1.0', '2.0'],
    )
    if include_pubsub is True:
        sub_parser = subparsers.add_parser(
            'sub',
            help='订阅主题消息',
            parents=[fmt_parser],
        )
        sub_parser.add_argument(
            'topics',
            nargs='?',
            help='主题名字',
        )