anima-cli 1.0.2 → 1.0.3
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 +21 -0
- package/README.md +122 -11
- package/package.json +8 -7
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Ariel Fernández
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,20 +1,131 @@
|
|
|
1
1
|
# anima-cli
|
|
2
2
|
|
|
3
|
+
[](https://www.npmjs.com/package/anima-cli)
|
|
4
|
+
[](./LICENSE)
|
|
5
|
+
[](https://nodejs.org)
|
|
6
|
+
|
|
7
|
+
Deterministic psychodynamic profiles for LLM agents. Give an agent a behavioral
|
|
8
|
+
structure — not a paragraph of adjectives you have to maintain by hand — run it
|
|
9
|
+
forward, and prove the result is reproducible byte-for-byte.
|
|
10
|
+
|
|
11
|
+
Built on [`@af199/anima-core`](https://www.npmjs.com/package/@af199/anima-core)
|
|
12
|
+
(7-dimensional state engine, seeded RNG) and
|
|
13
|
+
[`@af199/anima-trace`](https://www.npmjs.com/package/@af199/anima-trace)
|
|
14
|
+
(SHA-256 integrity hashing for run trajectories).
|
|
15
|
+
|
|
16
|
+
## Install
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
npm install -g anima-cli
|
|
3
20
|
```
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
21
|
+
|
|
22
|
+
Requires Node.js 16+.
|
|
23
|
+
|
|
24
|
+
## Quickstart
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
anima init # wizard: name, archetype, turns, signal preset
|
|
28
|
+
anima run <name> # step the engine forward, record + hash the trajectory
|
|
29
|
+
anima verify <name> # re-run and confirm the hash matches, byte for byte
|
|
30
|
+
anima export <name> --format prompt # emit a system-prompt fragment
|
|
9
31
|
```
|
|
10
32
|
|
|
11
|
-
|
|
33
|
+
## Commands
|
|
34
|
+
|
|
35
|
+
### `anima init`
|
|
36
|
+
|
|
37
|
+
Interactive wizard. Prompts for:
|
|
38
|
+
|
|
39
|
+
| Field | Description |
|
|
40
|
+
|---|---|
|
|
41
|
+
| Agent name | Identifier used by every other command |
|
|
42
|
+
| Archetype | One of: `histeria`, `obsesion`, `fobia`, `melancolia`, `paranoia`, `esquizofrenia`, `perversion` |
|
|
43
|
+
| Turns per run | How many steps `anima run` will execute (default 10) |
|
|
44
|
+
| Signal preset | `calm`, `clinical-crisis`, or `chaotic` — fixed signal vectors, no free text |
|
|
45
|
+
|
|
46
|
+
The seed is derived automatically from the agent name + creation date, so it's
|
|
47
|
+
stable across re-runs without you having to track it manually. Profiles are
|
|
48
|
+
saved to `./anima-profiles/<name>.json` in the current directory.
|
|
49
|
+
|
|
50
|
+
> Signal presets are fixed on purpose — there is no free-text signal input.
|
|
51
|
+
> This keeps every profile comparable and closes off prompt-injection style
|
|
52
|
+
> abuse of the signal channel.
|
|
53
|
+
|
|
54
|
+
### `anima run <name>`
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
anima run <name> [--turns N] [--preset calm|clinical-crisis|chaotic]
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Runs the engine for the profile's configured turns (or the override flags),
|
|
61
|
+
records the full state trajectory, and writes it to
|
|
62
|
+
`./anima-runs/<name>-<seed>.json` along with a SHA-256 integrity hash.
|
|
63
|
+
|
|
64
|
+
### `anima verify <name>`
|
|
65
|
+
|
|
66
|
+
Re-runs the stored signals against the engine and checks that the resulting
|
|
67
|
+
trajectory hash matches the one on file — byte for byte. This is the whole
|
|
68
|
+
trust model in one command: anyone with the run file can confirm it wasn't
|
|
69
|
+
tampered with and that the archetype+seed+signals genuinely produce that
|
|
70
|
+
trajectory.
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
$ anima verify test1
|
|
74
|
+
PASS — trajectory is byte-reproducible
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
### `anima export <name>`
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
anima export <name> [--format prompt|json] [--out file]
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
- `--format prompt` (default): a system-prompt fragment with one behavioral
|
|
84
|
+
directive per dimension, derived from the final state. Paste it into
|
|
85
|
+
Claude, GPT, Grok, or any other model's system prompt.
|
|
86
|
+
- `--format json`: the raw final state vector plus integrity hash, for your
|
|
87
|
+
own pipeline.
|
|
88
|
+
- `--out file`: write to a file instead of stdout.
|
|
89
|
+
|
|
90
|
+
## The 7 dimensions
|
|
91
|
+
|
|
92
|
+
Every archetype is a point in a 7-dimensional state space, stepped forward by
|
|
93
|
+
`@af199/anima-core`'s update equations on each turn:
|
|
94
|
+
|
|
95
|
+
| Symbol | Meaning |
|
|
96
|
+
|---|---|
|
|
97
|
+
| `E` | Expressive energy |
|
|
98
|
+
| `T` | Defensive tension |
|
|
99
|
+
| `A` | Anxiety |
|
|
100
|
+
| `C` | Symbolic closure |
|
|
101
|
+
| `G` | Jouissance / excess |
|
|
102
|
+
| `P` | Pressure |
|
|
103
|
+
| `ρ` (rho) | Fantasy rigidity |
|
|
12
104
|
|
|
13
105
|
## Known behavior: dimension saturation under high-intensity presets
|
|
14
106
|
|
|
15
|
-
Under sustained `clinical-crisis` or `chaotic` signal presets over several
|
|
16
|
-
(commonly `A` anxiety and `rho` fantasy rigidity) can
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
107
|
+
Under sustained `clinical-crisis` or `chaotic` signal presets over several
|
|
108
|
+
turns, some dimensions (commonly `A` anxiety and `rho` fantasy rigidity) can
|
|
109
|
+
drive to their floor (0) or ceiling (1) rather than settling mid-range. This
|
|
110
|
+
is the archetype's update equations behaving as designed, not a bug —
|
|
111
|
+
`anima verify` will confirm the trajectory is reproducible either way. `anima
|
|
112
|
+
export` flags saturated dimensions explicitly in its output. If you want more
|
|
113
|
+
gradual, mid-range trajectories, use the `calm` preset or fewer turns.
|
|
114
|
+
|
|
115
|
+
## Troubleshooting
|
|
116
|
+
|
|
117
|
+
**`profile not found: <name>`** — you ran `run`/`verify`/`export` from a
|
|
118
|
+
different directory than the one you ran `init` in. Profiles and runs are
|
|
119
|
+
scoped to `./anima-profiles` and `./anima-runs` in the current working
|
|
120
|
+
directory; `cd` back to where you initialized, or re-run `anima init` here.
|
|
121
|
+
|
|
122
|
+
**`no run found for <name>`** — you called `verify` or `export` before
|
|
123
|
+
`anima run <name>`. Run it first.
|
|
124
|
+
|
|
125
|
+
**`anima: command not found` after install** — your global npm bin directory
|
|
126
|
+
isn't on `PATH`. Run `npm config get prefix` and add `<prefix>/bin` (or
|
|
127
|
+
`<prefix>` on Windows) to your `PATH`, then restart the terminal.
|
|
128
|
+
|
|
129
|
+
## License
|
|
20
130
|
|
|
131
|
+
MIT
|
package/package.json
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "anima-cli",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "Deterministic psychodynamic profiles for LLM agents
|
|
3
|
+
"version": "1.0.3",
|
|
4
|
+
"description": "Deterministic psychodynamic profiles for LLM agents \u2014 7-dimensional state, seeded RNG, byte-reproducible traces, exportable to system prompts.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
7
|
-
"anima": "
|
|
7
|
+
"anima": "bin/anima.js"
|
|
8
8
|
},
|
|
9
9
|
"files": [
|
|
10
10
|
"bin/",
|
|
11
11
|
"src/",
|
|
12
|
-
"README.md"
|
|
12
|
+
"README.md",
|
|
13
|
+
"LICENSE"
|
|
13
14
|
],
|
|
14
15
|
"scripts": {
|
|
15
16
|
"test": "echo \"no tests yet\" && exit 0"
|
|
@@ -24,14 +25,14 @@
|
|
|
24
25
|
"system-prompt",
|
|
25
26
|
"cli"
|
|
26
27
|
],
|
|
27
|
-
"author": "Ariel
|
|
28
|
+
"author": "Ariel Fern\u00e1ndez",
|
|
28
29
|
"license": "MIT",
|
|
29
30
|
"engines": {
|
|
30
31
|
"node": ">=16"
|
|
31
32
|
},
|
|
32
33
|
"repository": {
|
|
33
34
|
"type": "git",
|
|
34
|
-
"url": "https://github.com/Peroroii/anima-cli.git"
|
|
35
|
+
"url": "git+https://github.com/Peroroii/anima-cli.git"
|
|
35
36
|
},
|
|
36
37
|
"homepage": "https://github.com/Peroroii/anima-cli#readme",
|
|
37
38
|
"dependencies": {
|
|
@@ -41,4 +42,4 @@
|
|
|
41
42
|
"commander": "^15.0.0",
|
|
42
43
|
"inquirer": "^8.2.7"
|
|
43
44
|
}
|
|
44
|
-
}
|
|
45
|
+
}
|