Skip to content

Workflow ​

A workflow selects an entry subroutine and defines the Python environment and agent resources in which it executes. Several workflows may select the same subroutine with different dependencies, profiles, or sessions.

Countdown example ​

The Countdown project has one runnable workflow:

Workflow elementCountdown
IDmain (demo.countdown.main)
Selected subroutinemain
Requirementsjinja2 for the authored prompt template
Runtime configurationA generated decrementer invoker is mapped to the entry subroutine's decrementer profile parameter

Authored files ​

Requirements ​

Every local workflow owns an authored ● requirements.txt. Write one PEP 508 requirement per line; blank lines and lines beginning with # are ignored:

text
jinja2

Countdown uses this dependency to render the Agent visit's prompt.

Pip directives such as -r and --index-url are not supported, and the same distribution cannot be declared twice. The published verdog-runtime package is a project dependency and does not belong in this file.

Each workflow executes in a Python environment containing the runtime and its own requirements, including workflows imported from other projects. Update that environment's dependencies after changing requirements.txt.

The root ◆ pyproject.toml describes the shared source package and does not merge workflow requirements.

Runtime configuration ​

Runtime configuration has no authored module. The workflow's profile and session declarations, together with its entry-resource mappings, determine the generated configuration. Profile scope determines the available bindings; session persistence and lifetime determine conversation reuse.

Files ​

Each local workflow has generated declarations and an authored dependency file. A root workflow lives directly under the project package:

General workflow structure

src/<package>/workflows/<workflow>/
├── ◆ __init__.py
├── profiles/
│   ├── ◆ __init__.py
│   └── <profile>/
│       └── ◆ __init__.py
├── sessions/
│   ├── ◆ __init__.py
│   └── <session>/
│       └── ◆ __init__.py
├── ◆ bindings/__init__.py
└── ● requirements.txt

A workflow declared inside a subroutine repeats the same layout under subroutines/<owner>/workflows/<id>/.

FileRole
◆ __init__.pyDeclares the entry call, boundary types, reachable parameter types, and cached definition() factory.
◆ profiles/<profile>/__init__.pyConstructs one provider invoker.
◆ profiles/__init__.pyMaps workflow profile IDs to invokers in INVOKERS.
◆ sessions/<session>/__init__.pyDeclares one workflow-owned session and its persistence policy.
◆ sessions/__init__.pyCollects workflow sessions in SESSIONS.
◆ bindings/__init__.pyConstructs CONFIGURATION from the workflow's invoker registry.
● requirements.txtDeclares the third-party Python packages installed only in this workflow's environment.

An external workflow binding has no local workflow directory. Its alias and pinned target live in ◆ project.json and ◆ verdog.lock.

Generated files ​

See the generated declaration reference for the Python declarations and registries maintained by generation.