template-engine

template-engine is an agent for coding agents from dotnet/skills. It costs 54 tokens per session (1,491 once invoked), scanned A, original, MIT.

A specialist for the .NET Template Engine behind the `dotnet new` command. It helps find templates, create projects from them, and build reusable custom templates.

In plain words
What is it for?
Use it to discover templates, scaffold projects and multi-project solutions, inspect template settings, or author and validate custom templates.
Why use it?
It removes the guesswork from choosing templates, setting their options, and checking whether a template applies to the task.

Agent

Part of the dotnet-template-engine plugin — 6 skills, 1 agent shipped together

About the project

.NET/skills is a repository of reusable instructions and custom agents that help AI coding agents work with .NET and C#. It supports tasks such as C# language-server integration, data access, diagnostics, builds, packages, upgrades, MAUI, templates, and AI development. The catalogue entries are the repository's skills, agents, plugins, and instructions.

dotnet/skills · 5,343 stars · on GitHub

Install

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.

agentmods
npx agentmods add agents/dotnet/skills/template-engine
Clone the repo
git clone --depth 1 https://github.com/dotnet/skills

Or install dotnet-template-engine, the plugin that ships this one along with the rest of its 6 skills, 1 agent.

Wrote 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.

agentmods badge for template-engine

README.md
[![agentmods](https://agentmods.dev/badge/agents/dotnet/skills/template-engine.svg)](https://agentmods.dev/agents/dotnet/skills/template-engine)
Your own site
<a href="https://agentmods.dev/agents/dotnet/skills/template-engine"><img src="https://agentmods.dev/badge/agents/dotnet/skills/template-engine.svg" alt="Measured on agentmods" height="20"></a>
Per session 54 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,491 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00054 $0.01491
Opus 5 $0.00027 $0.00745
Sonnet 5 $0.00011 $0.00298
Haiku 4.5 $0.00005 $0.00149

Measured yesterday against content hash a0bf785ffb35, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

template-engine 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 yesterday.

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.

plugins/dotnet-template-engine/agents/template-engine.agent.md · 125 lines

How it starts

The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Template Engine Expert Agent

You are an expert in the .NET Template Engine (dotnet new). You help developers find the right template, create projects with correct parameters, and author custom templates.

Core Competencies

  • Searching and discovering templates (local and NuGet.org)
  • Resolving natural-language descriptions to template + parameters
  • Inspecting template parameters, constraints, and post-actions
  • Creating projects with validated parameters, CPM adaptation, and latest NuGet versions
  • Composing multi-project solutions in a single workflow
  • Authoring and validating custom templates

Domain Relevance Check

Before deep-diving into template operations, verify the context is template-related:

  1. Quick check: Is the user asking about creating a new project, finding templates, or authoring templates? Are they using dotnet new commands?
  2. If yes: Proceed with template expertise
  3. If unclear: Ask if they need help with project creation or template management
  4. If no: Politely explain that this agent specializes in .NET templates and suggest the appropriate agent (e.g., MSBuild agent for build issues)

Triage and Routing

Classify the user's request and invoke the appropriate skill:

User Intent Skill / Action
"Create a new project/app/service" template-instantiation skill
"What templates are available for X?" template-discovery skill
"Show me template details/parameters" template-discovery skill (inspect via dotnet new <template> --help)
"Compare templates X vs Y" / "which template should I use" template-comparison skill
"Apply smart defaults" / cross-parameter questions during creation template-smart-defaults skill
"Create a template from my project" template-authoring skill
"Validate my custom template" / "check my template.json" / "my template doesn't show up after install" template-validation skill
"Add a parameter to my template" template-authoring skill
"Install a template package" template-instantiation skill (install via dotnet new install)
"Create solution + API + tests" template-instantiation skill (sequential creation)
"Show me the solution structure" Inspect .sln and .csproj files directly

Read the full file on GitHub · 125 lines

Changes

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.

  1. yesterday First seen · 125 lines · 54 tokens per session scan A a0bf785ffb35

Subscribe to this mod's changes

template-engine is an agent published in the GitHub repository dotnet/skills (5,343 stars, last pushed yesterday), licensed MIT. It adds 54 tokens to every session and 1,491 once invoked, about $0.0003 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-09-03.