perttool 0.5.0 → 0.5.2

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.
Files changed (41) hide show
  1. package/CHANGELOG.md +39 -1
  2. package/README.md +66 -28
  3. package/dist/cli.js +41 -0
  4. package/dist/cli.js.map +1 -1
  5. package/dist/command/actuals-discovery.d.ts.map +1 -1
  6. package/dist/command/actuals-discovery.js +92 -13
  7. package/dist/command/actuals-discovery.js.map +1 -1
  8. package/dist/history/git-probe.d.ts +4 -0
  9. package/dist/history/git-probe.d.ts.map +1 -1
  10. package/dist/history/git-probe.js +23 -14
  11. package/dist/history/git-probe.js.map +1 -1
  12. package/dist/index.d.ts +2 -0
  13. package/dist/index.d.ts.map +1 -1
  14. package/dist/index.js +1 -0
  15. package/dist/index.js.map +1 -1
  16. package/dist/schema/registry.d.ts +53 -0
  17. package/dist/schema/registry.d.ts.map +1 -0
  18. package/dist/schema/registry.js +346 -0
  19. package/dist/schema/registry.js.map +1 -0
  20. package/dist/version.d.ts +1 -1
  21. package/dist/version.js +1 -1
  22. package/package.json +5 -2
  23. package/schemas/Perttool.AgentGuidanceResult.v1.schema.json +607 -0
  24. package/schemas/Perttool.AnalysisResult.v4.schema.json +790 -0
  25. package/schemas/Perttool.CheckResult.v3.schema.json +203 -0
  26. package/schemas/Perttool.CliError.v1.schema.json +119 -0
  27. package/schemas/Perttool.CommandHelpResult.v1.schema.json +377 -0
  28. package/schemas/Perttool.Common.v1.schema.json +1893 -0
  29. package/schemas/Perttool.ExportResult.v1.schema.json +96 -0
  30. package/schemas/Perttool.FormatResult.v1.schema.json +82 -0
  31. package/schemas/Perttool.GuideResult.v1.schema.json +138 -0
  32. package/schemas/Perttool.ImportResult.v1.schema.json +111 -0
  33. package/schemas/Perttool.InitResult.v1.schema.json +70 -0
  34. package/schemas/Perttool.MutationResult.v3.schema.json +194 -0
  35. package/schemas/Perttool.NextResult.v5.schema.json +1264 -0
  36. package/schemas/Perttool.OverrideDecision.v1.schema.json +402 -0
  37. package/schemas/Perttool.ProjectHistoryResult.v1.schema.json +283 -0
  38. package/schemas/Perttool.ProjectResult.v3.schema.json +217 -0
  39. package/schemas/Perttool.SchemaResult.v1.schema.json +137 -0
  40. package/schemas/Perttool.UnitMigrationResult.v3.schema.json +343 -0
  41. package/schemas/Perttool.VelocityObservationResult.v1.schema.json +301 -0
@@ -0,0 +1,301 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://github.com/mako10k/perttool/schemas/Perttool.VelocityObservationResult.v1.schema.json",
4
+ "title": "Perttool.VelocityObservationResult.v1",
5
+ "$defs": {
6
+ "observationCause": {
7
+ "type": "object",
8
+ "required": [
9
+ "cause",
10
+ "task_id",
11
+ "event_id",
12
+ "commit_id"
13
+ ],
14
+ "properties": {
15
+ "cause": {
16
+ "enum": [
17
+ "no_selected_tasks",
18
+ "no_complete_sequence",
19
+ "non_positive_window",
20
+ "mixed_offsets",
21
+ "incomplete_active_intervals",
22
+ "missing_effort",
23
+ "missing_baseline",
24
+ "history_incomplete",
25
+ "history_unavailable",
26
+ "git_recorded_start_missing",
27
+ "git_recorded_finish_missing"
28
+ ]
29
+ },
30
+ "task_id": {
31
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
32
+ },
33
+ "event_id": {
34
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
35
+ },
36
+ "commit_id": {
37
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
38
+ }
39
+ },
40
+ "additionalProperties": false
41
+ },
42
+ "rate": {
43
+ "type": "object",
44
+ "required": [
45
+ "numerator",
46
+ "denominator",
47
+ "unit"
48
+ ],
49
+ "properties": {
50
+ "numerator": {
51
+ "type": "string",
52
+ "pattern": "^-?[0-9]+$"
53
+ },
54
+ "denominator": {
55
+ "type": "string",
56
+ "pattern": "^[1-9][0-9]*$"
57
+ },
58
+ "unit": {
59
+ "enum": [
60
+ "point_per_hour",
61
+ "point_per_day",
62
+ "point_per_person_hour"
63
+ ]
64
+ }
65
+ },
66
+ "additionalProperties": false
67
+ },
68
+ "candidate": {
69
+ "type": "object",
70
+ "required": [
71
+ "id",
72
+ "measure",
73
+ "evidence_class",
74
+ "state",
75
+ "numerator",
76
+ "denominator",
77
+ "rate",
78
+ "adoptable_velocity_token",
79
+ "included_task_ids",
80
+ "excluded",
81
+ "observation_start",
82
+ "observation_finish",
83
+ "baseline_sources",
84
+ "qualifiers",
85
+ "unavailable_causes"
86
+ ],
87
+ "properties": {
88
+ "id": {
89
+ "type": "string"
90
+ },
91
+ "measure": {
92
+ "enum": [
93
+ "elapsed_hour_throughput",
94
+ "active_date_throughput",
95
+ "effort_productivity",
96
+ "git_recorded_elapsed_hour_throughput"
97
+ ]
98
+ },
99
+ "evidence_class": {
100
+ "enum": [
101
+ "declared_actual",
102
+ "git_recorded_transition"
103
+ ]
104
+ },
105
+ "state": {
106
+ "enum": [
107
+ "available",
108
+ "unavailable"
109
+ ]
110
+ },
111
+ "numerator": {
112
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableQuantity"
113
+ },
114
+ "denominator": {
115
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableQuantity"
116
+ },
117
+ "rate": {
118
+ "oneOf": [
119
+ {
120
+ "$ref": "#/$defs/rate"
121
+ },
122
+ {
123
+ "type": "null"
124
+ }
125
+ ]
126
+ },
127
+ "adoptable_velocity_token": {
128
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
129
+ },
130
+ "included_task_ids": {
131
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/stringArray"
132
+ },
133
+ "excluded": {
134
+ "type": "array",
135
+ "items": {
136
+ "type": "object",
137
+ "required": [
138
+ "task_id",
139
+ "causes"
140
+ ],
141
+ "properties": {
142
+ "task_id": {
143
+ "type": "string"
144
+ },
145
+ "causes": {
146
+ "type": "array",
147
+ "items": {
148
+ "$ref": "#/$defs/observationCause"
149
+ }
150
+ }
151
+ },
152
+ "additionalProperties": false
153
+ }
154
+ },
155
+ "observation_start": {
156
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableCalendarValue"
157
+ },
158
+ "observation_finish": {
159
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableCalendarValue"
160
+ },
161
+ "baseline_sources": {
162
+ "type": "array",
163
+ "items": {
164
+ "type": "object",
165
+ "required": [
166
+ "task_id",
167
+ "source",
168
+ "event_id",
169
+ "commit_id"
170
+ ],
171
+ "properties": {
172
+ "task_id": {
173
+ "type": "string"
174
+ },
175
+ "source": {
176
+ "enum": [
177
+ "start_baseline",
178
+ "finish_snapshot"
179
+ ]
180
+ },
181
+ "event_id": {
182
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
183
+ },
184
+ "commit_id": {
185
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
186
+ }
187
+ },
188
+ "additionalProperties": false
189
+ }
190
+ },
191
+ "qualifiers": {
192
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/stringArray"
193
+ },
194
+ "unavailable_causes": {
195
+ "type": "array",
196
+ "items": {
197
+ "$ref": "#/$defs/observationCause"
198
+ }
199
+ }
200
+ },
201
+ "additionalProperties": false
202
+ }
203
+ },
204
+ "type": "object",
205
+ "required": [
206
+ "schema_version",
207
+ "cli_contract_version",
208
+ "tool_version",
209
+ "operation",
210
+ "ok",
211
+ "document_id",
212
+ "source",
213
+ "source_digest",
214
+ "diagnostics",
215
+ "diagnostics_truncated",
216
+ "grammar_version",
217
+ "history",
218
+ "observation"
219
+ ],
220
+ "properties": {
221
+ "schema_version": {
222
+ "const": "Perttool.VelocityObservationResult.v1"
223
+ },
224
+ "cli_contract_version": {
225
+ "const": 6
226
+ },
227
+ "tool_version": {
228
+ "type": "string"
229
+ },
230
+ "operation": {
231
+ "const": "project.observe-velocity"
232
+ },
233
+ "ok": {
234
+ "type": "boolean"
235
+ },
236
+ "document_id": {
237
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableString"
238
+ },
239
+ "source": {
240
+ "type": "string"
241
+ },
242
+ "source_digest": {
243
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/nullableDigest"
244
+ },
245
+ "diagnostics": {
246
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/diagnostics"
247
+ },
248
+ "diagnostics_truncated": {
249
+ "type": "boolean"
250
+ },
251
+ "grammar_version": {
252
+ "type": [
253
+ "integer",
254
+ "null"
255
+ ]
256
+ },
257
+ "history": {
258
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/historyMetadata"
259
+ },
260
+ "observation": {
261
+ "type": "object",
262
+ "required": [
263
+ "id",
264
+ "version",
265
+ "history_model_version",
266
+ "selected_task_ids",
267
+ "evidence",
268
+ "candidates"
269
+ ],
270
+ "properties": {
271
+ "id": {
272
+ "const": "perttool.velocity-observation"
273
+ },
274
+ "version": {
275
+ "const": 1
276
+ },
277
+ "history_model_version": {
278
+ "const": 1
279
+ },
280
+ "selected_task_ids": {
281
+ "$ref": "Perttool.Common.v1.schema.json#/$defs/stringArray"
282
+ },
283
+ "evidence": {
284
+ "enum": [
285
+ "declared",
286
+ "git-recorded",
287
+ "all"
288
+ ]
289
+ },
290
+ "candidates": {
291
+ "type": "array",
292
+ "items": {
293
+ "$ref": "#/$defs/candidate"
294
+ }
295
+ }
296
+ },
297
+ "additionalProperties": false
298
+ }
299
+ },
300
+ "additionalProperties": false
301
+ }