AttributeError: module transformers.tools has no attribute DocumentQuestionAnsweringTool keeps appearing in transformers version 4.29.0
### System Info

- `transformers` version: 4.29.0
- Platform: macOS-13.3.1-arm64-arm-64bit
- Python version: 3.10.11
- Huggingface_hub version: 0.14.1
- Safetensors version: not installed
- PyTorch version (GPU?): 2.0.1 (False)
- Tensorflow version (GPU?): not installed (NA)
- Flax version (CPU?/GPU?/TPU?): not installed (NA)
- Jax version: not installed
- JaxLib version: not installed
- Using GPU in script?: <fill in>
- Using distributed or parallel set-up in script?: <fill in>

### Who can help?

_No response_

### Information

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

### Tasks

- [X] An officially supported task in the `examples` folder (such as GLUE/SQuAD, ...)
- [ ] My own task or dataset (give details below)

### Reproduction

Hi together, I stumbled across the following error while trying the new Transformers Agent:


```python
from huggingface_hub import login

login('my_token')
```
...
Token is valid.
...
Login successful.
```python
from transformers import HfAgent

agent = HfAgent("https://api-inference.huggingface.co/models/bigcode/starcoder")
```
As soon as I try to instantiate the agent, the following error appears:
```python
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/happydata/miniforge3/envs/huggingface-env/lib/python3.10/site-packages/transformers/tools/agents.py", line 469, in __init__
    super().__init__(
  File "/Users/happydata/miniforge3/envs/huggingface-env/lib/python3.10/site-packages/transformers/tools/agents.py", line 199, in __init__
    _setup_default_tools()
  File "/Users/happydata/miniforge3/envs/huggingface-env/lib/python3.10/site-packages/transformers/tools/agents.py", line 97, in _setup_default_tools
    tool_class = getattr(tools_module, tool_class_name)
  File "/Users/happydata/miniforge3/envs/huggingface-env/lib/python3.10/site-packages/transformers/utils/import_utils.py", line 1165, in __getattr__
    raise AttributeError(f"module {self.__name__} has no attribute {name}")
AttributeError: module transformers.tools has no attribute DocumentQuestionAnsweringTool
```

In my case it didn't matter whether I tried BigCode, OpenAssistant or the OpenAiAgent.

### Expected behavior

I tried to follow the quickstart guide from https://huggingface.co/docs/transformers/transformers_agents, but it seems that the AttributeError with the transformers.tools module keeps appearing again and again.

Thank you for your help in advance!
In my case, re-installation solved the problem.

I got an error:
> Failed to import transformers.tools.agents ...`

Try this:
`$ pip install huggingface_hub>=0.14.1 git+https://github.com/huggingface/transformers@v4.29.0 diffusers accelerate datasets torch soundfile sentencepiece opencv-python openai`

And restart the connected ipykernel.<|||||>I had the same issue and installed these packages one by one, it seems that the "torch" lib missing is what causes this exact error.

> In my case, re-installation solved the problem.
> 
> I got an error:
> 
> > Failed to import transformers.tools.agents ...`
> 
> Try this: `$ pip install huggingface_hub>=0.14.1 git+https://github.com/huggingface/transformers@v4.29.0 diffusers accelerate datasets torch soundfile sentencepiece opencv-python openai`
> 
> And restart the connected ipykernel.

<|||||>@yerimJu @vitorrm Thank you for your answers, it looks like it works with the one-by-one reinstallation of the packages!