@tiangong-lca/pcr 0.4.0 → 0.4.2
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
CHANGED
|
@@ -9,13 +9,17 @@ Skill. Install the content separately with
|
|
|
9
9
|
|
|
10
10
|
## Install and run
|
|
11
11
|
|
|
12
|
-
Requires **Node.js 24.19 or later**. Supported platforms are Linux x64,
|
|
13
|
-
x64, and macOS ARM64.
|
|
12
|
+
Requires **Node.js 24.19 or later**. Supported platforms are Linux x64/ARM64,
|
|
13
|
+
Windows x64, and macOS ARM64.
|
|
14
|
+
|
|
15
|
+
These examples target PCR 0.4.2. Use the registry commands after guarded
|
|
16
|
+
publication makes that version available; source metadata and a preparing release
|
|
17
|
+
do not establish public availability.
|
|
14
18
|
|
|
15
19
|
In a project directory:
|
|
16
20
|
|
|
17
21
|
```sh
|
|
18
|
-
npm install @tiangong-lca/pcr@0.4.
|
|
22
|
+
npm install @tiangong-lca/pcr@0.4.2 @tiangong-lca/pcr-library@0.4.2
|
|
19
23
|
./node_modules/.bin/tiangong-pcr library verify --format json
|
|
20
24
|
./node_modules/.bin/tiangong-pcr list --format json
|
|
21
25
|
```
|
|
@@ -32,6 +36,41 @@ The selection order is `--library`, then `PCR_LIBRARY`, then the installed
|
|
|
32
36
|
content package. `--root` explicitly selects a source checkout and cannot be
|
|
33
37
|
combined with `--library`.
|
|
34
38
|
|
|
39
|
+
## Latest compatible content for a new task
|
|
40
|
+
|
|
41
|
+
Released `@tiangong-lca/cli` 0.1.25 or later can manage content freshness separately
|
|
42
|
+
from this offline reader; 0.1.25 is the qualified minimum for this workflow.
|
|
43
|
+
Use Node 24.19.0 for this task workflow; Tiangong CLI supports `>=24.19.0 <25`,
|
|
44
|
+
separately from the standalone PCR reader requirement above. After confirming its
|
|
45
|
+
publication, install that qualified version:
|
|
46
|
+
|
|
47
|
+
```sh
|
|
48
|
+
npm install @tiangong-lca/cli@0.1.25
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Select this installed PCR package's absolute root once when preparing a dedicated
|
|
52
|
+
task directory:
|
|
53
|
+
|
|
54
|
+
```sh
|
|
55
|
+
./node_modules/.bin/tiangong-lca pcr snapshot ensure --task-dir <absolute-task-dir> --tool-root <absolute-installed-PCR-package> --json
|
|
56
|
+
./node_modules/.bin/tiangong-lca pcr snapshot status --task-dir <absolute-task-dir> --json
|
|
57
|
+
./node_modules/.bin/tiangong-lca pcr exec --task-dir <absolute-task-dir> -- list --format json
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
On Windows, use `node_modules/.bin/tiangong-lca.cmd` for this preparation CLI.
|
|
61
|
+
|
|
62
|
+
Require `task_usable: true`. A new connected task selects the latest compatible
|
|
63
|
+
published content, while an existing task retains its version/hash without
|
|
64
|
+
network discovery. Explicit-version and offline modes remain available through
|
|
65
|
+
command help. The wrapper injects the selected library/hash; do not pass native
|
|
66
|
+
source overrides. It keeps the selected installed reader bytes fixed as well.
|
|
67
|
+
This is an explicit workflow preparation boundary, not a hook into every chat or
|
|
68
|
+
Foundry task. Standalone commands below preserve their existing behavior.
|
|
69
|
+
Content compatibility is independent of its product version: a capable reader
|
|
70
|
+
0.4.1 can consume newer content when its declared compatibility and any audited
|
|
71
|
+
legacy reader profile permit it. Keep that reader and an existing task's content
|
|
72
|
+
pin; a new website or release does not upgrade either implicitly.
|
|
73
|
+
|
|
35
74
|
## Common commands
|
|
36
75
|
|
|
37
76
|
```sh
|
|
@@ -72,15 +111,15 @@ package is optional; legacy `validate-model` only checks qualifier text and
|
|
|
72
111
|
On a connected machine, download both packages:
|
|
73
112
|
|
|
74
113
|
```sh
|
|
75
|
-
npm pack @tiangong-lca/pcr@0.4.
|
|
76
|
-
npm pack @tiangong-lca/pcr-library@0.4.
|
|
114
|
+
npm pack @tiangong-lca/pcr@0.4.2
|
|
115
|
+
npm pack @tiangong-lca/pcr-library@0.4.2
|
|
77
116
|
```
|
|
78
117
|
|
|
79
118
|
Transfer the two tarballs and a suitable Node.js runtime to the offline machine.
|
|
80
119
|
In the destination directory:
|
|
81
120
|
|
|
82
121
|
```sh
|
|
83
|
-
npm install --offline --ignore-scripts --no-audit --no-fund ./tiangong-lca-pcr-0.4.
|
|
122
|
+
npm install --offline --ignore-scripts --no-audit --no-fund ./tiangong-lca-pcr-0.4.2.tgz ./tiangong-lca-pcr-library-0.4.2.tgz
|
|
84
123
|
./node_modules/.bin/tiangong-pcr library verify --format json
|
|
85
124
|
```
|
|
86
125
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tiangong-lca/pcr",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Offline PCR consumer CLI and agent Skill",
|
|
6
6
|
"license": "MIT",
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
"README.md",
|
|
17
17
|
"LICENSE",
|
|
18
18
|
"NOTICE.md",
|
|
19
|
+
"reader-capabilities.json",
|
|
19
20
|
"product-release.json"
|
|
20
21
|
],
|
|
21
22
|
"dependencies": {
|
|
@@ -36,7 +37,7 @@
|
|
|
36
37
|
"type": "git",
|
|
37
38
|
"url": "git+https://github.com/tiangong-lca/pcr.git"
|
|
38
39
|
},
|
|
39
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "008da151ed2ddf3c880f75f92ee5847301393e44",
|
|
40
41
|
"publishConfig": {
|
|
41
42
|
"access": "public",
|
|
42
43
|
"registry": "https://registry.npmjs.org"
|
package/product-release.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema": 1,
|
|
3
|
-
"version": "0.4.
|
|
4
|
-
"tag": "v0.4.
|
|
5
|
-
"sourceCommit": "
|
|
6
|
-
"sourceFingerprint": "sha256:
|
|
3
|
+
"version": "0.4.2",
|
|
4
|
+
"tag": "v0.4.2",
|
|
5
|
+
"sourceCommit": "008da151ed2ddf3c880f75f92ee5847301393e44",
|
|
6
|
+
"sourceFingerprint": "sha256:65e8a3449f7719b63e07b747fb52b6cb82282820ee623c099e15ccdd42692ff6"
|
|
7
7
|
}
|
|
@@ -10,22 +10,64 @@ route from the user's task. General LCA authoring has no mandatory data-package
|
|
|
10
10
|
format; native TIDAS inputs can be reviewed directly. The Agent interprets scope,
|
|
11
11
|
applicability and evidence. The CLI supplies source-addressable facts and arithmetic.
|
|
12
12
|
|
|
13
|
-
## Prepare the
|
|
14
|
-
|
|
15
|
-
`@tiangong-lca/
|
|
16
|
-
|
|
17
|
-
Node 24.19
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
13
|
+
## Prepare and pin the PCR task
|
|
14
|
+
|
|
15
|
+
Use released `@tiangong-lca/cli` 0.1.25 or later providing `pcr snapshot ensure`;
|
|
16
|
+
0.1.25 is the qualified minimum for this preparation workflow. Use the qualified
|
|
17
|
+
Node 24.19.0 runtime; Tiangong CLI supports `>=24.19.0 <25`. Select the installed
|
|
18
|
+
`@tiangong-lca/pcr` reader independently. Content's
|
|
19
|
+
declared compatibility, including the current 0.4.1 minimum reader, determines
|
|
20
|
+
whether that reader can consume it; matching product versions are not required.
|
|
21
|
+
Confirm the required versions are published before installing them; source or
|
|
22
|
+
release-preparation metadata does not establish registry availability.
|
|
23
|
+
Provision these tools before going offline. This Skill ships with the PCR reader;
|
|
24
|
+
install its complete directory following the host's Skill setup. npm installation
|
|
25
|
+
alone does not activate it, and it is not an automatic runtime hook. No account
|
|
26
|
+
login is required for public PCR snapshots or local consumption.
|
|
27
|
+
|
|
28
|
+
At the preparation boundary of a new PCR-guided task, use its dedicated absolute
|
|
29
|
+
task directory. Reuse the supplied task directory when continuing work; never
|
|
30
|
+
silently create a new directory merely to refresh an existing task. If there is
|
|
31
|
+
no task directory yet, create one dedicated to this task and retain its path with
|
|
32
|
+
the work artifacts. Do not use a shared project root as every task's identity.
|
|
33
|
+
|
|
34
|
+
```sh
|
|
35
|
+
tiangong-lca pcr snapshot ensure --task-dir <absolute-task-dir> --tool-root <absolute-installed-PCR-package> --json
|
|
36
|
+
tiangong-lca pcr snapshot status --task-dir <absolute-task-dir> --json
|
|
37
|
+
tiangong-lca pcr exec --task-dir <absolute-task-dir> -- guidance --pcr <id> --topic overview --format json
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
For a new connected task, ensure checks the latest compatible stable published
|
|
41
|
+
snapshot, verifies it and records immutable data/tool pins. Continue only when
|
|
42
|
+
`task_usable` is true. A prior task lock is reused without checking latest;
|
|
43
|
+
repeated ensure may finish verification of the same partial preparation but
|
|
44
|
+
cannot upgrade that task. Preserve the lock files with the task. Tool and
|
|
45
|
+
content versions may differ when their explicit compatibility contract permits it.
|
|
46
|
+
|
|
47
|
+
Honor an explicit version, selected local snapshot or offline request rather than
|
|
48
|
+
using default online discovery. Use ensure's `--version`, or `--library` with an
|
|
49
|
+
independently trusted `--library-sha256`; add `--offline` for verified cached
|
|
50
|
+
selection without network. Read its help for supported legacy/local profiles.
|
|
51
|
+
Offline selection is not proof of publisher latest. Missing compatibility,
|
|
52
|
+
corrupted cache/tool bytes or failed native verification must be resolved before
|
|
53
|
+
consumption; do not bypass the task lock by switching to an unpinned command.
|
|
54
|
+
|
|
55
|
+
In the task-managed route, invoke the PCR arguments in the sections below through
|
|
56
|
+
`tiangong-lca pcr exec --task-dir <absolute-task-dir> -- ...`. Follow-up/page
|
|
57
|
+
commands returned by the standalone reader may include `--library` or
|
|
58
|
+
`--library-sha256`; retain their query/page arguments but remove source selectors
|
|
59
|
+
and route them through pcr exec, which injects the verified task pin. Do not
|
|
60
|
+
forward `PCR_LIBRARY` or `--root` into this route. Native command help works after
|
|
61
|
+
`--`. Inputs and output paths are relative to the task directory; use absolute
|
|
62
|
+
paths when the work artifacts live elsewhere.
|
|
63
|
+
|
|
64
|
+
An explicitly requested standalone or repository-maintainer workflow remains
|
|
65
|
+
available: use `tiangong-pcr` with explicit snapshot/hash selectors, or the
|
|
66
|
+
repository command with `--root`. Preserve the user's source choice and its
|
|
67
|
+
identity; do not call it an automatically updated published-snapshot task.
|
|
68
|
+
`inspect` and `calculate` use local inputs; the task wrapper still verifies its
|
|
69
|
+
retained context. Neither CLI calls an LLM or approves methodology. Fully offline
|
|
70
|
+
semantic work also requires the host Agent/model to be available offline.
|
|
29
71
|
|
|
30
72
|
## Select applicable methodology
|
|
31
73
|
|
|
@@ -52,7 +94,7 @@ for large results. Full `guidance` remains available for a saved complete view.
|
|
|
52
94
|
|
|
53
95
|
For several known PCRs, save `{ "schema_version": 1, "pcr_ids": ["<id>"] }`
|
|
54
96
|
and prefer `guidance batch --input <request.json> --output <new-result.json> --format json`
|
|
55
|
-
|
|
97
|
+
through the same task wrapper (or the same explicit standalone library selector). The fresh output file holds the complete result;
|
|
56
98
|
stdout is its receipt. Read the needed complete units and ancestor context from
|
|
57
99
|
that file. At most 100 IDs share one verified session; order is preserved and a
|
|
58
100
|
failed item rejects the whole batch.
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
# PCR consumer commands
|
|
2
2
|
|
|
3
3
|
Use command-specific `--help` for input shapes, defaults and next actions. Commands
|
|
4
|
-
below run without network access; provision
|
|
4
|
+
below are native PCR arguments and run without network access; provision the reader first.
|
|
5
|
+
For a managed task, prepare once with `tiangong-lca pcr snapshot ensure`, then invoke
|
|
6
|
+
`tiangong-lca pcr exec --task-dir <absolute-task-dir> -- <arguments below without tiangong-pcr>`.
|
|
7
|
+
Preparation may discover/download public data for a new task; existing task pins
|
|
8
|
+
never refresh. Require `task_usable: true`, retain the same task directory, and
|
|
9
|
+
use absolute input/output paths when files are outside that directory.
|
|
5
10
|
|
|
6
11
|
```sh
|
|
7
12
|
tiangong-pcr tree --format markdown
|
|
@@ -22,12 +27,15 @@ tiangong-pcr review check --pcr <id> --input process.json --related ./datasets -
|
|
|
22
27
|
tiangong-pcr feedback draft --pcr <id> --type <feedback-type> --summary "<finding>"
|
|
23
28
|
```
|
|
24
29
|
|
|
25
|
-
Use returned page
|
|
30
|
+
Use returned page/query arguments. In the task-managed route, remove the returned
|
|
31
|
+
standalone executable and any source selectors before passing arguments to
|
|
32
|
+
`pcr exec`; the wrapper supplies the retained library/hash and rejects overrides. Topic/section selection and exact pointer reading are
|
|
26
33
|
exclusive. New inspection/selection results use previews; truncated values carry
|
|
27
34
|
an explicit marker and a pointer for complete retrieval. Large complete output
|
|
28
35
|
requires `--output <new-file>`; existing files are not overwritten. This saves an
|
|
29
36
|
artifact and prints its path/hash. Input inspection and arithmetic do not need
|
|
30
|
-
`--library`; PCR commands honor PCR_LIBRARY or explicit selection/pinning.
|
|
37
|
+
`--library`; standalone PCR commands honor PCR_LIBRARY or explicit selection/pinning.
|
|
38
|
+
The managed wrapper instead verifies its task pins and clears ambient source overrides.
|
|
31
39
|
|
|
32
40
|
`--related` scans one explicitly supplied local directory, bounded to 200 JSON
|
|
33
41
|
files, 64 MiB total, 12 directory levels and 5000 entries. Each JSON file is bounded
|