Skip to content

Commit ffdb2a6

Browse files
Merge branch 'main' into claude/typescript-casting-reduction-9yj94i
2 parents a065b3c + 1361554 commit ffdb2a6

2,276 files changed

Lines changed: 7242 additions & 7296 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agents/skills/deslop/SKILL.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
name: deslop
3+
description: Remove AI-generated code slop from a branch or diff. Use after writing or generating code to strip unnecessary comments, defensive checks, `any` casts, and style that does not match the surrounding file. For prose and markdown, use the humanizer skill instead.
4+
---
5+
6+
# Deslop
7+
8+
Remove AI-generated code slop introduced in a branch so the diff reads like a human wrote it and
9+
matches the surrounding file and this repo's conventions.
10+
11+
## When to use
12+
13+
- After writing or generating a batch of code, before opening a PR.
14+
- When a diff shows the tells of AI generation: over-commenting, defensive scaffolding, or style
15+
that fights the existing file.
16+
- Prose and user-facing markdown are out of scope. Run the `humanizer` skill over those instead.
17+
18+
## What to remove
19+
20+
- Comments a human would not add: restating what the code already says, or inconsistent with the
21+
comment density of the rest of the file.
22+
- Defensive checks and `try/catch` blocks abnormal for the area, especially on trusted or
23+
already-validated code paths. The `security` rule puts validation at trust boundaries, not in
24+
internal code.
25+
- Casts to `any` used only to bypass a type error. Fix the type instead.
26+
- Deep nesting that early returns would flatten.
27+
- Naming, import, or export style inconsistent with the file and the `code-style` rule.
28+
29+
## Guardrails
30+
31+
- Keep behavior unchanged unless you are fixing a clear bug.
32+
- Prefer minimal, surgical edits over broad rewrites.
33+
- Never remove a check that guards a real trust boundary or real error handling. When unsure
34+
whether a check is slop or load-bearing, leave it.
35+
- Do not weaken types, lint rules, or tests to make the edit pass. Fix the root cause.
36+
- After editing, run `pnpm format && pnpm lint:fix` and let the tests pass.
37+
- Report a 1-3 sentence summary of what changed.
38+
39+
## Related skills
40+
41+
| Skill | Use for |
42+
| --- | --- |
43+
| [humanizer](../humanizer/SKILL.md) | Removing AI tells from prose and user-facing markdown |

.claude/commands/deslop.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
argument-hint: [path]
3+
description: Remove AI-generated code slop from the current branch's changes
4+
---
5+
6+
!`git diff --stat HEAD`
7+
8+
Remove AI-generated code slop from the changes on this branch.
9+
10+
1. Review the branch's changes: the diff against the default branch, narrowed to `$ARGUMENTS`
11+
when a path or glob is given.
12+
2. Strip the AI tells: unnecessary or inconsistent comments, defensive checks and `try/catch` on
13+
trusted code paths, `any` casts that only dodge a type error, and deep nesting that early
14+
returns would flatten.
15+
3. Keep behavior unchanged unless fixing a clear bug. Make minimal, surgical edits and do not
16+
weaken types, lint rules, or tests.
17+
4. Run `pnpm format && pnpm lint:fix` and report a 1-3 sentence summary.
18+
19+
Follow the `deslop` skill for the full checklist. For prose and user-facing markdown, use the
20+
`humanizer` skill instead.

AGENTS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ subagents, output styles, and hooks.
9898
You have new skills. If any skill might be relevant then you MUST read it.
9999

100100
- [changelog](.agents/skills/changelog/SKILL.md) - Automatically creates user-facing changelogs from git commits by analyzing commit history, categorizing changes, and transforming technical commits into clear, customer-friendly release notes. Turns hours of manual changelog writing into minutes of automated generation.
101+
- [deslop](.agents/skills/deslop/SKILL.md) - Remove AI-generated code slop from a branch or diff. Use after writing or generating code to strip unnecessary comments, defensive checks, `any` casts, and style that does not match the surrounding file. For prose and markdown, use the humanizer skill instead.
101102
- [documentation](.agents/skills/documentation/SKILL.md) - Use when writing blog posts or documentation markdown files - provides writing style guide (active voice, present tense), content structure patterns, and SEO optimization. Overrides brevity rules for proper grammar.
102103
- [humanizer](.agents/skills/humanizer/SKILL.md) - Remove AI writing patterns to make documentation sound natural, specific, and human. Covers content patterns, language patterns, style patterns, and communication patterns.
103104
- [jsdoc](.agents/skills/jsdoc/SKILL.md) - Full JSDoc format guide for TypeScript, covering @example formats (short, multi-line, multi-variant), tag usage (@default, @deprecated, what to avoid), documentation patterns for properties/enums/functions, and tag order.
Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
export { addFiles } from './petService/addFiles.ts'
2-
export { addPet } from './petService/addPet.ts'
3-
export { deletePet } from './petService/deletePet.ts'
4-
export { findPetsByStatus } from './petService/findPetsByStatus.ts'
5-
export { findPetsByTags } from './petService/findPetsByTags.ts'
6-
export { getPetById } from './petService/getPetById.ts'
7-
export { updatePet } from './petService/updatePet.ts'
8-
export { updatePetWithForm } from './petService/updatePetWithForm.ts'
9-
export { uploadFile } from './petService/uploadFile.ts'
10-
export { createPets } from './petsService/createPets.ts'
11-
export { streamPetEvents } from './streamService/streamPetEvents.ts'
1+
export { addFiles } from './petService/addFiles'
2+
export { addPet } from './petService/addPet'
3+
export { deletePet } from './petService/deletePet'
4+
export { findPetsByStatus } from './petService/findPetsByStatus'
5+
export { findPetsByTags } from './petService/findPetsByTags'
6+
export { getPetById } from './petService/getPetById'
7+
export { updatePet } from './petService/updatePet'
8+
export { updatePetWithForm } from './petService/updatePetWithForm'
9+
export { uploadFile } from './petService/uploadFile'
10+
export { createPets } from './petsService/createPets'
11+
export { streamPetEvents } from './streamService/streamPetEvents'

examples/advanced/src/gen/clients/axios/petService/addFiles.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import type { Options, RequestResult } from '../../../.kubb/client.ts'
2-
import type { AddFilesOptions, AddFilesResponses } from '../../../models/ts/pet/AddFiles.ts'
3-
import { client } from '../../../.kubb/client.ts'
1+
import type { Options, RequestResult } from '../../../.kubb/client'
2+
import type { AddFilesOptions, AddFilesResponses } from '../../../models/ts/pet/AddFiles'
3+
import { client } from '../../../.kubb/client'
44

55
/**
66
* @description Place a new file in the store

examples/advanced/src/gen/clients/axios/petService/addPet.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import type { Options, RequestResult } from '../../../.kubb/client.ts'
2-
import type { AddPetOptions, AddPetResponses } from '../../../models/ts/pet/AddPet.ts'
3-
import { client } from '../../../.kubb/client.ts'
4-
import { addPetResponseSchema, addPetErrorSchema } from '../../../zod/pet/addPetSchema.ts'
1+
import type { Options, RequestResult } from '../../../.kubb/client'
2+
import type { AddPetOptions, AddPetResponses } from '../../../models/ts/pet/AddPet'
3+
import { client } from '../../../.kubb/client'
4+
import { addPetResponseSchema, addPetErrorSchema } from '../../../zod/pet/addPetSchema'
55

66
/**
77
* @description Add a new pet to the store

examples/advanced/src/gen/clients/axios/petService/deletePet.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import type { Options, RequestResult } from '../../../.kubb/client.ts'
2-
import type { DeletePetOptions, DeletePetResponses } from '../../../models/ts/pet/DeletePet.ts'
3-
import { client } from '../../../.kubb/client.ts'
4-
import { deletePetResponseSchema, deletePetErrorSchema } from '../../../zod/pet/deletePetSchema.ts'
1+
import type { Options, RequestResult } from '../../../.kubb/client'
2+
import type { DeletePetOptions, DeletePetResponses } from '../../../models/ts/pet/DeletePet'
3+
import { client } from '../../../.kubb/client'
4+
import { deletePetResponseSchema, deletePetErrorSchema } from '../../../zod/pet/deletePetSchema'
55

66
/**
77
* @description delete a pet

examples/advanced/src/gen/clients/axios/petService/findPetsByStatus.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import type { Options, RequestResult } from '../../../.kubb/client.ts'
2-
import type { FindPetsByStatusOptions, FindPetsByStatusResponses } from '../../../models/ts/pet/FindPetsByStatus.ts'
3-
import { client } from '../../../.kubb/client.ts'
4-
import { findPetsByStatusResponseSchema, findPetsByStatusErrorSchema } from '../../../zod/pet/findPetsByStatusSchema.ts'
1+
import type { Options, RequestResult } from '../../../.kubb/client'
2+
import type { FindPetsByStatusOptions, FindPetsByStatusResponses } from '../../../models/ts/pet/FindPetsByStatus'
3+
import { client } from '../../../.kubb/client'
4+
import { findPetsByStatusResponseSchema, findPetsByStatusErrorSchema } from '../../../zod/pet/findPetsByStatusSchema'
55

66
/**
77
* @description Multiple status values can be provided with comma separated strings

examples/advanced/src/gen/clients/axios/petService/findPetsByTags.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import type { Options, RequestResult } from '../../../.kubb/client.ts'
2-
import type { FindPetsByTagsOptions, FindPetsByTagsResponses } from '../../../models/ts/pet/FindPetsByTags.ts'
3-
import { client } from '../../../.kubb/client.ts'
4-
import { findPetsByTagsResponseSchema, findPetsByTagsErrorSchema } from '../../../zod/pet/findPetsByTagsSchema.ts'
1+
import type { Options, RequestResult } from '../../../.kubb/client'
2+
import type { FindPetsByTagsOptions, FindPetsByTagsResponses } from '../../../models/ts/pet/FindPetsByTags'
3+
import { client } from '../../../.kubb/client'
4+
import { findPetsByTagsResponseSchema, findPetsByTagsErrorSchema } from '../../../zod/pet/findPetsByTagsSchema'
55

66
/**
77
* @description Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.

examples/advanced/src/gen/clients/axios/petService/getPetById.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import type { Options, RequestResult } from '../../../.kubb/client.ts'
2-
import type { GetPetByIdOptions, GetPetByIdResponses } from '../../../models/ts/pet/GetPetById.ts'
3-
import { client } from '../../../.kubb/client.ts'
4-
import { getPetByIdResponseSchema, getPetByIdErrorSchema } from '../../../zod/pet/getPetByIdSchema.ts'
1+
import type { Options, RequestResult } from '../../../.kubb/client'
2+
import type { GetPetByIdOptions, GetPetByIdResponses } from '../../../models/ts/pet/GetPetById'
3+
import { client } from '../../../.kubb/client'
4+
import { getPetByIdResponseSchema, getPetByIdErrorSchema } from '../../../zod/pet/getPetByIdSchema'
55

66
/**
77
* @description Returns a single pet

0 commit comments

Comments
 (0)