_to_args_and_kwargs() failed to handle tool definition with no arguments
Labels: name: area: agent, name: auto:bug

### System Info

(.venv) yale@LAPTOP-MATEBOOK:~/work/llm-app$ python --version
Python 3.10.12
(.venv) yale@LAPTOP-MATEBOOK:~/work/llm-app$ pip list|grep langchain
langchain                 0.0.262
langchainplus-sdk         0.0.20

### Who can help?

_No response_

### Information

- [ ] The official example notebooks/scripts
- [X] My own modified scripts

### Related Components

- [ ] LLMs/Chat Models
- [ ] Embedding Models
- [ ] Prompts / Prompt Templates / Prompt Selectors
- [ ] Output Parsers
- [ ] Document Loaders
- [ ] Vector Stores / Retrievers
- [ ] Memory
- [ ] Agents / Agent Executors
- [X] Tools / Toolkits
- [ ] Chains
- [ ] Callbacks/Tracing
- [ ] Async

### Reproduction

Update the official example of Tool https://python.langchain.com/docs/modules/agents/tools/custom_tools with a tool without argument:

`
    class NoParameterInput(BaseModel):
        pass
        
    tools = [        
        Tool(
            name="GetToday",
            func=lambda: "2023-09-30",
            description="Get today's date",
            args_schema=NoParameterInput
        ),        
`

When running, a error was triggered:

`
Traceback (most recent call last):
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/gradio/routes.py", line 437, in run_predict
    output = await app.get_blocks().process_api(
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/gradio/blocks.py", line 1352, in process_api
    result = await self.call_function(
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/gradio/blocks.py", line 1077, in call_function
    prediction = await anyio.to_thread.run_sync(
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread
    return await future
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run
    result = context.run(func, *args)
  File "/home/yale/work/llm-app/local_tests/gradio/langchain_chatbot.py", line 356, in qa_answer_question
    qa_answer = chain(question)
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/chains/base.py", line 282, in __call__
    raise e
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/chains/base.py", line 276, in __call__
    self._call(inputs, run_manager=run_manager)
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/chains/router/base.py", line 100, in _call
    return self.destination_chains[route.destination](
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/chains/base.py", line 282, in __call__
    raise e
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/chains/base.py", line 276, in __call__
    self._call(inputs, run_manager=run_manager)
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/agents/agent.py", line 1036, in _call
    next_step_output = self._take_next_step(
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/agents/agent.py", line 891, in _take_next_step
    observation = tool.run(
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/tools/base.py", line 340, in run
    raise e
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/tools/base.py", line 331, in run
    tool_args, tool_kwargs = self._to_args_and_kwargs(parsed_input)
  File "/home/yale/work/llm-app/.venv/lib/python3.10/site-packages/langchain/tools/base.py", line 488, in _to_args_and_kwargs
    raise ToolException(
langchain.tools.base.ToolException: Too many arguments to single-input tool GetToday. Args: []
`

The source of _to_args_and_kwargs():

`
    def _to_args_and_kwargs(self, tool_input: Union[str, Dict]) -> Tuple[Tuple, Dict]:
        """Convert tool input to pydantic model."""
        args, kwargs = super()._to_args_and_kwargs(tool_input)
        # For backwards compatibility. The tool must be run with a single input
        all_args = list(args) + list(kwargs.values())
        if len(all_args) != 1:
            raise ToolException(
                f"Too many arguments to single-input tool {self.name}."
                f" Args: {all_args}"
            )
        return tuple(all_args), {}
`

Which does not accept tools without argument.

### Expected behavior

Calls GetToday() successfully.