Skip to content

Add config.d.ts and schema version bump requirement to boost AGENTS.md #4282

Description

@fullsend-ai-retro

What happened

On PR #4250, the code agent introduced new config keys (boost.ingestion.healthRetention.maxAttemptsPerConnector, boost.connectors.<id>.enabled) without creating TypeScript config declarations in config.d.ts, without registering them in the Zod config schema (schemas.ts), and without bumping the config schema version. The human reviewer (mareklibra) added all three in commit 9c66942: +25 lines to config.d.ts with @configScope annotations, +16 lines to schemas.ts with Zod schemas, and bumped BOOST_CONFIG_SCHEMA_VERSION from 2 to 3. The review agent did not flag these omissions in either review pass.

What could go better

The boost AGENTS.md states "Config validation uses Zod schemas as single source of truth. TypeScript types are generated from Zod. No hand-written validators." This tells the agent how to validate config but does not tell it when to create config declarations or what files to update. The agent created the config fields in app-config.yaml examples but missed the three-step config registration process: (1) TypeScript declaration in config.d.ts with @configScope annotations, (2) Zod schema registration in schemas.ts, (3) schema version bump. Confidence is high — this is a mechanical checklist that, when documented, directly prevents this class of omission.

Proposed change

In workspaces/boost/AGENTS.md, add a subsection under Architecture rules or Code conventions titled "Adding new config fields" with this checklist:

  1. Add TypeScript declarations in plugins/boost-backend/config.d.ts with @configScope JSDoc annotations (yaml-only, per-environment, etc.)
  2. Register the field in src/config/schemas.ts under boostConfigFields with a Zod schema, configScope, and description
  3. Bump BOOST_CONFIG_SCHEMA_VERSION in schemas.ts
  4. Add example usage in examples/app-config.connectors.yaml
  5. Run yarn build:api-reports to capture the updated config surface

This makes the multi-file config registration process explicit rather than relying on the agent to discover it from existing code patterns.

Validation criteria

The next code agent run in the boost workspace that introduces new config keys should create the config.d.ts declarations, register Zod schemas, and bump the config schema version without requiring human intervention. Verify over the next 3 PRs that add config fields to the boost workspace.


Generated by retro agent from #4250

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions