mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-14 02:42:04 +08:00
fix: resolve Gemini-identified pipeline data flow inconsistencies
Fix 3 issues found by Gemini full-chain analysis:
1. (High) cross_cutting_specs path format mismatch: feature-index.json
uses relative paths ("role/file.md") but context-package uses full
paths (".workflow/.../role/file.md"). Changed action-planning-agent
to use endsWith() matching and read from context-package objects
instead of raw feature-index strings.
2. (Medium) Add explicit feature_index_path field to context-package
schema in context-search-agent, so task-generate-agent can read it
directly instead of hardcoding paths. Updated both single-module
and multi-module prompt templates with fallback logic.
3. (Medium) Expand synthesis_output in context-search-agent to include
feature_driven sub-object pointing to feature-index.json and
feature-specs/ directory alongside legacy synthesis-specification.md.
This commit is contained in:
@@ -338,7 +338,12 @@ if (dir_exists(brainstormDir)) {
|
||||
synthesis_output: {
|
||||
path: `${brainstormDir}/synthesis-specification.md`,
|
||||
exists: file_exists(`${brainstormDir}/synthesis-specification.md`),
|
||||
content: Read(`${brainstormDir}/synthesis-specification.md`) || null
|
||||
content: Read(`${brainstormDir}/synthesis-specification.md`) || null,
|
||||
// New feature-driven artifacts (preferred over legacy synthesis-specification.md)
|
||||
feature_driven: dir_exists(`${brainstormDir}/feature-specs`) ? {
|
||||
feature_index: `${brainstormDir}/feature-specs/feature-index.json`,
|
||||
feature_specs_dir: `${brainstormDir}/feature-specs/`
|
||||
} : undefined
|
||||
},
|
||||
// Feature index (optional - top level, matches action-planning-agent expected access pattern)
|
||||
feature_index: file_exists(`${brainstormDir}/feature-specs/feature-index.json`) ? {
|
||||
@@ -346,6 +351,10 @@ if (dir_exists(brainstormDir)) {
|
||||
exists: true,
|
||||
content: Read(`${brainstormDir}/feature-specs/feature-index.json`) || null
|
||||
} : undefined,
|
||||
// Convenience: direct path to feature-index.json (avoids hardcoding in task-generate-agent)
|
||||
feature_index_path: file_exists(`${brainstormDir}/feature-specs/feature-index.json`)
|
||||
? `${brainstormDir}/feature-specs/feature-index.json`
|
||||
: undefined,
|
||||
// Feature spec files (optional - individual feature specifications)
|
||||
feature_specs: dir_exists(`${brainstormDir}/feature-specs`)
|
||||
? glob(`${brainstormDir}/feature-specs/F-*-*.md`).map(file => ({
|
||||
@@ -479,13 +488,18 @@ Calculate risk level based on:
|
||||
"synthesis_output": {
|
||||
"path": ".workflow/WFS-xxx/.brainstorming/synthesis-specification.md",
|
||||
"exists": true,
|
||||
"content": "# Synthesis Specification\n\n## Cross-Role Integration\n..."
|
||||
"content": "# Synthesis Specification\n\n## Cross-Role Integration\n...",
|
||||
"feature_driven": {
|
||||
"feature_index": ".workflow/WFS-xxx/.brainstorming/feature-specs/feature-index.json",
|
||||
"feature_specs_dir": ".workflow/WFS-xxx/.brainstorming/feature-specs/"
|
||||
}
|
||||
},
|
||||
"feature_index": {
|
||||
"path": ".workflow/WFS-xxx/.brainstorming/feature-specs/feature-index.json",
|
||||
"exists": true,
|
||||
"content": "{\"version\":\"1.0\",\"features\":[...]}"
|
||||
},
|
||||
"feature_index_path": ".workflow/WFS-xxx/.brainstorming/feature-specs/feature-index.json",
|
||||
"feature_specs": [
|
||||
{
|
||||
"path": ".workflow/WFS-xxx/.brainstorming/feature-specs/F-001-auth.md",
|
||||
|
||||
Reference in New Issue
Block a user