xforce 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/index.js +19 -10
- package/dist/cli/index.js.map +1 -1
- package/dist/index.js +19 -10
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -810,22 +810,31 @@ Fix the code to make the ${kind} pass. Do not commit \u2014 the pipeline handles
|
|
|
810
810
|
// src/agents/prompts/planner-system.ts
|
|
811
811
|
var PLANNER_SYSTEM_PROMPT = `You are a senior software architect analyzing a codebase to create an implementation plan.
|
|
812
812
|
|
|
813
|
-
You have access to read-only tools: Read, Glob, and Grep. Use them to
|
|
814
|
-
1. Explore the repository structure (Glob for file patterns, Read for file contents)
|
|
815
|
-
2. Understand existing patterns, conventions, and architecture
|
|
816
|
-
3. Identify the exact files that need to be modified or created
|
|
817
|
-
4. Analyze dependencies and potential ripple effects
|
|
813
|
+
You have access to read-only tools: Read, Glob, and Grep. Use them to explore the repository before planning.
|
|
818
814
|
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
815
|
+
## TURN BUDGET \u2014 CRITICAL
|
|
816
|
+
You have a LIMITED number of turns. You MUST produce your JSON plan well before you run out.
|
|
817
|
+
|
|
818
|
+
- **Small/empty repos** (< 20 files): Spend 1-3 turns exploring, then output your plan.
|
|
819
|
+
- **Medium repos** (20-100 files): Spend 3-8 turns exploring, then output your plan.
|
|
820
|
+
- **Large repos** (100+ files): Spend at most 10-15 turns exploring, then output your plan.
|
|
821
|
+
|
|
822
|
+
If you are unsure whether you've explored enough, STOP EXPLORING AND OUTPUT YOUR PLAN. An incomplete plan is infinitely better than no plan at all. The coder agent will adapt.
|
|
823
|
+
|
|
824
|
+
## EXPLORATION STRATEGY
|
|
825
|
+
1. Start with a broad Glob (e.g. \`**/*.{ts,tsx,js,jsx,py}\`) to understand project size and structure.
|
|
826
|
+
2. Read key files: package.json, config files, entry points.
|
|
827
|
+
3. Grep for patterns relevant to the task.
|
|
828
|
+
4. Stop exploring once you understand the project structure and relevant patterns.
|
|
829
|
+
|
|
830
|
+
## PLAN QUALITY
|
|
831
|
+
- Be specific about file paths \u2014 use actual paths from the codebase, or specify paths to create.
|
|
822
832
|
- Consider test files and their patterns.
|
|
823
833
|
- Identify potential risks (breaking changes, missing test coverage, security).
|
|
824
834
|
- Estimate complexity honestly.
|
|
825
835
|
- Your plan should be actionable and concrete, not vague.
|
|
826
|
-
- Do NOT spend more than a few turns exploring. Produce your JSON plan as quickly as possible.
|
|
827
836
|
|
|
828
|
-
You MUST respond with valid JSON matching the required schema.`;
|
|
837
|
+
You MUST respond with valid JSON matching the required schema. Do NOT wrap it in markdown fences.`;
|
|
829
838
|
function buildPlannerPrompt(taskSpec) {
|
|
830
839
|
return `## Task: ${taskSpec.title}
|
|
831
840
|
|