Time estimate: 45 minutes. Assumes you’ve completed the amateur quickstart.
What you’ll build
15 new resources, wired together, plus the cluster access and namespace from the amateur quickstart. Pragmatiks 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)
- The
my-clusterKubernetes config andagentsnamespace from 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 four connected resources: an embedder, a Qdrant collection, a vector database configuration, and the knowledge base itself. Createknowledge.yaml:
knowledge.yaml
- The embedder references the OpenAI secret
- The collection creates the
knowledge-basecollection in Qdrant, sized for the embedder’s 1536-dimensional vectors - The vector database references the embedder (dependency), the collection’s name, and the Qdrant secret (field references)
- 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 theagents namespace of your cluster. Create runner.yaml:
runner.yaml
READY state. Pragmatiks resolved the dependency graph — secrets first, then models, tools, and the collection, 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, Pragmatiks 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.
WAITING state until their dependencies are ready, then processes them automatically.
Full YAML
Complete multi-document YAML (all 15 resources)
Complete multi-document YAML (all 15 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.