truthmark 1.2.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/LICENSE +21 -0
- package/README.de.md +229 -0
- package/README.es.md +229 -0
- package/README.md +248 -0
- package/README.ru.md +229 -0
- package/README.zh.md +229 -0
- package/dist/main.js +3158 -0
- package/dist/main.js.map +1 -0
- package/package.json +69 -0
package/README.md
ADDED
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
# Truthmark
|
|
2
|
+
|
|
3
|
+
**Truthmark is the truth layer for AI software development.**
|
|
4
|
+
|
|
5
|
+
English | [Deutsch](README.de.md) | [中文](README.zh.md) | [Español](README.es.md) | [Русский](README.ru.md)
|
|
6
|
+
|
|
7
|
+
AI coding agents are already good at writing code. They are still bad at reliably reconstructing product intent, architecture boundaries, and repository ownership from stale docs, scattered chats, and ephemeral tool memory.
|
|
8
|
+
|
|
9
|
+
Truthmark fixes that by turning branch-local repository truth into a first-class runtime surface for agents. It installs a Git-native, branch-scoped truth layer directly inside the repo, gives agents explicit routing and workflow boundaries, and makes that truth move with the code that actually ships.
|
|
10
|
+
|
|
11
|
+
This is not better prompt engineering. It is a more governable way to use AI in a real codebase: fewer repeated decisions, fewer stale docs, cleaner handoffs, and AI coding sessions that leave behind reviewable engineering records instead of disappearing into prompt history or opaque tool state.
|
|
12
|
+
|
|
13
|
+
For teams who already know agents can generate code, and now need the repository itself to stay legible, reviewable, and governable.
|
|
14
|
+
|
|
15
|
+
## Why teams try it
|
|
16
|
+
|
|
17
|
+
AI coding is now easy to start and expensive to govern. Once agents can write code quickly, repository truth becomes the control surface.
|
|
18
|
+
|
|
19
|
+
That failure mode shows up in predictable ways: requirements live in chat, architecture decisions get repeated, agents touch the wrong surfaces, and branches inherit context that reviewers cannot reliably inspect. The code may move fast, but the repository gets harder to trust.
|
|
20
|
+
|
|
21
|
+
Truthmark changes the working model:
|
|
22
|
+
|
|
23
|
+
- Branch-local truth travels with the branch instead of living in a private tool store.
|
|
24
|
+
- Git makes that truth reviewable, diffable, and shareable across the team.
|
|
25
|
+
- Docs follow code instead of drifting quietly into fiction.
|
|
26
|
+
- Routing stays explicit in `docs/truthmark/areas.md` and delegated child route files so agents know which docs own which code.
|
|
27
|
+
- Active product and architecture decisions live in the canonical docs they govern instead of in timestamped planning logs.
|
|
28
|
+
- Local-first workflows avoid a daemon, database, remote service, or MCP dependency.
|
|
29
|
+
- The model works across JavaScript, TypeScript, Go, Python, C#, and Java codebases.
|
|
30
|
+
|
|
31
|
+
For tech leads, the value is governance without theater: tests, code review, and ownership still do the real work; Truthmark makes the agent's context durable, inspectable, and branch-scoped.
|
|
32
|
+
|
|
33
|
+
## Where Truthmark fits
|
|
34
|
+
|
|
35
|
+
Truthmark is not trying to replace every other AI workflow tool. It sits in a specific layer of the stack:
|
|
36
|
+
|
|
37
|
+
| If you need | Best fit |
|
|
38
|
+
| --- | --- |
|
|
39
|
+
| Better results from a single coding session | Better prompts and tighter task framing |
|
|
40
|
+
| Convenience across sessions for one agent or one operator | Memory tools |
|
|
41
|
+
| Spec-first planning for new features | Spec tools such as Spec Kit |
|
|
42
|
+
| Branch-scoped, reviewable repository truth that travels with the code | Truthmark |
|
|
43
|
+
|
|
44
|
+
The point is not that prompts, memory, or specs are useless. The point is that none of them, by themselves, turn repository truth into a committed, inspectable asset that survives handoffs, review, and branch divergence.
|
|
45
|
+
|
|
46
|
+
## Table of Contents
|
|
47
|
+
|
|
48
|
+
- [What Truthmark solves](#what-truthmark-solves)
|
|
49
|
+
- [Where Truthmark fits](#where-truthmark-fits)
|
|
50
|
+
- [Get started](#get-started)
|
|
51
|
+
- [How it runs](#how-it-runs)
|
|
52
|
+
- [What it installs](#what-it-installs)
|
|
53
|
+
- [Commands](#commands)
|
|
54
|
+
- [Why it exists](#why-it-exists)
|
|
55
|
+
- [Project status](#project-status)
|
|
56
|
+
- [Documentation](#documentation)
|
|
57
|
+
- [Non-goals](#non-goals)
|
|
58
|
+
- [License](#license)
|
|
59
|
+
|
|
60
|
+
## What Truthmark solves
|
|
61
|
+
|
|
62
|
+
Truthmark turns repository truth into an explicit workflow surface for agents:
|
|
63
|
+
|
|
64
|
+
- `TRUTHMARK.md` defines the branch-local workflow contract.
|
|
65
|
+
- `docs/truthmark/areas.md` and delegated child route files map code areas to the docs that own them.
|
|
66
|
+
- Truth Sync keeps mapped truth docs aligned with functional changes.
|
|
67
|
+
- Truth Realize gives doc-first changes a bounded code-update path.
|
|
68
|
+
- `truthmark check` validates the resulting truth artifacts.
|
|
69
|
+
- The whole model stays local-first and Git-native.
|
|
70
|
+
|
|
71
|
+
This is the core promise: agent context becomes committed repository state instead of a private session artifact.
|
|
72
|
+
|
|
73
|
+
## Get started
|
|
74
|
+
|
|
75
|
+
To try Truthmark from a source checkout instead of the published npm package:
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
cd /path/to/truthmark
|
|
79
|
+
npm install
|
|
80
|
+
npm run build
|
|
81
|
+
|
|
82
|
+
cd /path/to/your-repo
|
|
83
|
+
node /path/to/truthmark/dist/main.js config
|
|
84
|
+
node /path/to/truthmark/dist/main.js init
|
|
85
|
+
node /path/to/truthmark/dist/main.js check
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Review `.truthmark/config.yml` before `init`; it is the committed hierarchy contract. After `init`, review the generated workflow surface and route files so the routed docs match the docs that actually own your code:
|
|
89
|
+
|
|
90
|
+
```text
|
|
91
|
+
.truthmark/config.yml
|
|
92
|
+
TRUTHMARK.md
|
|
93
|
+
docs/truthmark/areas.md
|
|
94
|
+
docs/truthmark/areas/repository.md
|
|
95
|
+
docs/features/README.md
|
|
96
|
+
docs/features/repository/README.md
|
|
97
|
+
docs/features/repository/overview.md
|
|
98
|
+
AGENTS.md
|
|
99
|
+
CLAUDE.md
|
|
100
|
+
skills/truthmark-structure/SKILL.md
|
|
101
|
+
skills/truthmark-sync/SKILL.md
|
|
102
|
+
skills/truthmark-realize/SKILL.md
|
|
103
|
+
skills/truthmark-check/SKILL.md
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
If you enable additional platforms in `.truthmark/config.yml`, Truthmark refreshes the corresponding managed surfaces on the next `init`.
|
|
107
|
+
|
|
108
|
+
The default scaffold keeps feature `README.md` files as indexes and starts current behavior truth in bounded leaf docs such as `docs/features/repository/overview.md`.
|
|
109
|
+
|
|
110
|
+
Truthmark does not specify which subagent should run Truth Sync. The acting agent and host environment decide whether to delegate or run the workflow inline.
|
|
111
|
+
|
|
112
|
+
## How it runs
|
|
113
|
+
|
|
114
|
+
### Normal code changes
|
|
115
|
+
|
|
116
|
+
Most users should not need to invoke Truth Sync directly. The normal path is:
|
|
117
|
+
|
|
118
|
+
```text
|
|
119
|
+
agent changes functional code
|
|
120
|
+
run relevant tests
|
|
121
|
+
Truth Sync triggers before the agent finishes
|
|
122
|
+
review the truth-doc diff if one was produced
|
|
123
|
+
commit or hand off the work
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
Truth Sync is code-first: code leads, truth docs follow, and Truth Sync must not rewrite functional code. Its main job is to act as an automatic finish-time safeguard when functional code changed. Direct invocation is mainly for troubleshooting, forcing an early sync before handoff, or running the workflow intentionally.
|
|
127
|
+
|
|
128
|
+
Codex users can invoke it with `/truthmark-sync` or `$truthmark-sync`. OpenCode-style hosts can invoke `/skill truthmark-sync`.
|
|
129
|
+
|
|
130
|
+
### Doc-first changes
|
|
131
|
+
|
|
132
|
+
Use this when a product or architecture decision starts in docs:
|
|
133
|
+
|
|
134
|
+
```text
|
|
135
|
+
user edits truth docs
|
|
136
|
+
user explicitly invokes Truth Realize
|
|
137
|
+
agent reads truth docs and relevant code
|
|
138
|
+
agent updates code only
|
|
139
|
+
run relevant tests
|
|
140
|
+
commit or hand off the work
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
Truth Realize is manual and doc-first: truth docs lead, code follows, and the agent must not edit the truth docs it is realizing.
|
|
144
|
+
|
|
145
|
+
Codex users can invoke it with `/truthmark-realize` or `$truthmark-realize`. OpenCode-style hosts can invoke `/skill truthmark-realize`.
|
|
146
|
+
|
|
147
|
+
## What it installs
|
|
148
|
+
|
|
149
|
+
Truthmark keeps the durable workflow surface small:
|
|
150
|
+
|
|
151
|
+
- `.truthmark/config.yml` for machine-readable configuration
|
|
152
|
+
- `TRUTHMARK.md` for the branch-local workflow contract
|
|
153
|
+
- `docs/truthmark/areas.md` for the root route index
|
|
154
|
+
- `docs/truthmark/areas/**/*.md` for delegated child route files
|
|
155
|
+
- managed instruction blocks for configured platforms such as `AGENTS.md`, `CLAUDE.md`, Cursor rules, Copilot instructions, and `GEMINI.md`
|
|
156
|
+
- Codex and repo-local skills for Truth Structure, Truth Sync, Truth Realize, and Truth Check
|
|
157
|
+
|
|
158
|
+
The installed workflow surfaces are the runtime:
|
|
159
|
+
|
|
160
|
+
- Truth Structure creates or repairs area routing and starter truth docs.
|
|
161
|
+
- Truth Sync keeps mapped truth docs aligned with functional changes.
|
|
162
|
+
- Truth Realize updates code to match truth docs.
|
|
163
|
+
- Truth Check audits repository truth health.
|
|
164
|
+
|
|
165
|
+
Feature `README.md` files are indexes. Truth Sync is expected to read and update bounded leaf docs for current behavior.
|
|
166
|
+
|
|
167
|
+
Generated surfaces are managed by Truthmark, include a version marker, and may be refreshed by `truthmark init`.
|
|
168
|
+
|
|
169
|
+
## Commands
|
|
170
|
+
|
|
171
|
+
Truthmark V1 intentionally keeps the CLI small. In downstream repositories, `truthmark config` creates the committed hierarchy contract, `truthmark init` installs and refreshes workflow surfaces from that reviewed config, and `truthmark check` validates truth artifacts for manual audits, CI, or troubleshooting.
|
|
172
|
+
|
|
173
|
+
```bash
|
|
174
|
+
truthmark config
|
|
175
|
+
truthmark init
|
|
176
|
+
truthmark check
|
|
177
|
+
truthmark config --json
|
|
178
|
+
truthmark check --json
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
`config` writes only `.truthmark/config.yml` unless `--stdout` is used.
|
|
182
|
+
|
|
183
|
+
`init` requires `.truthmark/config.yml`, then installs or refreshes the local workflow files.
|
|
184
|
+
|
|
185
|
+
`check` validates configuration, authority, routing, decision-bearing docs, frontmatter, internal links, branch scope, and coverage diagnostics.
|
|
186
|
+
|
|
187
|
+
Truth Structure, Truth Sync, Truth Realize, and Truth Check are installed agent workflows, not top-level daily CLI commands.
|
|
188
|
+
|
|
189
|
+
## Why it exists
|
|
190
|
+
|
|
191
|
+
Most AI coding workflows optimize for the next answer. Truthmark optimizes for the next handoff.
|
|
192
|
+
|
|
193
|
+
It assumes serious teams need:
|
|
194
|
+
|
|
195
|
+
- branch-specific product truth
|
|
196
|
+
- durable architecture and API decisions
|
|
197
|
+
- explicit ownership between docs and code
|
|
198
|
+
- safe write boundaries for agents
|
|
199
|
+
- ordinary Git diffs that humans can review
|
|
200
|
+
- readable Markdown that teammates can inspect without special tooling
|
|
201
|
+
- truth that travels with the branch instead of living in hidden session state
|
|
202
|
+
- workflows that still work when the package is not installed globally
|
|
203
|
+
|
|
204
|
+
Truthmark is not a memory server and it is not an MCP server. It is a repository practice packaged as a small CLI installer plus agent-native workflow surfaces.
|
|
205
|
+
|
|
206
|
+
## Project status
|
|
207
|
+
|
|
208
|
+
V1 currently provides:
|
|
209
|
+
|
|
210
|
+
- `truthmark config`
|
|
211
|
+
- `truthmark init`
|
|
212
|
+
- `truthmark check`
|
|
213
|
+
- managed `AGENTS.md` workflow instructions
|
|
214
|
+
- generated Truth Structure, Truth Sync, Truth Realize, and Truth Check skill surfaces for configured agent hosts
|
|
215
|
+
- branch-scope metadata
|
|
216
|
+
- config, authority, routing, decision-structure, frontmatter, link, and polyglot coverage diagnostics
|
|
217
|
+
|
|
218
|
+
## Documentation
|
|
219
|
+
|
|
220
|
+
The root README is for people evaluating and trying the package. Detailed functional and business specifications live under `docs/`:
|
|
221
|
+
|
|
222
|
+
- [Docs index](docs/README.md)
|
|
223
|
+
- [Architecture overview](docs/architecture/overview.md)
|
|
224
|
+
- [API and CLI contracts](docs/features/contracts.md)
|
|
225
|
+
- [Init and scaffold behavior](docs/features/init-and-scaffold.md)
|
|
226
|
+
- [Check diagnostics](docs/features/check-diagnostics.md)
|
|
227
|
+
- [Installed workflows](docs/features/installed-workflows.md)
|
|
228
|
+
- [Repository truth maintenance guide](docs/standards/maintaining-repository-truth.md)
|
|
229
|
+
|
|
230
|
+
Current behavior belongs in the canonical docs tree above.
|
|
231
|
+
|
|
232
|
+
## Non-goals
|
|
233
|
+
|
|
234
|
+
Truthmark V1 is not:
|
|
235
|
+
|
|
236
|
+
- a hosted service
|
|
237
|
+
- an MCP server
|
|
238
|
+
- a vector database
|
|
239
|
+
- a documentation website generator
|
|
240
|
+
- a CI or PR enforcement product
|
|
241
|
+
- a replacement for tests, code review, or technical leadership
|
|
242
|
+
- an autonomous code rewrite engine
|
|
243
|
+
|
|
244
|
+
It is a lightweight way to make local AI coding agents respect the truth your team keeps in Git.
|
|
245
|
+
|
|
246
|
+
## License
|
|
247
|
+
|
|
248
|
+
MIT. See [LICENSE](LICENSE).
|
package/README.ru.md
ADDED
|
@@ -0,0 +1,229 @@
|
|
|
1
|
+
# Truthmark это слой истины для разработки ПО с ИИ.
|
|
2
|
+
|
|
3
|
+
[English](README.md) | [Deutsch](README.de.md) | [中文](README.zh.md) | [Español](README.es.md) | Русский
|
|
4
|
+
|
|
5
|
+
ИИ-агенты для разработки уже неплохо пишут код. Но они все еще плохо восстанавливают намерения продукта, архитектурные границы и зоны ответственности в репозитории по устаревшей документации, разрозненным чатам и недолговечной памяти инструментов.
|
|
6
|
+
Truthmark решает эту проблему: он превращает истину репозитория, локальную для ветки, в полноценную поверхность выполнения для агентов. Он устанавливает прямо в репозиторий Git-native слой истины с областью действия в пределах ветки, задает агентам явные границы маршрутизации и рабочих процессов и делает так, чтобы эта истина двигалась вместе с кодом, который действительно будет поставлен.
|
|
7
|
+
Это не более удачная инженерия промптов. Это более управляемый способ использовать ИИ в настоящей кодовой базе: меньше повторных решений, меньше устаревшей документации, чище передача работы и сессии с ИИ, после которых остаются проверяемые инженерные записи, а не только следы в истории промптов или непрозрачном состоянии инструментов.
|
|
8
|
+
Для команд, которые уже знают, что агенты умеют генерировать код, и теперь хотят, чтобы сам репозиторий оставался понятным, проверяемым и управляемым.
|
|
9
|
+
|
|
10
|
+
## Что решает Truthmark
|
|
11
|
+
|
|
12
|
+
Начать писать код с ИИ сейчас легко, но управлять этим дорого. Как только агенты начинают быстро писать код, истина репозитория становится поверхностью управления.
|
|
13
|
+
Этот сбой проявляется предсказуемо: требования остаются в чатах, архитектурные решения принимаются заново, агенты трогают не те области, а ветки наследуют контекст, который ревьюеры не могут надежно проверить. Код может двигаться быстро, но репозиторию становится труднее доверять.
|
|
14
|
+
Truthmark меняет рабочую модель:
|
|
15
|
+
|
|
16
|
+
- Истина, локальная для ветки, путешествует вместе с веткой, а не живет в приватном хранилище инструмента.
|
|
17
|
+
- Git делает эту истину проверяемой, сравнимой в diff и доступной всей команде.
|
|
18
|
+
- Документация следует за кодом, а не тихо превращается в вымысел.
|
|
19
|
+
- Маршрутизация остается явной в `docs/truthmark/areas.md` и делегированных дочерних файлах маршрутов, чтобы агенты понимали, какая документация отвечает за какой код.
|
|
20
|
+
- Активные продуктовые и архитектурные решения живут в канонических документах, которыми они управляют, а не в планировочных журналах с временными метками.
|
|
21
|
+
- Local-first рабочие процессы не требуют демона, базы данных, удаленного сервиса или MCP-зависимости.
|
|
22
|
+
- Модель работает в кодовых базах на JavaScript, TypeScript, Go, Python, C# и Java.
|
|
23
|
+
|
|
24
|
+
Для технических лидеров ценность в управлении без показухи: тесты, ревью кода и владение зонами ответственности по-прежнему делают основную работу; Truthmark делает контекст агента долговечным, проверяемым и ограниченным веткой.
|
|
25
|
+
|
|
26
|
+
## Где уместен Truthmark
|
|
27
|
+
|
|
28
|
+
Truthmark не пытается заменить все остальные инструменты для ИИ-процессов. Он занимает конкретный слой в стеке:
|
|
29
|
+
|
|
30
|
+
| Если вам нужно | Лучший выбор |
|
|
31
|
+
| ------------------------------------------------------------------------------------------------ | ---------------------------------------------- |
|
|
32
|
+
| Лучшие результаты в одной сессии разработки | Более точные промпты и лучше очерченная задача |
|
|
33
|
+
| Удобная преемственность между сессиями для одного агента или оператора | Инструменты памяти |
|
|
34
|
+
| Spec-first планирование новых функций | Инструменты спецификаций, например Spec Kit |
|
|
35
|
+
| Проверяемая истина репозитория с областью действия в пределах ветки, которая идет вместе с кодом | Truthmark |
|
|
36
|
+
|
|
37
|
+
Смысл не в том, что промпты, память или спецификации бесполезны. Смысл в том, что ни один из этих подходов сам по себе не превращает истину репозитория в зафиксированный в Git, проверяемый актив, который переживает передачу работы, ревью и расхождение веток.
|
|
38
|
+
|
|
39
|
+
## Содержание
|
|
40
|
+
|
|
41
|
+
- [Что решает Truthmark](#что-решает-truthmark)
|
|
42
|
+
- [Где уместен Truthmark](#где-уместен-truthmark)
|
|
43
|
+
- [Рабочая поверхность](#рабочая-поверхность)
|
|
44
|
+
- [Начало работы](#начало-работы)
|
|
45
|
+
- [Как он работает](#как-он-работает)
|
|
46
|
+
- [Что он устанавливает](#что-он-устанавливает)
|
|
47
|
+
- [Команды](#команды)
|
|
48
|
+
- [Зачем он существует](#зачем-он-существует)
|
|
49
|
+
- [Статус проекта](#статус-проекта)
|
|
50
|
+
- [Документация](#документация)
|
|
51
|
+
- [Не-цели](#не-цели)
|
|
52
|
+
- [Лицензия](#лицензия)
|
|
53
|
+
|
|
54
|
+
## Рабочая поверхность
|
|
55
|
+
|
|
56
|
+
Truthmark превращает истину репозитория в явную рабочую поверхность для агентов:
|
|
57
|
+
|
|
58
|
+
- `TRUTHMARK.md` определяет контракт рабочего процесса, локальный для ветки.
|
|
59
|
+
- `docs/truthmark/areas.md` и делегированные дочерние файлы маршрутов сопоставляют области кода с документами, которые за них отвечают.
|
|
60
|
+
- Truth Sync поддерживает синхронизацию сопоставленных документов истины при функциональных изменениях.
|
|
61
|
+
- Truth Realize дает изменениям, начинающимся с документации, ограниченный путь для обновления кода.
|
|
62
|
+
- `truthmark check` валидирует получившиеся артефакты истины.
|
|
63
|
+
- Вся модель остается local-first и Git-native.
|
|
64
|
+
|
|
65
|
+
Главное обещание такое: контекст агента становится зафиксированным состоянием репозитория, а не приватным артефактом отдельной сессии.
|
|
66
|
+
|
|
67
|
+
## Начало работы
|
|
68
|
+
|
|
69
|
+
Чтобы попробовать Truthmark на другом локальном репозитории до публикации пакета где-либо еще:
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
cd /path/to/truthmark
|
|
73
|
+
npm install
|
|
74
|
+
npm run build
|
|
75
|
+
cd /path/to/your-repo
|
|
76
|
+
node /path/to/truthmark/dist/main.js config
|
|
77
|
+
node /path/to/truthmark/dist/main.js init
|
|
78
|
+
node /path/to/truthmark/dist/main.js check
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Проверьте `.truthmark/config.yml` перед `init`; это зафиксированный в Git контракт иерархии. После `init` проверьте сгенерированную рабочую поверхность и файлы маршрутов, чтобы маршрутизированная документация действительно совпадала с документами, которые отвечают за ваш код:
|
|
82
|
+
|
|
83
|
+
```text
|
|
84
|
+
.truthmark/config.yml
|
|
85
|
+
TRUTHMARK.md
|
|
86
|
+
docs/truthmark/areas.md
|
|
87
|
+
docs/truthmark/areas/repository.md
|
|
88
|
+
docs/features/README.md
|
|
89
|
+
docs/features/repository/README.md
|
|
90
|
+
docs/features/repository/overview.md
|
|
91
|
+
AGENTS.md
|
|
92
|
+
CLAUDE.md
|
|
93
|
+
skills/truthmark-structure/SKILL.md
|
|
94
|
+
skills/truthmark-sync/SKILL.md
|
|
95
|
+
skills/truthmark-realize/SKILL.md
|
|
96
|
+
skills/truthmark-check/SKILL.md
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
Если вы включите дополнительные платформы в `.truthmark/config.yml`, Truthmark обновит соответствующие управляемые поверхности при следующем `init`.
|
|
100
|
+
Стандартная шаблонная структура использует `README.md` функциональных разделов как индексы и начинает описывать истину текущего поведения в ограниченных листовых документах, например `docs/features/repository/overview.md`.
|
|
101
|
+
|
|
102
|
+
## Как он работает
|
|
103
|
+
|
|
104
|
+
Truthmark не задает, какой именно подагент должен запускать Truth Sync. Действующий агент и среда хоста сами решают, делегировать работу или выполнить процесс на месте.
|
|
105
|
+
Большинству пользователей не нужно вызывать Truth Sync напрямую. Нормальный путь выглядит так:
|
|
106
|
+
|
|
107
|
+
```text
|
|
108
|
+
агент изменяет функциональный код
|
|
109
|
+
запускаются релевантные тесты
|
|
110
|
+
Truth Sync срабатывает до завершения работы агента
|
|
111
|
+
если был создан diff документов истины, он проверяется
|
|
112
|
+
работа коммитится или передается дальше
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
Truth Sync работает по принципу code-first: сначала идет код, затем документы истины, и Truth Sync не должен переписывать функциональный код. Его основная задача быть автоматической финальной проверкой, когда менялся функциональный код. Прямой вызов нужен в основном для отладки, ранней синхронизации перед передачей работы или намеренного запуска рабочего процесса.
|
|
116
|
+
Пользователи Codex могут вызывать его через `/truthmark-sync` или `$truthmark-sync`. Хосты в стиле OpenCode могут использовать `/skill truthmark-sync`.
|
|
117
|
+
Используйте этот путь, когда продуктовое или архитектурное решение начинается в документации:
|
|
118
|
+
|
|
119
|
+
```text
|
|
120
|
+
пользователь редактирует документы истины
|
|
121
|
+
пользователь явно вызывает Truth Realize
|
|
122
|
+
агент читает документы истины и связанный код
|
|
123
|
+
агент обновляет только код
|
|
124
|
+
запускаются релевантные тесты
|
|
125
|
+
работа коммитится или передается дальше
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
Truth Realize это ручной процесс по принципу doc-first: документы истины идут первыми, код следует за ними, и агент не должен редактировать документы истины, которые он реализует.
|
|
129
|
+
Пользователи Codex могут вызывать его через `/truthmark-realize` или `$truthmark-realize`. Хосты в стиле OpenCode могут использовать `/skill truthmark-realize`.
|
|
130
|
+
|
|
131
|
+
## Что он устанавливает
|
|
132
|
+
|
|
133
|
+
Truthmark намеренно держит постоянную рабочую поверхность маленькой:
|
|
134
|
+
|
|
135
|
+
- `.truthmark/config.yml` для машиночитаемой конфигурации
|
|
136
|
+
- `TRUTHMARK.md` для контракта рабочего процесса, локального для ветки
|
|
137
|
+
- `docs/truthmark/areas.md` для корневого индекса маршрутов
|
|
138
|
+
- `docs/truthmark/areas/**/*.md` для делегированных дочерних файлов маршрутов
|
|
139
|
+
- управляемые блоки инструкций для настроенных платформ, таких как `AGENTS.md`, `CLAUDE.md`, правила Cursor, инструкции Copilot и `GEMINI.md`
|
|
140
|
+
- Codex- и repo-local skills для Truth Structure, Truth Sync, Truth Realize и Truth Check
|
|
141
|
+
|
|
142
|
+
Установленные рабочие поверхности и есть среда выполнения:
|
|
143
|
+
|
|
144
|
+
- Truth Structure создает или исправляет маршрутизацию областей и стартовые документы истины.
|
|
145
|
+
- Truth Sync поддерживает синхронизацию сопоставленных документов истины с функциональными изменениями.
|
|
146
|
+
- Truth Realize обновляет код так, чтобы он соответствовал документам истины.
|
|
147
|
+
- Truth Check аудитирует здоровье истины репозитория.
|
|
148
|
+
|
|
149
|
+
`README.md` функциональных разделов это индексы. Ожидается, что Truth Sync будет читать и обновлять ограниченные листовые документы для текущего поведения.
|
|
150
|
+
|
|
151
|
+
Сгенерированные поверхности управляются Truthmark, содержат маркер версии и могут обновляться через `truthmark init`.
|
|
152
|
+
|
|
153
|
+
## Команды
|
|
154
|
+
|
|
155
|
+
Truthmark V1 намеренно держит CLI небольшим. В нижестоящих репозиториях `truthmark config` создает зафиксированный контракт иерархии, `truthmark init` устанавливает и обновляет рабочие поверхности на основе этой проверенной конфигурации, а `truthmark check` валидирует артефакты истины для ручных аудитов, CI или отладки.
|
|
156
|
+
|
|
157
|
+
```bash
|
|
158
|
+
truthmark config
|
|
159
|
+
truthmark init
|
|
160
|
+
truthmark check
|
|
161
|
+
truthmark config --json
|
|
162
|
+
truthmark check --json
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
`config` пишет только `.truthmark/config.yml`, если не используется `--stdout`.
|
|
166
|
+
`init` требует `.truthmark/config.yml`, а затем устанавливает или обновляет локальные файлы рабочих процессов.
|
|
167
|
+
`check` валидирует конфигурацию, полномочия, маршрутизацию, документы с решениями, frontmatter, внутренние ссылки, область действия ветки и диагностику покрытия.
|
|
168
|
+
Truth Structure, Truth Sync, Truth Realize и Truth Check это установленные агентские рабочие процессы, а не повседневные CLI-команды верхнего уровня.
|
|
169
|
+
|
|
170
|
+
## Зачем он существует
|
|
171
|
+
|
|
172
|
+
Большинство ИИ-процессов для разработки оптимизируют следующий ответ. Truthmark оптимизирует следующую передачу работы.
|
|
173
|
+
Он исходит из того, что серьезным командам нужны:
|
|
174
|
+
|
|
175
|
+
- продуктовая истина, специфичная для ветки
|
|
176
|
+
- долговечные архитектурные и API-решения
|
|
177
|
+
- явная ответственность между документацией и кодом
|
|
178
|
+
- безопасные границы записи для агентов
|
|
179
|
+
- обычные Git diff, которые могут проверить люди
|
|
180
|
+
- читаемый Markdown, который команда может просматривать без специальных инструментов
|
|
181
|
+
- истина, которая путешествует вместе с веткой, а не живет в скрытом состоянии сессии
|
|
182
|
+
- рабочие процессы, которые продолжают работать, даже если пакет не установлен глобально
|
|
183
|
+
|
|
184
|
+
## Статус проекта
|
|
185
|
+
|
|
186
|
+
Truthmark не является сервером памяти и не является MCP-сервером. Это репозиторная практика, упакованная как небольшой CLI-установщик и родные для агентов рабочие поверхности.
|
|
187
|
+
V1 сейчас предоставляет:
|
|
188
|
+
|
|
189
|
+
- `truthmark config`
|
|
190
|
+
- `truthmark init`
|
|
191
|
+
- `truthmark check`
|
|
192
|
+
- управляемые инструкции рабочих процессов в `AGENTS.md`
|
|
193
|
+
- сгенерированные skill-поверхности Truth Structure, Truth Sync, Truth Realize и Truth Check для настроенных агентских хостов
|
|
194
|
+
- метаданные области ветки
|
|
195
|
+
- диагностика конфигурации, полномочий, маршрутизации, структуры решений, frontmatter, ссылок и полиглотного покрытия
|
|
196
|
+
|
|
197
|
+
Не следует считать, что пакет `truthmark` без scope уже опубликован.
|
|
198
|
+
|
|
199
|
+
## Документация
|
|
200
|
+
|
|
201
|
+
Корневой README предназначен для людей, которые оценивают и пробуют пакет. Подробные функциональные и бизнес-спецификации находятся в `docs/`:
|
|
202
|
+
|
|
203
|
+
- [Индекс документации](docs/README.md)
|
|
204
|
+
- [Обзор архитектуры](docs/architecture/overview.md)
|
|
205
|
+
- [Контракты API и CLI](docs/features/contracts.md)
|
|
206
|
+
- [Поведение init и scaffold](docs/features/init-and-scaffold.md)
|
|
207
|
+
- [Диагностика check](docs/features/check-diagnostics.md)
|
|
208
|
+
- [Установленные workflow](docs/features/installed-workflows.md)
|
|
209
|
+
- [Руководство по поддержанию истины репозитория](docs/standards/maintaining-repository-truth.md)
|
|
210
|
+
|
|
211
|
+
Текущее поведение должно жить в каноническом дереве документации выше.
|
|
212
|
+
|
|
213
|
+
## Не-цели
|
|
214
|
+
|
|
215
|
+
Truthmark V1 не является:
|
|
216
|
+
|
|
217
|
+
- размещенным сервисом
|
|
218
|
+
- MCP-сервером
|
|
219
|
+
- векторной базой данных
|
|
220
|
+
- генератором сайтов документации
|
|
221
|
+
- продуктом принудительного контроля для CI или PR
|
|
222
|
+
- заменой тестов, code review или технического лидерства
|
|
223
|
+
- автономным движком для переписывания кода
|
|
224
|
+
|
|
225
|
+
Это легкий способ заставить локальных ИИ-агентов для разработки уважать истину, которую ваша команда хранит в Git.
|
|
226
|
+
|
|
227
|
+
## Лицензия
|
|
228
|
+
|
|
229
|
+
MIT. См. [LICENSE](LICENSE).
|