> For the complete documentation index, see [llms.txt](https://mariadb.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mariadb.com/docs/connectors/other/langchain-mariadb/api-reference/translator.md).

# Translator

> **Version:** langchain-mariadb v0.0.21

## MariaDBTranslator

Translate `MariaDB` internal query language elements to valid filters.

### Methods

#### `visit_operation`

```python
visit_operation(operation: Operation) -> Dict
```

#### `visit_comparison`

```python
visit_comparison(comparison: Comparison) -> Dict
```

#### `visit_structured_query`

```python
visit_structured_query(structured_query: StructuredQuery) -> Tuple[str, dict]
```

### Attributes

* **allowed\_operators**: Subset of allowed logical operators.
* **allowed\_comparators**: Subset of allowed logical comparators.

***
