원클릭으로
pandas-operator
Reference documentation for the PandasOperator operator. Use when: applying custom DataFrame transformations without LLM.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Reference documentation for the PandasOperator operator. Use when: applying custom DataFrame transformations without LLM.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
DataFlow 开发专家上下文加载器。当用户在 DataFlow 仓库中进行开发时触发, 涵盖:新建算子/Pipeline/Prompt、诊断报错、规范审查、 以及感知仓库变更并建议更新知识库。 Trigger: user is developing in DataFlow repo, asks to create operator/pipeline/prompt, encounters errors, wants code review, or asks about operators.
Reasoning-guided pipeline planner that generates standard DataFlow pipeline code
Reference documentation for the BenchDatasetEvaluatorQuestion operator. Extended version of BenchDatasetEvaluator with question and subquestion support. Use when: evaluating answers with question context or multiple subquestions.
Reference documentation for the BenchDatasetEvaluator operator. Covers the constructor, two comparison modes (match/semantic), and pipeline usage. Use when: comparing predicted answers against ground truth answers in benchmark evaluation.
Reference documentation for the PromptedEvaluator operator. Use when: scoring text quality with LLM without filtering rows.
Reference documentation for the Text2QASampleEvaluator operator. Use when: evaluating QA pair quality across multiple dimensions.
| name | pandas-operator |
| description | Reference documentation for the PandasOperator operator. Use when: applying custom DataFrame transformations without LLM. |
| trigger_keywords | ["PandasOperator","pandas-operator","DataFrame transformation","custom transformation"] |
| version | 1.0.0 |
PandasOperator applies a list of transformation functions to a DataFrame sequentially. Each function receives a DataFrame and returns a modified DataFrame.
from dataflow.operators.core_text import PandasOperator
PandasOperator(
process_fn=[
lambda df: df.rename(columns={"old": "new"}),
lambda df: df[df["score"] > 0],
]
)
| Parameter | Required | Default | Description |
|---|---|---|---|
process_fn | Yes | None | List of transformation functions, each with signature (df: DataFrame) -> DataFrame |
op.run(
storage=self.storage.step(),
)
# returns: empty string ""
| Parameter | Required | Default | Description |
|---|---|---|---|
storage | Yes | None | Storage step object |
from dataflow.operators.core_text import PandasOperator
from dataflow.utils.storage import FileStorage
class MyPipeline:
def __init__(self):
self.storage = FileStorage(
first_entry_file_name="./data/input.jsonl",
cache_path="./cache",
file_name_prefix="step",
cache_type="jsonl"
)
self.transformer = PandasOperator(
process_fn=[
lambda df: df.assign(score2=df["score"] * 2),
lambda df: df.sort_values("score", ascending=False),
lambda df: df.drop(columns=["temp_col"])
]
)
def forward(self):
self.transformer.run(
storage=self.storage.step()
)
if __name__ == "__main__":
pipeline = MyPipeline()
pipeline.forward()
process_fn sequentially.process_fn must return a pd.DataFrameinput_key or output_key parameters (column operations are in lambda functions)