Skip to content

Define builtin content-policy rules by function instead of vocabulary - #116

Merged
morgaesis merged 3 commits into
mainfrom
content-policy-functional
Jul 24, 2026
Merged

Define builtin content-policy rules by function instead of vocabulary#116
morgaesis merged 3 commits into
mainfrom
content-policy-functional

Conversation

@morgaesis

@morgaesis morgaesis commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Moves the builtin content-policy baseline out of a config.rs string literal into src/builtin-content-policy.md, embedded at compile time with include_str!. Rules 5 and 6 state functional tests (information-free prose, claim inflation, manufactured rhetoric, redundant restatement, templated uniformity, time-dependent truth) with examples marked illustrative rather than exhaustive, so the policy does not go stale as model vocabularies shift, and the scope section lets repo-appended rules declare a narrower path scope such as a blog directory. Severities and the three-per-file threshold are unchanged, and the policy text stays within the prompt-size tolerance the hermetic bench pins for batched huge-diff windowing.

Move the content-policy baseline text out of a string literal in config.rs
into src/builtin-content-policy.md, pulled in at compile time with
include_str!. The embedded bytes are identical to the previous literal, so
review prompts are unchanged.
Rules 5 and 6 of the builtin content policy previously enumerated specific
words and phrases, which drift as model generations change their vocabulary.
Both rules now state the functional test (information-free prose, claim
inflation, manufactured rhetoric, redundant restatement, templated
uniformity, time-dependent truth) with examples marked illustrative rather
than exhaustive. The scope section also states that repo-appended rules may
declare their own narrower scope, such as applying only to a blog directory.
Severity annotations and the three-per-file threshold are unchanged.
The prompt shares one token budget with the batched diff, so policy text
size shifts batch windowing on large diffs; the hermetic bench pins that
behavior. The functional rewrite now fits within the windowing tolerance
while keeping every rule's test and severity.

@postil-dev postil-dev Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

info 1 finding in summary

  • PR description falsely claims byte-identical content in pull request description: The description says the new file is "byte-identical to the previous literal," but the diff rewrites rule 5 (line 9 of builtin-content-policy.md replaces the colon-plus-examples list with a functional test), rule 6 (line 11 replaces fixed vocabulary with functional categories), and the Scope section (line 13 adds a sentence about repo-appended narrower scopes). The same description later acknowledges "this changes prompt text," directly contradicting the byte-identical claim. Remove the byte-identical claim from the description, or revert the markdown text to actually match the old literal. The bench-live gate already confirms the prompt changed.

Review details

@morgaesis morgaesis closed this Jul 24, 2026
@morgaesis morgaesis reopened this Jul 24, 2026
@morgaesis
morgaesis merged commit 2d6d657 into main Jul 24, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant