Move naming changes that can be derived mechanically from the identifier, type,
or operation structure into Azure.Generator.Management. Align TypeSpec
linters with the generator, then remove redundant C# clientName decorators
after proving generated APIs are unchanged.
Tasks
Line-count note: "Lines" counts the physical lines occupied by matching
@@clientName statements in the current client.tsp files. A multi-line
decorator counts every line from its start through its end; surrounding blank
lines, comments, and imports are excluded. These are removable specification
lines, not generated SDK lines, and upper-bound categories may overlap.
1. Implement acronym normalization
Add one boundary-aware final-name normalizer for:
Ip -> IP
Db -> DB
Os -> OS
Ipv4 -> IPv4
Ipv6 -> IPv6
Apply it to model, extensible-enum/union type, enum type, and model-property
providers. Support repeated occurrences and preserve longer words such as
Oslo, Ipsum, Osmosis, and dbz.
Keep IPV4/IPV6 unchanged because an existing explicit IPV4Address name is a
public compatibility case.
Status: Implemented in draft PR
Azure/azure-sdk-for-net#61947;
42 focused tests pass.
2. Cover remaining acronym surfaces
Add the provider/visitor hooks needed for:
- Enum and union members.
- Client names.
- Operation names.
- Method parameters.
Keep this separate from Task 1 because these surfaces require different
generator plumbing.
3. Complete Url -> Uri
Reuse the existing suffix transformation for:
- Operation names: 9 decorators / 13 lines.
- Enum and union values: 5 decorators / 9 lines.
Only transform a complete Url suffix.
4. Complete date/time naming
Deliver as small changes:
- Typed
Timestamp/TimeStamp -> On: 37 decorators / 149 lines.
- Exact typed
Date -> On: 6 decorators / 6 lines.
- Date-time method parameters: 2 decorators / 10 lines.
Require a resolved date/time type. Do not rename date-looking strings.
5. Align TypeSpec linters
For each shipped generator rule:
- Make the TypeSpec linter suggest the same output.
- Add matching positive and negative test vectors.
- Keep the rule disabled until the generator version is available in spec CI.
- Re-enable the rule in the
client-sdk ruleset.
The acronym linter must support Ipv4/Ipv6 -> IPv4/IPv6 without auto-fixing
IPV4/IPV6.
6. Remove redundant specification decorators
After each generator change ships:
- Remove only decorators reproduced by the production generator.
- Batch changes by TypeSpec project.
- Format, compile, and run repository-native
tsv.
- Regenerate parent and candidate SDKs using the exact
LocalSpecRepo.
- Require byte-identical generated source and public APIs.
- Restore any decorator that changes generated output.
Not included
These are not deterministic enough for automatic generator behavior:
- Choosing boolean prefixes such as
Is, Has, Can, or Should.
- Blanket
Response -> Result.
- Choosing service/product prefixes such as
Grafana, FrontDoor,
NotificationHub, or CosmosDBBase.
- Request-body names such as
Content, Patch, or a resource/action-specific
stem beyond the structural resource PUT/PATCH behavior already implemented.
- Judgment-based
Resource, Options, Collection, or Operation renames.
These belong in a separate non-deterministic naming issue for LLM/reviewer-
assisted API design.
Completion
- Tasks 1-5 are implemented and released.
- Matching TypeSpec linters are enabled.
- Task 6 removes all proven-redundant decorators.
- Paired generation confirms the cleanup does not change generated .NET APIs.
Move naming changes that can be derived mechanically from the identifier, type,
or operation structure into
Azure.Generator.Management. Align TypeSpeclinters with the generator, then remove redundant C#
clientNamedecoratorsafter proving generated APIs are unchanged.
Tasks
IP/DB/OSandIPv4/IPv6normalizationNameVisitor.cs,NameVisitorTests.csUrl -> Urito operations and enum/union valuesNameVisitor.cs, method-parameter providers, teststypespec-azureC# rules, tests, andclient-sdk.tsazure-rest-api-specsclient.tspfiles1. Implement acronym normalization
Add one boundary-aware final-name normalizer for:
Ip -> IPDb -> DBOs -> OSIpv4 -> IPv4Ipv6 -> IPv6Apply it to model, extensible-enum/union type, enum type, and model-property
providers. Support repeated occurrences and preserve longer words such as
Oslo,Ipsum,Osmosis, anddbz.Keep
IPV4/IPV6unchanged because an existing explicitIPV4Addressname is apublic compatibility case.
Status: Implemented in draft PR
Azure/azure-sdk-for-net#61947;
42 focused tests pass.
2. Cover remaining acronym surfaces
Add the provider/visitor hooks needed for:
Keep this separate from Task 1 because these surfaces require different
generator plumbing.
3. Complete
Url -> UriReuse the existing suffix transformation for:
Only transform a complete
Urlsuffix.4. Complete date/time naming
Deliver as small changes:
Timestamp/TimeStamp -> On: 37 decorators / 149 lines.Date -> On: 6 decorators / 6 lines.Require a resolved date/time type. Do not rename date-looking strings.
5. Align TypeSpec linters
For each shipped generator rule:
client-sdkruleset.The acronym linter must support
Ipv4/Ipv6 -> IPv4/IPv6without auto-fixingIPV4/IPV6.6. Remove redundant specification decorators
After each generator change ships:
tsv.LocalSpecRepo.Not included
These are not deterministic enough for automatic generator behavior:
Is,Has,Can, orShould.Response -> Result.Grafana,FrontDoor,NotificationHub, orCosmosDBBase.Content,Patch, or a resource/action-specificstem beyond the structural resource PUT/PATCH behavior already implemented.
Resource,Options,Collection, orOperationrenames.These belong in a separate non-deterministic naming issue for LLM/reviewer-
assisted API design.
Completion