Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

Flytekit CLI

$ pyflyte Official Med Risk
Flyte · AI & Media · Apache-2.0 · macos / linux / windows

pyflyte is the command-line companion bundled with flytekit for executing Flyte tasks locally or remotely (pyflyte run --remote), serializing protobuf packages (pyflyte package), and registering workflows to a Flyte control plane. Note that Flyte 2.x succeeds pyflyte with the unified flyte CLI.

FCRS-1.0 Score
72 /100
Usable w/ Caveats
Medium Confidence
Zero-Friction Install
pip install flytekit
CLI vs MCP Decision CLI Preferred vs MCP

pyflyte serializes local Python workflow ASTs and container image specs directly from the repo, which remote MCP servers cannot inspect or package.

Agent-Readiness Checklist

— JSON Output
— Field Filtering
✓ Non-Interactive
— Dry-Run
— Read-Only Mode
— NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 16 / 25

Dynamic --help generation from Python type hints is helpful, but pyflyte lacks --json output across run/package/register subcommands.

  • Generates typed --help flags from @workflow signatures
  • No native --json stdout formatting flag
Trust & Safety 18 / 25

Defaults to local execution unless --remote is explicitly passed and supports offline pyflyte package serialization, though remote runs lack --dry-run.

  • pyflyte run defaults to local sandbox execution without --remote
  • pyflyte package produces offline artifacts before register
Setup & Portability 11 / 15

Distributed via PyPI (pip install flytekit) across macOS, Linux, and Windows, though container image building requires Docker or ImageSpec backends.

  • Standard PyPI package flytekit
Utility & Efficiency 12 / 15

Smoothly bridges local Python workflow iteration, serialization, and remote registration on Flyte 1.x clusters.

  • Supports run, package, register, and backfill
Maintenance & Lineage 7 / 10

Official flyteorg/flytekit project under Apache-2.0, though Flyte 2.x is transitioning users toward the newer flyte CLI.

  • Official flyteorg/flytekit repo, succeeded by flyte CLI in Flyte 2.x
Docs & Verifiability 8 / 10

Clear docs.flyte.org CLI reference and dynamic --help output.

  • Documented in Flytekit API/CLI reference at docs.flyte.org

Security, Auth & Guardrails

Auth Modes
Config File OAuth Browser Env API Key No Auth
Credential Storage

Reads Flyte endpoint and auth settings from ~/.flyte/config.yaml (or --config), FLYTECTL_CONFIG, or OAuth client credentials env vars.

Side Effects
Read-Only Local Write Remote Write
Cost & Quotas

Apache-2.0 open-source CLI; remote execution incurs Kubernetes or Union Cloud compute costs.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# Flytekit CLI (pyflyte) Agent Rules
- Run workflows locally (omit `--remote`) or serialize with `pyflyte package` before targeting remote clusters.
- Always pass explicit `-p <project>` and `-d <domain>` (e.g. `development`) when using `--remote` or `pyflyte register`.
- Inspect typed inputs first with `pyflyte run <file.py> <workflow> --help`.

Agent-Ready Command Recipes

Safe Read-Only Queries

Inspect workflow CLI arguments via help
pyflyte run workflows/example.py my_workflow --help

Dynamically parses typed Python workflow inputs into CLI flags without executing any tasks.

Controlled Writes & Previews

Package workflows locally without remote registration
pyflyte package --image ghcr.io/org/app:v1 -o ./dist

Serializes Flyte tasks and workflows to local protobuf files in ./dist without mutating a remote cluster.

Strengths for Agents

  • + Automatically turns Python @workflow parameters into self-describing CLI flags and --help docs.
  • + Local-by-default execution (pyflyte run without --remote) prevents accidental cluster runs.

Caveats & Pitfalls

  • ! Lacks --json output formatting; execution URLs and status are printed as plain text.
  • ! Being superseded by the unified flyte CLI in Flyte 2.x.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI