Skip to content

Run 2 Proxies and Publish — Byproducts

Date: 2026-04-01

1. Extensive Type Duplication Across Modules

Section titled “1. Extensive Type Duplication Across Modules”

When types are derived independently from OpenAPI specs per module, identical types get duplicated. Found 12 duplication groups with ~25 redundant definitions. Most significant: ResourceHome (4 copies), OrderMethod (2 copies), Contact/Identity (2 copies), RenderResult (2 copies).

Resolution: Established a type hierarchy with placement rules (module → domain → shared) and documented in knowledge-base/type-consolidation-decisions.md.

2. Dependency Hierarchy Constrains Type Placement

Section titled “2. Dependency Hierarchy Constrains Type Placement”

When two domains share a type, it must go in the lower domain (so the higher can import without violating the hierarchy). RenderResult was initially suggested for resources/ but had to go in reference/shared/types.ts because reference is lower than resources in the dependency graph.

Complex implementation tasks with many files (35+ source files, 8 test files, each requiring OpenAPI spec consultation) can exhaust a single agent’s token budget. The Run 2 agent required three sessions. Mitigation: break large runs further, or pre-fetch all external data before launching the agent.

Fetching OpenAPI specs one-at-a-time triggers a permission prompt for each curl command. Solution: batch all fetches into a single shell command with a loop. Documented in agent memory.

5. Changelog-Driven Publish Requires Placeholder Version

Section titled “5. Changelog-Driven Publish Requires Placeholder Version”

When package.json version matches the changelog version, npm version fails with “Version not changed.” The package.json must use a placeholder (e.g., 0.0.0) that always differs from real changelog versions. The publish workflow sets the real version at build time.

6. front-end-engineer vs. back-end-engineer for TypeScript Work

Section titled “6. front-end-engineer vs. back-end-engineer for TypeScript Work”

Neither existing agent profile fits pure TypeScript library work. Created a typescript-engineer agent profile and a typescript-coding skill to fill this gap.

ArtifactLocationPurpose
typescript-engineer agent profileworkspace/instructions/claude/agents/typescript-engineer.mdAgent for TypeScript package/library work
typescript-coding skillworkspace/instructions/claude/skills/typescript-coding/SKILL.mdTypeScript coding standards for libraries
release-lifecycle skill updateworkspace/instructions/claude/skills/release-lifecycle/SKILL.mdAdded CLQ and GitHub ruleset guidance
type-consolidation-decisions.mdapi-proxy/knowledge-base/Type architecture skill for api-proxy
proxy-implementation-patterns.mdapi-proxy/knowledge-base/Proxy implementation patterns skill
CLAUDE.mdapi-proxy/CLAUDE.mdRepository guide for agents
Type hierarchy analysisdocumentation/.../api-proxy/type-hierarchy.mdDomain architecture and type placement analysis