@aiwg/cli 2026.11.5 → 2026.11.7
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/agentic/code/providers/model-capabilities.v1.json +9 -9
- package/bin/aiwg.mjs +6 -4
- package/dist/src/activity-log/cli.js +1 -1
- package/dist/src/agents/agent-deployer.js +1 -1
- package/dist/src/artifacts/audit/types.js +1 -1
- package/dist/src/artifacts/browser-export.js +1 -0
- package/dist/src/artifacts/discover-facets.js +1 -1
- package/dist/src/artifacts/enrichment/prompt.js +1 -1
- package/dist/src/artifacts/enrichment/types.js +1 -1
- package/dist/src/artifacts/fortemi-core-query-adapter.js +2 -0
- package/dist/src/artifacts/index-builder.js +1 -0
- package/dist/src/artifacts/query-engine-discover-output.js +1 -0
- package/dist/src/artifacts/query-engine-discover.js +2 -2
- package/dist/src/artifacts/query-engine-scoring.js +7 -0
- package/dist/src/artifacts/template-output-kind.js +10 -0
- package/dist/src/artifacts/types.js +1 -1
- package/dist/src/artifacts/views/definition.js +1 -1
- package/dist/src/artifacts/views/types.js +1 -1
- package/dist/src/catalog/cli.js +1 -1
- package/dist/src/catalog/cli.mjs +1 -1
- package/dist/src/catalog/loader.js +1 -1
- package/dist/src/catalog/loader.mjs +1 -1
- package/dist/src/catalog/types.js +1 -1
- package/dist/src/cli/cli-extension-loader.js +19 -5
- package/dist/src/cli/cli-extension-paths.js +65 -0
- package/dist/src/cli/handlers/best-practices-audit.js +1 -1
- package/dist/src/cli/handlers/dataset.js +11 -2
- package/dist/src/cli/handlers/help.js +3 -4
- package/dist/src/cli/handlers/index.js +1 -1
- package/dist/src/cli/handlers/marketplace-plugin-search.js +37 -0
- package/dist/src/cli/handlers/marketplace.js +3 -1
- package/dist/src/cli/handlers/models.js +1 -1
- package/dist/src/cli/handlers/ralph-launcher.js +8 -2
- package/dist/src/cli/handlers/ralph.js +1 -1
- package/dist/src/cli/handlers/runtime-info.js +1 -1
- package/dist/src/cli/handlers/scaffolding.js +2 -2
- package/dist/src/cli/handlers/script-runner.js +1 -1
- package/dist/src/cli/handlers/sdlc-accelerate.js +1 -1
- package/dist/src/cli/handlers/subcommands-bundles.js +1 -1
- package/dist/src/cli/handlers/subcommands-list-format.js +19 -1
- package/dist/src/cli/handlers/types.js +1 -1
- package/dist/src/cli/handlers/update.js +26 -12
- package/dist/src/cli/handlers/use.js +6 -5
- package/dist/src/cli/handlers/utilities.js +1 -1
- package/dist/src/cli/handlers/version.js +1 -1
- package/dist/src/cli/handlers/workspace.js +1 -1
- package/dist/src/cli/handlers/writing.js +7 -1
- package/dist/src/cli/help-generator.js +9 -11
- package/dist/src/cli/hooks/builtin/activity-log-hook.js +1 -1
- package/dist/src/cli/router.js +1 -1
- package/dist/src/cli/workflow-orchestrator.js +1 -1
- package/dist/src/config/worker-context.js +37 -7
- package/dist/src/config/worker-parallelism.js +11 -0
- package/dist/src/contributors/detect.js +1 -1
- package/dist/src/contributors/discover.js +1 -1
- package/dist/src/contributors/heuristic.js +1 -1
- package/dist/src/contributors/index.js +1 -1
- package/dist/src/contributors/types.js +1 -1
- package/dist/src/contributors/validation.js +1 -1
- package/dist/src/dataset/backend-selection.d.ts +3 -0
- package/dist/src/dataset/backend-selection.js +11 -0
- package/dist/src/dataset/contract-range.d.ts +7 -0
- package/dist/src/dataset/contract-range.js +55 -0
- package/dist/src/dataset/fortemi-execution-bridge.d.ts +2 -0
- package/dist/src/dataset/fortemi-execution-bridge.js +12 -1
- package/dist/src/dataset/index.d.ts +2 -0
- package/dist/src/dataset/index.js +2 -0
- package/dist/src/dataset/orchestration-service.d.ts +1 -1
- package/dist/src/dataset/orchestration-service.js +7 -8
- package/dist/src/dataset/orchestration-types.d.ts +2 -0
- package/dist/src/dataset/service-binding-checkpoints.d.ts +10 -0
- package/dist/src/dataset/service-binding-checkpoints.js +26 -0
- package/dist/src/dataset/service-binding-contract.d.ts +46 -0
- package/dist/src/dataset/service-binding-contract.js +25 -0
- package/dist/src/dataset/service-binding-registry.d.ts +12 -0
- package/dist/src/dataset/service-binding-registry.js +118 -0
- package/dist/src/effects/worker-delivery.js +83 -0
- package/dist/src/extensions/capability-index.js +1 -1
- package/dist/src/extensions/commands/definitions.js +2 -2
- package/dist/src/extensions/deployment-registration.js +1 -1
- package/dist/src/extensions/index.js +1 -1
- package/dist/src/extensions/loader.js +1 -1
- package/dist/src/extensions/manifest.js +27 -9
- package/dist/src/extensions/project-local-activity.js +1 -1
- package/dist/src/extensions/project-local-discovery.js +2 -2
- package/dist/src/extensions/project-local-doctor.js +9 -4
- package/dist/src/extensions/project-local-promote.js +3 -3
- package/dist/src/extensions/project-local-remove.js +3 -3
- package/dist/src/extensions/project-local-scaffold.js +1 -1
- package/dist/src/extensions/project-quickref-discovery.js +11 -0
- package/dist/src/extensions/project-quickref.js +4 -7
- package/dist/src/extensions/registry.js +1 -1
- package/dist/src/extensions/shadow-resolver.js +1 -1
- package/dist/src/extensions/types.js +1 -1
- package/dist/src/extensions/upstream-registry.js +1 -1
- package/dist/src/extensions/validation.js +1 -1
- package/dist/src/intake/git-history-analyzer.js +1 -1
- package/dist/src/kb/cli.js +1 -1
- package/dist/src/marketplace/plugin-directory.js +36 -0
- package/dist/src/marketplace/plugin-search.js +180 -0
- package/dist/src/mcp/cli.mjs +2 -2
- package/dist/src/mcp/helpers.mjs +1 -1
- package/dist/src/mcp/http-tools.mjs +8 -6
- package/dist/src/mcp/http-transport.mjs +3 -1
- package/dist/src/mcp/server.mjs +1 -1
- package/dist/src/mcp/tools/command-run.mjs +1 -1
- package/dist/src/mcp/tools/discovery.mjs +1 -1
- package/dist/src/mcp/tools/subsystems.mjs +1 -1
- package/dist/src/mcp/tools/worker-invoke.mjs +71 -23
- package/dist/src/mcp/tools/worker-launch-ledger.mjs +33 -0
- package/dist/src/mcp/tools/worker-local-only-preflight.mjs +79 -0
- package/dist/src/mcp/tools/worker-recorded-launch.mjs +26 -0
- package/dist/src/mcp/tools/worker-stdin-runtime.mjs +33 -6
- package/dist/src/mcp/tools/worker-verify-deliver-schema.mjs +49 -0
- package/dist/src/mcp/tools/worker-verify-deliver.mjs +25 -0
- package/dist/src/models/catalog-policy.js +2 -2
- package/dist/src/models/conductor-data-policy.mjs +83 -14
- package/dist/src/models/config-loader.js +2 -2
- package/dist/src/models/index.js +2 -2
- package/dist/src/models/local-endpoint-models.js +155 -0
- package/dist/src/models/model-capabilities.v1.json +9 -9
- package/dist/src/models/model-discovery.js +9 -5
- package/dist/src/models/opencode-worker-model.mjs +16 -0
- package/dist/src/models/resolver.js +2 -2
- package/dist/src/models/worker-installation.mjs +5 -3
- package/dist/src/models/worker-plan.js +1 -1
- package/dist/src/plugin/plugin-installer.js +2 -2
- package/dist/src/plugin/registry-validator.js +2 -2
- package/dist/src/plugin/skill-command-translator.js +1 -1
- package/dist/src/providers/deployment-input-session.d.mts +2 -0
- package/dist/src/providers/deployment-input-session.mjs +38 -0
- package/dist/src/rlm/cache/hash.js +1 -1
- package/dist/src/rlm/cache/store.js +1 -1
- package/dist/src/rlm/cache/types.js +1 -1
- package/dist/src/serve/worker-invocation-preparation.js +54 -22
- package/dist/src/serve/worker-invocation.js +25 -8
- package/dist/src/serve/worker-shell-prompt.d.mts +6 -0
- package/dist/src/serve/worker-shell-prompt.mjs +78 -0
- package/dist/src/skills/run.js +0 -11
- package/dist/src/smiths/agentsmith/generator.js +1 -1
- package/dist/src/smiths/context-pipeline/index.js +1 -1
- package/dist/src/smiths/context-pipeline/provider-policy.js +1 -1
- package/dist/src/smiths/context-pipeline/types.js +1 -1
- package/dist/src/smiths/mcpsmith/analyzers/cli-analyzer.js +2 -2
- package/dist/src/smiths/mcpsmith/generator.js +2 -2
- package/dist/src/smiths/mcpsmith/index.js +2 -2
- package/dist/src/smiths/mcpsmith/types.js +2 -2
- package/dist/src/smiths/skillsmith/collision-detector.js +1 -1
- package/dist/src/smiths/skillsmith/namespace-adapter.js +1 -1
- package/dist/src/smiths/toolsmith/runtime-discovery.mjs +2 -2
- package/dist/src/smiths/toolsmith/types.js +2 -2
- package/dist/src/storage/backends/fortemi.js +1 -1
- package/dist/src/storage/backends/fs.js +1 -1
- package/dist/src/storage/backends/logseq.js +1 -1
- package/dist/src/storage/backends/obsidian.js +1 -1
- package/dist/src/storage/cli.js +2 -2
- package/dist/src/storage/config.js +1 -1
- package/dist/src/storage/index.js +1 -1
- package/dist/src/storage/subsystem-cli.js +1 -1
- package/dist/src/storage/types.js +1 -1
- package/dist/src/testing/generators/test-case-generator.js +1 -1
- package/dist/src/writing/campaign-patterns.js +96 -0
- package/dist/src/writing/campaign-report.js +41 -0
- package/dist/src/writing/contextual-diagnostics.js +29 -5
- package/dist/src/writing/current-patterns.catalogue.json +87 -0
- package/dist/src/writing/current-patterns.js +99 -0
- package/dist/src/writing/prose-mask.js +80 -0
- package/dist/src/writing/structural-patterns.js +109 -0
- package/dist/src/writing/validation-campaign.js +19 -0
- package/dist/src/writing/validation-engine.js +18 -11
- package/dist/src/writing/validation-rules.js +4 -3
- package/package.json +11 -1
- package/schemas/dataset/service-binding.v1.schema.json +70 -0
- package/schemas/models/model-catalog.v1.schema.json +6 -3
- package/tools/agents/providers/base-models-platforms.mjs +87 -48
- package/tools/agents/providers/conductor-data-guard.mjs +1 -1
- package/tools/agents/providers/rule-deployment-corpus-inputs.mjs +19 -0
- package/tools/agents/providers/rule-deployment-input-session.mjs +40 -0
- package/tools/agents/providers/rule-deployment-prepare.mjs +15 -6
- package/tools/plugin/package-plugins.mjs +2 -0
- package/tools/ralph-external/lib/mcp-worker-launch.mjs +67 -0
- package/tools/ralph-external/lib/opencode-adapter.mjs +9 -7
- package/tools/ralph-external/lib/trusted-verification.mjs +1021 -0
- package/tools/ralph-external/lib/typed-stop-delivery.mjs +55 -0
- package/tools/ralph-external/lib/verification-isolation.mjs +509 -0
- package/tools/ralph-external/lib/worker-context.mjs +3 -3
- package/tools/ralph-external/lib/worker-delivery-guards.mjs +141 -0
- package/tools/ralph-external/lib/worker-delivery-record.mjs +15 -0
- package/tools/ralph-external/lib/worker-final.mjs +4 -1
- package/tools/ralph-external/lib/worker-isolation-status.mjs +3 -0
- package/tools/ralph-external/lib/worker-launch-cli.mjs +8 -0
- package/tools/ralph-external/lib/worker-local-only-paths.mjs +45 -0
- package/tools/ralph-external/lib/worker-prompt.mjs +4 -1
- package/tools/ralph-external/lib/worker-retry-evidence.mjs +2 -1
- package/tools/ralph-external/lib/worker-run-directory-refusal.mjs +2 -1
- package/tools/ralph-external/lib/worker-run-directory.mjs +45 -0
- package/tools/ralph-external/lib/worker-unit-cleanup.mjs +10 -2
- package/tools/ralph-external/lib/worker-verification-cli.mjs +164 -0
- package/tools/ralph-external/lib/worktree-preparation.mjs +417 -0
- package/tools/ralph-external/session-launcher.mjs +8 -15
- package/vscode-extension/schemas/aiwg.config.v1.json +27 -0
|
@@ -28,6 +28,8 @@ import { existsSync, mkdirSync, writeFileSync, readFileSync, rmSync, readdirSync
|
|
|
28
28
|
import { getProviderConfig } from '../agent-spawn.js';
|
|
29
29
|
import { AiwgError, EXIT_CODES } from '../errors.js';
|
|
30
30
|
import { projectAiwgPath } from '../../config/project-artifacts.js';
|
|
31
|
+
/** Wall budget for capturing a managed Ralph child's stable identity (#4153). */
|
|
32
|
+
export const MANAGED_IDENTITY_BUDGET_MS = 2000;
|
|
31
33
|
/**
|
|
32
34
|
* Get the path to the external Ralph orchestrator
|
|
33
35
|
*/
|
|
@@ -258,8 +260,12 @@ export async function launchExternalRalph(frameworkRoot, projectRoot, options) {
|
|
|
258
260
|
let managedAdmission;
|
|
259
261
|
if (options.managedAdmission) {
|
|
260
262
|
const { sampleWorkerIdentity, createWorkerIdentityCapture } = await import(join(frameworkRoot, 'tools', 'ralph-external', 'process-monitor.mjs'));
|
|
261
|
-
|
|
262
|
-
|
|
263
|
+
// Two stable samples are needed. A loaded host can delay the 10 ms poll by
|
|
264
|
+
// hundreds of milliseconds, so a 250 ms window failed healthy launches
|
|
265
|
+
// (#4153). The child's own exit is checked every pass, so a wider window
|
|
266
|
+
// cannot bind a reused PID.
|
|
267
|
+
const capture = createWorkerIdentityCapture({ timeoutMs: MANAGED_IDENTITY_BUDGET_MS });
|
|
268
|
+
const identityDeadline = process.hrtime.bigint() + BigInt(MANAGED_IDENTITY_BUDGET_MS) * 1000000n;
|
|
263
269
|
let identity;
|
|
264
270
|
while (!identity && process.hrtime.bigint() < identityDeadline) {
|
|
265
271
|
if ((child.exitCode !== null && child.exitCode !== undefined) || child.signalCode)
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Uses external Ralph supervisor for crash-resilient background execution.
|
|
6
6
|
* Falls back to internal scripts when --internal flag is used.
|
|
7
7
|
*
|
|
8
|
-
* @implements
|
|
8
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
9
9
|
* @implements @.aiwg/working/issue-ralph-external-completion.md
|
|
10
10
|
* @tests @test/unit/cli/handlers/ralph.test.ts
|
|
11
11
|
* @issue #33, #275
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Runtime environment discovery and tool catalog management.
|
|
5
5
|
* Provides information about available tools, system resources, and runtime environment.
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @source @src/cli/router.ts
|
|
9
9
|
* @issue #33
|
|
10
10
|
*/
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Handlers for code generation and project scaffolding commands.
|
|
5
5
|
* Each handler delegates to existing scripts in tools/scaffolding/.
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @tests @test/unit/cli/handlers/scaffolding.test.ts
|
|
9
9
|
* @issue #33
|
|
10
10
|
*/
|
|
@@ -52,7 +52,7 @@ class AddCommandHandler extends ScaffoldingHandler {
|
|
|
52
52
|
console.warn('\x1b[33m⚠ DEPRECATED:\x1b[0m `aiwg add-command` is deprecated. ' +
|
|
53
53
|
'Use `aiwg add-skill` instead.\n' +
|
|
54
54
|
' Commands are now generated from skills at deploy time.\n' +
|
|
55
|
-
' See:
|
|
55
|
+
' See: docs/extensions/extension-types.md\n');
|
|
56
56
|
return super.execute(ctx);
|
|
57
57
|
}
|
|
58
58
|
}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Utility for running framework scripts from handlers.
|
|
5
5
|
* Script execution utility for CLI handlers.
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @source @src/cli/router.ts
|
|
9
9
|
* @issue #33
|
|
10
10
|
*/
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* provider's unrestricted-mode flag, and --params for arbitrary provider-specific
|
|
10
10
|
* args. IDE-integrated providers (copilot, cursor, etc.) receive guidance instead.
|
|
11
11
|
*
|
|
12
|
-
* @implements
|
|
12
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
13
13
|
* @issue #485
|
|
14
14
|
*/
|
|
15
15
|
import { spawn } from 'child_process';
|
|
@@ -2,7 +2,7 @@ import { getFrameworkRoot } from "../../channel/manager.mjs";
|
|
|
2
2
|
/**
|
|
3
3
|
* Promote handler — graduate a project-local bundle to upstream or to a
|
|
4
4
|
* private corpus path. Implements the design at
|
|
5
|
-
*
|
|
5
|
+
* @docs/customization/project-local-lifecycle.md (#1049).
|
|
6
6
|
*
|
|
7
7
|
* Usage:
|
|
8
8
|
* aiwg promote <name> # default: --to upstream
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
// Focused subcommand handlers preserving the public facade.
|
|
2
|
+
import { readFileSync } from 'node:fs';
|
|
3
|
+
import { basename, extname } from 'node:path';
|
|
4
|
+
import { findArtifactFiles } from '../../artifacts/index-files.js';
|
|
5
|
+
import { parseFlowDoc } from '../../artifacts/index-builder.js';
|
|
1
6
|
import { buildUpstreamRegistry } from "../../extensions/upstream-registry.js";
|
|
2
7
|
import { resolveShadows } from "../../extensions/shadow-resolver.js";
|
|
3
8
|
/**
|
|
@@ -20,7 +25,20 @@ export function formatProjectLocalOnly(result) {
|
|
|
20
25
|
for (const b of result.bundles) {
|
|
21
26
|
output += ` ${b.id} [project] [${b.type}] v${b.manifest.version}\n`;
|
|
22
27
|
output += ` Path: ${b.localPath}\n`;
|
|
23
|
-
output += ` Description: ${b.manifest.description.slice(0, 80)}${b.manifest.description.length > 80 ? '...' : ''}\n
|
|
28
|
+
output += ` Description: ${b.manifest.description.slice(0, 80)}${b.manifest.description.length > 80 ? '...' : ''}\n`;
|
|
29
|
+
// Match project graph classification, including custom flow entry directories.
|
|
30
|
+
const flows = findArtifactFiles(b.artifactPath, ['.yaml', '.yml']).flatMap(file => {
|
|
31
|
+
try {
|
|
32
|
+
const flow = parseFlowDoc(readFileSync(file, 'utf8'), file);
|
|
33
|
+
return flow?.type === 'flow' ? [flow.name ?? basename(file, extname(file))] : [];
|
|
34
|
+
}
|
|
35
|
+
catch {
|
|
36
|
+
return [];
|
|
37
|
+
}
|
|
38
|
+
}).sort();
|
|
39
|
+
if (flows.length)
|
|
40
|
+
output += ` Flows (${flows.length}): ${flows.join(', ')}\n`;
|
|
41
|
+
output += '\n';
|
|
24
42
|
}
|
|
25
43
|
if (result.errors.length > 0) {
|
|
26
44
|
output += '\nValidation errors:\n';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Defines the interface for CLI command handlers extracted from the monolithic router.
|
|
5
5
|
*
|
|
6
|
-
* @implements
|
|
6
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
7
7
|
* @source @src/cli/router.ts
|
|
8
8
|
* @issue #33
|
|
9
9
|
*/
|
|
@@ -8,6 +8,7 @@ import { bundleCopyArgs } from './bundle-deployment-mode.js';
|
|
|
8
8
|
import { bundleProviders, pruneUndeclaredBundles, pruneAfterScopedDeployments } from './bundle-reconciliation.js';
|
|
9
9
|
import { readAiwgConfig } from '../../config/aiwg-config.js';
|
|
10
10
|
import { withInstalledSelection } from '../../config/installed-selection.js';
|
|
11
|
+
import { withDeploymentInputSession } from '../../providers/deployment-input-session.mjs';
|
|
11
12
|
import { REGISTRY_ID_TO_USE_NAME } from '../../config/framework-aliases.js';
|
|
12
13
|
/**
|
|
13
14
|
* Read the installed frameworks from the on-disk registry.
|
|
@@ -131,17 +132,29 @@ export const updateHandler = {
|
|
|
131
132
|
}
|
|
132
133
|
// Step 3: Re-deploy each installed framework
|
|
133
134
|
const results = [];
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
135
|
+
// One immutable corpus per update; target/config inputs remain per-pass.
|
|
136
|
+
let cleanupFailed = false;
|
|
137
|
+
try {
|
|
138
|
+
await withDeploymentInputSession(async () => {
|
|
139
|
+
for (const { fw, args } of deployments) {
|
|
140
|
+
console.log(`Re-deploying ${fw}...`);
|
|
141
|
+
const deploy = () => useFrameworkHandler.execute({
|
|
142
|
+
...ctx,
|
|
143
|
+
args: [fw, ...args],
|
|
144
|
+
});
|
|
145
|
+
const result = await (deployAll ? deploy() : withInstalledSelection(ctx.cwd, installed, deploy));
|
|
146
|
+
results.push({ framework: fw, exitCode: result.exitCode });
|
|
147
|
+
if (result.exitCode !== 0) {
|
|
148
|
+
console.error(`Warning: Failed to re-deploy ${fw}: ${result.message || `exit ${result.exitCode}`}`);
|
|
149
|
+
}
|
|
150
|
+
}
|
|
139
151
|
});
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
if (
|
|
143
|
-
|
|
144
|
-
|
|
152
|
+
}
|
|
153
|
+
catch (error) {
|
|
154
|
+
if (results.length !== deployments.length)
|
|
155
|
+
throw error;
|
|
156
|
+
cleanupFailed = true;
|
|
157
|
+
console.error(`Warning: Deployment input cleanup failed: ${error instanceof Error ? error.message : String(error)}`);
|
|
145
158
|
}
|
|
146
159
|
if (!deployAll)
|
|
147
160
|
pruneFailures += await pruneAfterScopedDeployments(ctx.cwd, await readAiwgConfig(ctx.cwd), providerArgs[1], ctx.frameworkRoot);
|
|
@@ -157,10 +170,11 @@ export const updateHandler = {
|
|
|
157
170
|
console.log('');
|
|
158
171
|
console.log(`Updated: ${succeeded.length}/${results.length}`);
|
|
159
172
|
return {
|
|
160
|
-
exitCode: failed.length > 0 || pruneFailures ? 1 : 0,
|
|
173
|
+
exitCode: failed.length > 0 || pruneFailures || cleanupFailed ? 1 : 0,
|
|
161
174
|
message: failed.length > 0
|
|
162
175
|
? `Some frameworks failed to update: ${failed.map(f => f.framework).join(', ')}`
|
|
163
|
-
:
|
|
176
|
+
: cleanupFailed ? 'Deployment input cleanup failed'
|
|
177
|
+
: `Successfully updated ${succeeded.length} framework(s)`,
|
|
164
178
|
};
|
|
165
179
|
},
|
|
166
180
|
};
|
|
@@ -9,7 +9,7 @@ import { hermesHookAcceptanceNextStep, readHermesHookAcceptance } from '../../sm
|
|
|
9
9
|
* Deploys AIWG frameworks (SDLC, Marketing, Writing) to the current project.
|
|
10
10
|
* After deployment, registers deployed extensions in the extension registry.
|
|
11
11
|
*
|
|
12
|
-
* @implements
|
|
12
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
13
13
|
* @implements #56, #57
|
|
14
14
|
* @source @src/cli/router.ts
|
|
15
15
|
* @issue #33
|
|
@@ -46,6 +46,7 @@ export { getAllAddons, getAllExtensions, USE_ALL_DISALLOW, USE_ALL_EXTENSIONS_DI
|
|
|
46
46
|
import { checkCollisions, formatCollisionReport, hasBlockingCollisions, } from '../../smiths/skillsmith/collision-detector.js';
|
|
47
47
|
import { discoverProjectLocalBundles, formatProjectLocalTargetErrors, } from '../../extensions/project-local-discovery.js';
|
|
48
48
|
import { PROJECT_LOCAL_TYPE_TO_DIR } from '../../extensions/project-local-paths.js';
|
|
49
|
+
import { formatManifestValidationError } from '../../extensions/manifest.js';
|
|
49
50
|
import { buildUpstreamRegistry } from '../../extensions/upstream-registry.js';
|
|
50
51
|
import { resolveShadows, formatShadowReport, } from '../../extensions/shadow-resolver.js';
|
|
51
52
|
import { appendProjectLocalActivity, emitDiscoverEventsDeduped, } from '../../extensions/project-local-activity.js';
|
|
@@ -69,7 +70,7 @@ let machineReadableUseDepth = 0;
|
|
|
69
70
|
// rule-delivery transaction. Other built-ins retain their serial deploy path.
|
|
70
71
|
const PREPARABLE_BUILTIN_PROVIDERS = new Set(['claude', 'codex', 'cursor', 'hermes', 'pi', 'warp']);
|
|
71
72
|
// Context-pipeline: emits WORKSPACE.md + AIWG.md + provider adapters last.
|
|
72
|
-
// for non-Claude providers per ADR-1 (
|
|
73
|
+
// for non-Claude providers per ADR-1 (docs/configuration/workspace-context.md).
|
|
73
74
|
// Distinct from agentsmith (which creates subagent personas).
|
|
74
75
|
import { generate as generateContextFiles, discoverDeployedArtifacts, } from '../../smiths/context-pipeline/index.js';
|
|
75
76
|
import { verifyModelWrapperDeployment } from '../../models/wrapper-deployment.js';
|
|
@@ -1187,8 +1188,8 @@ async function deployOneProjectLocalBundle(opts) {
|
|
|
1187
1188
|
async function deployProjectLocalBundles(opts) {
|
|
1188
1189
|
const { ctx, frameworkRoot, projectDir, provider, target, dryRun, verbose, quiet, onlyBundleId, modelArgs = [], } = opts;
|
|
1189
1190
|
const discovery = await discoverProjectLocalBundles(projectDir);
|
|
1190
|
-
|
|
1191
|
-
ui.warn(
|
|
1191
|
+
for (const error of discovery.errors) {
|
|
1192
|
+
ui.warn(`${error.path}: ${formatManifestValidationError(error)} — run 'aiwg list --project-local' for details`);
|
|
1192
1193
|
}
|
|
1193
1194
|
const targetBundles = onlyBundleId
|
|
1194
1195
|
? discovery.bundles.filter(b => b.id === onlyBundleId)
|
|
@@ -3108,7 +3109,7 @@ export class UseHandler {
|
|
|
3108
3109
|
}
|
|
3109
3110
|
}
|
|
3110
3111
|
}
|
|
3111
|
-
if (totalDeployed > 0 &&
|
|
3112
|
+
if (totalDeployed > 0 && !dryRunSingle) {
|
|
3112
3113
|
try {
|
|
3113
3114
|
await rebuildExternalBundleIndex(projectDir, 'project', verboseSingle);
|
|
3114
3115
|
if (scopeSingle === 'user') {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Handlers for utility commands including card prefilling, contribution workflow,
|
|
5
5
|
* metadata validation, health diagnostics, and update checking.
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @source @src/cli/router.ts
|
|
9
9
|
* @tests @test/unit/cli/handlers/utilities.test.ts
|
|
10
10
|
* @issue #33, #342
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Displays version and channel information for the AIWG installation.
|
|
5
5
|
* Supports --verbose / --json for full environment fingerprint (Phase 4.5 #925).
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @source @src/cli/router.ts
|
|
9
9
|
* @issue #33, #925
|
|
10
10
|
*/
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Handlers for workspace health, migration, and rollback operations.
|
|
5
5
|
* Delegates to existing CLI scripts in tools/cli/.
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @source @src/cli/router.ts
|
|
9
9
|
* @issue #33
|
|
10
10
|
*/
|
|
@@ -10,7 +10,10 @@ import { resolveOutputModes } from '../../output-modes/registry.js';
|
|
|
10
10
|
import { resolveProjectAiwgDirForWrite } from '../../config/project-artifacts.js';
|
|
11
11
|
import { readAiwgConfig } from '../../config/aiwg-config.js';
|
|
12
12
|
import { resolveArtifactOutputs, recordArtifactOutputProvenance } from '../../artifacts/output-policy.js';
|
|
13
|
+
import { campaignReport } from '../../writing/campaign-report.js';
|
|
13
14
|
async function execute(ctx) {
|
|
15
|
+
if (ctx.args.includes('--cross'))
|
|
16
|
+
return { exitCode: 0, rawOutput: true, message: await campaignReport(ctx.cwd, ctx.args) };
|
|
14
17
|
const [action, ...args] = ctx.args;
|
|
15
18
|
if (!['plan', 'proofread'].includes(action))
|
|
16
19
|
throw new Error('Expected writing plan or proofread');
|
|
@@ -107,6 +110,7 @@ export const writingHandler = {
|
|
|
107
110
|
return { exitCode: 0, rawOutput: true, message: [
|
|
108
111
|
'aiwg writing plan --brief <brief.json> --profile <id> [--channel article|social|email|engineering|conversation] [--output <new-file>]',
|
|
109
112
|
'aiwg writing proofread --brief <brief.json> --profile <id> [--correction <id>]... [--output <new-file>]',
|
|
113
|
+
'aiwg writing --cross [--json] <file-or-dir>... Review one campaign without writing files',
|
|
110
114
|
'Proofreading applies listed author-authorized corrections (all by default), without a model or voice rewrite.',
|
|
111
115
|
'Canonical output and a receipt are written first. Optional local exports require a new file and project-policy allowance.',
|
|
112
116
|
'Mode selections are inspected; this command does not claim provider response interception or publication approval.',
|
|
@@ -115,7 +119,9 @@ export const writingHandler = {
|
|
|
115
119
|
async execute(ctx) { try {
|
|
116
120
|
return await execute(ctx);
|
|
117
121
|
}
|
|
118
|
-
catch {
|
|
122
|
+
catch (error) {
|
|
123
|
+
if (error instanceof RangeError && error.message.startsWith('Campaign exceeds'))
|
|
124
|
+
return { exitCode: 1, message: error.message };
|
|
119
125
|
return { exitCode: 1, message: 'Writing operation failed. Check the brief, profile, correction IDs, output destination and artifact policy. Private source text is omitted; any completed canonical artifacts remain available.' };
|
|
120
126
|
} },
|
|
121
127
|
};
|
|
@@ -2,12 +2,13 @@
|
|
|
2
2
|
* Help Generator
|
|
3
3
|
*
|
|
4
4
|
* Dynamically generates CLI help text from the extension registry.
|
|
5
|
-
*
|
|
5
|
+
* Shares provider help between the launcher and command handler.
|
|
6
6
|
*
|
|
7
|
-
* @implements
|
|
7
|
+
* @implements @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
8
8
|
* @tests @test/unit/cli/help-generator.test.ts
|
|
9
9
|
* @version 1.0.0
|
|
10
10
|
*/
|
|
11
|
+
import { listProviderDefinitions } from '../providers/provider-definitions.js';
|
|
11
12
|
/**
|
|
12
13
|
* Category display order and titles
|
|
13
14
|
*
|
|
@@ -82,15 +83,7 @@ export function generateHelp(registry) {
|
|
|
82
83
|
}
|
|
83
84
|
// Platform options
|
|
84
85
|
lines.push('Platform Options (--provider):');
|
|
85
|
-
lines.push(
|
|
86
|
-
lines.push(' copilot GitHub Copilot');
|
|
87
|
-
lines.push(' factory Factory AI');
|
|
88
|
-
lines.push(' codex / openai OpenAI Codex');
|
|
89
|
-
lines.push(' cursor Cursor IDE');
|
|
90
|
-
lines.push(' opencode OpenCode');
|
|
91
|
-
lines.push(' warp Warp Terminal');
|
|
92
|
-
lines.push(' devin Devin Desktop');
|
|
93
|
-
lines.push(' windsurf Deprecated alias for devin');
|
|
86
|
+
lines.push(` ${generateProviderHelp()}`);
|
|
94
87
|
lines.push('');
|
|
95
88
|
// Examples
|
|
96
89
|
lines.push('Examples:');
|
|
@@ -176,4 +169,9 @@ function formatCommandName(cmd) {
|
|
|
176
169
|
// Show command name with first alias
|
|
177
170
|
return `${cmd.id}, ${aliases[0]}`;
|
|
178
171
|
}
|
|
172
|
+
/** Provider list shared by both production help paths, including generic. */
|
|
173
|
+
export function generateProviderHelp() {
|
|
174
|
+
const providers = listProviderDefinitions();
|
|
175
|
+
return `Providers: ${providers.length} — ${providers.map(({ id, status }) => status === 'experimental' ? `${id} (experimental)` : id).join(', ')} (default: claude; aliases: agy → antigravity, devin → windsurf, oh-my-pi → omp, openai → codex)`;
|
|
176
|
+
}
|
|
179
177
|
//# sourceMappingURL=help-generator.js.map
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
* Failures are non-blocking: if the entry can't be written, we log to
|
|
12
12
|
* stderr and let the primary command's success stand.
|
|
13
13
|
*
|
|
14
|
-
* @design
|
|
14
|
+
* @design @docs/storage/overview.md
|
|
15
15
|
* @issue #934
|
|
16
16
|
* @issue #978
|
|
17
17
|
*/
|
package/dist/src/cli/router.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* Integrates hook system for lifecycle events.
|
|
7
7
|
*
|
|
8
8
|
* @implements @.aiwg/requirements/use-cases/UC-004-extension-system.md
|
|
9
|
-
* @architecture
|
|
9
|
+
* @architecture @docs/architecture/cli/adr-001-unified-extension-registry.md
|
|
10
10
|
* @tests @test/unit/cli/router.test.ts
|
|
11
11
|
* @issue #33
|
|
12
12
|
* @issue #58
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Supports batch processing, watch mode, auto-fix, and multiple output formats.
|
|
6
6
|
*
|
|
7
7
|
* @implements @.aiwg/requirements/use-cases/UC-001-validate-ai-generated-content.md
|
|
8
|
-
* @architecture
|
|
8
|
+
* @architecture @docs/architecture/cli/index.md
|
|
9
9
|
* @tests @test/unit/cli/workflow-orchestrator.test.ts
|
|
10
10
|
* @depends @src/writing/validation-engine.ts
|
|
11
11
|
* @depends @src/writing/prompt-optimizer.ts
|
|
@@ -13,7 +13,8 @@
|
|
|
13
13
|
* config through `readAiwgConfig` and injects it here; direct callers may
|
|
14
14
|
* pass an already-loaded config object instead.
|
|
15
15
|
*/
|
|
16
|
-
import { existsSync, readdirSync, readFileSync } from 'node:fs';
|
|
16
|
+
import { existsSync, mkdtempSync, readdirSync, readFileSync, rmSync } from 'node:fs';
|
|
17
|
+
import { tmpdir } from 'node:os';
|
|
17
18
|
import { spawnSync } from 'node:child_process';
|
|
18
19
|
import path from 'node:path';
|
|
19
20
|
import { getProviderArtifactPathStrings, getProviderDefinition, normalizeProviderDefinitionId, } from '../providers/provider-definitions.js';
|
|
@@ -239,7 +240,8 @@ export async function syncWorkerContextProviders(options) {
|
|
|
239
240
|
}
|
|
240
241
|
/**
|
|
241
242
|
* Canonical one-pass deploy argv: a single `aiwg use all` invocation
|
|
242
|
-
* covering every listed provider
|
|
243
|
+
* covering every listed provider, or explicitly selecting one project-local
|
|
244
|
+
* launch provider. Never one deploy per provider in a union preparation:
|
|
243
245
|
* per-provider invocations rewrite AGENTS.md piecemeal and clobber each
|
|
244
246
|
* other's rule sections, while one pass keeps them all. No `--providers`
|
|
245
247
|
* flag: it feeds only the global bootstrap and the orchestrated
|
|
@@ -249,14 +251,32 @@ export async function syncWorkerContextProviders(options) {
|
|
|
249
251
|
* configured-provider path: `syncWorkerContextProviders` first, then this
|
|
250
252
|
* single pass reads the union back from the worktree config.
|
|
251
253
|
*/
|
|
252
|
-
export function buildWorkerContextDeployArgs({ providers, target }) {
|
|
254
|
+
export function buildWorkerContextDeployArgs({ providers, target, selectedProvider }) {
|
|
253
255
|
// Fail fast on a hostile list; the synced worktree config carries the set.
|
|
254
256
|
validateExplicitWorkerContextProviders(providers);
|
|
257
|
+
if (selectedProvider !== undefined) {
|
|
258
|
+
validateExplicitWorkerContextProviders([selectedProvider]);
|
|
259
|
+
return ['use', 'all', '--provider', selectedProvider, '--scope', 'project', '--target', target, '--yes'];
|
|
260
|
+
}
|
|
255
261
|
return ['use', 'all', '--target', target, '--yes'];
|
|
256
262
|
}
|
|
263
|
+
/** Keep CLI bootstrap state and caches local to a launch-time context deploy. */
|
|
264
|
+
export function workerContextDeployEnv(workdir, env = process.env, scratch) {
|
|
265
|
+
const local = path.join(workdir, '.aiwg');
|
|
266
|
+
// Data and cache hold regenerable deploy output (the framework search index
|
|
267
|
+
// alone exceeds 100 MB). Inside the worker tree they break the verifier's
|
|
268
|
+
// tree digest, so a scratch directory outside the tree takes them (#4150).
|
|
269
|
+
return { ...env, HOME: workdir, USERPROFILE: workdir, AIWG_CONFIG: local,
|
|
270
|
+
XDG_CONFIG_HOME: path.join(local, 'config'), XDG_CACHE_HOME: path.join(scratch ?? local, 'cache'),
|
|
271
|
+
XDG_DATA_HOME: path.join(scratch ?? local, 'data'), XDG_STATE_HOME: path.join(local, 'state'),
|
|
272
|
+
AIWG_USER_REGISTRY_PATH: path.join(local, 'installed.json'),
|
|
273
|
+
AIWG_ARTIFACTS_PATH: local, AIWG_PROJECT_AIWG_DIR: local,
|
|
274
|
+
CODEX_HOME: path.join(workdir, '.codex'), HERMES_HOME: path.join(workdir, '.hermes') };
|
|
275
|
+
}
|
|
257
276
|
/**
|
|
258
277
|
* Ensure a worker workdir carries its CLI's AIWG bootstrap before launch.
|
|
259
|
-
* Present: no-op. Missing:
|
|
278
|
+
* Present: no-op. Missing: select one provider for projectLocal launches;
|
|
279
|
+
* otherwise sync the union set into the workdir config,
|
|
260
280
|
* then exactly one `aiwg use all` pass into the workdir (never anywhere
|
|
261
281
|
* else), then re-verify. Impossible (no binary, failed deploy, still
|
|
262
282
|
* missing afterwards): throw `WorkerContextBootstrapError` naming the
|
|
@@ -280,14 +300,15 @@ export async function ensureWorkerContextBootstrap(options) {
|
|
|
280
300
|
const sync = options.syncFn ?? syncWorkerContextProviders;
|
|
281
301
|
let synced;
|
|
282
302
|
try {
|
|
283
|
-
synced = await sync({ workdir, providers });
|
|
303
|
+
synced = options.projectLocal ? { providers: [provider], updated: false } : await sync({ workdir, providers });
|
|
284
304
|
}
|
|
285
305
|
catch (error) {
|
|
286
306
|
if (error instanceof WorkerContextBootstrapError)
|
|
287
307
|
throw error;
|
|
288
308
|
throw new WorkerContextBootstrapError(`worker context sync failed: ${error instanceof Error ? error.message : String(error)}`, `write the union providers into ${path.join(workdir, '.aiwg', 'aiwg.config')} (or run 'aiwg use all --target ${workdir} --yes' manually) before launch`, { provider, workdir });
|
|
289
309
|
}
|
|
290
|
-
const argv = buildWorkerContextDeployArgs({ providers: synced.providers, target: workdir
|
|
310
|
+
const argv = buildWorkerContextDeployArgs({ providers: synced.providers, target: workdir,
|
|
311
|
+
...(options.projectLocal ? { selectedProvider: provider } : {}) });
|
|
291
312
|
const deploy = options.deployFn ?? (({ worktreePath, providers: deployProviders, aiwgBin: bin }) => {
|
|
292
313
|
// worktreePath IS the worker workdir by construction: the only
|
|
293
314
|
// `--target` ever passed is `workdir` above, and the spawn cwd is the
|
|
@@ -295,7 +316,16 @@ export async function ensureWorkerContextBootstrap(options) {
|
|
|
295
316
|
if (path.resolve(worktreePath) !== path.resolve(workdir)) {
|
|
296
317
|
throw new WorkerContextBootstrapError(`refusing worker context deploy outside the worker workdir (${worktreePath} !== ${workdir})`, 'deploy worker context only into the worker workdir', { provider, workdir });
|
|
297
318
|
}
|
|
298
|
-
const
|
|
319
|
+
const scratch = options.projectLocal ? mkdtempSync(path.join(tmpdir(), 'aiwg-worker-deploy-')) : undefined;
|
|
320
|
+
let result;
|
|
321
|
+
try {
|
|
322
|
+
result = spawn(bin, argv, { cwd: workdir, encoding: 'utf8', timeout: timeoutMs,
|
|
323
|
+
...(options.projectLocal ? { env: workerContextDeployEnv(workdir, process.env, scratch) } : {}) });
|
|
324
|
+
}
|
|
325
|
+
finally {
|
|
326
|
+
if (scratch)
|
|
327
|
+
rmSync(scratch, { recursive: true, force: true });
|
|
328
|
+
}
|
|
299
329
|
if (result.error) {
|
|
300
330
|
throw new WorkerContextBootstrapError(`worker context deploy failed to run (${result.error?.message});`
|
|
301
331
|
+ ` missing in ${workdir}: ${status.missing.join('; ')}`, `install the aiwg CLI on PATH or set AIWG_BIN to its location (tried '${bin}'),`
|
|
@@ -7,6 +7,7 @@ import { fileURLToPath } from 'node:url';
|
|
|
7
7
|
import { PROVIDER_IDS } from '../providers/provider-definitions.js';
|
|
8
8
|
import { isCanonicalWorkerModelKey, loadProviderModelCapabilities, resolveWorkerInstallation } from '../models/provider-policy.js';
|
|
9
9
|
import { resolveDispatchHostThresholds } from './dispatch-thresholds-runtime.mjs';
|
|
10
|
+
import { localModelsUrl } from '../models/local-endpoint-models.js';
|
|
10
11
|
import { expandWorkerGroupTemplates } from './worker-group-templates.js';
|
|
11
12
|
let parallelismValidator;
|
|
12
13
|
/** Offline shape and declaration validation. Qualification is checked at use time. */
|
|
@@ -37,6 +38,16 @@ export function validateParallelismConfig(value) {
|
|
|
37
38
|
const error = (pointer, message) => { errors.push(`OG_CONFIG_REFERENCE /parallelism/${pointer}: ${message}`); };
|
|
38
39
|
const builtinIds = new Set(PROVIDER_IDS.filter(id => id !== 'generic'));
|
|
39
40
|
for (const [id, installation] of Object.entries(policy.clis ?? {})) {
|
|
41
|
+
if (installation.localModels) {
|
|
42
|
+
try {
|
|
43
|
+
localModelsUrl(installation.localModels);
|
|
44
|
+
}
|
|
45
|
+
catch {
|
|
46
|
+
error(`clis/${id}/localModels/endpoint`, 'Requires a credential-free HTTP endpoint on loopback or allowedHosts');
|
|
47
|
+
}
|
|
48
|
+
if (new Set(installation.localModels.models.map(model => model.id)).size !== installation.localModels.models.length)
|
|
49
|
+
error(`clis/${id}/localModels/models`, 'Duplicate model ID');
|
|
50
|
+
}
|
|
40
51
|
if (installation.adapter.startsWith('providers:') && !builtinIds.has(installation.adapter.slice(10)))
|
|
41
52
|
error(`clis/${id}/adapter`, 'Unknown provider binding');
|
|
42
53
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Determines whether the contributor's framework is *in use* on this project,
|
|
6
6
|
* not just installed. Pure I/O — no code execution.
|
|
7
7
|
*
|
|
8
|
-
* @architecture
|
|
8
|
+
* @architecture @docs/contributing/contributor-quickstart.md
|
|
9
9
|
* @issue #938
|
|
10
10
|
*/
|
|
11
11
|
import { glob } from 'glob';
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* runs detection on each candidate. Returns kept records and skipped entries
|
|
7
7
|
* with reasons. Failures of one contributor never abort discovery.
|
|
8
8
|
*
|
|
9
|
-
* @architecture
|
|
9
|
+
* @architecture @docs/contributing/contributor-quickstart.md
|
|
10
10
|
* @issue #938
|
|
11
11
|
*/
|
|
12
12
|
import { existsSync } from 'fs';
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* it only checks a small number of well-known paths and runs a handful of
|
|
13
13
|
* bounded globs.
|
|
14
14
|
*
|
|
15
|
-
* @architecture
|
|
15
|
+
* @architecture @docs/contributing/contributor-quickstart.md
|
|
16
16
|
* @issue #941
|
|
17
17
|
*/
|
|
18
18
|
import { existsSync, statSync } from 'fs';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Contributor Discovery — Public API
|
|
3
3
|
*
|
|
4
|
-
* @architecture
|
|
4
|
+
* @architecture @docs/contributing/contributor-quickstart.md
|
|
5
5
|
* @issue #938
|
|
6
6
|
*/
|
|
7
7
|
export { discoverContributors } from './discover.js';
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* best-practices-audit, ...) by shipping `<framework>/<kind>/contributor.md`
|
|
7
7
|
* files. The aggregator discovers, validates, and runs detection against them.
|
|
8
8
|
*
|
|
9
|
-
* @architecture
|
|
9
|
+
* @architecture @docs/contributing/contributor-quickstart.md
|
|
10
10
|
* @issue #938
|
|
11
11
|
*/
|
|
12
12
|
export {};
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* keyed by kind so future consumers register their schema without forking the
|
|
6
6
|
* discovery module.
|
|
7
7
|
*
|
|
8
|
-
* @architecture
|
|
8
|
+
* @architecture @docs/contributing/contributor-quickstart.md
|
|
9
9
|
* @issue #938
|
|
10
10
|
*/
|
|
11
11
|
import { z } from 'zod';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { DatasetOrchestrationDependencies } from './orchestration-types.js';
|
|
2
|
+
export declare function selectDatasetBackend(deps: DatasetOrchestrationDependencies, id?: string): import("./orchestration-types.js").DatasetExecutionBackend;
|
|
3
|
+
//# sourceMappingURL=backend-selection.d.ts.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DatasetContractError } from './contracts.js';
|
|
2
|
+
export function selectDatasetBackend(deps, id) {
|
|
3
|
+
if (deps.selectBackend)
|
|
4
|
+
return deps.selectBackend(id);
|
|
5
|
+
if (id === undefined || id === 'local')
|
|
6
|
+
return deps.localBackend;
|
|
7
|
+
if (id === 'fortemi-core' && deps.fortemiBackend)
|
|
8
|
+
return deps.fortemiBackend;
|
|
9
|
+
throw new DatasetContractError(id === 'fortemi-core' ? 'DATASET_FORTEMI_UNAVAILABLE' : 'DATASET_BACKEND_NOT_REGISTERED', 'An explicitly selected compatible dataset backend is required');
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=backend-selection.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* True when `version` (x.y.z) satisfies `range`. Supports exact versions, `^`, `~`,
|
|
3
|
+
* `>=`, `<=`, `>`, `<`, space-separated AND and `||` OR. Prerelease tags, wildcards,
|
|
4
|
+
* hyphen ranges and any other syntax return false rather than guessing.
|
|
5
|
+
*/
|
|
6
|
+
export declare function contractRangeIncludes(version: string, range: string): boolean;
|
|
7
|
+
//# sourceMappingURL=contract-range.d.ts.map
|