initialize_agent does not accept callable 'handle_parsing_errors', only bool ('value could not be parsed to a boolean')
Labels: name: area: agent, name: auto:bug

### System Info

langchain 0.0.301
Python 3.10.12
Ubuntu 22.04 LTS

### Who can help?

@hwchase17 

(based on blame of langchain/agents/agent.py", line 622)

### Information

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

### Related Components

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

### Reproduction

```
import yaml
import os
from langchain.chat_models import ChatOpenAI
from langchain.agents import initialize_agent

# https://python.langchain.com/docs/modules/agents/how_to/handle_parsing_errors
def _handle_error(error) -> str:
    return str(error)

# Do whatever to load your api key
with open('secrets.yml', 'r') as f:
    config = yaml.safe_load(f)
    os.environ["OPENAI_API_KEY"] = config['open_ai_key']

llm = ChatOpenAI(model_name='gpt-3.5-turbo')

agentExcecutor = initialize_agent(
    [], llm,
    agent="conversational-react-description",
    handle_parsing_errors=_handle_error,
)
```
Results in:
```
Traceback (most recent call last):
  File ".../test_error_handling.py", line 17, in <module>
    agentExcecutor = initialize_agent(
  File ".../langchain/agents/initialize.py", line 64, in initialize_agent
    return AgentExecutor.from_agent_and_tools(
  File ".../langchain/agents/agent.py", line 622, in from_agent_and_tools
    return cls(
  File "pydantic/main.py", line 341, in pydantic.main.BaseModel.__init__
pydantic.error_wrappers.ValidationError: 1 validation error for AgentExecutor
handle_parsing_errors
  value could not be parsed to a boolean (type=type_error.bool)
```

### Expected behavior

It should initialize the agent, and trigger the custom _handle_error as described in:
https://python.langchain.com/docs/modules/agents/how_to/handle_parsing_errors#custom-error-function

I am (like many) experiencing frequent ['Could not parse LLM output'](https://github.com/langchain-ai/langchain/issues/1358) #1358.
My current project is targeting gpt-3.5, and doing system-message/prompt tweaking - so parse failures are to be expected. However, I want to handle the error gracefully - retrying, summarizing failed attempts, apologizing and moving on, etc - depending on the specifics of my project.

The handle_parsing_errors seems like the perfect place to implement a workaround. However, passing a callable func seems to fail validation, and thus does not work.
Note:
* using try/except to handle parse errors is not ideal for us, as, by default, it omits those messages from the memory
* using handle_parsing_errors=true is what I am using now, but I'd like to customize the failure handling

As always, apologies if I misunderstand the documentation, or if this is already reported. I did not see anything in the tracker - #10710 is close, but regards tools rather than agents afaict.
Thank you for any help!