backend-runtime
Work on Langflow FastAPI backend routes, graph execution, services, settings, auth/authz, database, migrations, storage, telemetry, and runtime errors.
- License 许可
- MIT
- 最近更新
- 2026-10-08
- Stars
- ★ 11
- Forks
- 3
01 前言 Front Matter
- name
- backend-runtime
- license
- MIT
- metadata
- { "disco-role": "operating" }
- description
- Work on Langflow FastAPI backend routes, graph execution, services, settings, auth/authz, database, migrations, storage, telemetry, and runtime errors.
- disable-model-invocation
- true
02 资源文件 3
- 参考文档references/api-and-services.md10.3 KB
- 参考文档references/database-and-authorization.md10.4 KB
- 参考文档references/troubleshooting.md9.9 KB
03 SKILL.md 正文
Backend Runtime
Use this sub-skill for Langflow backend implementation tasks: FastAPI routes, API router wiring, flow execution internals, service dependencies, settings behavior, authorization guards, database sessions, Alembic migrations, storage boundaries, telemetry, and runtime error diagnosis.
Route elsewhere when the task is primarily:
- SDK or external client usage: use
../sdk-and-api-clients/. - Docker, cloud, or production deployment operations: use
../deployment-and-operations/. - Python component class authoring or bundles: use
../component-development/. - Local flow JSON authoring and validation without backend changes: use
../flow-authoring/.
Start Here
- Classify the affected backend surface: route/API, flow execution, service/settings, authz, database/migration, storage, or telemetry.
- Read references/api-and-services.md for router mounting, route dependency patterns,
simple_run_flow, request parsing, tweaks, service access, and focused API validation. - Read references/database-and-authorization.md before changing guarded routes, share-aware fetches, database models, sessions, or Alembic migrations.
- Use references/troubleshooting.md when a backend run, CLI/API call, auth decision, database connection, migration, file upload, or optional dependency fails.
- Inspect mounted routes with the bundled helper when route prefixes or hidden routes are unclear:
python scripts/inspect_routes.py --module langflow.api.router --router router --include-hidden
Backend Change Checklist
- Keep route handlers explicit about authentication, authorization, response status, response models, and 403-vs-404 privacy behavior.
- Use
get_*_service()helpers for managed services; avoid module-level settings reads for flags that may be supplied by--env-fileor runtime environment variables. - For flow execution endpoints, preserve JSON and multipart parsing behavior,
tweakssemantics, telemetry logging, job-service execution, memory-base fire-and-forget behavior, and streaming error propagation. - For authorization-aware fetches, widen cross-user loading only when an immediate
ensure_*_permission(...)guard follows. - For migrations, follow expand/migrate/contract safety and validate the specific migration before broad backend tests.
Useful Validation Commands
Run the narrowest safe check that covers the change:
python -m py_compile skills/langflow/sub-skills/backend-runtime/scripts/inspect_routes.py
uv run pytest src/backend/tests/unit/api/v1/test_flows.py -q
uv run pytest src/backend/tests/unit/api/v1/test_authz_share_routes.py -q
uv run pytest src/backend/tests/unit/alembic/test_migration_validator.py -q
Use uv run for repository Python commands. Avoid credentialed provider tests, live external services, GPU/transformer execution, or destructive migration fixes unless the user explicitly asks and the environment is disposable or backed up.
04 同仓库更多 Skills
obsidian-clipper-template-creator
Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.
obsidian-clipper-template-creator
Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.
python-api
Programmatic Object-Detection-Metrics API guidance for BoundingBox, BoundingBoxes, Evaluator, enums, coordinate conversion, AP/mAP semantics, and source-style import diagnostics.
file-evaluation
Folder-based PASCAL VOC AP/mAP evaluation from ground-truth and detection text files.
object-detection-metrics
Guides legacy Object-Detection-Metrics PASCAL VOC AP/mAP evaluation from detection text folders and direct Python API classes.
nx-workspace-patterns
Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.