semantic-atlas 0.2.0 → 0.3.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/.agents/skills/semantic-atlas/SKILL.md +3 -0
- package/.agents/skills/semantic-atlas/references/product-feedback.md +34 -0
- package/.agents/skills/semantic-atlas-insights/SKILL.md +55 -0
- package/README.md +203 -88
- package/README.zh-CN.md +181 -85
- package/dist/cli/argument-parser.js +9 -1
- package/dist/cli/bin.js +10 -2
- package/dist/cli/cli-application.d.ts +1 -0
- package/dist/cli/cli-application.d.ts.map +1 -1
- package/dist/cli/cli-application.js +64 -12
- package/dist/cli/insights-cli.d.ts +6 -0
- package/dist/cli/insights-cli.d.ts.map +1 -0
- package/dist/cli/insights-cli.js +236 -0
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/main.js +94 -2
- package/dist/cli/standalone-cli.d.ts.map +1 -1
- package/dist/cli/standalone-cli.js +36 -5
- package/dist/cli/types.d.ts +2 -0
- package/dist/cli/types.d.ts.map +1 -1
- package/dist/contracts/cli.d.ts +63 -0
- package/dist/contracts/cli.d.ts.map +1 -1
- package/dist/contracts/cli.js +7 -0
- package/dist/contracts/insights.d.ts +2 -0
- package/dist/contracts/insights.d.ts.map +1 -0
- package/dist/contracts/insights.js +1 -0
- package/dist/contracts/public-contracts.d.ts +1 -0
- package/dist/contracts/public-contracts.d.ts.map +1 -1
- package/dist/contracts/public-contracts.js +1 -0
- package/dist/insights/contracts.d.ts +266 -0
- package/dist/insights/contracts.d.ts.map +1 -0
- package/dist/insights/contracts.js +124 -0
- package/dist/insights/insights-store.d.ts +73 -0
- package/dist/insights/insights-store.d.ts.map +1 -0
- package/dist/insights/insights-store.js +246 -0
- package/dist/setup/package-upgrader.d.ts +54 -0
- package/dist/setup/package-upgrader.d.ts.map +1 -0
- package/dist/setup/package-upgrader.js +169 -0
- package/dist/setup/skill-installer.d.ts +3 -2
- package/dist/setup/skill-installer.d.ts.map +1 -1
- package/dist/setup/skill-installer.js +67 -36
- package/dist/storage/atlas-database.d.ts +1 -0
- package/dist/storage/atlas-database.d.ts.map +1 -1
- package/dist/storage/atlas-database.js +13 -6
- package/docs/contracts/cli-v1.md +25 -4
- package/docs/contracts/insights-v1.md +84 -0
- package/docs/index.md +2 -0
- package/docs/log.md +24 -0
- package/docs/product-contract.md +15 -8
- package/package.json +3 -1
- package/schemas/cli-envelope-v1.schema.json +85 -1
- package/schemas/insights-envelope-v1.schema.json +428 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"atlas-database.d.ts","sourceRoot":"","sources":["../../src/storage/atlas-database.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,IAAI,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAEpE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAE5D,eAAO,MAAM,4BAA4B,IAAI,CAAC;AAC9C,eAAO,MAAM,wCAAwC,wBAAwB,CAAC;AAM9E,qBAAa,aAAc,YAAW,UAAU;;IAC9C,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,UAAU,EAAE,gBAAgB,CAAC;gBAG1B,UAAU,EAAE,aAAa;IAcrC,IAAI,aAAa,IAAI,MAAM,CAO1B;IAED,KAAK,IAAI,IAAI;IAQb,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,IAAI;IAIxB,OAAO,CAAC,gBAAgB;IAuCxB,OAAO,CAAC,kBAAkB;CAqC3B;AAED,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,aAAa,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"atlas-database.d.ts","sourceRoot":"","sources":["../../src/storage/atlas-database.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,IAAI,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAEpE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAE5D,eAAO,MAAM,4BAA4B,IAAI,CAAC;AAC9C,eAAO,MAAM,wCAAwC,wBAAwB,CAAC;AAM9E,qBAAa,aAAc,YAAW,UAAU;;IAC9C,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,UAAU,EAAE,gBAAgB,CAAC;gBAG1B,UAAU,EAAE,aAAa;IAcrC,IAAI,aAAa,IAAI,MAAM,CAO1B;IAED,KAAK,IAAI,IAAI;IAQb,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,IAAI;IAIxB,OAAO,CAAC,gBAAgB;IAuCxB,OAAO,CAAC,kBAAkB;CAqC3B;AAED,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,aAAa,GAAG,MAAM,CASlE;AAED,wBAAgB,2BAA2B,IAAI,MAAM,CAEpD;AAeD,wBAAgB,wBAAwB,CAAC,UAAU,EAAE,aAAa,GAAG,MAAM,CAQ1E"}
|
|
@@ -111,6 +111,19 @@ export class AtlasDatabase {
|
|
|
111
111
|
}
|
|
112
112
|
}
|
|
113
113
|
export function resolveAtlasHome(repository) {
|
|
114
|
+
const realAtlasHome = resolveConfiguredAtlasHome();
|
|
115
|
+
for (const worktreeRoot of repository.worktreeRoots) {
|
|
116
|
+
const realWorktreeRoot = realpathExistingPath(worktreeRoot);
|
|
117
|
+
if (realWorktreeRoot !== null && isPathInside(realAtlasHome, realWorktreeRoot)) {
|
|
118
|
+
throw new Error("The Semantic Atlas home must be outside every repository worktree");
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
return realAtlasHome;
|
|
122
|
+
}
|
|
123
|
+
export function resolveInsightsDatabasePath() {
|
|
124
|
+
return join(resolveConfiguredAtlasHome(), "insights.db");
|
|
125
|
+
}
|
|
126
|
+
function resolveConfiguredAtlasHome() {
|
|
114
127
|
const configuredHome = process.env[SEMANTIC_ATLAS_HOME_ENVIRONMENT_VARIABLE];
|
|
115
128
|
if (configuredHome !== undefined && !isAbsolute(configuredHome)) {
|
|
116
129
|
throw new Error(`${SEMANTIC_ATLAS_HOME_ENVIRONMENT_VARIABLE} must be an absolute path`);
|
|
@@ -119,12 +132,6 @@ export function resolveAtlasHome(repository) {
|
|
|
119
132
|
mkdirSync(atlasHome, { recursive: true, mode: 0o700 });
|
|
120
133
|
requireRealDirectory(atlasHome, "The Semantic Atlas home");
|
|
121
134
|
const realAtlasHome = realpathSync(atlasHome);
|
|
122
|
-
for (const worktreeRoot of repository.worktreeRoots) {
|
|
123
|
-
const realWorktreeRoot = realpathExistingPath(worktreeRoot);
|
|
124
|
-
if (realWorktreeRoot !== null && isPathInside(realAtlasHome, realWorktreeRoot)) {
|
|
125
|
-
throw new Error("The Semantic Atlas home must be outside every repository worktree");
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
135
|
return realAtlasHome;
|
|
129
136
|
}
|
|
130
137
|
export function resolveAtlasDatabasePath(repository) {
|
package/docs/contracts/cli-v1.md
CHANGED
|
@@ -4,12 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
The npm package and executable are both named `semantic-atlas`. Development uses Node.js 24; the published CLI supports Node.js 22.12 through 24.
|
|
6
6
|
|
|
7
|
-
Repository-independent commands run before Git, Atlas storage, or
|
|
8
|
-
opened:
|
|
7
|
+
Repository-independent lifecycle commands run before Git, Atlas storage, or
|
|
8
|
+
SQLite is opened:
|
|
9
9
|
|
|
10
10
|
| Command | Contract |
|
|
11
11
|
| --- | --- |
|
|
12
|
-
| `setup` | Atomically install or update the exact bundled
|
|
12
|
+
| `setup` | Atomically install or update the exact bundled `semantic-atlas` and `semantic-atlas-insights` Skills at `~/.agents/skills/`. A recognized legacy `~/.codex/skills/semantic-atlas` copy is removed after the shared installation succeeds. |
|
|
13
|
+
| `upgrade` | Resolve npm's `latest` tag, install that exact release globally, verify the new executable, and invoke the new package's `setup`. An already-current package still verifies and repairs its bundled Skills. |
|
|
13
14
|
| `-h`, `--help` | Print top-level usage and command help. |
|
|
14
15
|
| `--version` | Print the installed package version. |
|
|
15
16
|
|
|
@@ -19,10 +20,22 @@ repeated execution verifies the installed files and restores a changed managed
|
|
|
19
20
|
copy. A directory that does not identify itself as the Semantic Atlas Skill is
|
|
20
21
|
reported as a conflict and left unchanged.
|
|
21
22
|
|
|
23
|
+
`upgrade` resolves a version before mutation and installs
|
|
24
|
+
`semantic-atlas@<resolved-version>` rather than leaving the install step bound to
|
|
25
|
+
a moving tag. It locates the new package through npm's global root and starts its
|
|
26
|
+
CLI through the current Node executable, so Skill synchronization is owned by
|
|
27
|
+
the package that was actually installed. Registry lookup, package installation,
|
|
28
|
+
new-version verification, and Skill synchronization are one fail-closed command:
|
|
29
|
+
any failed step returns exit code `1` and does not report the upgrade as ready.
|
|
30
|
+
These lifecycle commands do not discover a Git repository or open Atlas storage.
|
|
31
|
+
Installation-scoped `insights` commands also avoid Git and repository Atlas
|
|
32
|
+
storage, while opening the separate local insights store described in
|
|
33
|
+
[Insights v1](insights-v1.md).
|
|
34
|
+
|
|
22
35
|
Global project options:
|
|
23
36
|
|
|
24
37
|
- `--repo <path>` selects a directory within the target repository; the default is the current directory.
|
|
25
|
-
- `--pretty` indents JSON without changing fields or values.
|
|
38
|
+
- `--pretty` indents a project or insights JSON envelope without changing fields or values.
|
|
26
39
|
|
|
27
40
|
Project commands:
|
|
28
41
|
|
|
@@ -36,6 +49,7 @@ Project commands:
|
|
|
36
49
|
| `code search <structural-term> [--limit <n>]` | Return bounded structural symbols and source locations when business knowledge is absent or insufficient; the default limit is 20. |
|
|
37
50
|
| `learn --stdin` | Read one complete GraphPatch v1 JSON value from standard input and apply it atomically. |
|
|
38
51
|
| `changes [--from <snapshot-id>] [--to <snapshot-id>]` | Report net semantic graph changes between persisted Atlas snapshot endpoints, not a raw Git diff. The source must be an ancestor of the target in the publication chain; defaults compare the previous and current snapshots. |
|
|
52
|
+
| `feedback report --stdin` | Store an explicit, evidence-contextual product problem or suggestion after source confirmation. The report links nearby local command-event IDs without storing arguments or output. |
|
|
39
53
|
|
|
40
54
|
`map` commands expose business navigation. `code search` is the explicit structural fallback. The calling agent extracts concepts, reformulates searches, opens returned source locations, and judges impact.
|
|
41
55
|
|
|
@@ -90,6 +104,7 @@ The schema requires these fields while allowing additive fields inside command d
|
|
|
90
104
|
| `code.search` | `query`, `limit`, scored structural-only `results` with source locations and support |
|
|
91
105
|
| `learn` | `baseSnapshotId`, `snapshotId`, applied operation counts |
|
|
92
106
|
| `changes` | source and target snapshot IDs, node/relation change sets, stale assertions |
|
|
107
|
+
| `feedback.report` | created report ID, classification, source-confirmed flag, status, and linked-event count |
|
|
93
108
|
|
|
94
109
|
`index.facts` uses one structural-fact unit across every publication: one backend node or
|
|
95
110
|
relation is one fact. `added`, `changed`, and `reused` partition the facts in the newly
|
|
@@ -105,6 +120,12 @@ Each connection identifies visible business endpoints and groups summaries by re
|
|
|
105
120
|
|
|
106
121
|
`BUSINESS_KNOWLEDGE_EMPTY` is the stable warning code for a current indexed world with no learned business nodes. World `map.view` returns an empty `regions` array in this state. Structural modules and symbols remain discoverable through `code.search`; they are never emitted as business regions.
|
|
107
122
|
|
|
123
|
+
`feedback report --stdin` accepts one strict JSON object with `kind`, `category`,
|
|
124
|
+
`impact`, `observed`, `expected`, optional `suggestion`, and `sourceConfirmed`.
|
|
125
|
+
The report itself is explicit feedback; the surrounding passive command event
|
|
126
|
+
contains only objective metadata. It is operational product data and never a
|
|
127
|
+
GraphPatch or business-world assertion.
|
|
128
|
+
|
|
108
129
|
Change ranges follow the current publication history and fold the requested endpoints into one content comparison. When a content-addressed snapshot was published more than once, `--to` selects its latest occurrence in that history and `--from` selects the latest matching occurrence at or before the target; equal IDs compare the selected occurrence with itself. Paths that have the same presence and content at both endpoints are omitted even if they changed in between, while `staleAssertions` reports the selected target occurrence's final validity state. An unknown target has no change result.
|
|
109
130
|
|
|
110
131
|
## Errors
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
# Insights Contract v1
|
|
2
|
+
|
|
3
|
+
## Question and scope
|
|
4
|
+
|
|
5
|
+
This page defines the local product-observability interface for Semantic Atlas.
|
|
6
|
+
It answers how a maintainer can evaluate adoption and confirmed friction without
|
|
7
|
+
adding work to a normal engineering task. The current contract is implemented
|
|
8
|
+
by `semantic-atlas insights` and `semantic-atlas feedback report`.
|
|
9
|
+
|
|
10
|
+
Insights are installation-scoped under `~/.semantic-atlas/insights.db`, or the
|
|
11
|
+
absolute `SEMANTIC_ATLAS_HOME` override. They are separate from each
|
|
12
|
+
repository's `atlas.db` knowledge and every worktree's `.atlas` projection.
|
|
13
|
+
|
|
14
|
+
## Data boundary
|
|
15
|
+
|
|
16
|
+
Every completed project command best-effort records one event containing:
|
|
17
|
+
|
|
18
|
+
- repository identity and the current snapshot identity when available;
|
|
19
|
+
- command name, outcome, exit code, stable warning codes, and rounded duration;
|
|
20
|
+
- a generated event ID and timestamp.
|
|
21
|
+
|
|
22
|
+
Events never contain command arguments, prompts, query text, source text, or
|
|
23
|
+
command output. A failure to write an event never changes the project command's
|
|
24
|
+
exit code, JSON response, or standard output.
|
|
25
|
+
|
|
26
|
+
`feedback report --stdin` stores explicit Agent input only when source
|
|
27
|
+
confirmation establishes meaningful product friction or a concrete improvement.
|
|
28
|
+
Each report includes a product classification, observed and expected behavior,
|
|
29
|
+
an optional suggestion, and up to five recent event IDs from the same
|
|
30
|
+
repository. The maintainer must keep this text concise and free of credentials,
|
|
31
|
+
source contents, prompts, command output, and unrelated task detail.
|
|
32
|
+
|
|
33
|
+
## Commands
|
|
34
|
+
|
|
35
|
+
| Command | Result |
|
|
36
|
+
| --- | --- |
|
|
37
|
+
| `semantic-atlas insights summary [--period <period>]` | Aggregates command outcomes, command names, warning codes, and feedback categories. |
|
|
38
|
+
| `semantic-atlas insights feedback [--period <period>] [--status <status>]` | Lists explicit feedback reports for review. |
|
|
39
|
+
| `semantic-atlas insights feedback update --stdin` | Writes one triage decision: `triaged`, `resolved`, or `dismissed`, with a required explanatory note. |
|
|
40
|
+
| `semantic-atlas feedback report --stdin` | Project-scoped write of one evidence-contextual product report. |
|
|
41
|
+
|
|
42
|
+
The default period is `today`; accepted period values are `today`, `yesterday`,
|
|
43
|
+
`7d`, `30d`, and `all`. Day boundaries use the executing machine's local time,
|
|
44
|
+
and stored timestamps are ISO-8601 UTC. `--pretty` indents insights responses.
|
|
45
|
+
|
|
46
|
+
## Envelope
|
|
47
|
+
|
|
48
|
+
`insights` commands write the strict, repository-independent schema in
|
|
49
|
+
`schemas/insights-envelope-v1.schema.json`:
|
|
50
|
+
|
|
51
|
+
```json
|
|
52
|
+
{
|
|
53
|
+
"schemaVersion": 1,
|
|
54
|
+
"status": "ok",
|
|
55
|
+
"data": {
|
|
56
|
+
"command": "insights.summary",
|
|
57
|
+
"range": {
|
|
58
|
+
"from": "2026-08-20T16:00:00.000Z",
|
|
59
|
+
"to": "2026-08-21T16:00:00.000Z"
|
|
60
|
+
},
|
|
61
|
+
"summary": {
|
|
62
|
+
"commands": { "total": 12, "outcomes": { "ok": 10, "partial": 2, "error": 0 }, "byCommand": [], "warningCodes": [] },
|
|
63
|
+
"feedback": { "total": 1, "byCategory": [] }
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
The envelope intentionally omits repository and snapshot fields because one
|
|
70
|
+
installation-level query can aggregate many repositories. Individual feedback
|
|
71
|
+
reports retain their hashed repository and nullable snapshot identity.
|
|
72
|
+
|
|
73
|
+
Invalid input returns the same envelope with `status: "error"`,
|
|
74
|
+
`data.error.code: "INVALID_INPUT"`, and exit code `2`. An internal local-store
|
|
75
|
+
failure returns `INTERNAL_ERROR` and exit code `1`. Successful data, including
|
|
76
|
+
an empty range, returns exit code `0`.
|
|
77
|
+
|
|
78
|
+
## Interpretation
|
|
79
|
+
|
|
80
|
+
Command volume and warnings show usage shape; they are not a retrieval-recall
|
|
81
|
+
or task-quality score. Evaluate a product change by connecting trends to
|
|
82
|
+
source-confirmed feedback, reproducible investigations, tests, and fresh-agent
|
|
83
|
+
task evaluation. The `semantic-atlas-insights` Skill provides the daily review
|
|
84
|
+
and triage workflow while the primary Skill stays focused on development work.
|
package/docs/index.md
CHANGED
|
@@ -29,6 +29,8 @@ source and tests.
|
|
|
29
29
|
contract.
|
|
30
30
|
- [CLI v1](contracts/cli-v1.md): deterministic commands, envelopes, warnings,
|
|
31
31
|
and exit codes.
|
|
32
|
+
- [Insights v1](contracts/insights-v1.md): local product signals, explicit
|
|
33
|
+
feedback, triage, storage boundary, and interpretation.
|
|
32
34
|
|
|
33
35
|
## Evaluation
|
|
34
36
|
|
package/docs/log.md
CHANGED
|
@@ -3,6 +3,30 @@
|
|
|
3
3
|
This log records material documentation ingestion and revisions. Current
|
|
4
4
|
conclusions live on their owning pages rather than in this chronology.
|
|
5
5
|
|
|
6
|
+
## [2026-08-21] add | Local product insights and separate maintenance Skill
|
|
7
|
+
|
|
8
|
+
- Added passive, installation-level command observations plus explicit,
|
|
9
|
+
evidence-contextual feedback and a strict `insights` JSON envelope.
|
|
10
|
+
- Kept normal task context lean: the primary Skill loads feedback guidance only
|
|
11
|
+
after confirmed material friction, while a separately installed insights Skill
|
|
12
|
+
owns daily review and feedback triage.
|
|
13
|
+
- Defined the privacy boundary, interpretation limits, and independent
|
|
14
|
+
repository/worktree storage in `contracts/insights-v1.md`.
|
|
15
|
+
- Affected pages: `product-contract.md`, `contracts/cli-v1.md`,
|
|
16
|
+
`contracts/insights-v1.md`, and `index.md`.
|
|
17
|
+
|
|
18
|
+
## [2026-08-20] revise | Business-first README and managed package upgrade
|
|
19
|
+
|
|
20
|
+
- Rebuilt the bilingual README around the product gap between file search and
|
|
21
|
+
business understanding, task-driven learning, and one semantically zoomable
|
|
22
|
+
map.
|
|
23
|
+
- Added repository-independent `upgrade`: resolve npm `latest`, install the
|
|
24
|
+
exact target, verify the new CLI, and synchronize the new package's Skill.
|
|
25
|
+
- Kept `setup` as the repair and synchronization command for the currently
|
|
26
|
+
installed package, including the already-current upgrade path.
|
|
27
|
+
- Affected pages: `README.md`, `README.zh-CN.md`, `product-contract.md`, and
|
|
28
|
+
`contracts/cli-v1.md`.
|
|
29
|
+
|
|
6
30
|
## [2026-08-20] revise | Versioned evaluation command replay
|
|
7
31
|
|
|
8
32
|
- Bound each Fresh Agent run to the command-policy version that produced it.
|
package/docs/product-contract.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Semantic Atlas
|
|
1
|
+
# Semantic Atlas Product Contract
|
|
2
2
|
|
|
3
3
|
## Purpose and authority
|
|
4
4
|
|
|
@@ -6,14 +6,15 @@ Semantic Atlas is a local project world model used by AI coding agents. It conne
|
|
|
6
6
|
|
|
7
7
|
Source code remains authoritative. Atlas is a revision-aware projection with explicit evidence and validity. A stale, unsupported, unresolved, or insufficient result sends the calling agent back to source inspection.
|
|
8
8
|
|
|
9
|
-
This document
|
|
9
|
+
This document defines the current product boundary. The versioned machine contracts live in `schemas/`; the storage and integration design is defined in [CodeGraph backend architecture](architecture/codegraph-backend.md).
|
|
10
10
|
|
|
11
11
|
## One-product boundary
|
|
12
12
|
|
|
13
13
|
Users and calling agents interact with one product:
|
|
14
14
|
|
|
15
15
|
- the `semantic-atlas` CLI supplies deterministic, machine-readable operations;
|
|
16
|
-
- the
|
|
16
|
+
- the `semantic-atlas` Skill teaches the calling agent when and how to use those operations;
|
|
17
|
+
- the separate `semantic-atlas-insights` Skill supports deliberate product review and feedback triage;
|
|
17
18
|
- `@colbymchenry/codegraph` is an internal structural-index dependency behind an Atlas-owned adapter;
|
|
18
19
|
- CodeGraph's CLI, MCP server, storage model, and public types are not exposed as Semantic Atlas workflows.
|
|
19
20
|
|
|
@@ -42,13 +43,14 @@ An indexed repository may legitimately have no business nodes. In that state, th
|
|
|
42
43
|
|
|
43
44
|
| Concern | Semantic Atlas | Calling agent |
|
|
44
45
|
| --- | --- | --- |
|
|
45
|
-
| Product interface | Exposes the `semantic-atlas` CLI and
|
|
46
|
-
|
|
|
46
|
+
| Product interface | Exposes the `semantic-atlas` CLI and two focused Skills | Chooses the repository, task scope, and maintenance cadence |
|
|
47
|
+
| Installation lifecycle | Ships version-matched primary and insights Skills, synchronizes them through `semantic-atlas setup`, and upgrades the global package plus Skills through `semantic-atlas upgrade` | Performs the initial global npm installation and can invoke setup or upgrade from any directory |
|
|
47
48
|
| Structural code model | Uses the embedded CodeGraph SDK for extraction, cross-file resolution, incremental sync, and structural queries | Reads source when the structural map is insufficient |
|
|
48
49
|
| Business world model | Stores and queries capabilities, scenarios, operations, invariants, interfaces, data, and their relationships | Understands natural language and decides which business assertions are justified |
|
|
49
50
|
| Unified graph | Connects business assertions to structural evidence and returns one Atlas graph contract | Uses graph results as bounded context |
|
|
50
51
|
| Evidence lifecycle | Records source locators and hashes, then derives `valid` or `stale` after indexing | Revalidates or replaces stale assertions |
|
|
51
52
|
| Generated state | Writes durable knowledge under the user Atlas home and disposable structure under ignored `.atlas/` | Edits source and project configuration |
|
|
53
|
+
| Product observability | Best-effort records objective command events and explicit feedback in the installation-level insights store | Reviews signals, validates reports, and chooses product follow-up work |
|
|
52
54
|
| Verification | Reports evidence, freshness, support, and unresolved boundaries | Runs tests, reviews diffs, and judges correctness |
|
|
53
55
|
| Git workflow | Reads Git state for snapshots without changing tracked state | Commits, merges, rebases, reviews, and releases |
|
|
54
56
|
|
|
@@ -60,6 +62,9 @@ Atlas separates repository knowledge from worktree structure:
|
|
|
60
62
|
~/.semantic-atlas/repositories/<repository-id>/
|
|
61
63
|
└── atlas.db repository-wide durable knowledge
|
|
62
64
|
|
|
65
|
+
~/.semantic-atlas/
|
|
66
|
+
└── insights.db installation-level product observations and feedback
|
|
67
|
+
|
|
63
68
|
<worktree>/
|
|
64
69
|
└── .atlas/
|
|
65
70
|
├── .gitignore
|
|
@@ -68,6 +73,7 @@ Atlas separates repository knowledge from worktree structure:
|
|
|
68
73
|
```
|
|
69
74
|
|
|
70
75
|
- The user-level `atlas.db` stores business knowledge, repository snapshots, snapshot-specific evidence bindings and validity, plus one publication chain for each Git directory.
|
|
76
|
+
- The separate user-level `insights.db` stores product command metadata and explicit feedback. It contains no business assertions, structural projection data, command arguments, prompts, source text, or command output.
|
|
71
77
|
- `SEMANTIC_ATLAS_HOME` is the only storage override. It must be absolute; the default is `~/.semantic-atlas`.
|
|
72
78
|
- Atlas prepares `.atlas/.gitignore` so generated state does not change normal Git status. No tracked source file or project configuration is created or modified.
|
|
73
79
|
- Every worktree has an independent CodeGraph index because its checked-out and dirty source state can differ. A missing index is copied from the best compatible sibling through SQLite backup and always incrementally synchronized before publication; full indexing is the fallback.
|
|
@@ -108,13 +114,13 @@ Root placement is provisional. Business keys remain stable vocabulary identifier
|
|
|
108
114
|
|
|
109
115
|
## Supported scope
|
|
110
116
|
|
|
111
|
-
|
|
117
|
+
The current release supports business understanding for TypeScript and JavaScript projects, with initial evaluation coverage for NestJS, GraphQL, TypeORM, and BullMQ flows. CodeGraph supplies the structural coverage available from the pinned dependency version. Atlas reports unsupported or unresolved structure instead of promising complete JavaScript runtime semantics.
|
|
112
118
|
|
|
113
119
|
Framework knowledge is implemented as Atlas-owned business interpretation over structural queries. It focuses on capabilities, operations, interfaces, data flow, rules, tests, and their evidence. Language parsing, cross-file symbol resolution, callers, callees, and file dependencies remain the structural backend's responsibility.
|
|
114
120
|
|
|
115
121
|
## Non-goals
|
|
116
122
|
|
|
117
|
-
|
|
123
|
+
Semantic Atlas does not provide:
|
|
118
124
|
|
|
119
125
|
- a second CodeGraph-facing product, CLI, MCP server, or user workflow;
|
|
120
126
|
- a new compiler, language server, or general-purpose JavaScript runtime analyzer;
|
|
@@ -132,7 +138,7 @@ The fallback order is direct dependency, a small upstream extension, a thin main
|
|
|
132
138
|
|
|
133
139
|
## Release gate
|
|
134
140
|
|
|
135
|
-
|
|
141
|
+
Every public release requires all of the following on the release commit:
|
|
136
142
|
|
|
137
143
|
1. A packaged install uses the pinned CodeGraph SDK through an Atlas-owned adapter and exposes no CodeGraph CLI or MCP workflow.
|
|
138
144
|
2. `semantic-atlas index` creates only ignored `.atlas/` state in the target worktree and leaves tracked files and normal Git status unchanged.
|
|
@@ -152,5 +158,6 @@ The gate is fixed before comparative results are collected. A failed gate create
|
|
|
152
158
|
- [CodeGraph backend architecture](architecture/codegraph-backend.md)
|
|
153
159
|
- [Graph model](contracts/graph-model.md)
|
|
154
160
|
- [CLI v1](contracts/cli-v1.md)
|
|
161
|
+
- [Insights v1](contracts/insights-v1.md)
|
|
155
162
|
- [GraphPatch v1](contracts/graph-patch-v1.md)
|
|
156
163
|
- [Evaluation protocol](evaluation.md)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "semantic-atlas",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "A local, revision-aware project world model for AI coding agents.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ai-agents",
|
|
@@ -36,10 +36,12 @@
|
|
|
36
36
|
},
|
|
37
37
|
"files": [
|
|
38
38
|
".agents/skills/semantic-atlas",
|
|
39
|
+
".agents/skills/semantic-atlas-insights",
|
|
39
40
|
"dist",
|
|
40
41
|
"docs",
|
|
41
42
|
"schemas",
|
|
42
43
|
"README.md",
|
|
44
|
+
"README.zh-CN.md",
|
|
43
45
|
"LICENSE"
|
|
44
46
|
],
|
|
45
47
|
"engines": {
|
|
@@ -604,6 +604,89 @@
|
|
|
604
604
|
"staleAssertions"
|
|
605
605
|
],
|
|
606
606
|
"additionalProperties": {}
|
|
607
|
+
},
|
|
608
|
+
{
|
|
609
|
+
"type": "object",
|
|
610
|
+
"properties": {
|
|
611
|
+
"command": {
|
|
612
|
+
"type": "string",
|
|
613
|
+
"const": "feedback.report"
|
|
614
|
+
},
|
|
615
|
+
"report": {
|
|
616
|
+
"type": "object",
|
|
617
|
+
"properties": {
|
|
618
|
+
"id": {
|
|
619
|
+
"type": "string",
|
|
620
|
+
"format": "uuid",
|
|
621
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
622
|
+
},
|
|
623
|
+
"kind": {
|
|
624
|
+
"type": "string",
|
|
625
|
+
"enum": [
|
|
626
|
+
"problem",
|
|
627
|
+
"suggestion"
|
|
628
|
+
]
|
|
629
|
+
},
|
|
630
|
+
"category": {
|
|
631
|
+
"type": "string",
|
|
632
|
+
"enum": [
|
|
633
|
+
"misleading-result",
|
|
634
|
+
"missing-knowledge",
|
|
635
|
+
"workflow-friction",
|
|
636
|
+
"performance",
|
|
637
|
+
"cli-error",
|
|
638
|
+
"skill-instruction"
|
|
639
|
+
]
|
|
640
|
+
},
|
|
641
|
+
"impact": {
|
|
642
|
+
"type": "string",
|
|
643
|
+
"enum": [
|
|
644
|
+
"blocked",
|
|
645
|
+
"slowed",
|
|
646
|
+
"minor"
|
|
647
|
+
]
|
|
648
|
+
},
|
|
649
|
+
"sourceConfirmed": {
|
|
650
|
+
"type": "boolean"
|
|
651
|
+
},
|
|
652
|
+
"status": {
|
|
653
|
+
"type": "string",
|
|
654
|
+
"enum": [
|
|
655
|
+
"new",
|
|
656
|
+
"triaged",
|
|
657
|
+
"resolved",
|
|
658
|
+
"dismissed"
|
|
659
|
+
]
|
|
660
|
+
},
|
|
661
|
+
"contextEventCount": {
|
|
662
|
+
"type": "integer",
|
|
663
|
+
"minimum": 0,
|
|
664
|
+
"maximum": 9007199254740991
|
|
665
|
+
},
|
|
666
|
+
"createdAt": {
|
|
667
|
+
"type": "string",
|
|
668
|
+
"format": "date-time",
|
|
669
|
+
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
|
|
670
|
+
}
|
|
671
|
+
},
|
|
672
|
+
"required": [
|
|
673
|
+
"id",
|
|
674
|
+
"kind",
|
|
675
|
+
"category",
|
|
676
|
+
"impact",
|
|
677
|
+
"sourceConfirmed",
|
|
678
|
+
"status",
|
|
679
|
+
"contextEventCount",
|
|
680
|
+
"createdAt"
|
|
681
|
+
],
|
|
682
|
+
"additionalProperties": false
|
|
683
|
+
}
|
|
684
|
+
},
|
|
685
|
+
"required": [
|
|
686
|
+
"command",
|
|
687
|
+
"report"
|
|
688
|
+
],
|
|
689
|
+
"additionalProperties": {}
|
|
607
690
|
}
|
|
608
691
|
]
|
|
609
692
|
},
|
|
@@ -670,7 +753,8 @@
|
|
|
670
753
|
"map.show",
|
|
671
754
|
"code.search",
|
|
672
755
|
"learn",
|
|
673
|
-
"changes"
|
|
756
|
+
"changes",
|
|
757
|
+
"feedback.report"
|
|
674
758
|
]
|
|
675
759
|
},
|
|
676
760
|
{
|