Skip to content

fix(shared): add scaffolding rule to treat init output as starter code#423

Open
atilafassina wants to merge 1 commit into
mainfrom
template-instructions
Open

fix(shared): add scaffolding rule to treat init output as starter code#423
atilafassina wants to merge 1 commit into
mainfrom
template-instructions

Conversation

@atilafassina

Copy link
Copy Markdown
Contributor

What

Adds a must rule to the template manifest's scaffolding ruleset (TEMPLATE_SCAFFOLDING.rules.must):

Treat databricks apps init output as starter code, not requirements; adapt or replace it to match the requested app

Why

The scaffolding rules steer the AI agent that drives databricks apps init. Without this directive, an agent can treat the generated starter app as a fixed spec and build around it, rather than adapting/replacing it to match what the user actually asked for. This makes the "scaffold is a starting point" expectation explicit.

How

  • Edits the canonical sourcepackages/shared/src/schemas/manifest.ts (TEMPLATE_SCAFFOLDING.rules.must). The rule is 117 chars, within the schema's 120-char SCAFFOLDING_RULE_MAX_LENGTH.
  • Updates the pinning test validate-manifest.test.ts (toEqual on rules.must).
  • Regenerates template/appkit.plugins.json via pnpm sync:template (the JSON is a generated artifact — not hand-edited).

Verification

  • validate-manifest.test.ts — 61 passed (includes the schema-parse + pinning tests)
  • sync.test.ts — 25 passed
  • pnpm --filter shared typecheck — clean

Draft for review of the rule wording before merge.

This pull request and its description were written by Isaac.

Add a `must` rule to TEMPLATE_SCAFFOLDING.rules in the canonical manifest
schema, instructing scaffolding agents to treat `databricks apps init`
output as starter code rather than requirements — adapting or replacing
it to match the requested app behavior.

Updates the validate-manifest pinning test and regenerates
template/appkit.plugins.json via `pnpm sync:template`.

Co-authored-by: Isaac
Signed-off-by: Atila Fassina <atila@fassina.eu>
@atilafassina atilafassina requested a review from MarioCadenas June 8, 2026 16:11
@atilafassina atilafassina marked this pull request as ready for review June 8, 2026 16:11
@atilafassina atilafassina requested a review from a team as a code owner June 8, 2026 16:11
Copilot AI review requested due to automatic review settings June 8, 2026 16:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the template scaffolding rules so that agents running databricks apps init treat generated output as starter code (modifiable/replacable) rather than a fixed spec, preventing the scaffold from being inadvertently “locked in” when it conflicts with the user’s requested app.

Changes:

  • Adds a new must directive to TEMPLATE_SCAFFOLDING.rules.must clarifying scaffold output is a starting point, not a requirement.
  • Updates the manifest pinning test to include the new directive (order and content pinned).
  • Regenerates the synced template/appkit.plugins.json artifact to reflect the canonical manifest change.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
template/appkit.plugins.json Regenerated template manifest artifact including the new scaffolding must rule.
packages/shared/src/schemas/manifest.ts Adds the new canonical TEMPLATE_SCAFFOLDING.rules.must directive for databricks apps init.
packages/shared/src/cli/commands/plugin/validate/validate-manifest.test.ts Updates the pinned expectation for TEMPLATE_SCAFFOLDING.rules.must to include the new directive.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@atilafassina atilafassina changed the title feat(shared): add scaffolding rule to treat init output as starter code fix(shared): add scaffolding rule to treat init output as starter code Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants