Run the named stages in order. Validate each handoff against its declared schema, and make the final output identify the stage lineage that produced it.Prompt chaining
Pass intermediate results through planned stages.
sequential_stage_compositionRECORD STATUSCandidate · v0.1.0UML class view
The proposed contract drawn as participant roles, received calls, and numbered dependencies.
Object interactions
The same roles and calls as a class collaboration and a numbered message sequence.
Pointcut
Where the mechanism applies. All four dimensions belong to the proposed match, not just its vocabulary.
- Context
- A task is decomposed into ordered agent or prompt stages.
- Trigger
- One stage produces an intermediate result consumed by the next.
- Structure
- Stage graph, typed handoff payload, validation, and terminal output.
- Effect
- Stages execute in order and downstream input is attributable to upstream output.
Protected contract
The obligation that clients, operators, and auditors should be able to rely on.
- Requires
- Stage order and handoff schema are defined.
- Ensures
- Every stage receives validated input and the final output identifies its stage lineage.
- Invariant
- A later stage cannot execute before its prerequisites complete.
- Violation
- A stage failure stops, retries, or branches according to declared policy.
Negative control
Independent prompts with no intermediate-result dependency do not count.
Variation & lifecycle
The hot spot is admitted only where the protected semantics survive.
Permitted variation
Sequential agents, prompt templates, pipelines, and transform nodes.
Test obligation
Test order, input propagation, stage failure, and branching.
Evolution question
Did chains add typed handoffs and explicit failure propagation?
Prompt + code design
An illustrative prompt and a small design sketch for the proposed contract. Names and APIs are invented; this is not a repository excerpt.
def run_chain(stages, initial_input):
payload, lineage = initial_input, []
for stage in stages:
validated = stage.input_schema.validate(payload)
payload = stage.run(validated)
lineage.append(stage.id)
return ChainResult(output=payload, lineage=lineage)Illustrative design sketch. A chain without validated handoffs is a sequence of unrelated prompts. This example is a teaching aid, not implementation evidence or a conformance claim.
Detection & matching
The frozen rule that retrieves this record, the canonical source exemplar, and the control that should stay unmatched.
- Join point
sequential_stage_composition- Source locator
- Anthropic
- Lexical cue
(?i)\b(?:prompt[_-]?chain(?:ing)?|chain[_-]?(?:prompt|agent)|sequential[_-]?(?:workflow|pipeline))\bFrozen expression, v0.1.0. A match is a retrieval cue, not a confirmed implementation.- Aliases
- promptchain, sequentialagent, sequentialpipeline
- Canonical exemplar
- google/adk-python
src/google/adk/agents/sequential_agent.py:91Support: tests/unittests/agents/test_sequential_agent.py:80 - Negative control
- Independent prompts with no intermediate-result dependency do not count.
Scope-anchored review. pohe-agent analyze <repo> --pattern W01 anchors the cue to its enclosing declaration and checks a separate operational signature for all four pointcut dimensions. Missing roles and negative-control risks remain visible; a structural match is not E2/E3. Calibration report ↗
Repository files
Up to five public files retrieved by the frozen cue and pinned to the audited commit. A match is a place to inspect, not a confirmed implementation.
src/google/adk/agents/sequential_agent.py:91CANONICAL SOURCE02aaif-goose/goosedocumentation/docs/guides/sessions/in-session-actions.md:123RETRIEVAL CUE03affaan-m/ECCskills/autonomous-loops/SKILL.md:32RETRIEVAL CUE04agno-agi/agnolibs/agno/tests/unit/db/test_reserved_run_metadata.py:117RETRIEVAL CUE05microsoft/agent-frameworkpython/packages/devui/tests/devui/conftest.py:460RETRIEVAL CUEEvidence & provenance
Each layer answers a different question. Do not substitute retrieval for review.
Source-located exemplar
A concrete source anchor is available for this proposed record. It is one exemplar, not evidence that all repositories—or every contract field—conform.
Review boundary: this candidate and its specification come from an AI-assisted study. Independent human validation remains open.
16.7% of repository families in the frozen panel have at least one current cue, historical cue, or canonical source layer. This is not confirmed prevalence.
Current lexical-cue repositories: 7 / 41946ca77224d5src/google/adk/agents/sequential_agent.py:91tests/unittests/agents/test_sequential_agent.py:80SequentialAgent passes output through ordered sub-agents.
Exploratory retrieval cue Regex / v0.1.0
(?i)\b(?:prompt[_-]?chain(?:ing)?|chain[_-]?(?:prompt|agent)|sequential[_-]?(?:workflow|pipeline))\bThis expression is a discovery instrument only. A match is a retrieval cue—not a confirmed implementation, pointcut match, or contract proof.