What You’ll Build
A three-layer pipeline where:- A secret stores an API key
- A model references the secret
- An agent depends on the model
Prerequisites
- pragma CLI installed and authenticated
- Agno provider deployed (
pragma providers listto verify)
Step 1: Define the Pipeline
Create a file calledpipeline.yaml with all three resources:
Step 2: Apply Everything at Once
- The secret is processed first (no dependencies)
- Once the secret is
ready, the model’s FieldReference resolves and the model is processed - Once the model is
ready, the agent’s Dependency resolves and the agent is processed
Step 3: Trigger a Change
Now swap the model. Updatepipeline.yaml to use a different model ID:
- Re-processes the model with the new
model_id - Detects that
assistantdepends onclaude - Automatically re-processes the agent with the updated model data
Step 4: Inspect the Resolution
To see how pragma-os resolved the dependencies, inspect the resolved config:config— Your original YAML with Dependency markersresolved_config— The fully resolved version with actual model data embedded
FieldReference Patterns
Single Value References
Reference a specific output field:Multiple References
A single resource can reference multiple dependencies:Debugging Tips
Check dependency states
If a resource is stuck inpending, its dependencies might not be ready:
Compare config vs resolved_config
- If
resolved_configisnull, the resource is waiting for dependencies - If
resolved_confighas values, the resource has been submitted to the provider - Compare the two to verify references resolved correctly
Force re-processing
If a resource should have updated but didn’t, re-apply it:Next Steps
Reactive Dependencies
Deep dive into the dependency resolution system.
File Uploads
Add file resources to your pipelines.