# convert_runnable_to_tool

> **Function** in `langchain_core`

📖 [View in docs](https://reference.langchain.com/python/langchain-core/tools/convert/convert_runnable_to_tool)

Convert a `Runnable` into a `BaseTool`.

## Signature

```python
convert_runnable_to_tool(
    runnable: Runnable[Any, Any],
    args_schema: TypeBaseModel | None = None,
    *,
    name: str | None = None,
    description: str | None = None,
    arg_types: dict[str, type] | None = None,
) -> BaseTool
```

## Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `runnable` | `Runnable[Any, Any]` | Yes | The `Runnable` to convert. |
| `args_schema` | `TypeBaseModel \| None` | No | The schema for the tool's input arguments. (default: `None`) |
| `name` | `str \| None` | No | The name of the tool. (default: `None`) |
| `description` | `str \| None` | No | The description of the tool. (default: `None`) |
| `arg_types` | `dict[str, type] \| None` | No | The types of the arguments. (default: `None`) |

## Returns

`BaseTool`

The tool.

---

[View source on GitHub](https://github.com/langchain-ai/langchain/blob/4fe9d3062f4b68e2e472eb92decf369c93aebb46/libs/core/langchain_core/tools/convert.py#L433)