Time estimate: 45 minutes. Assumes you’ve completed the amateur quickstart.
What you’ll build
13 resources, wired together. pragma-os resolves the entire dependency graph in the correct order.Prerequisites
- Completed the amateur quickstart (CLI installed, authenticated)
- An OpenAI API key (for embeddings and GPT-4o)
- A running Qdrant instance (Qdrant Cloud free tier works)
- A GKE cluster managed by pragma-os (created in the amateur quickstart)
Step 1: Secrets
Store all API keys as pragma secrets. Createsecrets.yaml:
secrets.yaml
Step 2: AI models
Configure two models from different providers. Createmodels.yaml:
models.yaml
api_key is a field reference pointing to a secret output. The key value is injected automatically at provisioning time.
Step 3: Tools
Give agents capabilities through tools. Createtools.yaml:
tools.yaml
Step 4: Knowledge base
Set up vector search so agents can query a knowledge base. This creates three connected resources: an embedder, a vector database, and the knowledge base itself. Createknowledge.yaml:
knowledge.yaml
- The embedder references the OpenAI secret
- The vector database references the embedder (dependency) and the Qdrant secret (field reference)
- The knowledge base references the vector database
Step 5: Agents
Define two specialized agents with different models and capabilities. Createagents.yaml:
agents.yaml
Step 6: Team
Combine agents into a team. Createteam.yaml:
team.yaml
members list. When either agent changes, the team rebuilds.
Step 7: Deploy and observe
Deploy the team to your GKE cluster. Createrunner.yaml:
runner.yaml
READY state. pragma-os resolved the dependency graph — secrets first, then models and tools, then agents, then the team, then the runner.
Step 8: Change propagation
This is where reactive dependencies shine. Swap the researcher’s model from Claude to GPT-4o and watch the cascade. Updateagents.yaml — change the researcher’s model reference:
- The researcher agent rebuilds with the new model
- The research-team automatically rebuilds because its member changed
- The runner redeploys because the team spec changed
How it works
Two mechanisms make this possible: Dependencies (Dependency[T]) link resources together. When a resource declares a dependency on another, pragma-os tracks the relationship. If the upstream resource changes, the dependent rebuilds.
Field[T]) inject specific output values from other resources. The referenced value is resolved at provisioning time and re-resolved when the source changes.
PENDING state until their dependencies are ready, then processes them automatically.
Full YAML
Complete multi-document YAML (all 13 resources)
Complete multi-document YAML (all 13 resources)
pipeline.yaml
Next steps
Create a Custom Provider
Build your own provider to manage custom resource types.
Reactive Dependencies
Deep dive into the dependency resolution system.