---
metadata:
  - name: generator
    content: Diplodoc Platform v5.50.6
alternate:
  - https://ytsaurus.tech/docs/en/yql/udf/python.md
  - https://ytsaurus.tech/docs/ru/yql/udf/python.md
---
> **Documentation Index:** Fetch the complete configuration index at https://ytsaurus.tech/docs/en/llms.txt

# Instructions for writing Python user-defined functions (UDFs) for YQL


Using a purely declarative, SQL-like approach to describe task results can sometimes be impractical. You may need to specify which data to `JOIN` and how to group it declaratively, while handling the data processing logic imperatively. For these use cases, YQL provides a mechanism for writing and calling user-defined functions (UDFs) in Python.
To learn more about UDFs, see [Python user-defined functions (UDFs) in YQL](https://ytsaurus.tech/docs/en/user-guide/query-tracker/system-python-udf.md).


