@codacy/verity-cli 0.32.5-experimental.4d91ca0 → 0.32.6-experimental.833e71a
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 +38 -0
- package/README.md +28 -0
- package/bin/verity.js +2536 -836
- package/data/skills/verity-reflect/SKILL.md +55 -31
- package/package.json +1 -1
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: >-
|
|
3
3
|
Capture a durable learning at the end of a task: draft a concrete, cited observation from
|
|
4
|
-
what actually happened
|
|
4
|
+
what actually happened and record it straight into the project knowledge base. Use at natural
|
|
5
5
|
task-completion moments, or when the user asks to record a lesson.
|
|
6
6
|
---
|
|
7
7
|
# /verity-reflect — Capture learnings after a task
|
|
8
8
|
|
|
9
|
-
At a natural task-completion moment, **the agent reflects
|
|
10
|
-
concrete, cited observation from what actually happened
|
|
11
|
-
|
|
12
|
-
"reflection flip": Verity stops asking the user to do the reflecting and instead
|
|
13
|
-
does the work, with the human as editor rather than author.
|
|
9
|
+
At a natural task-completion moment, **the agent reflects and records** — draft a
|
|
10
|
+
concrete, cited observation from what actually happened, write it to the project
|
|
11
|
+
knowledge base, and say what you wrote. No question, no waiting.
|
|
14
12
|
|
|
15
|
-
|
|
13
|
+
This is the second half of the "reflection flip". Verity first stopped asking the
|
|
14
|
+
user to do the reflecting; it now also stops asking permission to keep it. The
|
|
15
|
+
human is a reader and editor of the record, not a gate in front of it.
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
## The flow
|
|
18
|
+
|
|
19
|
+
### 1. Draft
|
|
18
20
|
|
|
19
21
|
When a task is complete, draft **1–3** things genuinely worth remembering — a
|
|
20
22
|
**decision**, a **gotcha**, or a **pattern** — from what happened this task. Each
|
|
@@ -22,47 +24,69 @@ item must be **concrete and cited**: name the files, PR, commands, or
|
|
|
22
24
|
error-signatures it came from. **Skip entirely if nothing non-obvious happened**
|
|
23
25
|
— an empty reflection is better than a filler one.
|
|
24
26
|
|
|
27
|
+
That last rule is now the *only* filter. Nobody is going to catch a weak
|
|
28
|
+
reflection before it lands, so do not record one.
|
|
29
|
+
|
|
25
30
|
Pick the right `--kind` per item: `decision`, `gotcha`, `pattern`, `security`,
|
|
26
31
|
`quality`, `intent`, `domain`, `integration`.
|
|
27
32
|
|
|
28
|
-
|
|
33
|
+
**Citing the files is not decoration — it is what makes the reflection findable.**
|
|
34
|
+
Verity scopes a node to the paths named in its text, and retrieval seeds on that
|
|
35
|
+
scope. A reflection that names no file in this repo is recorded and then never
|
|
36
|
+
surfaces again, in any future review. So write `src/payments/retry.ts:88`, not
|
|
37
|
+
"the retry path".
|
|
38
|
+
|
|
39
|
+
### 2. Record it
|
|
29
40
|
|
|
30
|
-
|
|
31
|
-
|
|
41
|
+
```bash
|
|
42
|
+
verity reflect --user-input "<your draft>" --kind <kind>
|
|
43
|
+
```
|
|
32
44
|
|
|
33
|
-
|
|
34
|
-
|
|
45
|
+
That is the whole step. It never blocks, never prompts, and works the same in a
|
|
46
|
+
TTY, a hook, CI, or a cron run.
|
|
35
47
|
|
|
36
|
-
|
|
48
|
+
If the reflection genuinely cannot name its files in prose, scope it explicitly:
|
|
37
49
|
|
|
38
50
|
```bash
|
|
39
|
-
verity reflect --user-input "<
|
|
51
|
+
verity reflect --user-input "<your draft>" --kind <kind> --file-globs "src/auth/**"
|
|
40
52
|
```
|
|
41
53
|
|
|
42
|
-
|
|
54
|
+
The command warns when a reflection resolved to no files, so you will know when
|
|
55
|
+
this is needed rather than discovering it months later as a node nobody read.
|
|
43
56
|
|
|
44
|
-
**
|
|
45
|
-
|
|
46
|
-
never blocking:
|
|
57
|
+
**When the *user* authored the words** — they said "record this: …", or dictated
|
|
58
|
+
a lesson in their own terms — add `--confirmed`:
|
|
47
59
|
|
|
48
60
|
```bash
|
|
49
|
-
verity reflect --user-input "<
|
|
61
|
+
verity reflect --user-input "<what they said>" --kind <kind> --confirmed
|
|
50
62
|
```
|
|
51
63
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
64
|
+
This is not a formality. Without the flag a reflection is stored as
|
|
65
|
+
`source: agent` (confidence 0.7) — *Verity thought this, nobody checked it*. With
|
|
66
|
+
it, `source: user` at confidence 1.0 — *a person stands behind this*. The
|
|
67
|
+
dashboard, the retrieval ranking, and the next agent to read the node all rely on
|
|
68
|
+
the difference. Never pass `--confirmed` for your own draft, even a good one.
|
|
69
|
+
|
|
70
|
+
### 3. Tell the user, in one line
|
|
71
|
+
|
|
72
|
+
The command prints the node id, the local file path, and a dashboard link. Relay
|
|
73
|
+
it — one line, no ceremony:
|
|
74
|
+
|
|
75
|
+
> Recorded a gotcha about the Stripe retry path → `.verity/memory/gotchas/n104-stripe-idempotency-keys.md`
|
|
76
|
+
|
|
77
|
+
They did not agree to this in advance, so they need to know it happened and where
|
|
78
|
+
to go if it is wrong. Do not ask them to confirm it after the fact either — the
|
|
79
|
+
file is right there, and editing or deleting it is the correction.
|
|
55
80
|
|
|
56
|
-
###
|
|
81
|
+
### 4. Where it lands
|
|
57
82
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
`confidence: 1.0`, never auto-archived.
|
|
83
|
+
Only Verity's own memory namespace — `.verity/memory/` (mirrored to the service).
|
|
84
|
+
Verity never writes a repo's own `agents/memory` or any other store. One node per
|
|
85
|
+
item, synced to disk immediately so it is readable and editable straight away.
|
|
62
86
|
|
|
63
87
|
## Auto-reflection (extract from task history)
|
|
64
88
|
|
|
65
|
-
Complementary to the
|
|
89
|
+
Complementary to the above: trigger the server-side LLM extractor to mine the
|
|
66
90
|
current task's run history and produce 0–3 nodes. This is the same extraction
|
|
67
91
|
that runs automatically on task close and every 5 runs — use it to trigger
|
|
68
92
|
mid-task:
|
|
@@ -71,8 +95,8 @@ mid-task:
|
|
|
71
95
|
verity reflect
|
|
72
96
|
```
|
|
73
97
|
|
|
74
|
-
Use the
|
|
75
|
-
|
|
98
|
+
Use the draft flow above for the **compound moment** (a specific insight worth a
|
|
99
|
+
node); use auto-extract to harvest what the run history shows.
|
|
76
100
|
|
|
77
101
|
## When to reflect
|
|
78
102
|
|
package/package.json
CHANGED