guardian-framework 0.1.103 → 0.1.104
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.js
CHANGED
|
@@ -3197,7 +3197,7 @@ __export(exports_package, {
|
|
|
3197
3197
|
bin: () => bin,
|
|
3198
3198
|
author: () => author
|
|
3199
3199
|
});
|
|
3200
|
-
var name = "guardian-framework", version = "0.1.
|
|
3200
|
+
var name = "guardian-framework", version = "0.1.104", description = "Token-optimized agentic framework scaffolder with pi-first architecture", type = "module", main = "dist/exports.js", exports, types = "dist/exports.d.ts", bin, files, engines, scripts, publishConfig, pi, repository, homepage = "https://github.com/arman-jalili/guardian-framework#readme", bugs, dependencies, devDependencies, keywords, author = "Arman Wolkensteiner-Jalili", license = "MIT", package_default;
|
|
3201
3201
|
var init_package = __esm(() => {
|
|
3202
3202
|
exports = {
|
|
3203
3203
|
".": {
|
package/dist/exports.js
CHANGED
|
@@ -1982,7 +1982,7 @@ __export(exports_package, {
|
|
|
1982
1982
|
bin: () => bin,
|
|
1983
1983
|
author: () => author
|
|
1984
1984
|
});
|
|
1985
|
-
var name = "guardian-framework", version = "0.1.
|
|
1985
|
+
var name = "guardian-framework", version = "0.1.104", description = "Token-optimized agentic framework scaffolder with pi-first architecture", type = "module", main = "dist/exports.js", exports, types = "dist/exports.d.ts", bin, files, engines, scripts, publishConfig, pi, repository, homepage = "https://github.com/arman-jalili/guardian-framework#readme", bugs, dependencies, devDependencies, keywords, author = "Arman Wolkensteiner-Jalili", license = "MIT", package_default;
|
|
1986
1986
|
var init_package = __esm(() => {
|
|
1987
1987
|
exports = {
|
|
1988
1988
|
".": {
|
package/package.json
CHANGED
|
@@ -121,15 +121,57 @@ function buildInScope(comp: ModuleComponent, primaryAcRows: AcRow[], implSteps:
|
|
|
121
121
|
];
|
|
122
122
|
}
|
|
123
123
|
|
|
124
|
-
/**
|
|
125
|
-
|
|
126
|
-
|
|
124
|
+
/** Supported project languages. */
|
|
125
|
+
type ProjectLanguage = "typescript" | "java" | "python" | "go" | "rust";
|
|
126
|
+
|
|
127
|
+
/** Detect project language at `cwd` by checking for build files. */
|
|
128
|
+
function detectLanguage(cwd?: string): ProjectLanguage {
|
|
129
|
+
if (!cwd) return "typescript";
|
|
127
130
|
try {
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
+
if (existsSync(join(cwd, "pom.xml")) || existsSync(join(cwd, "build.gradle")) || existsSync(join(cwd, "build.gradle.kts")))
|
|
132
|
+
return "java";
|
|
133
|
+
if (existsSync(join(cwd, "go.mod")))
|
|
134
|
+
return "go";
|
|
135
|
+
if (existsSync(join(cwd, "Cargo.toml")))
|
|
136
|
+
return "rust";
|
|
137
|
+
if (existsSync(join(cwd, "pyproject.toml")) || existsSync(join(cwd, "setup.py")) || existsSync(join(cwd, "requirements.txt")))
|
|
138
|
+
return "python";
|
|
139
|
+
return "typescript";
|
|
131
140
|
} catch {
|
|
132
|
-
return
|
|
141
|
+
return "typescript";
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
/** Language-specific file extension for implementation files. */
|
|
146
|
+
function implExtension(lang: ProjectLanguage): string {
|
|
147
|
+
switch (lang) {
|
|
148
|
+
case "java": return "java";
|
|
149
|
+
case "python": return "py";
|
|
150
|
+
case "go": return "go";
|
|
151
|
+
case "rust": return "rs";
|
|
152
|
+
default: return "ts";
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
/** Language-specific test directory base. */
|
|
157
|
+
function testBaseDirFromLang(lang: ProjectLanguage): string {
|
|
158
|
+
switch (lang) {
|
|
159
|
+
case "java": return "src/test/java";
|
|
160
|
+
case "python": return "tests";
|
|
161
|
+
case "go": return "tests";
|
|
162
|
+
case "rust": return "tests";
|
|
163
|
+
default: return "tests/unit";
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/** Language-specific test runner command hint. */
|
|
168
|
+
function testRunnerHintFromLang(lang: ProjectLanguage): string {
|
|
169
|
+
switch (lang) {
|
|
170
|
+
case "java": return "mvn test";
|
|
171
|
+
case "python": return "pytest";
|
|
172
|
+
case "go": return "go test ./...";
|
|
173
|
+
case "rust": return "cargo test";
|
|
174
|
+
default: return "bun test";
|
|
133
175
|
}
|
|
134
176
|
}
|
|
135
177
|
|
|
@@ -156,9 +198,10 @@ export function generateIssueMarkdown(
|
|
|
156
198
|
const inScope = buildInScope(comp, compAcs, implSteps, moduleId);
|
|
157
199
|
|
|
158
200
|
// Language-aware test paths
|
|
159
|
-
const
|
|
160
|
-
const
|
|
161
|
-
const
|
|
201
|
+
const lang = detectLanguage(cwd);
|
|
202
|
+
const ext = implExtension(lang);
|
|
203
|
+
const testBaseDir = testBaseDirFromLang(lang);
|
|
204
|
+
const testRunnerHint = testRunnerHintFromLang(lang);
|
|
162
205
|
|
|
163
206
|
const testLine = tdd
|
|
164
207
|
? ` - "update: ${testBaseDir}/ (failing tests already generated — make them pass)"`
|
|
@@ -252,7 +295,7 @@ ${yamlAcs}
|
|
|
252
295
|
All Acceptance Criteria in that file must be satisfied before this issue is closed.
|
|
253
296
|
Component focus: ${comp.name}.
|
|
254
297
|
CONCRETE IMPLEMENTATIONS MUST BE CREATED — interface stubs from the contract freeze
|
|
255
|
-
are not sufficient. Each domain service/aggregate needs a concrete .impl.${
|
|
298
|
+
are not sufficient. Each domain service/aggregate needs a concrete .impl.${ext} file.
|
|
256
299
|
|
|
257
300
|
file_changes:
|
|
258
301
|
- "create: src/${moduleId}/domain/"
|
|
@@ -307,7 +350,7 @@ ${stepsMarkdown}
|
|
|
307
350
|
> **Agent instructions:**
|
|
308
351
|
> 1. Open \`.pi/architecture/modules/${slice.module}.md\` — read the full Acceptance Criteria table
|
|
309
352
|
> 2. Identify which rows are your responsibility for **${comp.name}**
|
|
310
|
-
> 3. Create concrete implementation files (\`.impl.${
|
|
353
|
+
> 3. Create concrete implementation files (\`.impl.${ext}\`) in \`src/${moduleId}/\` — the interface stubs from the contract freeze are NOT enough
|
|
311
354
|
> 4. Each domain aggregate/service must have a working implementation with business logic
|
|
312
355
|
> 5. Verify each AC row is satisfied in \`src/\` before marking done
|
|
313
356
|
> 6. Run validators and create MR
|