mdkg 0.3.4 → 0.3.5
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/CHANGELOG.md +41 -0
- package/CLI_COMMAND_MATRIX.md +42 -2
- package/README.md +22 -1
- package/dist/cli.js +89 -0
- package/dist/command-contract.json +353 -2
- package/dist/commands/graph.js +582 -0
- package/dist/commands/validate.js +16 -11
- package/dist/init/CLI_COMMAND_MATRIX.md +17 -0
- package/dist/init/README.md +18 -1
- package/dist/init/init-manifest.json +3 -3
- package/dist/util/argparse.js +3 -0
- package/package.json +3 -2
package/CHANGELOG.md
CHANGED
|
@@ -12,6 +12,47 @@ mdkg is pre-v1 public alpha software. Command, graph, cache, bundle, and DAL con
|
|
|
12
12
|
|
|
13
13
|
- No changes yet.
|
|
14
14
|
|
|
15
|
+
## 0.3.5 - 2026-06-17
|
|
16
|
+
|
|
17
|
+
### Added
|
|
18
|
+
|
|
19
|
+
- Added `mdkg graph clone <source> --target <path>` to create a complete
|
|
20
|
+
authored mdkg graph in a separate contained target directory while preserving
|
|
21
|
+
source IDs.
|
|
22
|
+
- Added `mdkg graph fork <source> --target <path> --start-goal <goal-id>` to
|
|
23
|
+
preserve IDs in a separate target graph and optionally select the demo or
|
|
24
|
+
bootstrap start goal in that target.
|
|
25
|
+
- Added `mdkg graph import-template <source> --dry-run|--apply` for same-repo
|
|
26
|
+
template graph imports with deterministic canonical ID rewrites, structured
|
|
27
|
+
reference rewrites, safe body ID/qid rewrites, and optional selected-goal
|
|
28
|
+
setup.
|
|
29
|
+
- Added packed `smoke:graph-clone` coverage that installs mdkg from a tarball
|
|
30
|
+
in a temp prefix and validates clone, fork, import-template dry-run/apply,
|
|
31
|
+
source non-mutation, help text, search, pack, and validation behavior.
|
|
32
|
+
|
|
33
|
+
### Changed
|
|
34
|
+
|
|
35
|
+
- Updated README, seeded init README, command matrix, help snapshots,
|
|
36
|
+
prepublish gates, and publish-readiness assertions to document the
|
|
37
|
+
distinction between authored graph creation through `mdkg graph ...` and
|
|
38
|
+
read-only orchestration context through `mdkg subgraph ...`.
|
|
39
|
+
- Added `smoke:graph-clone` to `prepublishOnly` before the existing subgraph
|
|
40
|
+
smoke so graph template import behavior is proven before release.
|
|
41
|
+
- Consolidated website-template-mdkg dogfood planning under the 0.3.5 graph
|
|
42
|
+
clone/import goal without mutating downstream repositories or starting
|
|
43
|
+
website implementation.
|
|
44
|
+
|
|
45
|
+
### Security
|
|
46
|
+
|
|
47
|
+
- Clone/fork targets must be empty or absent, root-contained, and not nested
|
|
48
|
+
inside live directory sources.
|
|
49
|
+
- Same-repo template imports default to dry-run, require `--apply` to write,
|
|
50
|
+
run under the mdkg mutation lock, rebuild generated indexes, and validate the
|
|
51
|
+
resulting graph before selecting a start goal.
|
|
52
|
+
- Semantic ID collisions during template import require an explicit
|
|
53
|
+
`--id-prefix`; numeric canonical IDs are rewritten to the next unused ID so
|
|
54
|
+
links remain deterministic.
|
|
55
|
+
|
|
15
56
|
## 0.3.4 - 2026-06-17
|
|
16
57
|
|
|
17
58
|
### Added
|
package/CLI_COMMAND_MATRIX.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# CLI Command Matrix
|
|
2
2
|
|
|
3
|
-
as_of: 2026-06-
|
|
4
|
-
package_version_in_source: 0.3.
|
|
3
|
+
as_of: 2026-06-17
|
|
4
|
+
package_version_in_source: 0.3.5
|
|
5
5
|
source: live help from `src/cli.ts`, runtime command handlers, and `dec-15`..`dec-18`
|
|
6
6
|
status: canonical single-source command and flag reference for mdkg
|
|
7
7
|
|
|
@@ -28,6 +28,7 @@ Primary commands:
|
|
|
28
28
|
- `spec`
|
|
29
29
|
- `archive`
|
|
30
30
|
- `bundle`
|
|
31
|
+
- `graph`
|
|
31
32
|
- `subgraph`
|
|
32
33
|
- `work`
|
|
33
34
|
- `goal`
|
|
@@ -55,6 +56,7 @@ Capability cache discovery is read-only and accessed through `mdkg capability ..
|
|
|
55
56
|
Optional reusable SPEC capability records are accessed through `mdkg spec ...`.
|
|
56
57
|
Archive sidecars are accessed through `mdkg archive ...`.
|
|
57
58
|
Full graph snapshot bundles are accessed through `mdkg bundle ...`.
|
|
59
|
+
Whole-graph clone, fork, and same-repo template import workflows are accessed through `mdkg graph ...`.
|
|
58
60
|
Read-only child graph orchestration is accessed through `mdkg subgraph ...`.
|
|
59
61
|
Work contract/order/receipt semantic mirrors are accessed through `mdkg work ...`.
|
|
60
62
|
Recursive long-running objective contracts are accessed through `mdkg goal ...`.
|
|
@@ -615,6 +617,44 @@ JSON receipts:
|
|
|
615
617
|
- `show`: `{ action: "show", bundle, manifest }`
|
|
616
618
|
- `list`: `{ action: "list", count, items }`
|
|
617
619
|
|
|
620
|
+
### `mdkg graph`
|
|
621
|
+
|
|
622
|
+
When to use:
|
|
623
|
+
- clone or fork a complete mdkg graph into a separate target directory while preserving IDs
|
|
624
|
+
- import a template graph into the current repo with deterministic ID/link rewrites
|
|
625
|
+
- prepare selected-goal demo handoffs from reusable graph templates
|
|
626
|
+
|
|
627
|
+
Usage:
|
|
628
|
+
- `mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]`
|
|
629
|
+
- `mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]`
|
|
630
|
+
- `mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]`
|
|
631
|
+
|
|
632
|
+
Flags:
|
|
633
|
+
- `--target <path>`
|
|
634
|
+
- `--start-goal <goal-id>`
|
|
635
|
+
- `--select-goal`
|
|
636
|
+
- `--id-prefix <prefix>`
|
|
637
|
+
- `--dry-run`
|
|
638
|
+
- `--apply`
|
|
639
|
+
- `--json`
|
|
640
|
+
|
|
641
|
+
Notes:
|
|
642
|
+
- `graph clone` and `graph fork` preserve IDs because the target is a separate graph namespace
|
|
643
|
+
- clone/fork targets must be empty or absent and stay under the current mdkg root
|
|
644
|
+
- live directory sources are never mutated; clone/fork refuses targets nested inside a live source directory
|
|
645
|
+
- `graph fork --start-goal <goal-id>` writes selected-goal state in the target graph after validation
|
|
646
|
+
- `graph import-template` imports authored `.mdkg/work/*.md` template nodes into the current repo and skips config, generated indexes, archive payloads, bundles, and materialized subgraph views
|
|
647
|
+
- `graph import-template` defaults to dry-run unless `--apply` is supplied
|
|
648
|
+
- same-repo template import rewrites canonical numeric IDs to the next unused ID by type prefix and rewrites structured refs plus safe body-local id/qid mentions
|
|
649
|
+
- colliding semantic template IDs require `--id-prefix`
|
|
650
|
+
- `--select-goal` requires `--start-goal` and writes selected-goal state only after apply validation
|
|
651
|
+
- subgraphs remain read-only bundle projections for orchestration context; use `graph clone|fork|import-template` when authored graph state should be created
|
|
652
|
+
|
|
653
|
+
JSON receipts:
|
|
654
|
+
- `clone`: `{ action: "graph.clone", ok, mode, source, target, source_hash, preserved_ids, files_written, skipped_paths, index, validation, warnings }`
|
|
655
|
+
- `fork`: `{ action: "graph.fork", ok, mode, source, target, source_hash, preserved_ids, files_written, skipped_paths, start_goal?, selected_goal?, index, validation, warnings }`
|
|
656
|
+
- `import-template`: `{ action: "graph.import_template", ok, mode, source, source_hash, preserved_ids: false, rewritten_ids, rewritten_refs, planned_paths, files_written, skipped_paths, start_goal?, selected_goal?, index?, validation?, warnings }`
|
|
657
|
+
|
|
618
658
|
### `mdkg subgraph`
|
|
619
659
|
|
|
620
660
|
When to use:
|
package/README.md
CHANGED
|
@@ -14,7 +14,7 @@ mdkg stays deliberately boring:
|
|
|
14
14
|
- first-class rebuildable SQLite cache through built-in `node:sqlite`
|
|
15
15
|
- no daemon, hosted index, or vector DB
|
|
16
16
|
|
|
17
|
-
Current package version in source: `0.3.
|
|
17
|
+
Current package version in source: `0.3.5`
|
|
18
18
|
|
|
19
19
|
mdkg is still pre-v1 public alpha software. The public package is usable, but graph, cache, bundle, and DAL contracts may continue to change quickly while the project converges on a stable v1 surface.
|
|
20
20
|
|
|
@@ -150,6 +150,27 @@ mdkg bundle list --json
|
|
|
150
150
|
|
|
151
151
|
Bundles are explicit graph transport artifacts, separate from task context packs. Before a commit in repos that track archives or bundles, refresh compressed archive caches first, then create the private bundle so the committed graph state is self-consistent. Private bundles are the default and may be committed in private repos when configured. Public bundles require at least one selected workspace with `visibility: public` and include only public workspace content and public archive sidecars; bundle creation fails if public content points at private graph, archive, or subgraph records.
|
|
152
152
|
|
|
153
|
+
Clone or fork a reusable graph template into a separate target when the target
|
|
154
|
+
should preserve IDs as its own graph namespace:
|
|
155
|
+
|
|
156
|
+
```bash
|
|
157
|
+
mdkg graph clone .mdkg/bundles/private/all.mdkg.zip --target demos/demo-1 --json
|
|
158
|
+
mdkg graph fork templates/website-template-mdkg --target demos/live-build --start-goal goal-1 --json
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
Import a template graph into the current repo only through the rewritten-ID
|
|
162
|
+
path. Review the dry-run receipt first, then apply explicitly:
|
|
163
|
+
|
|
164
|
+
```bash
|
|
165
|
+
mdkg graph import-template templates/website-template-mdkg --start-goal goal-1 --select-goal --dry-run --json
|
|
166
|
+
mdkg graph import-template templates/website-template-mdkg --start-goal goal-1 --select-goal --apply --json
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
`graph clone` and `graph fork` preserve IDs; `graph import-template` rewrites
|
|
170
|
+
canonical numeric IDs and internal links to avoid same-repo collisions. Subgraphs
|
|
171
|
+
remain read-only planning views; use `mdkg graph ...` when authored graph state
|
|
172
|
+
should be created.
|
|
173
|
+
|
|
153
174
|
Register a child repo bundle as a read-only subgraph planning view:
|
|
154
175
|
|
|
155
176
|
```bash
|
package/dist/cli.js
CHANGED
|
@@ -25,6 +25,7 @@ const capability_1 = require("./commands/capability");
|
|
|
25
25
|
const spec_1 = require("./commands/spec");
|
|
26
26
|
const archive_1 = require("./commands/archive");
|
|
27
27
|
const bundle_1 = require("./commands/bundle");
|
|
28
|
+
const graph_1 = require("./commands/graph");
|
|
28
29
|
const subgraph_1 = require("./commands/subgraph");
|
|
29
30
|
const checkpoint_1 = require("./commands/checkpoint");
|
|
30
31
|
const init_1 = require("./commands/init");
|
|
@@ -69,6 +70,7 @@ function printUsage(log) {
|
|
|
69
70
|
log(" spec List, show, and validate optional SPEC.md capability records");
|
|
70
71
|
log(" archive Add, list, show, verify, and compress archive sidecars");
|
|
71
72
|
log(" bundle Create, list, show, and verify full graph snapshot bundles");
|
|
73
|
+
log(" graph Clone and fork whole mdkg graphs");
|
|
72
74
|
log(" subgraph Register, audit, plan, sync, materialize, and verify read-only child graph snapshots");
|
|
73
75
|
log(" work Create and update work contracts, orders, receipts, and artifacts");
|
|
74
76
|
log(" goal Inspect and advance recursive goal nodes");
|
|
@@ -554,6 +556,45 @@ function printBundleHelp(log, subcommand) {
|
|
|
554
556
|
}
|
|
555
557
|
printGlobalOptions(log);
|
|
556
558
|
}
|
|
559
|
+
function printGraphHelp(log, subcommand) {
|
|
560
|
+
switch ((subcommand ?? "").toLowerCase()) {
|
|
561
|
+
case "clone":
|
|
562
|
+
log("Usage:");
|
|
563
|
+
log(" mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]");
|
|
564
|
+
log("\nNotes:");
|
|
565
|
+
log(" - clones a complete graph into an empty contained target directory");
|
|
566
|
+
log(" - preserves IDs because the target is a separate graph namespace");
|
|
567
|
+
log(" - source bundle or source directory is never mutated");
|
|
568
|
+
break;
|
|
569
|
+
case "fork":
|
|
570
|
+
log("Usage:");
|
|
571
|
+
log(" mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]");
|
|
572
|
+
log("\nNotes:");
|
|
573
|
+
log(" - forks a complete graph into an empty contained target directory");
|
|
574
|
+
log(" - preserves IDs and can select a start goal in the target graph");
|
|
575
|
+
log(" - source bundle or source directory is never mutated");
|
|
576
|
+
break;
|
|
577
|
+
case "import-template":
|
|
578
|
+
log("Usage:");
|
|
579
|
+
log(" mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]");
|
|
580
|
+
log("\nNotes:");
|
|
581
|
+
log(" - imports authored .mdkg/work template nodes into the current graph");
|
|
582
|
+
log(" - defaults to dry-run unless --apply is supplied");
|
|
583
|
+
log(" - rewrites canonical numeric IDs and structured graph links deterministically");
|
|
584
|
+
log(" - --select-goal requires --start-goal and writes selected-goal state only after apply validation");
|
|
585
|
+
break;
|
|
586
|
+
default:
|
|
587
|
+
log("Usage:");
|
|
588
|
+
log(" mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]");
|
|
589
|
+
log(" mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]");
|
|
590
|
+
log(" mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]");
|
|
591
|
+
log("\nNotes:");
|
|
592
|
+
log(" - graph clone/fork create authored graph state in separate target directories and preserve IDs");
|
|
593
|
+
log(" - graph import-template imports template work nodes into the current graph with rewritten IDs");
|
|
594
|
+
log(" - subgraphs remain read-only bundle projections for orchestration context");
|
|
595
|
+
}
|
|
596
|
+
printGlobalOptions(log);
|
|
597
|
+
}
|
|
557
598
|
function printSubgraphHelp(log, subcommand) {
|
|
558
599
|
switch ((subcommand ?? "").toLowerCase()) {
|
|
559
600
|
case "add":
|
|
@@ -1020,6 +1061,9 @@ function printCommandHelp(log, command, subcommand) {
|
|
|
1020
1061
|
case "bundle":
|
|
1021
1062
|
printBundleHelp(log, subcommand);
|
|
1022
1063
|
return;
|
|
1064
|
+
case "graph":
|
|
1065
|
+
printGraphHelp(log, subcommand);
|
|
1066
|
+
return;
|
|
1023
1067
|
case "subgraph":
|
|
1024
1068
|
printSubgraphHelp(log, subcommand);
|
|
1025
1069
|
return;
|
|
@@ -1687,6 +1731,49 @@ function runBundleSubcommand(parsed, root) {
|
|
|
1687
1731
|
throw new errors_1.UsageError("bundle requires create/list/show/verify");
|
|
1688
1732
|
}
|
|
1689
1733
|
}
|
|
1734
|
+
function runGraphSubcommand(parsed, root) {
|
|
1735
|
+
const subcommand = (parsed.positionals[1] ?? "").toLowerCase();
|
|
1736
|
+
const source = parsed.positionals[2];
|
|
1737
|
+
const target = requireFlagValue("--target", parsed.flags["--target"]);
|
|
1738
|
+
const json = parseBooleanFlag("--json", parsed.flags["--json"]);
|
|
1739
|
+
switch (subcommand) {
|
|
1740
|
+
case "clone": {
|
|
1741
|
+
if (!source || parsed.positionals.length > 3) {
|
|
1742
|
+
throw new errors_1.UsageError("graph clone requires <source-bundle-or-mdkg-dir>");
|
|
1743
|
+
}
|
|
1744
|
+
if (!target) {
|
|
1745
|
+
throw new errors_1.UsageError("graph clone requires --target <path>");
|
|
1746
|
+
}
|
|
1747
|
+
(0, graph_1.runGraphCloneCommand)({ root, source, target, json });
|
|
1748
|
+
return 0;
|
|
1749
|
+
}
|
|
1750
|
+
case "fork": {
|
|
1751
|
+
if (!source || parsed.positionals.length > 3) {
|
|
1752
|
+
throw new errors_1.UsageError("graph fork requires <source-bundle-or-mdkg-dir>");
|
|
1753
|
+
}
|
|
1754
|
+
if (!target) {
|
|
1755
|
+
throw new errors_1.UsageError("graph fork requires --target <path>");
|
|
1756
|
+
}
|
|
1757
|
+
const startGoal = requireFlagValue("--start-goal", parsed.flags["--start-goal"]);
|
|
1758
|
+
(0, graph_1.runGraphForkCommand)({ root, source, target, startGoal, json });
|
|
1759
|
+
return 0;
|
|
1760
|
+
}
|
|
1761
|
+
case "import-template": {
|
|
1762
|
+
if (!source || parsed.positionals.length > 3) {
|
|
1763
|
+
throw new errors_1.UsageError("graph import-template requires <source-bundle-or-mdkg-dir>");
|
|
1764
|
+
}
|
|
1765
|
+
const startGoal = requireFlagValue("--start-goal", parsed.flags["--start-goal"]);
|
|
1766
|
+
const idPrefix = requireFlagValue("--id-prefix", parsed.flags["--id-prefix"]);
|
|
1767
|
+
const dryRun = parseBooleanFlag("--dry-run", parsed.flags["--dry-run"]);
|
|
1768
|
+
const apply = parseBooleanFlag("--apply", parsed.flags["--apply"]);
|
|
1769
|
+
const selectGoal = parseBooleanFlag("--select-goal", parsed.flags["--select-goal"]);
|
|
1770
|
+
(0, graph_1.runGraphImportTemplateCommand)({ root, source, startGoal, idPrefix, dryRun, apply, selectGoal, json });
|
|
1771
|
+
return 0;
|
|
1772
|
+
}
|
|
1773
|
+
default:
|
|
1774
|
+
throw new errors_1.UsageError("graph requires clone/fork/import-template");
|
|
1775
|
+
}
|
|
1776
|
+
}
|
|
1690
1777
|
function runSubgraphSubcommand(parsed, root) {
|
|
1691
1778
|
const subcommand = (parsed.positionals[1] ?? "").toLowerCase();
|
|
1692
1779
|
const json = parseBooleanFlag("--json", parsed.flags["--json"]);
|
|
@@ -2479,6 +2566,8 @@ function runCommand(parsed, root, runtime) {
|
|
|
2479
2566
|
return runArchiveSubcommand(parsed, root);
|
|
2480
2567
|
case "bundle":
|
|
2481
2568
|
return runBundleSubcommand(parsed, root);
|
|
2569
|
+
case "graph":
|
|
2570
|
+
return runGraphSubcommand(parsed, root);
|
|
2482
2571
|
case "subgraph":
|
|
2483
2572
|
return runSubgraphSubcommand(parsed, root);
|
|
2484
2573
|
case "work":
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema_version": 1,
|
|
3
3
|
"tool": "mdkg",
|
|
4
|
-
"package_version": "0.3.
|
|
4
|
+
"package_version": "0.3.5",
|
|
5
5
|
"source": {
|
|
6
6
|
"help_targets": "scripts/cli_help_targets.js",
|
|
7
7
|
"command_matrix": "CLI_COMMAND_MATRIX.md"
|
|
@@ -3714,6 +3714,357 @@
|
|
|
3714
3714
|
"command_matrix": "CLI_COMMAND_MATRIX.md"
|
|
3715
3715
|
}
|
|
3716
3716
|
},
|
|
3717
|
+
{
|
|
3718
|
+
"key": "graph",
|
|
3719
|
+
"path": [
|
|
3720
|
+
"graph"
|
|
3721
|
+
],
|
|
3722
|
+
"category": "graph",
|
|
3723
|
+
"status": "stable",
|
|
3724
|
+
"visibility": "public",
|
|
3725
|
+
"summary": "mdkg graph command",
|
|
3726
|
+
"usage": [
|
|
3727
|
+
" mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]",
|
|
3728
|
+
" mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]",
|
|
3729
|
+
" mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]"
|
|
3730
|
+
],
|
|
3731
|
+
"args": [
|
|
3732
|
+
{
|
|
3733
|
+
"name": "source-bundle-or-mdkg-dir",
|
|
3734
|
+
"required": true,
|
|
3735
|
+
"source": "<source-bundle-or-mdkg-dir>"
|
|
3736
|
+
}
|
|
3737
|
+
],
|
|
3738
|
+
"flags": [
|
|
3739
|
+
{
|
|
3740
|
+
"name": "--help",
|
|
3741
|
+
"value": null,
|
|
3742
|
+
"required": false,
|
|
3743
|
+
"description": "--help, -h Show help"
|
|
3744
|
+
},
|
|
3745
|
+
{
|
|
3746
|
+
"name": "--root",
|
|
3747
|
+
"value": null,
|
|
3748
|
+
"required": false,
|
|
3749
|
+
"description": "--root, -r <path> Run against a specific repo root"
|
|
3750
|
+
},
|
|
3751
|
+
{
|
|
3752
|
+
"name": "--target",
|
|
3753
|
+
"value": "<path>",
|
|
3754
|
+
"required": false,
|
|
3755
|
+
"description": "mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]"
|
|
3756
|
+
},
|
|
3757
|
+
{
|
|
3758
|
+
"name": "--version",
|
|
3759
|
+
"value": null,
|
|
3760
|
+
"required": false,
|
|
3761
|
+
"description": "--version, -V Show version"
|
|
3762
|
+
}
|
|
3763
|
+
],
|
|
3764
|
+
"output_formats": [
|
|
3765
|
+
"text",
|
|
3766
|
+
"json"
|
|
3767
|
+
],
|
|
3768
|
+
"json_schema_ref": "mdkg.command_output.v1",
|
|
3769
|
+
"side_effects": [
|
|
3770
|
+
"none"
|
|
3771
|
+
],
|
|
3772
|
+
"read_paths": [
|
|
3773
|
+
".mdkg/**"
|
|
3774
|
+
],
|
|
3775
|
+
"write_paths": [],
|
|
3776
|
+
"dry_run": {
|
|
3777
|
+
"supported": false
|
|
3778
|
+
},
|
|
3779
|
+
"lock_policy": "none-read-only",
|
|
3780
|
+
"atomic_write_policy": "none-read-only",
|
|
3781
|
+
"receipts": [],
|
|
3782
|
+
"danger_level": "read-only",
|
|
3783
|
+
"aliases": [],
|
|
3784
|
+
"exit_codes": [
|
|
3785
|
+
{
|
|
3786
|
+
"code": 0,
|
|
3787
|
+
"meaning": "success"
|
|
3788
|
+
},
|
|
3789
|
+
{
|
|
3790
|
+
"code": 1,
|
|
3791
|
+
"meaning": "validation-or-runtime-error"
|
|
3792
|
+
}
|
|
3793
|
+
],
|
|
3794
|
+
"examples": [
|
|
3795
|
+
" mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]",
|
|
3796
|
+
" mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]",
|
|
3797
|
+
" mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]"
|
|
3798
|
+
],
|
|
3799
|
+
"docs": {
|
|
3800
|
+
"help_target": "mdkg help graph",
|
|
3801
|
+
"command_matrix": "CLI_COMMAND_MATRIX.md"
|
|
3802
|
+
}
|
|
3803
|
+
},
|
|
3804
|
+
{
|
|
3805
|
+
"key": "graph clone",
|
|
3806
|
+
"path": [
|
|
3807
|
+
"graph",
|
|
3808
|
+
"clone"
|
|
3809
|
+
],
|
|
3810
|
+
"category": "graph",
|
|
3811
|
+
"status": "stable",
|
|
3812
|
+
"visibility": "public",
|
|
3813
|
+
"summary": "mdkg graph clone command",
|
|
3814
|
+
"usage": [
|
|
3815
|
+
" mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]"
|
|
3816
|
+
],
|
|
3817
|
+
"args": [
|
|
3818
|
+
{
|
|
3819
|
+
"name": "source-bundle-or-mdkg-dir",
|
|
3820
|
+
"required": true,
|
|
3821
|
+
"source": "<source-bundle-or-mdkg-dir>"
|
|
3822
|
+
}
|
|
3823
|
+
],
|
|
3824
|
+
"flags": [
|
|
3825
|
+
{
|
|
3826
|
+
"name": "--help",
|
|
3827
|
+
"value": null,
|
|
3828
|
+
"required": false,
|
|
3829
|
+
"description": "--help, -h Show help"
|
|
3830
|
+
},
|
|
3831
|
+
{
|
|
3832
|
+
"name": "--root",
|
|
3833
|
+
"value": null,
|
|
3834
|
+
"required": false,
|
|
3835
|
+
"description": "--root, -r <path> Run against a specific repo root"
|
|
3836
|
+
},
|
|
3837
|
+
{
|
|
3838
|
+
"name": "--target",
|
|
3839
|
+
"value": "<path>",
|
|
3840
|
+
"required": false,
|
|
3841
|
+
"description": "mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]"
|
|
3842
|
+
},
|
|
3843
|
+
{
|
|
3844
|
+
"name": "--version",
|
|
3845
|
+
"value": null,
|
|
3846
|
+
"required": false,
|
|
3847
|
+
"description": "--version, -V Show version"
|
|
3848
|
+
}
|
|
3849
|
+
],
|
|
3850
|
+
"output_formats": [
|
|
3851
|
+
"text",
|
|
3852
|
+
"json"
|
|
3853
|
+
],
|
|
3854
|
+
"json_schema_ref": "mdkg.command_output.v1",
|
|
3855
|
+
"side_effects": [
|
|
3856
|
+
"none"
|
|
3857
|
+
],
|
|
3858
|
+
"read_paths": [
|
|
3859
|
+
".mdkg/**"
|
|
3860
|
+
],
|
|
3861
|
+
"write_paths": [],
|
|
3862
|
+
"dry_run": {
|
|
3863
|
+
"supported": false
|
|
3864
|
+
},
|
|
3865
|
+
"lock_policy": "none-read-only",
|
|
3866
|
+
"atomic_write_policy": "none-read-only",
|
|
3867
|
+
"receipts": [],
|
|
3868
|
+
"danger_level": "read-only",
|
|
3869
|
+
"aliases": [],
|
|
3870
|
+
"exit_codes": [
|
|
3871
|
+
{
|
|
3872
|
+
"code": 0,
|
|
3873
|
+
"meaning": "success"
|
|
3874
|
+
},
|
|
3875
|
+
{
|
|
3876
|
+
"code": 1,
|
|
3877
|
+
"meaning": "validation-or-runtime-error"
|
|
3878
|
+
}
|
|
3879
|
+
],
|
|
3880
|
+
"examples": [
|
|
3881
|
+
" mdkg graph clone <source-bundle-or-mdkg-dir> --target <path> [--json]"
|
|
3882
|
+
],
|
|
3883
|
+
"docs": {
|
|
3884
|
+
"help_target": "mdkg help graph clone",
|
|
3885
|
+
"command_matrix": "CLI_COMMAND_MATRIX.md"
|
|
3886
|
+
}
|
|
3887
|
+
},
|
|
3888
|
+
{
|
|
3889
|
+
"key": "graph fork",
|
|
3890
|
+
"path": [
|
|
3891
|
+
"graph",
|
|
3892
|
+
"fork"
|
|
3893
|
+
],
|
|
3894
|
+
"category": "graph",
|
|
3895
|
+
"status": "stable",
|
|
3896
|
+
"visibility": "public",
|
|
3897
|
+
"summary": "mdkg graph fork command",
|
|
3898
|
+
"usage": [
|
|
3899
|
+
" mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]"
|
|
3900
|
+
],
|
|
3901
|
+
"args": [
|
|
3902
|
+
{
|
|
3903
|
+
"name": "source-bundle-or-mdkg-dir",
|
|
3904
|
+
"required": true,
|
|
3905
|
+
"source": "<source-bundle-or-mdkg-dir>"
|
|
3906
|
+
}
|
|
3907
|
+
],
|
|
3908
|
+
"flags": [
|
|
3909
|
+
{
|
|
3910
|
+
"name": "--help",
|
|
3911
|
+
"value": null,
|
|
3912
|
+
"required": false,
|
|
3913
|
+
"description": "--help, -h Show help"
|
|
3914
|
+
},
|
|
3915
|
+
{
|
|
3916
|
+
"name": "--root",
|
|
3917
|
+
"value": null,
|
|
3918
|
+
"required": false,
|
|
3919
|
+
"description": "--root, -r <path> Run against a specific repo root"
|
|
3920
|
+
},
|
|
3921
|
+
{
|
|
3922
|
+
"name": "--target",
|
|
3923
|
+
"value": "<path>",
|
|
3924
|
+
"required": false,
|
|
3925
|
+
"description": "mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]"
|
|
3926
|
+
},
|
|
3927
|
+
{
|
|
3928
|
+
"name": "--version",
|
|
3929
|
+
"value": null,
|
|
3930
|
+
"required": false,
|
|
3931
|
+
"description": "--version, -V Show version"
|
|
3932
|
+
}
|
|
3933
|
+
],
|
|
3934
|
+
"output_formats": [
|
|
3935
|
+
"text",
|
|
3936
|
+
"json"
|
|
3937
|
+
],
|
|
3938
|
+
"json_schema_ref": "mdkg.command_output.v1",
|
|
3939
|
+
"side_effects": [
|
|
3940
|
+
"none"
|
|
3941
|
+
],
|
|
3942
|
+
"read_paths": [
|
|
3943
|
+
".mdkg/**"
|
|
3944
|
+
],
|
|
3945
|
+
"write_paths": [],
|
|
3946
|
+
"dry_run": {
|
|
3947
|
+
"supported": false
|
|
3948
|
+
},
|
|
3949
|
+
"lock_policy": "none-read-only",
|
|
3950
|
+
"atomic_write_policy": "none-read-only",
|
|
3951
|
+
"receipts": [],
|
|
3952
|
+
"danger_level": "read-only",
|
|
3953
|
+
"aliases": [],
|
|
3954
|
+
"exit_codes": [
|
|
3955
|
+
{
|
|
3956
|
+
"code": 0,
|
|
3957
|
+
"meaning": "success"
|
|
3958
|
+
},
|
|
3959
|
+
{
|
|
3960
|
+
"code": 1,
|
|
3961
|
+
"meaning": "validation-or-runtime-error"
|
|
3962
|
+
}
|
|
3963
|
+
],
|
|
3964
|
+
"examples": [
|
|
3965
|
+
" mdkg graph fork <source-bundle-or-mdkg-dir> --target <path> [--start-goal <goal-id>] [--json]"
|
|
3966
|
+
],
|
|
3967
|
+
"docs": {
|
|
3968
|
+
"help_target": "mdkg help graph fork",
|
|
3969
|
+
"command_matrix": "CLI_COMMAND_MATRIX.md"
|
|
3970
|
+
}
|
|
3971
|
+
},
|
|
3972
|
+
{
|
|
3973
|
+
"key": "graph import-template",
|
|
3974
|
+
"path": [
|
|
3975
|
+
"graph",
|
|
3976
|
+
"import-template"
|
|
3977
|
+
],
|
|
3978
|
+
"category": "graph",
|
|
3979
|
+
"status": "stable",
|
|
3980
|
+
"visibility": "public",
|
|
3981
|
+
"summary": "mdkg graph import-template command",
|
|
3982
|
+
"usage": [
|
|
3983
|
+
" mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]"
|
|
3984
|
+
],
|
|
3985
|
+
"args": [
|
|
3986
|
+
{
|
|
3987
|
+
"name": "source-bundle-or-mdkg-dir",
|
|
3988
|
+
"required": true,
|
|
3989
|
+
"source": "<source-bundle-or-mdkg-dir>"
|
|
3990
|
+
}
|
|
3991
|
+
],
|
|
3992
|
+
"flags": [
|
|
3993
|
+
{
|
|
3994
|
+
"name": "--apply",
|
|
3995
|
+
"value": "is",
|
|
3996
|
+
"required": false,
|
|
3997
|
+
"description": "- defaults to dry-run unless --apply is supplied"
|
|
3998
|
+
},
|
|
3999
|
+
{
|
|
4000
|
+
"name": "--help",
|
|
4001
|
+
"value": null,
|
|
4002
|
+
"required": false,
|
|
4003
|
+
"description": "--help, -h Show help"
|
|
4004
|
+
},
|
|
4005
|
+
{
|
|
4006
|
+
"name": "--root",
|
|
4007
|
+
"value": null,
|
|
4008
|
+
"required": false,
|
|
4009
|
+
"description": "--root, -r <path> Run against a specific repo root"
|
|
4010
|
+
},
|
|
4011
|
+
{
|
|
4012
|
+
"name": "--select-goal",
|
|
4013
|
+
"value": "requires",
|
|
4014
|
+
"required": false,
|
|
4015
|
+
"description": "- --select-goal requires --start-goal and writes selected-goal state only after apply validation"
|
|
4016
|
+
},
|
|
4017
|
+
{
|
|
4018
|
+
"name": "--start-goal",
|
|
4019
|
+
"value": "and",
|
|
4020
|
+
"required": false,
|
|
4021
|
+
"description": "- --select-goal requires --start-goal and writes selected-goal state only after apply validation"
|
|
4022
|
+
},
|
|
4023
|
+
{
|
|
4024
|
+
"name": "--version",
|
|
4025
|
+
"value": null,
|
|
4026
|
+
"required": false,
|
|
4027
|
+
"description": "--version, -V Show version"
|
|
4028
|
+
}
|
|
4029
|
+
],
|
|
4030
|
+
"output_formats": [
|
|
4031
|
+
"text",
|
|
4032
|
+
"json"
|
|
4033
|
+
],
|
|
4034
|
+
"json_schema_ref": "mdkg.command_output.v1",
|
|
4035
|
+
"side_effects": [
|
|
4036
|
+
"none"
|
|
4037
|
+
],
|
|
4038
|
+
"read_paths": [
|
|
4039
|
+
".mdkg/**"
|
|
4040
|
+
],
|
|
4041
|
+
"write_paths": [],
|
|
4042
|
+
"dry_run": {
|
|
4043
|
+
"supported": false
|
|
4044
|
+
},
|
|
4045
|
+
"lock_policy": "none-read-only",
|
|
4046
|
+
"atomic_write_policy": "none-read-only",
|
|
4047
|
+
"receipts": [],
|
|
4048
|
+
"danger_level": "read-only",
|
|
4049
|
+
"aliases": [],
|
|
4050
|
+
"exit_codes": [
|
|
4051
|
+
{
|
|
4052
|
+
"code": 0,
|
|
4053
|
+
"meaning": "success"
|
|
4054
|
+
},
|
|
4055
|
+
{
|
|
4056
|
+
"code": 1,
|
|
4057
|
+
"meaning": "validation-or-runtime-error"
|
|
4058
|
+
}
|
|
4059
|
+
],
|
|
4060
|
+
"examples": [
|
|
4061
|
+
" mdkg graph import-template <source-bundle-or-mdkg-dir> [--start-goal <goal-id>] [--select-goal] [--id-prefix <prefix>] [--dry-run] [--apply] [--json]"
|
|
4062
|
+
],
|
|
4063
|
+
"docs": {
|
|
4064
|
+
"help_target": "mdkg help graph import-template",
|
|
4065
|
+
"command_matrix": "CLI_COMMAND_MATRIX.md"
|
|
4066
|
+
}
|
|
4067
|
+
},
|
|
3717
4068
|
{
|
|
3718
4069
|
"key": "guide",
|
|
3719
4070
|
"path": [
|
|
@@ -7864,5 +8215,5 @@
|
|
|
7864
8215
|
}
|
|
7865
8216
|
}
|
|
7866
8217
|
],
|
|
7867
|
-
"contract_hash": "
|
|
8218
|
+
"contract_hash": "2fd862666a24adc363a0912822b639f7e437bf5fd31dea13e6f4d87bf0a57d60"
|
|
7868
8219
|
}
|