From c82754999372945eab64ccf06a435728da6d4e2e Mon Sep 17 00:00:00 2001 From: Tony Powell Date: Thu, 15 Jan 2026 09:16:47 -0500 Subject: [PATCH 1/3] feat: Include more guidelines in template prompts --- .changeset/cute-emus-rule.md | 5 +++++ src/plan.ts | 5 +++++ src/templates.ts | 2 +- 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 .changeset/cute-emus-rule.md diff --git a/.changeset/cute-emus-rule.md b/.changeset/cute-emus-rule.md new file mode 100644 index 0000000..e649e18 --- /dev/null +++ b/.changeset/cute-emus-rule.md @@ -0,0 +1,5 @@ +--- +"@cephalization/math": patch +--- + +feat: Include more guidelines in template prompts diff --git a/src/plan.ts b/src/plan.ts index 0bf97cb..6a6949c 100644 --- a/src/plan.ts +++ b/src/plan.ts @@ -46,6 +46,11 @@ FIRST, examine the project to understand its technology stack: - Identify the linter/formatter (e.g., eslint, prettier, rustfmt, black) - Note any existing scripts or commands defined in the project +NOTE: +- Distinguish between frontend and backend tooling. +- For frontend tooling, check if 'agent-browser' cli is installed. If so, it should be used for validating visual changes. +- Distinguish between unit tests and integration tests. + ## Step 2: Plan the Tasks Break the user's goal into discrete, implementable tasks using this format: diff --git a/src/templates.ts b/src/templates.ts index fab3580..e70f36a 100644 --- a/src/templates.ts +++ b/src/templates.ts @@ -10,7 +10,7 @@ Implement ONE task from TASKS.md, test it, commit it, log your learnings, then E 1. **Read TASKS.md** - Find the first task with \`status: pending\` where ALL dependencies have \`status: complete\` 2. **Mark in_progress** - Update the task's status to \`in_progress\` in TASKS.md -3. **Implement** - Write the code following the project's patterns +3. **Implement** - Write the code following the project's patterns. Use prior learnings to your advantage. 4. **Write tests** - For behavioral code changes, create unit tests in the appropriate directory. Skip for documentation-only tasks. 5. **Run tests** - Execute tests from the package directory (ensures existing tests still pass) 6. **Fix failures** - If tests fail, debug and fix. DO NOT PROCEED WITH FAILING TESTS. From 9ff38aaa43f0cefce9b4483380cd632aa669e86e Mon Sep 17 00:00:00 2001 From: Tony Powell Date: Thu, 15 Jan 2026 09:19:07 -0500 Subject: [PATCH 2/3] feat: Add guideline to prefer code generation tools over manual coding --- src/plan.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plan.ts b/src/plan.ts index 6a6949c..44c9251 100644 --- a/src/plan.ts +++ b/src/plan.ts @@ -50,6 +50,7 @@ NOTE: - Distinguish between frontend and backend tooling. - For frontend tooling, check if 'agent-browser' cli is installed. If so, it should be used for validating visual changes. - Distinguish between unit tests and integration tests. +- Prefer code generation tools over manual coding when there are scripts to generate code (e.g. relay, openapi-codegen, etc). ## Step 2: Plan the Tasks From 3376e38e33d500f793aae8ba05986ca617c06b37 Mon Sep 17 00:00:00 2001 From: Tony Powell Date: Thu, 15 Jan 2026 09:22:31 -0500 Subject: [PATCH 3/3] feat: Add guideline to prefer safe types in typed languages --- src/plan.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plan.ts b/src/plan.ts index 44c9251..7d07aeb 100644 --- a/src/plan.ts +++ b/src/plan.ts @@ -51,6 +51,7 @@ NOTE: - For frontend tooling, check if 'agent-browser' cli is installed. If so, it should be used for validating visual changes. - Distinguish between unit tests and integration tests. - Prefer code generation tools over manual coding when there are scripts to generate code (e.g. relay, openapi-codegen, etc). +- If typed languages are used, prefer concrete, safe types (e.g. unknown instead of any in TypeScript) ## Step 2: Plan the Tasks