Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add medy-gribkov/arcana --skill cost-optimizationgit clone --depth 1 https://github.com/medy-gribkov/arcanaWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/medy-gribkov/arcana/cost-optimization)<a href="https://agentmods.dev/skills/medy-gribkov/arcana/cost-optimization"><img src="https://agentmods.dev/badge/skills/medy-gribkov/arcana/cost-optimization/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/medy-gribkov/arcana/cost-optimization"><img src="https://agentmods.dev/badge/skills/medy-gribkov/arcana/cost-optimization.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00037 | $0.01467 |
| Opus 5 | $0.00018 | $0.00733 |
| Sonnet 5 | $0.00007 | $0.00293 |
| Haiku 4.5 | $0.00004 | $0.00147 |
Grade A, and why
cost-optimization scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 240 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Container Right-Sizing
Monitor CPU and memory for 7 days before setting limits. Set requests to P50, limits to P99.
BAD: Guessing resource limits. Over-provisioned containers waste money.
resources:
requests:
memory: "1Gi"
cpu: "1000m"
limits:
memory: "2Gi"
cpu: "2000m"
GOOD: Use actual usage data from monitoring.
kubectl top pod myapp-12345 --containers
If P50 is 200Mi/100m and P99 is 400Mi/300m:
resources:
requests:
memory: "200Mi"
cpu: "100m"
limits:
memory: "400Mi"
cpu: "300m"
Vertical Pod Autoscaler
Get sizing recommendations from real workload data.
apiVersion: autoscaling.k8s.io/v1
kind: VerticalPodAutoscaler
metadata:
name: myapp-vpa
spec:
targetRef:
apiVersion: apps/v1
kind: Deployment
name: myapp
updateMode: "Off" # Recommendation mode only
Check recommendations:
kubectl describe vpa myapp-vpa
Cost Calculation
Example: 10 pods running 24/7 with 1Gi memory, 1 CPU.
- Memory: 10 pods x 1 GiB x $0.0004/hr = $29/month
- CPU: 10 pods x 1 core x $0.04/hr = $292/month
- Total: $321/month
Right-size to 200Mi memory, 100m CPU:
- Memory: 10 pods x 0.2 GiB x $0.0004/hr = $5.80/month
- CPU: 10 pods x 0.1 core x $0.04/hr = $29.20/month
- Total: $35/month
Savings: 89% ($286/month)
Horizontal Pod Autoscaler
Scale replicas based on actual load. Do not run excess capacity during low traffic.
BAD: Fixed replica count. Wastes money overnight and weekends.
spec:
replicas: 10
GOOD: HPA scales from 2 to 10 based on CPU usage.
apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: myapp-hpa
spec:
scaleTargetRef:
apiVersion: apps/v1
kind: Deployment
name: myapp
minReplicas: 2
maxReplicas: 10
metrics:
- type: Resource
resource:
name: cpu
target:
type: Utilization
averageUtilization: 70
Cost Impact
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 240 lines · 37 tokens per session scan A f22107a5fefe
cost-optimization is a skill published in the GitHub repository medy-gribkov/arcana (1 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 37 tokens to every session and 1,467 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
aws-architect
Design AWS architectures — VPCs, EC2, ECS, Lambda, RDS, S3, CloudFront, and Well-Architected Framework reviews.
azure-architect
Design Azure architectures — AKS, Functions, Cosmos DB, Service Bus, and Azure AD integration patterns.
gcp-architect
Design Google Cloud architectures — GKE, Cloud Run, BigQuery, Pub/Sub, and Cloud Spanner solutions.
n8n-workflow
Build n8n automation workflows — nodes, expressions, error handling, and self-hosted deployment.
terraform-writer
Write Terraform infrastructure-as-code — providers, modules, state management, and cloud resource definitions.
docker-devops
Docker/K8s: Dockerfile, multi-stage, compose, manifests, Helm. Triggers: Docker, Dockerfile, container, Kubernetes, k8s, compose, Helm, pod.