truemap-cli 0.3.0 → 0.5.1

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
@@ -2,21 +2,24 @@
2
2
 
3
3
  # truemap
4
4
 
5
- **A map of your codebase that your agent draws, and that stays true to the code.**
5
+ **Review what your coding agents plan and what they changed, on a map of your system that stays true to the code.**
6
6
 
7
- Your coding agent explains the project as HTML pages in your repo: a blueprint of the whole system, a page per module, the options when it needs your call. You read them in the browser, click any box to comment on it, and the agent answers right next to the page. Every box is pinned to real code, so when the code moves on, the map tells you.
7
+ Your agent keeps a map of the project in your repo: small boxes in groups, each pinned to real code. Before a bigger change it draws the plan on that map and waits for your approval. After it edits, the changed boxes light up with their lines, one click away from the diff. You ask about anything right next to the map, and the answer points at the boxes it talks about.
8
8
 
9
- ![The truemap workspace: a project blueprint with wires, a comment pinned to a box, and the agent's answer in the conversation panel](docs/images/workspace.png)
9
+ ![The truemap workspace: a plan drawn on the project map, with the new box dashed and the touched boxes marked, waiting for approval](docs/images/workspace.png)
10
10
 
11
11
  ## Why
12
12
 
13
- Coding agents write code faster than anyone can read it. Their explanations come back as walls of text, and the diagrams they draw are gone after one chat.
13
+ Coding agents write code faster than anyone can read it. Review is the bottleneck, and a wall of text or a 40-file diff is the wrong place to do it.
14
14
 
15
- - **Pages, not paragraphs.** The agent draws the architecture, a flow, or the options as a page and opens it for you.
16
- - **Point at it.** Switch on Annotate, click a box or select a sentence, write a comment. Comments go out together, each with the code it points to. It is the agent session you already have open: no login, no extra app.
17
- - **Click to decide.** When the agent needs your call, the page shows the options. One click and the answer is back with the agent.
18
- - **Pages that stay true.** Every box carries a `data-src="path#name"` anchor. When that code changes or disappears, the box is marked and the agent fixes the page.
19
- - **It stays in the repo.** Pages live in `.truemap/`, with `index.html` as the blueprint. Plain files you commit, diff and share.
15
+ - **Review the plan before the work.** For a change that touches several parts, the agent draws what it will add and touch on the map. Click a box to comment, then approve or ask for changes. The agent waits.
16
+ - **See the change after the work.** When the agent finishes a turn, a card in the conversation lists the boxes it changed (+/- lines) and files no box covers; the changed boxes carry their lines on the map. Click one to see its diff, next to what the plan said.
17
+ - **Ask, and the answer points.** Answers come as short steps; each step lights up the boxes it is about. Escape or a click on empty space brings back the plain map.
18
+ - **Click a box to follow it; double-click to comment.** A click lights its connections. A double-click opens a small card right there with what it is and a comment field; Details shows the real code, read live from your repo.
19
+ - **A map that stays true.** Every box carries a `data-src="path#name"` anchor. When that code changes or disappears, the box is marked and the agent fixes the map.
20
+ - **Many projects.** Every project with truemap running is one click away, and the tab tells you when another one needs you (a plan to review, a new reply).
21
+ - **Any agent.** Claude Code, Codex, OpenCode, Cursor CLI, or agents inside hosts such as T3 Code: anything that can run a shell command.
22
+ - **It stays in the repo.** Maps live in `.truemap/`. Plain HTML files you commit, diff and share.
20
23
 
21
24
  ## Install
22
25
 
@@ -26,7 +29,7 @@ Install the skill once. That is the whole setup.
26
29
  npx skills add TaoMachina/truemap --skill truemap
27
30
  ```
28
31
 
29
- Then talk to your agent (Claude Code or Codex) as usual: *"How does payment work?"* or *"Show me the project."* The agent writes or updates a page and opens it. You can also ask directly: `/truemap draw the architecture`.
32
+ Then work with your agent as usual. Ask *"show me the project"* for a first map; ask for a bigger change and the agent shows the plan first. You can also ask directly: `/truemap draw the architecture`.
30
33
 
31
34
  No skill installed? Tell the agent: *"use `npx -y truemap-cli --help`"*.
32
35
 
@@ -35,38 +38,39 @@ No skill installed? Tell the agent: *"use `npx -y truemap-cli --help`"*.
35
38
  ```
36
39
  your repo/
37
40
  └── .truemap/
38
- ├── index.html the blueprint: every module links to its page
39
- ├── payments.html
40
- ├── retry-decision.html
41
- └── assets/theme.css optional: your brand colors and font
41
+ ├── index.html the map of the whole system
42
+ ├── payments.html a page per module, when one is needed
43
+ └── plans/ plans the agent proposed (JSON)
42
44
  ```
43
45
 
44
46
  | Command (run by the agent) | What it does |
45
47
  |---|---|
46
- | `npx -y truemap-cli [page] [--annotate]` | Opens the workspace in your browser, or switches the tab you already have open |
47
- | `npx -y truemap-cli outline` | A compact map of the repo, so the first blueprint takes minutes, not an hour |
48
- | `npx -y truemap-cli listen` | Waits for your next message or comments from the page |
49
- | `npx -y truemap-cli reply "…" --listen` | Shows the answer in the conversation panel, then keeps listening |
50
- | `npx -y truemap-cli check` | Checks every `data-src` anchor against the code, and that every map wire has a target |
51
- | `npx -y truemap-cli export <page>` | Writes the page as one self-contained HTML file to share (also in the workspace ⋮ menu) |
52
- | `npx -y truemap-cli guide` | The page-writing guide for agents: the map, anchors, decisions, design rules |
48
+ | `npx -y truemap-cli [page]` | Opens the workspace in your browser, or switches the tab you already have open |
49
+ | `npx -y truemap-cli outline` | A compact outline of the repo, so the first map takes minutes |
50
+ | `npx -y truemap-cli plan --file plan.json` | Draws a plan on the map for review; `--approve` / `--done` from the terminal |
51
+ | `npx -y truemap-cli changes [--base head\|main]` | What changed, by box; also posted to the conversation after each turn |
52
+ | `npx -y truemap-cli listen` | Waits for your next message, comments or approval |
53
+ | `npx -y truemap-cli reply "…" --listen` | Shows the answer in the panel, then keeps listening |
54
+ | `npx -y truemap-cli show [page] --focus ids --note "…"` | Points at the map while explaining |
55
+ | `npx -y truemap-cli check` | Checks every anchor against the code, and that each map follows the drawing rules |
56
+ | `npx -y truemap-cli export <page>` | Writes a page as one self-contained HTML file to share |
57
+ | `npx -y truemap-cli guide` | The guide for agents: maps, anchors, plans, changes |
53
58
 
54
- The checker works for any language. It uses git and a plain-text search:
59
+ The map is declared, not drawn: the agent writes groups, boxes and connections in HTML, and truemap lays them out (one reading direction, few crossings, curved arrows with a verb on each). The look is fixed on purpose, so every map reads the same.
55
60
 
56
- - **No longer matches**: the path is gone, or `#name` no longer appears in the file (whole word, case-sensitive).
57
- - **Changed in code**: the file changed after the page was last updated. The agent reviews it, then updates the page or runs `check --ok`.
61
+ Changes come from git. truemap snapshots the working tree through a throwaway copy of the index (your staging area is never touched) and attributes each changed file to the boxes whose anchors cover it.
58
62
 
59
63
  Everything runs on your machine:
60
64
 
61
65
  - The server listens on `127.0.0.1` only and needs a per-launch token.
62
66
  - Pages render in a sandboxed frame on a separate origin, so page scripts can't reach the agent.
63
- - Nothing leaves your machine. truemap keeps a local log of which commands ran (`~/.truemap/usage.jsonl`) and the chat history per repo (`~/.truemap/history/`); delete them any time.
67
+ - Nothing leaves your machine. truemap keeps a local log of which commands ran (`~/.truemap/usage.jsonl`), the chat history and change snapshots per repo (`~/.truemap/`); delete them any time.
64
68
 
65
69
  ## Requirements
66
70
 
67
71
  - Node.js 20 or newer
68
- - git (optional; without it, only missing paths and names are checked)
72
+ - git (for change review; without it, only missing paths and names are checked)
69
73
 
70
74
  ## License
71
75
 
72
- MIT. Fonts: IBM Plex Sans and IBM Plex Mono, SIL Open Font License (`kit/fonts/OFL.txt`).
76
+ MIT. Fonts: Instrument Sans and Commit Mono, SIL Open Font License (`kit/fonts/`).
@@ -0,0 +1,90 @@
1
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
2
+ This license is copied below, and is also available with a FAQ at:
3
+ http://scripts.sil.org/OFL
4
+
5
+ -----------------------------------------------------------
6
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
7
+ -----------------------------------------------------------
8
+
9
+ PREAMBLE
10
+ The goals of the Open Font License (OFL) are to stimulate worldwide
11
+ development of collaborative font projects, to support the font creation
12
+ efforts of academic and linguistic communities, and to provide a free and
13
+ open framework in which fonts may be shared and improved in partnership
14
+ with others.
15
+
16
+ The OFL allows the licensed fonts to be used, studied, modified and
17
+ redistributed freely as long as they are not sold by themselves. The
18
+ fonts, including any derivative works, can be bundled, embedded,
19
+ redistributed and/or sold with any software provided that any reserved
20
+ names are not used by derivative works. The fonts and derivatives,
21
+ however, cannot be released under any other type of license. The
22
+ requirement for fonts to remain under this license does not apply
23
+ to any document created using the fonts or their derivatives.
24
+
25
+ DEFINITIONS
26
+ "Font Software" refers to the set of files released by the Copyright
27
+ Holder(s) under this license and clearly marked as such. This may
28
+ include source files, build scripts and documentation.
29
+
30
+ "Reserved Font Name" refers to any names specified as such after the
31
+ copyright statement(s).
32
+
33
+ "Original Version" refers to the collection of Font Software components as
34
+ distributed by the Copyright Holder(s).
35
+
36
+ "Modified Version" refers to any derivative made by adding to, deleting,
37
+ or substituting -- in part or in whole -- any of the components of the
38
+ Original Version, by changing formats or by porting the Font Software to a
39
+ new environment.
40
+
41
+ "Author" refers to any designer, engineer, programmer, technical
42
+ writer or other person who contributed to the Font Software.
43
+
44
+ PERMISSION & CONDITIONS
45
+ Permission is hereby granted, free of charge, to any person obtaining
46
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
47
+ redistribute, and sell modified and unmodified copies of the Font
48
+ Software, subject to the following conditions:
49
+
50
+ 1) Neither the Font Software nor any of its individual components,
51
+ in Original or Modified Versions, may be sold by itself.
52
+
53
+ 2) Original or Modified Versions of the Font Software may be bundled,
54
+ redistributed and/or sold with any software, provided that each copy
55
+ contains the above copyright notice and this license. These can be
56
+ included either as stand-alone text files, human-readable headers or
57
+ in the appropriate machine-readable metadata fields within text or
58
+ binary files as long as those fields can be easily viewed by the user.
59
+
60
+ 3) No Modified Version of the Font Software may use the Reserved Font
61
+ Name(s) unless explicit written permission is granted by the corresponding
62
+ Copyright Holder. This restriction only applies to the primary font name as
63
+ presented to the users.
64
+
65
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
66
+ Software shall not be used to promote, endorse or advertise any
67
+ Modified Version, except to acknowledge the contribution(s) of the
68
+ Copyright Holder(s) and the Author(s) or with their explicit written
69
+ permission.
70
+
71
+ 5) The Font Software, modified or unmodified, in part or in whole,
72
+ must be distributed entirely under this license, and must not be
73
+ distributed under any other license. The requirement for fonts to
74
+ remain under this license does not apply to any document created
75
+ using the Font Software.
76
+
77
+ TERMINATION
78
+ This license becomes null and void if any of the above conditions are
79
+ not met.
80
+
81
+ DISCLAIMER
82
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
83
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
84
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
85
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
86
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
87
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
88
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
89
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
90
+ OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,93 @@
1
+ Copyright 2022 The Instrument Sans Project Authors (https://github.com/Instrument/instrument-sans) InstrumentSans-Italic[wdth,wght].ttf: Copyright 2022 The Instrument Sans Project Authors (https://github.com/Instrument/instrument-sans)
2
+
3
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
4
+ This license is copied below, and is also available with a FAQ at:
5
+ http://scripts.sil.org/OFL
6
+
7
+
8
+ -----------------------------------------------------------
9
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10
+ -----------------------------------------------------------
11
+
12
+ PREAMBLE
13
+ The goals of the Open Font License (OFL) are to stimulate worldwide
14
+ development of collaborative font projects, to support the font creation
15
+ efforts of academic and linguistic communities, and to provide a free and
16
+ open framework in which fonts may be shared and improved in partnership
17
+ with others.
18
+
19
+ The OFL allows the licensed fonts to be used, studied, modified and
20
+ redistributed freely as long as they are not sold by themselves. The
21
+ fonts, including any derivative works, can be bundled, embedded,
22
+ redistributed and/or sold with any software provided that any reserved
23
+ names are not used by derivative works. The fonts and derivatives,
24
+ however, cannot be released under any other type of license. The
25
+ requirement for fonts to remain under this license does not apply
26
+ to any document created using the fonts or their derivatives.
27
+
28
+ DEFINITIONS
29
+ "Font Software" refers to the set of files released by the Copyright
30
+ Holder(s) under this license and clearly marked as such. This may
31
+ include source files, build scripts and documentation.
32
+
33
+ "Reserved Font Name" refers to any names specified as such after the
34
+ copyright statement(s).
35
+
36
+ "Original Version" refers to the collection of Font Software components as
37
+ distributed by the Copyright Holder(s).
38
+
39
+ "Modified Version" refers to any derivative made by adding to, deleting,
40
+ or substituting -- in part or in whole -- any of the components of the
41
+ Original Version, by changing formats or by porting the Font Software to a
42
+ new environment.
43
+
44
+ "Author" refers to any designer, engineer, programmer, technical
45
+ writer or other person who contributed to the Font Software.
46
+
47
+ PERMISSION & CONDITIONS
48
+ Permission is hereby granted, free of charge, to any person obtaining
49
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
50
+ redistribute, and sell modified and unmodified copies of the Font
51
+ Software, subject to the following conditions:
52
+
53
+ 1) Neither the Font Software nor any of its individual components,
54
+ in Original or Modified Versions, may be sold by itself.
55
+
56
+ 2) Original or Modified Versions of the Font Software may be bundled,
57
+ redistributed and/or sold with any software, provided that each copy
58
+ contains the above copyright notice and this license. These can be
59
+ included either as stand-alone text files, human-readable headers or
60
+ in the appropriate machine-readable metadata fields within text or
61
+ binary files as long as those fields can be easily viewed by the user.
62
+
63
+ 3) No Modified Version of the Font Software may use the Reserved Font
64
+ Name(s) unless explicit written permission is granted by the corresponding
65
+ Copyright Holder. This restriction only applies to the primary font name as
66
+ presented to the users.
67
+
68
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69
+ Software shall not be used to promote, endorse or advertise any
70
+ Modified Version, except to acknowledge the contribution(s) of the
71
+ Copyright Holder(s) and the Author(s) or with their explicit written
72
+ permission.
73
+
74
+ 5) The Font Software, modified or unmodified, in part or in whole,
75
+ must be distributed entirely under this license, and must not be
76
+ distributed under any other license. The requirement for fonts to
77
+ remain under this license does not apply to any document created
78
+ using the Font Software.
79
+
80
+ TERMINATION
81
+ This license becomes null and void if any of the above conditions are
82
+ not met.
83
+
84
+ DISCLAIMER
85
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93
+ OTHER DEALINGS IN THE FONT SOFTWARE.