graview 0.0.0-stage → 0.1.0

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/LICENSE ADDED
@@ -0,0 +1,96 @@
1
+ Elastic License 2.0
2
+
3
+ ## Acceptance
4
+
5
+ By using the software, you agree to all of the terms and conditions below.
6
+
7
+ ## Copyright License
8
+
9
+ The licensor grants you a non-exclusive, royalty-free, worldwide,
10
+ non-sublicensable, non-transferable license to use, copy, distribute, make
11
+ available, and prepare derivative works of the software, in each case subject
12
+ to the limitations and conditions below.
13
+
14
+ ## Limitations
15
+
16
+ You may not provide the software to third parties as a hosted or managed
17
+ service, where the service provides users with access to any substantial set
18
+ of the features or functionality of the software.
19
+
20
+ You may not move, change, disable, or circumvent the license key
21
+ functionality in the software, and you may not remove or obscure any
22
+ functionality in the software that is protected by the license key.
23
+
24
+ You may not alter, remove, or obscure any licensing, copyright, or other
25
+ notices of the licensor in the software. Any use of the licensor's trademarks
26
+ is subject to applicable law.
27
+
28
+ ## Patents
29
+
30
+ The licensor grants you a license, under any patent claims the licensor can
31
+ license, or becomes able to license, to make, have made, use, sell, offer for
32
+ sale, import and have imported the software, in each case subject to the
33
+ limitations and conditions in this license. This license does not cover any
34
+ patent claims that you cause to be infringed by modifications or additions to
35
+ the software. If you or your company make any written claim that the software
36
+ infringes or contributes to infringement of any patent, your patent license
37
+ for the software granted under these terms ends immediately. If your company
38
+ makes such a claim, your patent license ends immediately for work on behalf
39
+ of your company.
40
+
41
+ ## Notices
42
+
43
+ You must ensure that anyone who gets a copy of any part of the software from
44
+ you also gets a copy of these terms.
45
+
46
+ If you modify the software, you must include in any modified copies of the
47
+ software prominent notices stating that you have modified the software.
48
+
49
+ ## No Other Rights
50
+
51
+ These terms do not imply any licenses other than those expressly granted in
52
+ these terms.
53
+
54
+ ## Termination
55
+
56
+ If you use the software in violation of these terms, such use is not
57
+ licensed, and your licenses will automatically terminate. If the licensor
58
+ provides you with a notice of your violation, and you cease all violation of
59
+ this license no later than 30 days after you receive that notice, your
60
+ licenses will be reinstated retroactively. However, if you violate these
61
+ terms after such reinstatement, any additional violation of these terms will
62
+ cause your licenses to terminate automatically and permanently.
63
+
64
+ ## No Liability
65
+
66
+ *As far as the law allows, the software comes as is, without any warranty or
67
+ condition, and the licensor will not be liable to you for any damages arising
68
+ out of these terms or the use or nature of the software, under any kind of
69
+ legal claim.*
70
+
71
+ ## Definitions
72
+
73
+ The **licensor** is the entity offering these terms, and the **software** is
74
+ the software the licensor makes available under these terms, including any
75
+ portion of it.
76
+
77
+ **you** refers to the individual or entity agreeing to these terms.
78
+
79
+ **your company** is any legal entity, sole proprietorship, or other kind of
80
+ organization that you work for, plus all organizations that have control
81
+ over, are under the control of, or are under common control with that
82
+ organization. **control** means ownership of substantially all the assets of
83
+ an entity, or the power to direct its management and policies by vote,
84
+ contract, or otherwise. Control can be direct or indirect.
85
+
86
+ **your licenses** are all the licenses granted to you for the software under
87
+ these terms.
88
+
89
+ **use** means anything you do with the software requiring one of your
90
+ licenses.
91
+
92
+ **trademark** means trademarks, service marks, and similar rights.
93
+
94
+ ---
95
+
96
+ Copyright 2025-2026 En Dash Consulting
package/README.md CHANGED
@@ -1,3 +1,36 @@
1
- # Temporary Holding Version
1
+ # graview
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ The Graview command line. `graview` is the tool; `@graview/*` is the
4
+ framework a product imports.
5
+
6
+ ```sh
7
+ npx graview create my-app # a product on Graview, from nothing
8
+ npm create graview my-app # the same, by npm's convention
9
+
10
+ graview check ./dist/domain/app.js # the declaration, judged
11
+ graview docs ./dist/domain/app.js # llms.txt and agents.md, derived
12
+ graview describe ./dist/domain/app.js # the app read out, for something that cannot see
13
+ graview lens <name> --roles a,b # a lens that compiles, with its reuse test red
14
+ graview figure <entry> --kind <kind> # the figure line for a kind
15
+ graview serve ./dist/domain/app.js # the store behind HTTP, data in a folder
16
+ graview mcp ./dist/domain/app.js # the same store, for an agent over MCP (stdio)
17
+ graview apply ./dist/domain/app.js --call <act> --args '{...}' # one act, from a shell
18
+ graview sync-seed ./dist/domain/app.js --seed ./seed.json # default content, moved without a wipe
19
+ graview skills install . # the authoring skills, for Claude Code and Codex
20
+ ```
21
+
22
+ `serve`, `mcp`, `apply` and `sync-seed` share one store: `--data <dir>` (a
23
+ folder of readable JSON, the default), `--sqlite <file>`, or — for `mcp` and
24
+ `apply` — `--remote-url <url>` against a running `graview serve`. `--as` and
25
+ `--roles` say who is acting; the policy judges on the host exactly as it
26
+ judges in a browser.
27
+
28
+ A project made by `graview create` has this package as a devDependency, so
29
+ `npm run check`, `npm run docs` and `npm run skills` reach the same version
30
+ of the tool the project was scaffolded with.
31
+
32
+ Every subcommand is implemented in the package whose concern it is:
33
+ `create`, `check`, `docs`, `describe`, `lens` and `figure` in
34
+ `@graview/core`, `serve` and `sync-seed` in `@graview/ship`, `mcp` and
35
+ `apply` in `@graview/tools`, `skills` in `@graview/skills`. This package
36
+ dispatches and nothing else.
package/dist/cli.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":""}
package/dist/cli.js ADDED
@@ -0,0 +1,11 @@
1
+ #!/usr/bin/env node
2
+ import { main } from "./index.js";
3
+ main(process.argv.slice(2))
4
+ .then((code) => {
5
+ process.exitCode = code;
6
+ })
7
+ .catch((error) => {
8
+ process.stderr.write(`graview: ${error instanceof Error ? error.message : String(error)}\n`);
9
+ process.exitCode = 1;
10
+ });
11
+ //# sourceMappingURL=cli.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAElC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;KACxB,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE;IACb,OAAO,CAAC,QAAQ,GAAG,IAAI,CAAC;AAC1B,CAAC,CAAC;KACD,KAAK,CAAC,CAAC,KAAc,EAAE,EAAE;IACxB,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,YAAY,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAC7F,OAAO,CAAC,QAAQ,GAAG,CAAC,CAAC;AACvB,CAAC,CAAC,CAAC"}
@@ -0,0 +1,18 @@
1
+ /**
2
+ * `graview` — the one command line.
3
+ *
4
+ * The framework is `@graview/*`, the packages an app imports. This package
5
+ * is the tool a person installs: `npx graview create my-app` from nothing,
6
+ * or `graview check` from inside a project that has it as a devDependency.
7
+ * It owns no logic. Every subcommand lives in the package whose concern it
8
+ * is — the generator and the checker in core, `serve` and `sync-seed` in
9
+ * ship, `mcp` and `apply` in tools, `skills` in skills — and this
10
+ * dispatches to it, so a project made with `graview
11
+ * create` and one made by calling core's own CLI are the same project.
12
+ *
13
+ * `serve` and `skills` are imported when asked for, not before: `graview
14
+ * check` should not load an HTTP server, and a bundler that ever sees this
15
+ * file should not be asked to follow better-sqlite3.
16
+ */
17
+ export declare function main(argv: readonly string[]): Promise<number>;
18
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;GAeG;AACH,wBAAsB,IAAI,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAuBnE"}
package/dist/index.js ADDED
@@ -0,0 +1,49 @@
1
+ import { main as core, USAGE as CORE_USAGE } from "@graview/core/cli";
2
+ /**
3
+ * `graview` — the one command line.
4
+ *
5
+ * The framework is `@graview/*`, the packages an app imports. This package
6
+ * is the tool a person installs: `npx graview create my-app` from nothing,
7
+ * or `graview check` from inside a project that has it as a devDependency.
8
+ * It owns no logic. Every subcommand lives in the package whose concern it
9
+ * is — the generator and the checker in core, `serve` and `sync-seed` in
10
+ * ship, `mcp` and `apply` in tools, `skills` in skills — and this
11
+ * dispatches to it, so a project made with `graview
12
+ * create` and one made by calling core's own CLI are the same project.
13
+ *
14
+ * `serve` and `skills` are imported when asked for, not before: `graview
15
+ * check` should not load an HTTP server, and a bundler that ever sees this
16
+ * file should not be asked to follow better-sqlite3.
17
+ */
18
+ export async function main(argv) {
19
+ const [command, ...rest] = argv;
20
+ if (command === "serve") {
21
+ const { serve } = await import("@graview/ship/cli");
22
+ return serve(rest);
23
+ }
24
+ if (command === "sync-seed") {
25
+ const { syncSeed } = await import("@graview/ship/cli");
26
+ return syncSeed(rest);
27
+ }
28
+ if (command === "mcp" || command === "apply") {
29
+ const { mcp, apply } = await import("@graview/tools/cli");
30
+ return command === "mcp" ? mcp(rest) : apply(rest);
31
+ }
32
+ if (command === "skills") {
33
+ const { skills } = await import("@graview/skills/cli");
34
+ return skills(rest);
35
+ }
36
+ if (!command || command === "--help" || command === "-h" || command === "help") {
37
+ process.stdout.write(await usage());
38
+ return 0;
39
+ }
40
+ return core([...argv]);
41
+ }
42
+ /** Core's usage, then the subcommands the other packages contribute. */
43
+ async function usage() {
44
+ const { SERVE_USAGE } = await import("@graview/ship/cli");
45
+ const { MCP_USAGE } = await import("@graview/tools/cli");
46
+ const { SKILLS_USAGE } = await import("@graview/skills/cli");
47
+ return `${CORE_USAGE}\n${SERVE_USAGE}\n${MCP_USAGE}\n${SKILLS_USAGE}`;
48
+ }
49
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,IAAI,IAAI,EAAE,KAAK,IAAI,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AI,CAAC,CAAC,CAAC;AACzB,CAAC;AAED,wEAAwE;AACxE,KAAK,UAAU,KAAK;IAClB,MAAM,EAAE,WAAW,EAAE,GAAG,MAAM,MAAM,CAAC,mBAAmB,CAAC,CAAC;IAC1D,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,MAAM,CAAC,oBAAoB,CAAC,CAAC;IACzD,MAAM,EAAE,YAAY,EAAE,GAAG,MAAM,MAAM,CAAC,qBAAqB,CAAC,CAAC;IAC7D,OAAO,GAAG,UAAU,KAAK,WAAW,KAAK,SAAS,KAAK,YAAY,EAAE,CAAC;AACxE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,56 @@
1
1
  {
2
2
  "name": "graview",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
3
+ "version": "0.1.0",
4
+ "type": "module",
5
+ "description": "The Graview command line: start a product, check its declaration, write its agent docs, serve its store, host it for an agent over MCP, apply an act to it, sync its seed, install the authoring skills. The tool; @graview/* is the framework.",
6
+ "keywords": [
7
+ "graview",
8
+ "context-graph",
9
+ "typed-graph",
10
+ "interface",
11
+ "declarative",
12
+ "cli",
13
+ "scaffolder"
14
+ ],
15
+ "license": "Elastic-2.0",
16
+ "homepage": "https://graview.dev/docs/packages/graview.html",
17
+ "bugs": {
18
+ "url": "https://github.com/en-dash-consulting/graview/issues"
19
+ },
20
+ "main": "./dist/index.js",
21
+ "types": "./dist/index.d.ts",
22
+ "bin": {
23
+ "graview": "./dist/cli.js"
24
+ },
25
+ "exports": {
26
+ ".": {
27
+ "types": "./dist/index.d.ts",
28
+ "default": "./dist/index.js"
29
+ }
30
+ },
31
+ "dependencies": {
32
+ "@graview/core": "0.1.0",
33
+ "@graview/ship": "0.1.0",
34
+ "@graview/tools": "0.1.0",
35
+ "@graview/skills": "0.1.0"
36
+ },
37
+ "engines": {
38
+ "node": ">=22"
39
+ },
40
+ "files": [
41
+ "dist",
42
+ "README.md"
43
+ ],
44
+ "sideEffects": false,
45
+ "repository": {
46
+ "type": "git",
47
+ "url": "git+https://github.com/en-dash-consulting/graview.git",
48
+ "directory": "packages/graview"
49
+ },
50
+ "publishConfig": {
51
+ "access": "public"
52
+ },
53
+ "scripts": {
54
+ "build": "tsc -b"
55
+ }
6
56
  }