What this is
signetry-core ships a policy registry: a directory of YAML files, one per repository
shape, that says which paths an AI agent may touch for a given task and which it may not.
Six ship today (signetry_core/policies/):
python-library, node-service, monorepo-service, docs-only, dependency-bump,
ci-workflow-fix. A .NET service is missing.
This is the highest-leverage thing you can contribute without touching the kernel: one new
file, no Python, and no test to write — tests/test_policy_registry.py is parametrized
over every file in that directory, so your policy is validated the moment it exists.
The deliverable
One file: signetry_core/policies/dotnet-service.yaml. Copy
python-library.yaml
as your starting shape — the # @policy header comments are load-bearing metadata, not
decoration.
A starting point, not a spec to type in verbatim — argue with it, the reasoning is the
contribution:
# @policy id: dotnet-service
# @policy title: .NET service (src/tests layout, dotnet test)
# @policy summary: A .NET service. The agent may change project sources and tests, and must keep
# `dotnet build` and `dotnet test` green. Tree-wide build props, the NuGet source
# configuration, production appsettings and publish profiles stay off-limits.
# @policy stack: dotnet, csharp, nuget, xunit
# @policy author: your-github-handle
# @policy blocks: Directory.Build.props, nuget.config, src/Api/appsettings.Production.json, src/Api/Properties/PublishProfiles/prod.pubxml, .github/workflows/release.yml
# @policy allows: src/Api/Controllers/CheckoutController.cs, src/Domain/Subscription.cs, tests/Api.Tests/CheckoutTests.cs, src/Api/Api.csproj, README.md
version: 2
task_type: feature-work
allowed_paths:
- "src/**"
- "tests/**"
- "*.sln"
- "README.md"
- "CHANGELOG.md"
forbidden_paths:
# Directory.Build.props / Directory.Packages.props are imported by EVERY project
# below them, including projects with no file in this diff. One line here changes
# the compilation of code the reviewer never opened — invisible blast radius.
- "Directory.Build.props"
- "Directory.Build.targets"
- "Directory.Packages.props"
- "**/Directory.Build.*"
# nuget.config decides where packages come from. Redirecting a source is a supply
# chain change that looks like configuration.
- "nuget.config"
- "NuGet.config"
- "**/nuget.config"
# Inside src/** which is otherwise allowed: production configuration and publish
# profiles configure the deployed system and are never loaded by `dotnet test`.
- "**/appsettings.Production.json"
- "**/appsettings.Prod*.json"
- "**/PublishProfiles/**"
- ".github/**"
- "Dockerfile*"
- "**/.env*"
- "**/*secret*"
max_files_changed: 15
required_checks:
- "dotnet build --warnaserror"
- "dotnet test --no-build"
policy_owner: your-team
policy_version: "1.0"
The part people get wrong
Your blocks list must include at least one path that sits inside your own
allowed_paths. Carving an exception out of a directory you otherwise own is the whole
skill. For a .NET service that exception is:
**/appsettings.Production.json and **/PublishProfiles/** — both sit under
src/**, which you want allowed. Neither is loaded by dotnet test, so the required check
that gates the change cannot see a mistake in either.
The .NET trap worth a comment in the file
Directory.Build.props is the one to get right — it applies tree-wide by
directory position, not by reference, so nothing in a .csproj diff hints that it applies.
Same trap in reverse for central package management: with Directory.Packages.props in
play, a version bump moves every project at once.
Acceptance criteria
Getting started
The full numbered walkthrough, including what makes a policy worth merging, is in
docs/site/policy-registry.md → "Contributing a policy".
git clone https://github.com/Signetry/core && cd core
uv sync
uv run pytest tests/test_policy_registry.py -q
uv run signetry policies # your entry should appear here once the file exists
Comment to claim it — one policy per contributor so nobody's work gets duplicated. Happy to
review a half-finished scope list; the reasoning matters more than the YAML.
What this is
signetry-coreships a policy registry: a directory of YAML files, one per repositoryshape, that says which paths an AI agent may touch for a given task and which it may not.
Six ship today (
signetry_core/policies/):python-library,node-service,monorepo-service,docs-only,dependency-bump,ci-workflow-fix. A .NET service is missing.This is the highest-leverage thing you can contribute without touching the kernel: one new
file, no Python, and no test to write —
tests/test_policy_registry.pyis parametrizedover every file in that directory, so your policy is validated the moment it exists.
The deliverable
One file:
signetry_core/policies/dotnet-service.yaml. Copypython-library.yamlas your starting shape — the
# @policyheader comments are load-bearing metadata, notdecoration.
A starting point, not a spec to type in verbatim — argue with it, the reasoning is the
contribution:
The part people get wrong
Your
blockslist must include at least one path that sits inside your ownallowed_paths. Carving an exception out of a directory you otherwise own is the wholeskill. For a .NET service that exception is:
**/appsettings.Production.jsonand**/PublishProfiles/**— both sit undersrc/**, which you want allowed. Neither is loaded bydotnet test, so the required checkthat gates the change cannot see a mistake in either.
The .NET trap worth a comment in the file
Directory.Build.propsis the one to get right — it applies tree-wide bydirectory position, not by reference, so nothing in a
.csprojdiff hints that it applies.Same trap in reverse for central package management: with
Directory.Packages.propsinplay, a version bump moves every project at once.
Acceptance criteria
signetry_core/policies/dotnet-service.yamlexists; filename matches@policy id.blocksandallowseach list 3–4 realistic paths for this stack, and don't overlap.blocksentry is insideallowed_paths.forbidden_pathsentry that isn't self-evident carries a comment saying why,not just that it is.
python-libraryforbidsconftest.pyat any depth and the commentexplains it executes at collection time on every developer machine — that is the bar.
pytest tests/test_policy_registry.pyis green. The suite proves each claimed block isactually refused by the real
evaluate_contract, so a policy that misleads adoptersfails CI rather than shipping.
caution:—signetry initprints it at adoption time. A risky policy with no caution gets sent back; a risky
policy that's honest is fine.
Getting started
The full numbered walkthrough, including what makes a policy worth merging, is in
docs/site/policy-registry.md→ "Contributing a policy".Comment to claim it — one policy per contributor so nobody's work gets duplicated. Happy to
review a half-finished scope list; the reasoning matters more than the YAML.