Skip to content

Python API Flowfile Reference

This section documents Flowfile's Python API, focusing on extensions and differences from Polars. For standard Polars operations, see the Polars documentation.

Core API

Data Input/Output

Transformations

Flowfile-Specific Features

Key Extensions to Polars

Description Parameter

Every operation accepts description for visual documentation:

df = df.filter(ff.col("active") == True, description="Keep active records")

Flowfile Formula Syntax

Alternative bracket-based syntax for expressions:

df.filter(flowfile_formula="[price] > 100 AND [quantity] >= 10")
See Formulas in Python for the methods that accept formulas, the Formula Language guide for the syntax, or try it in the interactive playground.

Automatic Node Types

Operations map to UI nodes when possible, otherwise fall back to polars_code:

# Simple → UI node
df.group_by("category").agg(ff.col("value").sum())

# Complex → polars_code node
df.group_by([ff.col("category").str.to_uppercase()]).agg(ff.col("value").sum())

Graph Access

Inspect and visualize the pipeline DAG:

ff.open_graph_in_editor(df.flow_graph)

Architecture Deep Dives

For understanding how Flowfile works internally:

Getting Help


This reference covers Flowfile-specific features. For standard Polars operations, see the Polars API Reference.