openplanr 1.2.8 → 1.4.0
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/README.md +30 -3
- package/dist/agents/task-parser.d.ts.map +1 -1
- package/dist/agents/task-parser.js +8 -34
- package/dist/agents/task-parser.js.map +1 -1
- package/dist/ai/prompts/prompt-builder.d.ts +14 -0
- package/dist/ai/prompts/prompt-builder.d.ts.map +1 -1
- package/dist/ai/prompts/prompt-builder.js +32 -1
- package/dist/ai/prompts/prompt-builder.js.map +1 -1
- package/dist/ai/prompts/system-prompts.d.ts +3 -2
- package/dist/ai/prompts/system-prompts.d.ts.map +1 -1
- package/dist/ai/prompts/system-prompts.js +117 -7
- package/dist/ai/prompts/system-prompts.js.map +1 -1
- package/dist/ai/schemas/ai-response-schemas.d.ts +62 -0
- package/dist/ai/schemas/ai-response-schemas.d.ts.map +1 -1
- package/dist/ai/schemas/ai-response-schemas.js +51 -1
- package/dist/ai/schemas/ai-response-schemas.js.map +1 -1
- package/dist/ai/types.d.ts.map +1 -1
- package/dist/ai/types.js +2 -0
- package/dist/ai/types.js.map +1 -1
- package/dist/cli/commands/backlog.d.ts +12 -0
- package/dist/cli/commands/backlog.d.ts.map +1 -1
- package/dist/cli/commands/backlog.js +88 -2
- package/dist/cli/commands/backlog.js.map +1 -1
- package/dist/cli/commands/config.d.ts.map +1 -1
- package/dist/cli/commands/config.js +8 -2
- package/dist/cli/commands/config.js.map +1 -1
- package/dist/cli/commands/linear.d.ts +8 -0
- package/dist/cli/commands/linear.d.ts.map +1 -0
- package/dist/cli/commands/linear.js +550 -0
- package/dist/cli/commands/linear.js.map +1 -0
- package/dist/cli/commands/quick.d.ts +17 -0
- package/dist/cli/commands/quick.d.ts.map +1 -1
- package/dist/cli/commands/quick.js +31 -15
- package/dist/cli/commands/quick.js.map +1 -1
- package/dist/cli/commands/revise.d.ts +9 -8
- package/dist/cli/commands/revise.d.ts.map +1 -1
- package/dist/cli/commands/revise.js +93 -25
- package/dist/cli/commands/revise.js.map +1 -1
- package/dist/cli/commands/spec.d.ts +28 -0
- package/dist/cli/commands/spec.d.ts.map +1 -0
- package/dist/cli/commands/spec.js +529 -0
- package/dist/cli/commands/spec.js.map +1 -0
- package/dist/cli/index.js +4 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/models/schema.d.ts +44 -0
- package/dist/models/schema.d.ts.map +1 -1
- package/dist/models/schema.js +50 -0
- package/dist/models/schema.js.map +1 -1
- package/dist/models/types.d.ts +188 -3
- package/dist/models/types.d.ts.map +1 -1
- package/dist/services/artifact-gathering.d.ts +4 -0
- package/dist/services/artifact-gathering.d.ts.map +1 -1
- package/dist/services/artifact-gathering.js +1 -1
- package/dist/services/artifact-gathering.js.map +1 -1
- package/dist/services/artifact-service.d.ts +12 -1
- package/dist/services/artifact-service.d.ts.map +1 -1
- package/dist/services/artifact-service.js +49 -6
- package/dist/services/artifact-service.js.map +1 -1
- package/dist/services/atomic-write-service.d.ts +2 -2
- package/dist/services/atomic-write-service.js +2 -2
- package/dist/services/audit-log-service.d.ts +3 -6
- package/dist/services/audit-log-service.d.ts.map +1 -1
- package/dist/services/audit-log-service.js +4 -7
- package/dist/services/audit-log-service.js.map +1 -1
- package/dist/services/cascade-service.d.ts +2 -2
- package/dist/services/cascade-service.js +3 -3
- package/dist/services/cascade-service.js.map +1 -1
- package/dist/services/config-service.d.ts.map +1 -1
- package/dist/services/config-service.js +1 -0
- package/dist/services/config-service.js.map +1 -1
- package/dist/services/credentials-service.js +2 -2
- package/dist/services/credentials-service.js.map +1 -1
- package/dist/services/diff-service.d.ts +1 -1
- package/dist/services/diff-service.js +1 -1
- package/dist/services/evidence-verifier.d.ts +1 -1
- package/dist/services/evidence-verifier.d.ts.map +1 -1
- package/dist/services/evidence-verifier.js +5 -2
- package/dist/services/evidence-verifier.js.map +1 -1
- package/dist/services/git-service.d.ts +4 -4
- package/dist/services/git-service.js +4 -4
- package/dist/services/graph-integrity.d.ts +2 -3
- package/dist/services/graph-integrity.d.ts.map +1 -1
- package/dist/services/graph-integrity.js +2 -3
- package/dist/services/graph-integrity.js.map +1 -1
- package/dist/services/linear/body-formatters.d.ts +69 -0
- package/dist/services/linear/body-formatters.d.ts.map +1 -0
- package/dist/services/linear/body-formatters.js +183 -0
- package/dist/services/linear/body-formatters.js.map +1 -0
- package/dist/services/linear/constants.d.ts +61 -0
- package/dist/services/linear/constants.d.ts.map +1 -0
- package/dist/services/linear/constants.js +84 -0
- package/dist/services/linear/constants.js.map +1 -0
- package/dist/services/linear/errors.d.ts +14 -0
- package/dist/services/linear/errors.d.ts.map +1 -0
- package/dist/services/linear/errors.js +106 -0
- package/dist/services/linear/errors.js.map +1 -0
- package/dist/services/linear/estimate-resolver.d.ts +50 -0
- package/dist/services/linear/estimate-resolver.d.ts.map +1 -0
- package/dist/services/linear/estimate-resolver.js +82 -0
- package/dist/services/linear/estimate-resolver.js.map +1 -0
- package/dist/services/linear/plan-builders.d.ts +64 -0
- package/dist/services/linear/plan-builders.d.ts.map +1 -0
- package/dist/services/linear/plan-builders.js +237 -0
- package/dist/services/linear/plan-builders.js.map +1 -0
- package/dist/services/linear/scope-loaders.d.ts +79 -0
- package/dist/services/linear/scope-loaders.d.ts.map +1 -0
- package/dist/services/linear/scope-loaders.js +227 -0
- package/dist/services/linear/scope-loaders.js.map +1 -0
- package/dist/services/linear/strategy-context.d.ts +66 -0
- package/dist/services/linear/strategy-context.d.ts.map +1 -0
- package/dist/services/linear/strategy-context.js +121 -0
- package/dist/services/linear/strategy-context.js.map +1 -0
- package/dist/services/linear-mapping-service.d.ts +11 -0
- package/dist/services/linear-mapping-service.d.ts.map +1 -0
- package/dist/services/linear-mapping-service.js +220 -0
- package/dist/services/linear-mapping-service.js.map +1 -0
- package/dist/services/linear-pull-service.d.ts +137 -0
- package/dist/services/linear-pull-service.d.ts.map +1 -0
- package/dist/services/linear-pull-service.js +720 -0
- package/dist/services/linear-pull-service.js.map +1 -0
- package/dist/services/linear-push-service.d.ts +86 -0
- package/dist/services/linear-push-service.d.ts.map +1 -0
- package/dist/services/linear-push-service.js +956 -0
- package/dist/services/linear-push-service.js.map +1 -0
- package/dist/services/linear-service.d.ts +122 -0
- package/dist/services/linear-service.d.ts.map +1 -0
- package/dist/services/linear-service.js +361 -0
- package/dist/services/linear-service.js.map +1 -0
- package/dist/services/prompt-service.d.ts +19 -0
- package/dist/services/prompt-service.d.ts.map +1 -1
- package/dist/services/prompt-service.js +64 -0
- package/dist/services/prompt-service.js.map +1 -1
- package/dist/services/revise-apply-service.d.ts +55 -0
- package/dist/services/revise-apply-service.d.ts.map +1 -0
- package/dist/services/revise-apply-service.js +255 -0
- package/dist/services/revise-apply-service.js.map +1 -0
- package/dist/services/revise-cache-service.d.ts +1 -1
- package/dist/services/revise-cache-service.js +1 -1
- package/dist/services/revise-plan-service.d.ts +38 -0
- package/dist/services/revise-plan-service.d.ts.map +1 -0
- package/dist/services/revise-plan-service.js +151 -0
- package/dist/services/revise-plan-service.js.map +1 -0
- package/dist/services/revise-service.d.ts +18 -11
- package/dist/services/revise-service.d.ts.map +1 -1
- package/dist/services/revise-service.js +57 -12
- package/dist/services/revise-service.js.map +1 -1
- package/dist/services/spec-service.d.ts +292 -0
- package/dist/services/spec-service.d.ts.map +1 -0
- package/dist/services/spec-service.js +805 -0
- package/dist/services/spec-service.js.map +1 -0
- package/dist/services/template-sections.d.ts +1 -1
- package/dist/services/template-sections.js +1 -1
- package/dist/templates/backlog/backlog-item.md.hbs +3 -0
- package/dist/templates/quick/quick-task.md.hbs +6 -0
- package/dist/templates/spec/spec-shaped.md.hbs +89 -0
- package/dist/templates/spec/spec.md.hbs +68 -0
- package/dist/templates/spec/story.md.hbs +51 -0
- package/dist/templates/spec/task.md.hbs +98 -0
- package/dist/utils/constants.d.ts +18 -0
- package/dist/utils/constants.d.ts.map +1 -1
- package/dist/utils/constants.js +25 -0
- package/dist/utils/constants.js.map +1 -1
- package/dist/utils/diff.d.ts +22 -1
- package/dist/utils/diff.d.ts.map +1 -1
- package/dist/utils/diff.js +136 -1
- package/dist/utils/diff.js.map +1 -1
- package/dist/utils/markdown.d.ts +23 -0
- package/dist/utils/markdown.d.ts.map +1 -1
- package/dist/utils/markdown.js +79 -0
- package/dist/utils/markdown.js.map +1 -1
- package/package.json +3 -2
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* `planr revise` — core service
|
|
2
|
+
* `planr revise` — core service.
|
|
3
3
|
*
|
|
4
|
-
* Exposes composable primitives
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* write path and exposes the verifier context so callers can run
|
|
8
|
-
* `verifyDecision` against the same inputs the agent saw.
|
|
4
|
+
* Exposes composable primitives. `reviseArtifact` produces dry-run decisions;
|
|
5
|
+
* `applyDecision` writes them to disk. The verifier context is exposed so
|
|
6
|
+
* callers can run `verifyDecision` against the same inputs the agent saw.
|
|
9
7
|
*/
|
|
10
8
|
import { type RevisePromptArtifact, type ReviseWritableScope } from '../ai/prompts/prompt-builder.js';
|
|
11
9
|
import { type AIProvider, type AIUsage } from '../ai/types.js';
|
|
@@ -13,7 +11,7 @@ import type { ArtifactType, OpenPlanrConfig, ReviseAuditEntry, ReviseDecision }
|
|
|
13
11
|
import type { AuditLogWriter } from './audit-log-service.js';
|
|
14
12
|
import type { EvidenceVerifierContext } from './evidence-verifier.js';
|
|
15
13
|
export interface ReviseArtifactOptions {
|
|
16
|
-
/** Must be `true` in
|
|
14
|
+
/** Must be `true` in this release; reserved for future write path. */
|
|
17
15
|
dryRun: true;
|
|
18
16
|
/** Which parts of the artifact the agent may modify. Default: 'all'. */
|
|
19
17
|
writableScope?: ReviseWritableScope;
|
|
@@ -50,12 +48,12 @@ export declare class ReviseArtifactNotFoundError extends Error {
|
|
|
50
48
|
constructor(artifactId: string, message: string);
|
|
51
49
|
}
|
|
52
50
|
/**
|
|
53
|
-
* Revise a single artifact
|
|
51
|
+
* Revise a single artifact (dry-run).
|
|
54
52
|
*
|
|
55
53
|
* Does NOT write any files. The returned decision is the agent output after
|
|
56
|
-
* schema validation; evidence verification, diff preview, and write
|
|
57
|
-
*
|
|
58
|
-
*
|
|
54
|
+
* schema validation; evidence verification, diff preview, and write live in
|
|
55
|
+
* the CLI / apply path. Cascade, siblings, and declared sources are future
|
|
56
|
+
* extensions.
|
|
59
57
|
*/
|
|
60
58
|
export declare function reviseArtifact(projectDir: string, config: OpenPlanrConfig, provider: AIProvider, artifactId: string, options: ReviseArtifactOptions): Promise<ReviseArtifactResult>;
|
|
61
59
|
export interface ApplyDecisionOptions {
|
|
@@ -88,6 +86,15 @@ export interface ApplyDecisionResult {
|
|
|
88
86
|
* trusts that whatever decision arrives is allowed to be written.
|
|
89
87
|
*/
|
|
90
88
|
export declare function applyDecision(options: ApplyDecisionOptions): Promise<ApplyDecisionResult>;
|
|
89
|
+
/**
|
|
90
|
+
* `true` when the agent's `revisedMarkdown` is byte-identical to `original`,
|
|
91
|
+
* or differs only in trailing whitespace/newlines (LLM markdown serializers
|
|
92
|
+
* routinely drop or add one trailing newline without changing semantics).
|
|
93
|
+
*
|
|
94
|
+
* Exported so the `--apply-from <audit>` replay path and the interactive
|
|
95
|
+
* UI can share the same unchanged-detection rule.
|
|
96
|
+
*/
|
|
97
|
+
export declare function isEffectivelyUnchanged(original: string, revised: string | undefined): boolean;
|
|
91
98
|
/**
|
|
92
99
|
* Load immediate-sibling artifacts (same artifact type, same parent) as
|
|
93
100
|
* prompt entries. Lazy-reads each sibling's body only if it's going to be
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"revise-service.d.ts","sourceRoot":"","sources":["../../src/services/revise-service.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"revise-service.d.ts","sourceRoot":"","sources":["../../src/services/revise-service.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AASH,OAAO,EAEL,KAAK,oBAAoB,EACzB,KAAK,mBAAmB,EACzB,MAAM,iCAAiC,CAAC;AAEzC,OAAO,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planr revise` — core service
|
|
2
|
+
* `planr revise` — core service.
|
|
3
3
|
*
|
|
4
|
-
* Exposes composable primitives
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* write path and exposes the verifier context so callers can run
|
|
8
|
-
* `verifyDecision` against the same inputs the agent saw.
|
|
4
|
+
* Exposes composable primitives. `reviseArtifact` produces dry-run decisions;
|
|
5
|
+
* `applyDecision` writes them to disk. The verifier context is exposed so
|
|
6
|
+
* callers can run `verifyDecision` against the same inputs the agent saw.
|
|
9
7
|
*/
|
|
10
8
|
import path from 'node:path';
|
|
11
9
|
import { buildCodebaseContext, extractKeywords, formatCodebaseContext, } from '../ai/codebase/context-builder.js';
|
|
@@ -31,12 +29,12 @@ export class ReviseArtifactNotFoundError extends Error {
|
|
|
31
29
|
}
|
|
32
30
|
}
|
|
33
31
|
/**
|
|
34
|
-
* Revise a single artifact
|
|
32
|
+
* Revise a single artifact (dry-run).
|
|
35
33
|
*
|
|
36
34
|
* Does NOT write any files. The returned decision is the agent output after
|
|
37
|
-
* schema validation; evidence verification, diff preview, and write
|
|
38
|
-
*
|
|
39
|
-
*
|
|
35
|
+
* schema validation; evidence verification, diff preview, and write live in
|
|
36
|
+
* the CLI / apply path. Cascade, siblings, and declared sources are future
|
|
37
|
+
* extensions.
|
|
40
38
|
*/
|
|
41
39
|
export async function reviseArtifact(projectDir, config, provider, artifactId, options) {
|
|
42
40
|
const artifactType = findArtifactTypeById(artifactId);
|
|
@@ -84,7 +82,7 @@ export async function reviseArtifact(projectDir, config, provider, artifactId, o
|
|
|
84
82
|
config,
|
|
85
83
|
artifactDir: path.dirname(artifactPath),
|
|
86
84
|
codebaseContextFormatted,
|
|
87
|
-
knownSourceRefs: [], //
|
|
85
|
+
knownSourceRefs: [], // sources loader (future extension) will populate
|
|
88
86
|
knownPatternRuleIds: codebaseCtx ? codebaseCtx.patternRules.map((r) => r.name) : [],
|
|
89
87
|
};
|
|
90
88
|
return {
|
|
@@ -126,6 +124,17 @@ export async function applyDecision(options) {
|
|
|
126
124
|
return { outcome: 'skipped-by-agent', wrote: false, diff: '' };
|
|
127
125
|
}
|
|
128
126
|
if (decision.action === 'flag') {
|
|
127
|
+
// When a revise → flag demotion happened upstream, `revisedMarkdown`
|
|
128
|
+
// still holds the agent's proposed rewrite. Include the would-have-been
|
|
129
|
+
// diff in the audit entry so users can see what was rejected and decide
|
|
130
|
+
// whether to hand-apply it.
|
|
131
|
+
const proposedDiff = decision.revisedMarkdown
|
|
132
|
+
? renderDiff(originalContent, decision.revisedMarkdown, {
|
|
133
|
+
color: false,
|
|
134
|
+
oldLabel: `${decision.artifactId} (before)`,
|
|
135
|
+
newLabel: `${decision.artifactId} (proposed — REJECTED by verifier)`,
|
|
136
|
+
})
|
|
137
|
+
: undefined;
|
|
129
138
|
audit.appendEntry({
|
|
130
139
|
artifactId: decision.artifactId,
|
|
131
140
|
artifactPath,
|
|
@@ -134,9 +143,10 @@ export async function applyDecision(options) {
|
|
|
134
143
|
evidence: decision.evidence,
|
|
135
144
|
ambiguous: decision.ambiguous,
|
|
136
145
|
cascadeLevel: options.cascadeLevel,
|
|
146
|
+
...(proposedDiff ? { diff: proposedDiff } : {}),
|
|
137
147
|
timestamp,
|
|
138
148
|
});
|
|
139
|
-
return { outcome: 'flagged', wrote: false, diff: '' };
|
|
149
|
+
return { outcome: 'flagged', wrote: false, diff: proposedDiff ?? '' };
|
|
140
150
|
}
|
|
141
151
|
// action === 'revise'
|
|
142
152
|
const diff = decision.revisedMarkdown
|
|
@@ -146,6 +156,26 @@ export async function applyDecision(options) {
|
|
|
146
156
|
newLabel: `${decision.artifactId} (proposed)`,
|
|
147
157
|
})
|
|
148
158
|
: '';
|
|
159
|
+
// Short-circuit: if the agent returned content that is effectively
|
|
160
|
+
// identical to the original (byte-exact, or only trailing-whitespace
|
|
161
|
+
// differences from markdown serializer normalization), skip the write
|
|
162
|
+
// and report `unchanged-by-agent`. Prevents the "Proposed diff: <empty>
|
|
163
|
+
// → applied" UX bug where a trivial newline-strip got reported as a
|
|
164
|
+
// successful revise even though the agent explicitly said the artifact
|
|
165
|
+
// was already well-structured.
|
|
166
|
+
if (isEffectivelyUnchanged(originalContent, decision.revisedMarkdown)) {
|
|
167
|
+
audit.appendEntry({
|
|
168
|
+
artifactId: decision.artifactId,
|
|
169
|
+
artifactPath,
|
|
170
|
+
outcome: 'unchanged-by-agent',
|
|
171
|
+
rationale: decision.rationale,
|
|
172
|
+
evidence: decision.evidence,
|
|
173
|
+
ambiguous: decision.ambiguous,
|
|
174
|
+
cascadeLevel: options.cascadeLevel,
|
|
175
|
+
timestamp,
|
|
176
|
+
});
|
|
177
|
+
return { outcome: 'unchanged-by-agent', wrote: false, diff: '' };
|
|
178
|
+
}
|
|
149
179
|
if (dryRun) {
|
|
150
180
|
audit.appendEntry({
|
|
151
181
|
artifactId: decision.artifactId,
|
|
@@ -176,6 +206,21 @@ export async function applyDecision(options) {
|
|
|
176
206
|
});
|
|
177
207
|
return { outcome: 'applied', wrote: true, diff };
|
|
178
208
|
}
|
|
209
|
+
/**
|
|
210
|
+
* `true` when the agent's `revisedMarkdown` is byte-identical to `original`,
|
|
211
|
+
* or differs only in trailing whitespace/newlines (LLM markdown serializers
|
|
212
|
+
* routinely drop or add one trailing newline without changing semantics).
|
|
213
|
+
*
|
|
214
|
+
* Exported so the `--apply-from <audit>` replay path and the interactive
|
|
215
|
+
* UI can share the same unchanged-detection rule.
|
|
216
|
+
*/
|
|
217
|
+
export function isEffectivelyUnchanged(original, revised) {
|
|
218
|
+
if (revised === undefined)
|
|
219
|
+
return true;
|
|
220
|
+
if (revised === original)
|
|
221
|
+
return true;
|
|
222
|
+
return revised.replace(/\s+$/, '') === original.replace(/\s+$/, '');
|
|
223
|
+
}
|
|
179
224
|
/**
|
|
180
225
|
* Load immediate-sibling artifacts (same artifact type, same parent) as
|
|
181
226
|
* prompt entries. Lazy-reads each sibling's body only if it's going to be
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"revise-service.js","sourceRoot":"","sources":["../../src/services/revise-service.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"revise-service.js","sourceRoot":"","sources":["../../src/services/revise-service.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EACL,oBAAoB,EAEpB,eAAe,EACf,qBAAqB,GACtB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,iBAAiB,GAGlB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAC9E,OAAO,EAAiC,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAO9E,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EACL,oBAAoB,EACpB,cAAc,EACd,cAAc,EACd,aAAa,EACb,YAAY,EACZ,eAAe,EACf,uBAAuB,GACxB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAE5D,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAE/C,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAkC9D;;;GAGG;AACH,MAAM,OAAO,2BAA4B,SAAQ,KAAK;IACpC,UAAU,CAAS;IAEnC,YAAY,UAAkB,EAAE,OAAe;QAC7C,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,6BAA6B,CAAC;QAC1C,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;IAC/B,CAAC;CACF;AAED;;;;;;;GAOG;AACH,MAAM,CAAC,KAAK,UAAU,cAAc,CAClC,UAAkB,EAClB,MAAuB,EACvB,QAAoB,EACpB,UAAkB,EAClB,OAA8B;IAE9B,MAAM,YAAY,GAAG,oBAAoB,CAAC,UAAU,CAAC,C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AM,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC;YAC/B,IAAI,EAAE,OAAO;YACb,OAAO,EAAE,KAAK,CAAC,KAAK,CAAC,OAAO;SAC7B,CAAC,CAAC;IACL,CAAC;IACD,OAAO,OAAO,CAAC;AACjB,CAAC"}
|
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* spec-service — directory-aware CRUD for spec-driven planning mode.
|
|
3
|
+
*
|
|
4
|
+
* Unlike agile/QT artifacts which are flat single files, each spec is a
|
|
5
|
+
* **self-contained directory** (per BL-011 addendum + design doc):
|
|
6
|
+
*
|
|
7
|
+
* .planr/specs/SPEC-NNN-{slug}/
|
|
8
|
+
* ├── SPEC-NNN-{slug}.md ← the spec document
|
|
9
|
+
* ├── design/ ← UI mockups + design-spec.md (if any)
|
|
10
|
+
* │ ├── *.png
|
|
11
|
+
* │ └── design-spec.md ← reserved path (written by openplanr-pipeline's designer-agent)
|
|
12
|
+
* ├── stories/
|
|
13
|
+
* │ └── US-NNN-{slug}.md ← US-NNN scoped to this spec
|
|
14
|
+
* └── tasks/
|
|
15
|
+
* └── T-NNN-{slug}.md ← T-NNN scoped to this spec
|
|
16
|
+
*
|
|
17
|
+
* Why directory-per-spec:
|
|
18
|
+
* - Self-contained / portable / `rm -rf` clean
|
|
19
|
+
* - `PREFIX-NNN-slug` naming consistent with every other planr artifact
|
|
20
|
+
* - US-NNN and T-NNN are SCOPED TO THE PARENT SPEC (not project-globally
|
|
21
|
+
* unique). Two specs can each have their own US-001. Disambiguation is
|
|
22
|
+
* via the path or via `specId` frontmatter.
|
|
23
|
+
* - Schema matches openplanr-pipeline plugin verbatim — both products
|
|
24
|
+
* share one contract. See https://github.com/openplanr/openplanr-pipeline
|
|
25
|
+
*
|
|
26
|
+
* This service owns spec authoring inside the planr CLI. The
|
|
27
|
+
* openplanr-pipeline plugin is the executor: it reads `.planr/specs/` (when
|
|
28
|
+
* spec mode is active) and runs the PO/DEV phases to ship code.
|
|
29
|
+
*/
|
|
30
|
+
import type { OpenPlanrConfig } from '../models/types.js';
|
|
31
|
+
/** Root directory holding all specs (e.g., `.planr/specs/`). */
|
|
32
|
+
export declare function getSpecsRootDir(projectDir: string, config: OpenPlanrConfig): string;
|
|
33
|
+
/** Self-contained directory for a single spec, e.g. `.planr/specs/SPEC-001-auth-flow/`. */
|
|
34
|
+
export declare function getSpecDir(projectDir: string, config: OpenPlanrConfig, specId: string, slug: string): string;
|
|
35
|
+
/** Stories subdirectory inside a spec. */
|
|
36
|
+
export declare function getSpecStoriesDir(specDir: string): string;
|
|
37
|
+
/** Tasks subdirectory inside a spec. */
|
|
38
|
+
export declare function getSpecTasksDir(specDir: string): string;
|
|
39
|
+
/** Design assets subdirectory inside a spec (PNGs + design-spec.md). */
|
|
40
|
+
export declare function getSpecDesignDir(specDir: string): string;
|
|
41
|
+
/**
|
|
42
|
+
* Resolve a spec ID (e.g. `SPEC-001`) to its on-disk directory by scanning
|
|
43
|
+
* `.planr/specs/` for a matching `SPEC-NNN-{slug}` directory. Returns null
|
|
44
|
+
* if the spec isn't found.
|
|
45
|
+
*
|
|
46
|
+
* The directory name encodes both ID and slug, so we don't need to read the
|
|
47
|
+
* spec file to find it.
|
|
48
|
+
*/
|
|
49
|
+
export declare function resolveSpecDir(projectDir: string, config: OpenPlanrConfig, specId: string): Promise<{
|
|
50
|
+
dir: string;
|
|
51
|
+
slug: string;
|
|
52
|
+
} | null>;
|
|
53
|
+
/** Spec metadata returned by listSpecs. */
|
|
54
|
+
export interface SpecListing {
|
|
55
|
+
id: string;
|
|
56
|
+
slug: string;
|
|
57
|
+
title: string;
|
|
58
|
+
status: string;
|
|
59
|
+
dirName: string;
|
|
60
|
+
storyCount: number;
|
|
61
|
+
taskCount: number;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* List every spec under `.planr/specs/`.
|
|
65
|
+
* Reads each spec's frontmatter for title + status; counts stories + tasks.
|
|
66
|
+
*/
|
|
67
|
+
export declare function listSpecs(projectDir: string, config: OpenPlanrConfig): Promise<SpecListing[]>;
|
|
68
|
+
export interface CreateSpecOptions {
|
|
69
|
+
/** Optional explicit slug (kebab-case). If omitted, derived from title. */
|
|
70
|
+
slug?: string;
|
|
71
|
+
/** Priority (P0 / P1 / P2). Defaults to P1. */
|
|
72
|
+
priority?: string;
|
|
73
|
+
/** Milestone string (e.g., `v1.0`). */
|
|
74
|
+
milestone?: string;
|
|
75
|
+
/** Author handle. */
|
|
76
|
+
po?: string;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Create a new spec directory + spec file from the template.
|
|
80
|
+
* Returns the assigned ID and the absolute file path of the spec markdown.
|
|
81
|
+
*
|
|
82
|
+
* Refuses if a directory with the same slug already exists, to avoid
|
|
83
|
+
* accidental overwrites.
|
|
84
|
+
*/
|
|
85
|
+
export declare function createSpec(projectDir: string, config: OpenPlanrConfig, title: string, options?: CreateSpecOptions): Promise<{
|
|
86
|
+
id: string;
|
|
87
|
+
slug: string;
|
|
88
|
+
specDir: string;
|
|
89
|
+
specFile: string;
|
|
90
|
+
}>;
|
|
91
|
+
export interface SpecArtifact {
|
|
92
|
+
id: string;
|
|
93
|
+
slug: string;
|
|
94
|
+
specDir: string;
|
|
95
|
+
specFile: string;
|
|
96
|
+
data: Record<string, unknown>;
|
|
97
|
+
content: string;
|
|
98
|
+
}
|
|
99
|
+
export declare function readSpec(projectDir: string, config: OpenPlanrConfig, specId: string): Promise<SpecArtifact | null>;
|
|
100
|
+
/** Overwrite the spec markdown file in place. Atomic. */
|
|
101
|
+
export declare function updateSpec(projectDir: string, config: OpenPlanrConfig, specId: string, content: string): Promise<void>;
|
|
102
|
+
/**
|
|
103
|
+
* Surgical YAML frontmatter update for a spec.
|
|
104
|
+
* Mirrors artifact-service.updateArtifactFields shape.
|
|
105
|
+
*/
|
|
106
|
+
export declare function updateSpecFields(projectDir: string, config: OpenPlanrConfig, specId: string, fields: Partial<Record<string, unknown>>): Promise<void>;
|
|
107
|
+
export interface SyncSpecReport {
|
|
108
|
+
specId: string;
|
|
109
|
+
specSlug: string;
|
|
110
|
+
/** Issues that were auto-repaired (file was rewritten). */
|
|
111
|
+
fixed: string[];
|
|
112
|
+
/** Issues that need human attention (orphans, schema drift, etc.). */
|
|
113
|
+
warnings: string[];
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Validate one spec's internal integrity and repair safe inconsistencies.
|
|
117
|
+
*
|
|
118
|
+
* Checks performed:
|
|
119
|
+
* 1. Orphaned task: `task.storyId` doesn't match any existing US in the same
|
|
120
|
+
* spec → WARN (don't auto-delete; user reviews and either fixes the
|
|
121
|
+
* storyId or destroys the task)
|
|
122
|
+
* 2. Story without tasks: WARN (decomposition is incomplete)
|
|
123
|
+
* 3. Missing `specId` in US/Task frontmatter → AUTO-FIX from path
|
|
124
|
+
* 4. Schema version mismatch (artifact's schemaVersion older than current)
|
|
125
|
+
* → WARN (no auto-migration in v1; flagged for follow-up)
|
|
126
|
+
*
|
|
127
|
+
* Note: this is a *read-mostly* operation. The only writes happen in case 3
|
|
128
|
+
* (adding a missing `specId` field via updateSpecFields-equivalent); all
|
|
129
|
+
* other findings are reported as warnings so the user controls the fix.
|
|
130
|
+
*
|
|
131
|
+
* `dryRun: true` skips writes entirely; only report.
|
|
132
|
+
*/
|
|
133
|
+
export declare function syncSpec(projectDir: string, config: OpenPlanrConfig, specId: string, opts?: {
|
|
134
|
+
dryRun?: boolean;
|
|
135
|
+
}): Promise<SyncSpecReport>;
|
|
136
|
+
/**
|
|
137
|
+
* Run syncSpec across every spec in the project.
|
|
138
|
+
* Aggregates per-spec reports.
|
|
139
|
+
*/
|
|
140
|
+
export declare function syncAllSpecs(projectDir: string, config: OpenPlanrConfig, opts?: {
|
|
141
|
+
dryRun?: boolean;
|
|
142
|
+
}): Promise<{
|
|
143
|
+
specsScanned: number;
|
|
144
|
+
reports: SyncSpecReport[];
|
|
145
|
+
}>;
|
|
146
|
+
export interface DecomposeSpecOptions {
|
|
147
|
+
/** When true, overwrite existing US/Task files. Default false. */
|
|
148
|
+
force?: boolean;
|
|
149
|
+
/**
|
|
150
|
+
* When true, skip the codebase scanner. Faster but generated tasks
|
|
151
|
+
* reference generic paths the user must edit afterwards.
|
|
152
|
+
*/
|
|
153
|
+
noCodeContext?: boolean;
|
|
154
|
+
/** Cap the number of stories the AI emits (1-8, default 6 from prompt). */
|
|
155
|
+
maxStories?: number;
|
|
156
|
+
}
|
|
157
|
+
export interface DecomposeSpecResult {
|
|
158
|
+
storiesCreated: number;
|
|
159
|
+
tasksCreated: number;
|
|
160
|
+
decompositionNotes: string;
|
|
161
|
+
}
|
|
162
|
+
/**
|
|
163
|
+
* Decompose a SPEC into User Stories + Tasks via AI.
|
|
164
|
+
*
|
|
165
|
+
* High-level flow:
|
|
166
|
+
* 1. Read the spec; refuse if stories/ or tasks/ already populated
|
|
167
|
+
* (unless `opts.force === true`)
|
|
168
|
+
* 2. Read `input/tech/stack.md` (best-effort; passed as a hint to the AI)
|
|
169
|
+
* 3. Build codebase context via planr's existing scanner (skipped if
|
|
170
|
+
* `opts.noCodeContext === true`)
|
|
171
|
+
* 4. Build prompt + call AI provider via `generateStreamingJSON`
|
|
172
|
+
* 5. Validate the response with `aiSpecDecomposeResponseSchema`
|
|
173
|
+
* 6. Write each US via `createSpecStory` and each Task via `createSpecTask`
|
|
174
|
+
* 7. Update SPEC frontmatter status: pending|shaping → decomposing → decomposed
|
|
175
|
+
*/
|
|
176
|
+
export declare function decomposeSpec(projectDir: string, config: OpenPlanrConfig, specId: string, opts?: DecomposeSpecOptions): Promise<DecomposeSpecResult>;
|
|
177
|
+
/**
|
|
178
|
+
* Answers gathered by `planr spec shape` from the PO.
|
|
179
|
+
*
|
|
180
|
+
* The shape command captures four areas: business context, functional
|
|
181
|
+
* requirements, business rules / constraints, and acceptance criteria.
|
|
182
|
+
* `decompositionNotes` is optional — hints for `planr spec decompose` later.
|
|
183
|
+
*/
|
|
184
|
+
export interface ShapeSpecAnswers {
|
|
185
|
+
context: string;
|
|
186
|
+
functionalRequirements: string[];
|
|
187
|
+
businessRules?: string;
|
|
188
|
+
outOfScope?: string[];
|
|
189
|
+
acceptanceCriteria: string[];
|
|
190
|
+
decompositionNotes?: string;
|
|
191
|
+
}
|
|
192
|
+
/**
|
|
193
|
+
* Re-render the SPEC body from a structured set of answers and write it back
|
|
194
|
+
* atomically. Preserves frontmatter values that the user (or `planr spec
|
|
195
|
+
* create`) already set: priority, milestone, po, ui_files, created, etc.
|
|
196
|
+
*
|
|
197
|
+
* Updates `status` to `shaping` so subsequent commands (`decompose`, `promote`)
|
|
198
|
+
* can see the spec has moved past the initial empty placeholder body.
|
|
199
|
+
*/
|
|
200
|
+
export declare function shapeSpec(projectDir: string, config: OpenPlanrConfig, specId: string, answers: ShapeSpecAnswers): Promise<{
|
|
201
|
+
specFile: string;
|
|
202
|
+
}>;
|
|
203
|
+
/**
|
|
204
|
+
* Destroy a spec directory. Self-contained = single `rm -rf` of the
|
|
205
|
+
* spec's own directory. Stories and tasks are removed atomically with the
|
|
206
|
+
* spec. No cross-spec references to clean up.
|
|
207
|
+
*/
|
|
208
|
+
export declare function destroySpec(projectDir: string, config: OpenPlanrConfig, specId: string): Promise<void>;
|
|
209
|
+
export interface SpecStoryListing {
|
|
210
|
+
id: string;
|
|
211
|
+
slug: string;
|
|
212
|
+
title: string;
|
|
213
|
+
status: string;
|
|
214
|
+
filename: string;
|
|
215
|
+
filePath: string;
|
|
216
|
+
}
|
|
217
|
+
/**
|
|
218
|
+
* List US-NNN files inside a spec's stories/ subdirectory.
|
|
219
|
+
* Returns IDs scoped to this spec — two specs can each have US-001.
|
|
220
|
+
*/
|
|
221
|
+
export declare function listSpecStories(specDir: string): Promise<SpecStoryListing[]>;
|
|
222
|
+
/** Append a US-NNN-{slug}.md file under the spec's stories/ directory. */
|
|
223
|
+
export declare function createSpecStory(projectDir: string, config: OpenPlanrConfig, specId: string, title: string, body: {
|
|
224
|
+
roleAction: string;
|
|
225
|
+
benefit: string;
|
|
226
|
+
scope?: string;
|
|
227
|
+
acceptanceCriteria?: string[];
|
|
228
|
+
}): Promise<{
|
|
229
|
+
id: string;
|
|
230
|
+
slug: string;
|
|
231
|
+
filePath: string;
|
|
232
|
+
}>;
|
|
233
|
+
export interface SpecTaskListing {
|
|
234
|
+
id: string;
|
|
235
|
+
slug: string;
|
|
236
|
+
title: string;
|
|
237
|
+
status: string;
|
|
238
|
+
type: string;
|
|
239
|
+
agent: string;
|
|
240
|
+
storyId: string;
|
|
241
|
+
filename: string;
|
|
242
|
+
filePath: string;
|
|
243
|
+
}
|
|
244
|
+
/**
|
|
245
|
+
* List T-NNN files inside a spec's tasks/ subdirectory.
|
|
246
|
+
*/
|
|
247
|
+
export declare function listSpecTasks(specDir: string): Promise<SpecTaskListing[]>;
|
|
248
|
+
export interface CreateSpecTaskInput {
|
|
249
|
+
storyId: string;
|
|
250
|
+
title: string;
|
|
251
|
+
type: 'UI' | 'Tech';
|
|
252
|
+
agent: string;
|
|
253
|
+
filesCreate?: string[];
|
|
254
|
+
filesModify?: string[];
|
|
255
|
+
filesPreserve?: string[];
|
|
256
|
+
objective?: string;
|
|
257
|
+
technicalSpec?: string;
|
|
258
|
+
testRequirements?: string;
|
|
259
|
+
}
|
|
260
|
+
/** Create a new T-NNN task file under the spec's tasks/ directory. */
|
|
261
|
+
export declare function createSpecTask(projectDir: string, config: OpenPlanrConfig, specId: string, input: CreateSpecTaskInput): Promise<{
|
|
262
|
+
id: string;
|
|
263
|
+
slug: string;
|
|
264
|
+
filePath: string;
|
|
265
|
+
}>;
|
|
266
|
+
/**
|
|
267
|
+
* Copy PNG mockup files into a spec's design/ directory. Updates the
|
|
268
|
+
* spec frontmatter `ui_files` to list the copied filenames.
|
|
269
|
+
*/
|
|
270
|
+
export declare function attachSpecDesigns(projectDir: string, config: OpenPlanrConfig, specId: string, pngPaths: string[]): Promise<{
|
|
271
|
+
copied: string[];
|
|
272
|
+
designDir: string;
|
|
273
|
+
}>;
|
|
274
|
+
/**
|
|
275
|
+
* Snapshot of all specs + their decomposition state. Used by `planr spec status`.
|
|
276
|
+
*/
|
|
277
|
+
export interface SpecStatusReport {
|
|
278
|
+
specCount: number;
|
|
279
|
+
specs: SpecListing[];
|
|
280
|
+
totalStories: number;
|
|
281
|
+
totalTasks: number;
|
|
282
|
+
}
|
|
283
|
+
export declare function getSpecStatus(projectDir: string, config: OpenPlanrConfig): Promise<SpecStatusReport>;
|
|
284
|
+
/**
|
|
285
|
+
* Validate that a spec is ready to hand off to openplanr-pipeline.
|
|
286
|
+
* Returns the list of issues, or empty array if ready.
|
|
287
|
+
*/
|
|
288
|
+
export declare function validateSpecForPromotion(projectDir: string, config: OpenPlanrConfig, specId: string): Promise<{
|
|
289
|
+
ready: boolean;
|
|
290
|
+
issues: string[];
|
|
291
|
+
}>;
|
|
292
|
+
//# sourceMappingURL=spec-service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spec-service.d.ts","sourceRoot":"","sources":["../../src/services/spec-service.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAGH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAa1D,gEAAgE;AAChE,wBAAgB,eAAe,CAAC,UAAU,EAAE,MAAM,EAAE,MAAM,EAAE,eAAe,GAAG,MAAM,CAEnF;AAED,2FAA2F;AAC3F,wBAAgB,UAAU,CACxB,UAAU,EAAE,MAAM,EAClB,MAAM,EAAE,eAAe,EACvB,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,MAAM,GACX,MAAM,CAER;AAED,0CAA0C;AAC1C,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAEzD;AAED,wCAAwC;AACxC,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAEvD;AAED,wEAAwE;AACxE,wBAAgB,gBAAgB,CAAC,OAA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