@a5c-ai/agent-catalog 5.0.1-staging.c9bb2c61
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 +117 -0
- package/dist/assets.d.ts +4 -0
- package/dist/assets.d.ts.map +1 -0
- package/dist/assets.js +76 -0
- package/dist/cli.d.ts +168 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +336 -0
- package/dist/data.d.ts +54 -0
- package/dist/data.d.ts.map +1 -0
- package/dist/data.js +636 -0
- package/dist/discovery-snapshot.json +319345 -0
- package/dist/discovery.d.ts +143 -0
- package/dist/discovery.d.ts.map +1 -0
- package/dist/discovery.js +728 -0
- package/dist/evidence-projection.d.ts +4 -0
- package/dist/evidence-projection.d.ts.map +1 -0
- package/dist/evidence-projection.js +34 -0
- package/dist/evidence.d.ts +13 -0
- package/dist/evidence.d.ts.map +1 -0
- package/dist/evidence.js +227 -0
- package/dist/graph.d.ts +20 -0
- package/dist/graph.d.ts.map +1 -0
- package/dist/graph.js +194 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +28 -0
- package/dist/models.d.ts +559 -0
- package/dist/models.d.ts.map +1 -0
- package/dist/models.js +2 -0
- package/dist/sdk.d.ts +48 -0
- package/dist/sdk.d.ts.map +1 -0
- package/dist/sdk.js +902 -0
- package/dist/transport-mux-cutover.d.ts +9 -0
- package/dist/transport-mux-cutover.d.ts.map +1 -0
- package/dist/transport-mux-cutover.js +158 -0
- package/dist/ui.d.ts +2 -0
- package/dist/ui.d.ts.map +1 -0
- package/dist/ui.js +8 -0
- package/docs/ontology-evidence.md +82 -0
- package/evidence/ontology-evidence/claims/catalog-processes-and-packaging.json +89 -0
- package/evidence/ontology-evidence/claims/plugins-hooks-discovery.json +136 -0
- package/evidence/ontology-evidence/claims/runtime-core.json +113 -0
- package/evidence/ontology-evidence/claims/vendor-web.json +977 -0
- package/evidence/ontology-evidence/evidence-sources/catalog-processes-and-packaging.json +48 -0
- package/evidence/ontology-evidence/evidence-sources/plugins-hooks-discovery.json +88 -0
- package/evidence/ontology-evidence/evidence-sources/runtime-core.json +78 -0
- package/evidence/ontology-evidence/evidence-sources/vendor-web.json +918 -0
- package/evidence/ontology-evidence/manifest.json +56 -0
- package/graph/agent-catalog.graph.yaml +43 -0
- package/graph/edges/relations/agent-runtime/babysitter-agent.yaml +31 -0
- package/graph/edges/relations/agent-runtime/discovery-and-paths.yaml +433 -0
- package/graph/edges/relations/agent-runtime/session-and-lifecycle.yaml +137 -0
- package/graph/edges/relations/agent-runtime/transports-and-modalities.yaml +387 -0
- package/graph/edges/relations/capabilities/babysitter-agent-links.yaml +46 -0
- package/graph/edges/relations/capabilities/capability-vocabulary-links-agents.yaml +478 -0
- package/graph/edges/relations/capabilities/capability-vocabulary-links-providers.yaml +40 -0
- package/graph/edges/relations/capabilities/capability-vocabulary-links-transports.yaml +70 -0
- package/graph/edges/relations/capabilities/support-record-links-agents.yaml +478 -0
- package/graph/edges/relations/capabilities/support-record-links-providers.yaml +40 -0
- package/graph/edges/relations/capabilities/support-record-links-transports.yaml +70 -0
- package/graph/edges/relations/evolution.yaml +16 -0
- package/graph/edges/relations/hooks-and-plugins.yaml +462 -0
- package/graph/edges/relations/identity-babysitter-agent.yaml +11 -0
- package/graph/edges/relations/identity.yaml +218 -0
- package/graph/edges/relations/processes-and-packages.yaml +71 -0
- package/graph/edges/relations/provenance/babysitter-agent-and-claude-web.yaml +102 -0
- package/graph/edges/relations/provenance/catalog-core-agents.yaml +370 -0
- package/graph/edges/relations/provenance/catalog-core-models.yaml +88 -0
- package/graph/edges/relations/provenance/catalog-core-providers.yaml +220 -0
- package/graph/edges/relations/provenance/evidence-sources.yaml +136 -0
- package/graph/edges/relations/provenance/hooks-plugins-and-discovery-discovery.yaml +124 -0
- package/graph/edges/relations/provenance/hooks-plugins-and-discovery-hooks.yaml +244 -0
- package/graph/edges/relations/provenance/hooks-plugins-and-discovery-plugins.yaml +166 -0
- package/graph/edges/relations/provenance/processes-packages-and-paths.yaml +490 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capability.yaml +202 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-claude.yaml +210 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-codex.yaml +302 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-copilot.yaml +170 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-cursor.yaml +146 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-gemini.yaml +143 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-omp.yaml +76 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-openclaw.yaml +112 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-opencode.yaml +139 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-agents-pi.yaml +40 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-providers.yaml +112 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-capabilitySupport-transports.yaml +190 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-modality.yaml +88 -0
- package/graph/edges/relations/provenance/runtime-and-capabilities-transport.yaml +172 -0
- package/graph/nodes/agents/babysitter-agent.yaml +43 -0
- package/graph/nodes/agents/products.yaml +163 -0
- package/graph/nodes/agents/versions.yaml +282 -0
- package/graph/nodes/capabilities/capabilities.yaml +234 -0
- package/graph/nodes/capabilities/modalities.yaml +74 -0
- package/graph/nodes/capabilities/supports/agents/babysitter-agent.yaml +46 -0
- package/graph/nodes/capabilities/supports/agents/claude.yaml +166 -0
- package/graph/nodes/capabilities/supports/agents/codex.yaml +190 -0
- package/graph/nodes/capabilities/supports/agents/copilot.yaml +121 -0
- package/graph/nodes/capabilities/supports/agents/cursor.yaml +104 -0
- package/graph/nodes/capabilities/supports/agents/gemini.yaml +104 -0
- package/graph/nodes/capabilities/supports/agents/omp.yaml +74 -0
- package/graph/nodes/capabilities/supports/agents/openclaw.yaml +67 -0
- package/graph/nodes/capabilities/supports/agents/opencode.yaml +103 -0
- package/graph/nodes/capabilities/supports/agents/pi.yaml +65 -0
- package/graph/nodes/capabilities/supports/provider-versions.yaml +73 -0
- package/graph/nodes/capabilities/supports/transport-runtimes.yaml +122 -0
- package/graph/nodes/evidence/babysitter-agent-and-claude-web.yaml +83 -0
- package/graph/nodes/evidence/claims.yaml +315 -0
- package/graph/nodes/evidence/claude-code-capability-claims.yaml +170 -0
- package/graph/nodes/evidence/claude-code-docs-core.yaml +103 -0
- package/graph/nodes/evidence/claude-code-docs-extensions.yaml +114 -0
- package/graph/nodes/evidence/codex-web.yaml +155 -0
- package/graph/nodes/evidence/copilot-web.yaml +213 -0
- package/graph/nodes/evidence/cursor-web.yaml +191 -0
- package/graph/nodes/evidence/evidence-sources.yaml +206 -0
- package/graph/nodes/evidence/gemini-cli-web.yaml +177 -0
- package/graph/nodes/evidence/omp-web.yaml +129 -0
- package/graph/nodes/evidence/opencode-web.yaml +144 -0
- package/graph/nodes/hooks-and-plugins/hook-mappings.yaml +399 -0
- package/graph/nodes/hooks-and-plugins/hook-surfaces.yaml +160 -0
- package/graph/nodes/hooks-and-plugins/plugin-artifacts.yaml +229 -0
- package/graph/nodes/hooks-and-plugins/plugin-targets.yaml +330 -0
- package/graph/nodes/models.yaml +103 -0
- package/graph/nodes/processes-and-packages/ci-surfaces.yaml +45 -0
- package/graph/nodes/processes-and-packages/packages.yaml +89 -0
- package/graph/nodes/processes-and-packages/processes.yaml +44 -0
- package/graph/nodes/providers/products.yaml +102 -0
- package/graph/nodes/providers/versions.yaml +108 -0
- package/graph/nodes/runtime-semantics/discovery-signals-hooks.yaml +185 -0
- package/graph/nodes/runtime-semantics/discovery-signals-host.yaml +254 -0
- package/graph/nodes/runtime-semantics/lifecycle-semantics.yaml +151 -0
- package/graph/nodes/runtime-semantics/paths.yaml +289 -0
- package/graph/nodes/runtime-semantics/session-semantics.yaml +214 -0
- package/graph/nodes/transports.yaml +202 -0
- package/graph/schema/ontology-schema.yaml +529 -0
- package/package.json +65 -0
package/README.md
ADDED
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
# @a5c-ai/agent-catalog
|
|
2
|
+
|
|
3
|
+
`@a5c-ai/agent-catalog` is a public package for the shared agent ontology, discovery catalog, packaged evidence shards, and graph-backed helper APIs used across the Babysitter toolchain.
|
|
4
|
+
|
|
5
|
+
The package is published through the central `release.yml` and `staging-publish.yml` workflows. `main` publishes production releases, and `staging` publishes prerelease builds with the `staging` dist-tag.
|
|
6
|
+
|
|
7
|
+
## What ships
|
|
8
|
+
|
|
9
|
+
The published workspace surface is defined by `package.json`:
|
|
10
|
+
|
|
11
|
+
- package root export: compiled runtime helpers from `dist/index.js` and `dist/index.d.ts`
|
|
12
|
+
- `./graph` and `./graph/*`: the source-of-truth ontology YAML under `graph/`
|
|
13
|
+
- `./evidence` and `./evidence/*`: generated evidence shards under `evidence/ontology-evidence/`
|
|
14
|
+
- `./docs` and `./docs/*`: shipped package docs under `docs/`
|
|
15
|
+
- packaged files: `README.md`, `dist/`, `graph/`, `docs/`, and `evidence/`
|
|
16
|
+
|
|
17
|
+
Anything outside that list is maintained in the repo only and is not part of the installed package contract.
|
|
18
|
+
|
|
19
|
+
## Usage
|
|
20
|
+
|
|
21
|
+
Import runtime helpers from the package root when you need graph-backed metadata, discovery snapshots, UI projections, or evidence lookups:
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
import {
|
|
25
|
+
getCatalogDiscoverySnapshot,
|
|
26
|
+
getOntologyEvidenceSnapshot,
|
|
27
|
+
getUiAgentOntologyList,
|
|
28
|
+
resolveCatalogGraphAssetPath,
|
|
29
|
+
resolveCatalogEvidenceAssetPath,
|
|
30
|
+
} from "@a5c-ai/agent-catalog";
|
|
31
|
+
|
|
32
|
+
const graphPath = resolveCatalogGraphAssetPath("agent-catalog.graph.yaml");
|
|
33
|
+
const evidencePath = resolveCatalogEvidenceAssetPath("ontology-evidence", "manifest.json");
|
|
34
|
+
|
|
35
|
+
const discovery = getCatalogDiscoverySnapshot();
|
|
36
|
+
const evidence = getOntologyEvidenceSnapshot();
|
|
37
|
+
const agents = getUiAgentOntologyList();
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Use exported asset subpaths when you need the raw packaged files:
|
|
41
|
+
|
|
42
|
+
```ts
|
|
43
|
+
const graphEntrypoint = require.resolve("@a5c-ai/agent-catalog/graph/agent-catalog.graph.yaml");
|
|
44
|
+
const evidenceManifest = require.resolve("@a5c-ai/agent-catalog/evidence/ontology-evidence/manifest.json");
|
|
45
|
+
const docsEntrypoint = require.resolve("@a5c-ai/agent-catalog/docs/ontology-evidence.md");
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Downstream consumers should not reconstruct repo paths from `process.cwd()` or assume a monorepo checkout. Use the exported helpers and subpaths instead.
|
|
49
|
+
|
|
50
|
+
## Package surface
|
|
51
|
+
|
|
52
|
+
The package surface is intentionally split by concern:
|
|
53
|
+
|
|
54
|
+
- graph access: `getCatalogGraph()`, `getGraphDocument()`, `getOntologySchema()`, and the `./graph` asset export
|
|
55
|
+
- evidence access: `getOntologyEvidenceManifest()`, `getOntologyEvidenceSnapshot()`, evidence and claim lookup helpers, and the `./evidence` asset export
|
|
56
|
+
- discovery access: `getCatalogDiscoverySnapshot()`, `refreshCatalogDiscoverySnapshot()`, search helpers, and `listCatalog*` discovery collections
|
|
57
|
+
- SDK-facing projections: fallback harness metadata, host detection rules, plugin targets, package/process topology, and UI-oriented agent views
|
|
58
|
+
- asset resolution: `resolveCatalogAssetPath()`, `resolveCatalogGraphAssetPath()`, and `resolveCatalogEvidenceAssetPath()`
|
|
59
|
+
|
|
60
|
+
For a deeper graph/evidence walkthrough, see [`docs/ontology-evidence.md`](./docs/ontology-evidence.md).
|
|
61
|
+
|
|
62
|
+
## Source of truth and generated assets
|
|
63
|
+
|
|
64
|
+
- `graph/` is the editable source of truth for the ontology, relations, package/process metadata, and evidence nodes.
|
|
65
|
+
- `graph/agent-catalog.graph.yaml` is the root graph document entrypoint used by validators and packaged asset consumers.
|
|
66
|
+
- `evidence/ontology-evidence/` is generated from the graph evidence nodes for installed-package consumption.
|
|
67
|
+
- `dist/discovery-snapshot.json` is generated during build for runtime discovery helpers; it is part of the compiled runtime, not an editable source file.
|
|
68
|
+
- `docs/ontology-evidence.md` is the shipped deep-dive for graph/evidence conventions.
|
|
69
|
+
|
|
70
|
+
When graph structure or evidence claims change, update the YAML inputs first, then regenerate derived artifacts.
|
|
71
|
+
|
|
72
|
+
## Docs taxonomy
|
|
73
|
+
|
|
74
|
+
- `README.md`: package contract, usage, lifecycle policy, and taxonomy index
|
|
75
|
+
- `docs/ontology-evidence.md`: shipped deep-dive for graph layout, evidence policy, and refresh workflow
|
|
76
|
+
- `protocol.pseudocode.task.md`: internal planning scaffolding kept in the package root for repo context only; it is not in `files`, is not exported from `package.json`, and is not part of the shipped package surface
|
|
77
|
+
|
|
78
|
+
## Lifecycle policy
|
|
79
|
+
|
|
80
|
+
- The package must stay publishable: it ships with `publishConfig.access = public`, includes this README in `files`, and is owned by the central publish workflows.
|
|
81
|
+
- `npm run ci:test --workspace=@a5c-ai/agent-catalog` is the release-equivalent contract for this workspace. It covers build output, graph validation, evidence freshness, package contract tests, and the publish lifecycle policy check.
|
|
82
|
+
- `release.yml` and `staging-publish.yml` version, pack, and publish this package alongside the SDK, hooks-mux, agent-mux, and plugin compiler surfaces that consume it.
|
|
83
|
+
|
|
84
|
+
## Downstream compatibility
|
|
85
|
+
|
|
86
|
+
- Public and monorepo consumers may depend on the package's documented exports and packaged graph/evidence assets.
|
|
87
|
+
- Breaking changes to exported APIs, graph documents, evidence layout, or generated discovery data require a semver-major release and must keep downstream consumer contract tests green in the same change.
|
|
88
|
+
- Workspace consumers in this repo should still be updated in lockstep whenever a change would otherwise break their install, build, or runtime assumptions.
|
|
89
|
+
|
|
90
|
+
## Expected validation
|
|
91
|
+
|
|
92
|
+
Run this workspace command before landing changes that affect graph data, generated evidence, exports, packaged docs, or downstream consumers:
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
npm run ci:test --workspace=@a5c-ai/agent-catalog
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
For evidence-only refresh work, the package-local sequence is:
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
npm run generate:evidence --workspace=@a5c-ai/agent-catalog
|
|
102
|
+
npm run validate:graph --workspace=@a5c-ai/agent-catalog
|
|
103
|
+
npm run validate:evidence:freshness --workspace=@a5c-ai/agent-catalog
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## CI contract matrix
|
|
107
|
+
|
|
108
|
+
`npm run test:agent-catalog-contracts` is the enforced downstream compatibility matrix for `@a5c-ai/agent-catalog` in CI. It currently covers these consumer surfaces:
|
|
109
|
+
|
|
110
|
+
- package export and packaged-asset contract: `packages/agent-catalog/src/catalog.test.ts`, `packages/agent-catalog/src/discovery.contract.test.ts`, `packages/agent-catalog/src/sdk.contract.test.ts`, `packages/agent-catalog/src/discovery.packaged.test.ts`
|
|
111
|
+
- catalog API integration: `packages/catalog/src/app/api/agents/route.contract.test.ts`, `packages/catalog/src/app/api/agents/[slug]/route.contract.test.ts`, `packages/catalog/src/app/api/catalog-integration.contract.test.ts`
|
|
112
|
+
- SDK fallback metadata integration: `packages/sdk/src/harness/amuxFallbackMetadata.contract.test.ts`
|
|
113
|
+
- hooks-mux discovery integration: `packages/hooks-mux/core/src/discovery/__tests__/detector.contract.test.ts`
|
|
114
|
+
- agent-mux integration: `packages/agent-mux/core/tests/host-detection.contract.test.ts`, `packages/agent-mux/core/tests/invocation.contract.test.ts`
|
|
115
|
+
- agent-plugins-mux integration: `packages/agent-plugins-mux/src/__tests__/targets.contract.test.ts`
|
|
116
|
+
|
|
117
|
+
If a new consumer family or route starts importing `@a5c-ai/agent-catalog`, update this matrix and add its contract test to `test:agent-catalog-contracts` in the same change.
|
package/dist/assets.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare function resolveCatalogAssetPath(relativeAssetPath: string): string;
|
|
2
|
+
export declare function resolveCatalogGraphAssetPath(...segments: string[]): string;
|
|
3
|
+
export declare function resolveCatalogEvidenceAssetPath(...segments: string[]): string;
|
|
4
|
+
//# sourceMappingURL=assets.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assets.d.ts","sourceRoot":"","sources":["../src/assets.ts"],"names":[],"mappings":"AA6DA,wBAAgB,uBAAuB,CAAC,iBAAiB,EAAE,MAAM,GAAG,MAAM,CAezE;AAED,wBAAgB,4BAA4B,CAAC,GAAG,QAAQ,EAAE,MAAM,EAAE,GAAG,MAAM,CAE1E;AAED,wBAAgB,+BAA+B,CAAC,GAAG,QAAQ,EAAE,MAAM,EAAE,GAAG,MAAM,CAE7E"}
|
package/dist/assets.js
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.resolveCatalogAssetPath = resolveCatalogAssetPath;
|
|
7
|
+
exports.resolveCatalogGraphAssetPath = resolveCatalogGraphAssetPath;
|
|
8
|
+
exports.resolveCatalogEvidenceAssetPath = resolveCatalogEvidenceAssetPath;
|
|
9
|
+
const node_fs_1 = __importDefault(require("node:fs"));
|
|
10
|
+
const node_path_1 = __importDefault(require("node:path"));
|
|
11
|
+
const PACKAGE_NAME = "@a5c-ai/agent-catalog";
|
|
12
|
+
const PACKAGE_ROOT = node_path_1.default.resolve(__dirname, "..");
|
|
13
|
+
const ALLOWED_ASSET_ROOTS = new Set(["graph", "evidence", "docs"]);
|
|
14
|
+
function normalizeAssetPath(relativeAssetPath) {
|
|
15
|
+
const normalized = relativeAssetPath.replace(/\\/g, "/").replace(/^\.\/+/, "");
|
|
16
|
+
if (!normalized || node_path_1.default.isAbsolute(normalized)) {
|
|
17
|
+
throw new Error(`Expected a relative asset path within ${PACKAGE_NAME}, got "${relativeAssetPath}".`);
|
|
18
|
+
}
|
|
19
|
+
const segments = normalized.split("/").filter(Boolean);
|
|
20
|
+
if (segments.length === 0 || segments.some((segment) => segment === "..")) {
|
|
21
|
+
throw new Error(`Asset path must stay within ${PACKAGE_NAME}, got "${relativeAssetPath}".`);
|
|
22
|
+
}
|
|
23
|
+
if (!ALLOWED_ASSET_ROOTS.has(segments[0])) {
|
|
24
|
+
throw new Error(`Asset path must start with one of ${[...ALLOWED_ASSET_ROOTS].join(", ")}; got "${relativeAssetPath}".`);
|
|
25
|
+
}
|
|
26
|
+
return segments.join("/");
|
|
27
|
+
}
|
|
28
|
+
function resolveExportedAssetPath(relativeAssetPath) {
|
|
29
|
+
try {
|
|
30
|
+
return require.resolve(`${PACKAGE_NAME}/${relativeAssetPath}`);
|
|
31
|
+
}
|
|
32
|
+
catch {
|
|
33
|
+
return undefined;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
function resolvePackageRootCandidates() {
|
|
37
|
+
const candidates = new Set();
|
|
38
|
+
try {
|
|
39
|
+
candidates.add(node_path_1.default.dirname(require.resolve(`${PACKAGE_NAME}/package.json`)));
|
|
40
|
+
}
|
|
41
|
+
catch {
|
|
42
|
+
// Ignore packaged/bundled environments that do not expose package.json.
|
|
43
|
+
}
|
|
44
|
+
candidates.add(PACKAGE_ROOT);
|
|
45
|
+
let currentDir = process.cwd();
|
|
46
|
+
while (true) {
|
|
47
|
+
candidates.add(node_path_1.default.join(currentDir, "packages", "agent-catalog"));
|
|
48
|
+
candidates.add(node_path_1.default.join(currentDir, "agent-catalog"));
|
|
49
|
+
const parentDir = node_path_1.default.dirname(currentDir);
|
|
50
|
+
if (parentDir === currentDir) {
|
|
51
|
+
break;
|
|
52
|
+
}
|
|
53
|
+
currentDir = parentDir;
|
|
54
|
+
}
|
|
55
|
+
return [...candidates];
|
|
56
|
+
}
|
|
57
|
+
function resolveCatalogAssetPath(relativeAssetPath) {
|
|
58
|
+
const normalized = normalizeAssetPath(relativeAssetPath);
|
|
59
|
+
const exportedPath = resolveExportedAssetPath(normalized);
|
|
60
|
+
if (exportedPath && node_fs_1.default.existsSync(exportedPath)) {
|
|
61
|
+
return exportedPath;
|
|
62
|
+
}
|
|
63
|
+
for (const packageRoot of resolvePackageRootCandidates()) {
|
|
64
|
+
const localPath = node_path_1.default.join(packageRoot, normalized);
|
|
65
|
+
if (node_fs_1.default.existsSync(localPath)) {
|
|
66
|
+
return localPath;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
throw new Error(`Asset "${relativeAssetPath}" is unavailable for ${PACKAGE_NAME}.`);
|
|
70
|
+
}
|
|
71
|
+
function resolveCatalogGraphAssetPath(...segments) {
|
|
72
|
+
return resolveCatalogAssetPath(node_path_1.default.posix.join("graph", ...segments.map((segment) => segment.replace(/\\/g, "/"))));
|
|
73
|
+
}
|
|
74
|
+
function resolveCatalogEvidenceAssetPath(...segments) {
|
|
75
|
+
return resolveCatalogAssetPath(node_path_1.default.posix.join("evidence", ...segments.map((segment) => segment.replace(/\\/g, "/"))));
|
|
76
|
+
}
|
package/dist/cli.d.ts
ADDED
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
import type { GraphNode } from "./models";
|
|
2
|
+
export interface CliCatalogRow {
|
|
3
|
+
agent: string;
|
|
4
|
+
version: string;
|
|
5
|
+
providers: string;
|
|
6
|
+
hooks: string;
|
|
7
|
+
capabilities: string;
|
|
8
|
+
}
|
|
9
|
+
export interface CliCatalogSummary {
|
|
10
|
+
schemaVersion: string;
|
|
11
|
+
graphId: string;
|
|
12
|
+
totalAgents: number;
|
|
13
|
+
totalCapabilities: number;
|
|
14
|
+
totalModelProviders: number;
|
|
15
|
+
}
|
|
16
|
+
export interface CliGraphNodeRow {
|
|
17
|
+
nodeId: string;
|
|
18
|
+
kind: GraphNode["kind"];
|
|
19
|
+
label: string;
|
|
20
|
+
evidenceIds: string[];
|
|
21
|
+
attributes: Record<string, unknown>;
|
|
22
|
+
}
|
|
23
|
+
export interface CliGraphEdgeRow {
|
|
24
|
+
edgeId: string;
|
|
25
|
+
relation: string;
|
|
26
|
+
fromNodeId: string;
|
|
27
|
+
fromKind?: GraphNode["kind"];
|
|
28
|
+
fromLabel: string;
|
|
29
|
+
toNodeId: string;
|
|
30
|
+
toKind?: GraphNode["kind"];
|
|
31
|
+
toLabel: string;
|
|
32
|
+
versionRange?: string;
|
|
33
|
+
evidenceIds: string[];
|
|
34
|
+
attributes: Record<string, unknown>;
|
|
35
|
+
}
|
|
36
|
+
export interface CliNodeRelationRow extends CliGraphEdgeRow {
|
|
37
|
+
direction: "incoming" | "outgoing";
|
|
38
|
+
relatedNodeId: string;
|
|
39
|
+
relatedNodeKind?: GraphNode["kind"];
|
|
40
|
+
relatedLabel: string;
|
|
41
|
+
}
|
|
42
|
+
export interface CliNodeQuery {
|
|
43
|
+
node: CliGraphNodeRow;
|
|
44
|
+
outgoing: CliNodeRelationRow[];
|
|
45
|
+
incoming: CliNodeRelationRow[];
|
|
46
|
+
claims: CliEvidenceClaimRow[];
|
|
47
|
+
evidenceSources: CliEvidenceSourceRow[];
|
|
48
|
+
}
|
|
49
|
+
export interface CliEvidenceClaimRow {
|
|
50
|
+
claimId: string;
|
|
51
|
+
subjectKind: string;
|
|
52
|
+
subjectId: string;
|
|
53
|
+
statement: string;
|
|
54
|
+
confidence: string;
|
|
55
|
+
status: string;
|
|
56
|
+
evidenceIds: string[];
|
|
57
|
+
sourceIds: string[];
|
|
58
|
+
}
|
|
59
|
+
export interface CliEvidenceSourceRow {
|
|
60
|
+
evidenceId: string;
|
|
61
|
+
kind: string;
|
|
62
|
+
sourcePathOrUrl: string;
|
|
63
|
+
locator: string;
|
|
64
|
+
capturedAt: string;
|
|
65
|
+
trustLevel: string;
|
|
66
|
+
claimIds: string[];
|
|
67
|
+
}
|
|
68
|
+
export interface CliCapabilitySupportRow {
|
|
69
|
+
supportId: string;
|
|
70
|
+
capabilityId: string;
|
|
71
|
+
capabilityLabel: string;
|
|
72
|
+
supportLevel: string;
|
|
73
|
+
subjectKind: string;
|
|
74
|
+
subjectId: string;
|
|
75
|
+
subjectLabel: string;
|
|
76
|
+
versionRange: string;
|
|
77
|
+
notes?: string;
|
|
78
|
+
claimIds: string[];
|
|
79
|
+
sourceIds: string[];
|
|
80
|
+
evidenceIds: string[];
|
|
81
|
+
}
|
|
82
|
+
export interface CliAgentRelationRow {
|
|
83
|
+
nodeId: string;
|
|
84
|
+
agentId: string;
|
|
85
|
+
displayName: string;
|
|
86
|
+
versionRange: string;
|
|
87
|
+
providerIds: string[];
|
|
88
|
+
modelIds: string[];
|
|
89
|
+
transportIds: string[];
|
|
90
|
+
modalityIds: string[];
|
|
91
|
+
hookIds: string[];
|
|
92
|
+
pluginTargetIds: string[];
|
|
93
|
+
sessionNuanceIds: string[];
|
|
94
|
+
lifecycleNuanceIds: string[];
|
|
95
|
+
evidenceIds: string[];
|
|
96
|
+
}
|
|
97
|
+
export interface CliPackageRelationRow {
|
|
98
|
+
nodeId: string;
|
|
99
|
+
packageId: string;
|
|
100
|
+
packageName: string;
|
|
101
|
+
workspacePath: string;
|
|
102
|
+
moduleType: string;
|
|
103
|
+
sourceOfTruthRole: string;
|
|
104
|
+
surfaceKinds: string[];
|
|
105
|
+
processIds: string[];
|
|
106
|
+
pathIds: string[];
|
|
107
|
+
paths: string[];
|
|
108
|
+
ciIds: string[];
|
|
109
|
+
graphIds: string[];
|
|
110
|
+
evidenceIds: string[];
|
|
111
|
+
}
|
|
112
|
+
export interface CliProcessRelationRow {
|
|
113
|
+
nodeId: string;
|
|
114
|
+
processId: string;
|
|
115
|
+
displayName: string;
|
|
116
|
+
category: string;
|
|
117
|
+
ownerPackageId: string;
|
|
118
|
+
pathIds: string[];
|
|
119
|
+
paths: string[];
|
|
120
|
+
inputs: string[];
|
|
121
|
+
outputs: string[];
|
|
122
|
+
evidenceIds: string[];
|
|
123
|
+
}
|
|
124
|
+
export interface CliGraphEdgeFilter {
|
|
125
|
+
relation?: string;
|
|
126
|
+
fromNodeId?: string;
|
|
127
|
+
toNodeId?: string;
|
|
128
|
+
nodeId?: string;
|
|
129
|
+
}
|
|
130
|
+
export interface CliNodeRelationFilter {
|
|
131
|
+
nodeId: string;
|
|
132
|
+
direction?: "incoming" | "outgoing" | "both";
|
|
133
|
+
relation?: string;
|
|
134
|
+
}
|
|
135
|
+
export interface CliEvidenceClaimFilter {
|
|
136
|
+
claimId?: string;
|
|
137
|
+
subjectId?: string;
|
|
138
|
+
subjectKind?: string;
|
|
139
|
+
nodeId?: string;
|
|
140
|
+
evidenceId?: string;
|
|
141
|
+
}
|
|
142
|
+
export interface CliEvidenceSourceFilter {
|
|
143
|
+
evidenceId?: string;
|
|
144
|
+
claimId?: string;
|
|
145
|
+
nodeId?: string;
|
|
146
|
+
}
|
|
147
|
+
export interface CliCapabilitySupportFilter {
|
|
148
|
+
supportId?: string;
|
|
149
|
+
capabilityId?: string;
|
|
150
|
+
subjectKind?: string;
|
|
151
|
+
subjectId?: string;
|
|
152
|
+
subjectIdPrefix?: string;
|
|
153
|
+
supportLevel?: string;
|
|
154
|
+
versionRange?: string;
|
|
155
|
+
}
|
|
156
|
+
export declare function listCliRows(): CliCatalogRow[];
|
|
157
|
+
export declare function getCliCatalogSummary(): CliCatalogSummary;
|
|
158
|
+
export declare function listCliGraphNodes(kind?: GraphNode["kind"]): CliGraphNodeRow[];
|
|
159
|
+
export declare function listCliGraphEdges(filter?: CliGraphEdgeFilter): CliGraphEdgeRow[];
|
|
160
|
+
export declare function listCliNodeRelations(filter: CliNodeRelationFilter): CliNodeRelationRow[];
|
|
161
|
+
export declare function getCliNodeQuery(nodeId: string): CliNodeQuery | undefined;
|
|
162
|
+
export declare function listCliEvidenceClaims(filter?: CliEvidenceClaimFilter): CliEvidenceClaimRow[];
|
|
163
|
+
export declare function listCliEvidenceSources(filter?: CliEvidenceSourceFilter): CliEvidenceSourceRow[];
|
|
164
|
+
export declare function listCliCapabilitySupport(filter?: CliCapabilitySupportFilter): CliCapabilitySupportRow[];
|
|
165
|
+
export declare function listCliAgentRelations(agentId?: string): CliAgentRelationRow[];
|
|
166
|
+
export declare function listCliPackageRelations(packageId?: string): CliPackageRelationRow[];
|
|
167
|
+
export declare function listCliProcessRelations(processId?: string): CliProcessRelationRow[];
|
|
168
|
+
//# sourceMappingURL=cli.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAqB,MAAM,UAAU,CAAC;AAE7D,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,iBAAiB;IAChC,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,mBAAmB,EAAE,MAAM,CAAC;CAC7B;AAED,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,SAAS,CAAC,MAAM,CAAC,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACrC;AAED,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,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