Skip to content

Commit 8b4ab90

Browse files
dmealingclaude
andcommitted
docs(template): @requiredTags is prompt-only in verify — fix the C#/TS constant doc (#231)
The `@requiredTags` constant doc claimed "Generic — not prompt-only: any rendered artifact (email, export, prompt) can carry a tag contract", but `verify --templates` enforces it ONLY on the prompt path in every port (the email/document output gate deliberately does not apply per-part slot/tag rules — the #193/#230 cross-port consensus). Corrected the comment in both C# (TemplateConstants.cs) and TS (template-constants.ts, which carried the identical claim) to state the actual behavior: the attr may be authored on any template, but verify checks it for prompts only. Doc-only; no behavior change. Resolution (b) of #231 — the prompt-only behavior is intentional and consistent cross-port, so the doc was the thing that was wrong (not the behavior). Closes #231. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XeGSV3StPCcJGZNNJ4ZfAb
1 parent 19f29a5 commit 8b4ab90

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

server/csharp/MetaObjects/Template/TemplateConstants.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,10 @@ public static class TemplateConstants
4949
public const string TEMPLATE_ATTR_MAX_CHARS = "maxChars";
5050
public const string TEMPLATE_ATTR_OWNER = "owner";
5151
public const string TEMPLATE_ATTR_SINCE = "since";
52-
// Output tags the rendered text must contain (drives the verify output-tag check).
53-
// Generic — not prompt-only: any rendered artifact (email, export, prompt) can
54-
// carry a tag contract a downstream parser depends on.
52+
// Output tags a template.prompt's rendered text must contain. `verify --templates` enforces
53+
// this ONLY on the prompt path — the email/document output gate does not apply per-part
54+
// slot/tag rules (the #193/#230 cross-port consensus). The attr may be authored on any
55+
// template, but verify checks it for prompts only.
5556
public const string TEMPLATE_ATTR_REQUIRED_TAGS = "requiredTags";
5657

5758
// --- @kind + email part-refs (template.output only) ---

server/typescript/packages/metadata/src/template/template-constants.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,10 @@ export const TEMPLATE_ATTR_FORMAT = "format";
3636
export const TEMPLATE_ATTR_MAX_CHARS = "maxChars";
3737
export const TEMPLATE_ATTR_OWNER = "owner";
3838
export const TEMPLATE_ATTR_SINCE = "since";
39-
// Output tags the rendered text must contain (drives the verify output-tag check).
40-
// Generic — not prompt-only: any rendered artifact (email, export, prompt) can
41-
// carry a tag contract a downstream parser depends on.
39+
// Output tags a template.prompt's rendered text must contain. `verify --templates` enforces
40+
// this ONLY on the prompt path — the email/document output gate does not apply per-part slot/tag
41+
// rules (the #193/#230 cross-port consensus). The attr may be authored on any template, but
42+
// verify checks it for prompts only.
4243
export const TEMPLATE_ATTR_REQUIRED_TAGS = "requiredTags";
4344

4445
// --- @kind + email part-refs (template.output only) ---

0 commit comments

Comments
 (0)