principles 0.0.4 → 0.0.6

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 (227) hide show
  1. checksums.yaml +4 -4
  2. data/lib/principles/after_commit_hook_options.rb +4 -1
  3. data/lib/principles/cli.rb +3 -1
  4. data/lib/principles/command_line.rb +38 -26
  5. data/lib/principles/command_routes.rb +11 -4
  6. data/lib/principles/controllers/acknowledgement.rb +93 -17
  7. data/lib/principles/controllers/answer.rb +45 -76
  8. data/lib/principles/controllers/answer_phase.rb +54 -0
  9. data/lib/principles/controllers/assessment.rb +46 -11
  10. data/lib/principles/controllers/audit.rb +17 -6
  11. data/lib/principles/controllers/audit_completion.rb +9 -5
  12. data/lib/principles/controllers/command.rb +5 -4
  13. data/lib/principles/controllers/correction.rb +22 -10
  14. data/lib/principles/controllers/full_audit_request.rb +11 -1
  15. data/lib/principles/controllers/guidance_search_paths.rb +31 -0
  16. data/lib/principles/controllers/inventory.rb +15 -29
  17. data/lib/principles/controllers/mapping.rb +9 -1
  18. data/lib/principles/controllers/member_addition.rb +65 -0
  19. data/lib/principles/controllers/member_entries.rb +6 -24
  20. data/lib/principles/controllers/member_problems_report.rb +13 -6
  21. data/lib/principles/controllers/members_a_commit_changed.rb +2 -1
  22. data/lib/principles/controllers/members_to_assess.rb +21 -13
  23. data/lib/principles/controllers/meta_principle_setup.rb +1 -1
  24. data/lib/principles/controllers/repoint.rb +22 -23
  25. data/lib/principles/controllers/survey.rb +60 -0
  26. data/lib/principles/data/audit_files.rb +4 -0
  27. data/lib/principles/data/bounded_file.rb +9 -4
  28. data/lib/principles/data/candidate_files_found.rb +48 -13
  29. data/lib/principles/data/command-steps.json +85 -24
  30. data/lib/principles/data/committed_tree.rb +84 -0
  31. data/lib/principles/data/first_parent_log.rb +48 -0
  32. data/lib/principles/data/first_parent_range.rb +122 -0
  33. data/lib/principles/data/git_command.rb +37 -0
  34. data/lib/principles/data/guidance_search_paths_file.rb +107 -0
  35. data/lib/principles/data/map_files.rb +35 -10
  36. data/lib/principles/data/principles_directory.rb +40 -0
  37. data/lib/principles/data/principles_subfolder.rb +39 -16
  38. data/lib/principles/data/project_files.rb +22 -11
  39. data/lib/principles/data/repository.rb +55 -29
  40. data/lib/principles/data/requested_candidate_files.rb +43 -0
  41. data/lib/principles/data/running_version.rb +3 -5
  42. data/lib/principles/data/schema_check.rb +16 -6
  43. data/lib/principles/data/schemas/acknowledgement-answer.schema.json +18 -5
  44. data/lib/principles/data/schemas/answer-guide.schema.json +255 -68
  45. data/lib/principles/data/schemas/audit-record.schema.json +10 -1
  46. data/lib/principles/data/schemas/command-steps.schema.json +2 -1
  47. data/lib/principles/data/schemas/correction-answer-guide.schema.json +2 -1
  48. data/lib/principles/data/schemas/correction-answer.schema.json +6 -0
  49. data/lib/principles/data/schemas/guidance-search-paths.schema.json +13 -0
  50. data/lib/principles/data/schemas/member-map-history.schema.json +20 -0
  51. data/lib/principles/data/verified_head.rb +162 -0
  52. data/lib/principles/invocation_options.rb +3 -3
  53. data/lib/principles/models/acknowledgement.rb +95 -84
  54. data/lib/principles/models/acknowledgement_left_as_printed.rb +51 -0
  55. data/lib/principles/models/acknowledgement_refusal.rb +90 -0
  56. data/lib/principles/models/answer_place.rb +4 -0
  57. data/lib/principles/models/assessment_answer.rb +0 -45
  58. data/lib/principles/models/assessment_left_as_printed.rb +81 -0
  59. data/lib/principles/models/audit_entry_protecting_map.rb +28 -0
  60. data/lib/principles/models/audit_record.rb +12 -16
  61. data/lib/principles/models/audit_records.rb +52 -23
  62. data/lib/principles/models/candidate_files.rb +44 -10
  63. data/lib/principles/models/candidate_inventory.rb +69 -8
  64. data/lib/principles/models/candidate_outline.rb +195 -0
  65. data/lib/principles/models/captured_head.rb +72 -0
  66. data/lib/principles/models/carried_member.rb +42 -0
  67. data/lib/principles/models/check_since_last_audit.rb +20 -11
  68. data/lib/principles/models/command_steps.rb +17 -1
  69. data/lib/principles/models/declared_map_changes.rb +29 -12
  70. data/lib/principles/models/declared_member_removals.rb +75 -0
  71. data/lib/principles/models/disposition.rb +4 -2
  72. data/lib/principles/models/fix_only_fields.rb +12 -0
  73. data/lib/principles/models/frontmatter_fields.rb +9 -8
  74. data/lib/principles/models/guidance_search_path.rb +26 -0
  75. data/lib/principles/models/guidance_search_paths.rb +57 -0
  76. data/lib/principles/models/instruction_named.rb +35 -0
  77. data/lib/principles/models/left_as_printed.rb +39 -0
  78. data/lib/principles/models/line_span.rb +6 -0
  79. data/lib/principles/models/loaded_files.rb +1 -2
  80. data/lib/principles/models/loading_scope.rb +61 -0
  81. data/lib/principles/models/locator.rb +6 -0
  82. data/lib/principles/models/mapped_principles.rb +39 -37
  83. data/lib/principles/models/member_assessments.rb +9 -31
  84. data/lib/principles/models/member_file.rb +20 -47
  85. data/lib/principles/models/member_hashes_as_written.rb +10 -6
  86. data/lib/principles/models/member_history.rb +7 -5
  87. data/lib/principles/models/member_lines.rb +63 -15
  88. data/lib/principles/models/member_loading_scopes.rb +49 -0
  89. data/lib/principles/models/member_loads.rb +4 -0
  90. data/lib/principles/models/member_mapping_run.rb +30 -0
  91. data/lib/principles/models/member_moves.rb +4 -0
  92. data/lib/principles/models/member_problems.rb +63 -33
  93. data/lib/principles/models/member_region.rb +129 -0
  94. data/lib/principles/models/member_repair_moves.rb +52 -0
  95. data/lib/principles/models/member_snapshots.rb +14 -1
  96. data/lib/principles/models/members_in_consecutive_sections.rb +56 -0
  97. data/lib/principles/models/meta_principle.rb +14 -0
  98. data/lib/principles/models/missing_files.rb +2 -2
  99. data/lib/principles/models/open_findings_elsewhere.rb +4 -0
  100. data/lib/principles/models/other_templates_placeholders.rb +81 -42
  101. data/lib/principles/models/outline_budget.rb +142 -0
  102. data/lib/principles/models/outline_group.rb +31 -0
  103. data/lib/principles/models/outline_section.rb +56 -0
  104. data/lib/principles/models/principle.rb +14 -7
  105. data/lib/principles/models/principle_file_revision.rb +48 -0
  106. data/lib/principles/models/principle_history.rb +46 -19
  107. data/lib/principles/models/principle_lineage.rb +118 -0
  108. data/lib/principles/models/principle_map_revision.rb +39 -0
  109. data/lib/principles/models/principle_mapping_history.rb +132 -0
  110. data/lib/principles/models/principle_members.rb +25 -0
  111. data/lib/principles/models/principle_predecessor.rb +45 -0
  112. data/lib/principles/models/principle_publication.rb +177 -0
  113. data/lib/principles/models/principle_revision.rb +104 -0
  114. data/lib/principles/models/prior_decision_fields.rb +3 -2
  115. data/lib/principles/models/prior_finding_decision.rb +14 -4
  116. data/lib/principles/models/problem_report.rb +17 -5
  117. data/lib/principles/models/project.rb +46 -39
  118. data/lib/principles/models/project_history.rb +45 -25
  119. data/lib/principles/models/quoted_change.rb +137 -0
  120. data/lib/principles/models/record_format.rb +12 -2
  121. data/lib/principles/models/recorded_entry.rb +6 -0
  122. data/lib/principles/models/recorded_hashes.rb +7 -3
  123. data/lib/principles/models/recorded_members.rb +27 -15
  124. data/lib/principles/models/refusal_before_shape.rb +21 -0
  125. data/lib/principles/models/repoint.rb +13 -0
  126. data/lib/principles/models/reported_check.rb +5 -14
  127. data/lib/principles/models/sent_answer.rb +61 -0
  128. data/lib/principles/models/shape_problems_beside.rb +40 -0
  129. data/lib/principles/models/submitted_answer.rb +34 -0
  130. data/lib/principles/models/survey_search_paths.rb +26 -0
  131. data/lib/principles/models/template_placeholders.rb +34 -4
  132. data/lib/principles/models/text_within.rb +55 -0
  133. data/lib/principles/models/unchecked_members.rb +76 -0
  134. data/lib/principles/models/uncommitted_files.rb +50 -0
  135. data/lib/principles/models/unknown_principle.rb +29 -0
  136. data/lib/principles/models/write_up_opening.rb +21 -4
  137. data/lib/principles/positional_arguments.rb +37 -0
  138. data/lib/principles/session_start_options.rb +2 -2
  139. data/lib/principles/start_audit_options.rb +19 -4
  140. data/lib/principles/version.rb +2 -2
  141. data/lib/principles/views/acknowledgement_result.rb +23 -11
  142. data/lib/principles/views/added_member.rb +41 -0
  143. data/lib/principles/views/answered_request.rb +21 -0
  144. data/lib/principles/views/assessed_members.rb +43 -10
  145. data/lib/principles/views/assessment_request.rb +91 -31
  146. data/lib/principles/views/audit_result.rb +40 -28
  147. data/lib/principles/views/candidate_files_result.rb +85 -19
  148. data/lib/principles/views/candidate_outlines_result.rb +25 -0
  149. data/lib/principles/views/check_notes.rb +44 -0
  150. data/lib/principles/views/check_result_template.rb +14 -23
  151. data/lib/principles/views/consecutive_sections_elsewhere.rb +27 -0
  152. data/lib/principles/views/correction_request.rb +32 -1
  153. data/lib/principles/views/guidance_search_paths_result.rb +26 -0
  154. data/lib/principles/views/instruction.rb +74 -0
  155. data/lib/principles/views/json_with_entries_on_lines.rb +59 -0
  156. data/lib/principles/views/loads_to_check_result.rb +2 -2
  157. data/lib/principles/views/map_added_to.rb +56 -2
  158. data/lib/principles/views/map_result.rb +23 -43
  159. data/lib/principles/views/maps_needing_members_or_audit.rb +47 -0
  160. data/lib/principles/views/member_change_since_baseline.rb +23 -5
  161. data/lib/principles/views/member_repairs.rb +22 -52
  162. data/lib/principles/views/members_a_commit_changed.rb +16 -6
  163. data/lib/principles/views/new_loading_scope.rb +31 -0
  164. data/lib/principles/views/one_member_check_result_template.rb +47 -0
  165. data/lib/principles/views/open_findings_elsewhere_result.rb +3 -3
  166. data/lib/principles/views/open_findings_line.rb +77 -23
  167. data/lib/principles/views/principle_read_result.rb +24 -29
  168. data/lib/principles/views/principles_with_no_completed_audit.rb +9 -3
  169. data/lib/principles/views/prior_findings_result.rb +23 -15
  170. data/lib/principles/views/problem_lines.rb +3 -1
  171. data/lib/principles/views/problem_result.rb +8 -3
  172. data/lib/principles/views/prompts/acknowledge-a-change/run-the-check-and-report-it-passing.md +3 -0
  173. data/lib/principles/views/prompts/acknowledge-a-change/say-whether-the-change-keeps-the-meaning.md +6 -12
  174. data/lib/principles/views/prompts/assess-every-member/answer-guide.json +67 -48
  175. data/lib/principles/views/prompts/assess-every-member/assess-each-member-and-the-set.md +0 -4
  176. data/lib/principles/views/prompts/assess-every-member/claim-an-earlier-first-raised-at.md +7 -0
  177. data/lib/principles/views/prompts/assess-every-member/decide-each-prior-finding.md +4 -16
  178. data/lib/principles/views/prompts/assess-every-member/judge-the-set-with-carried-assessments.md +5 -10
  179. data/lib/principles/views/prompts/assess-every-member/keep-or-change-what-a-deferral-waits-on.md +4 -0
  180. data/lib/principles/views/prompts/assess-every-member/read-a-compact-carried-member.md +8 -0
  181. data/lib/principles/views/prompts/assess-every-member/read-a-trimmed-instruction-whole.md +1 -0
  182. data/lib/principles/views/prompts/assess-every-member/review-a-new-or-changed-check-before-running-it.md +9 -0
  183. data/lib/principles/views/prompts/assess-every-member/say-what-observed-means.md +4 -0
  184. data/lib/principles/views/prompts/dispose-of-each-finding/answer-guide.json +1 -0
  185. data/lib/principles/views/prompts/dispose-of-each-finding/fix-or-record-each-finding.md +16 -3
  186. data/lib/principles/views/prompts/dispose-of-each-finding/retain-assessment-and-correction.md +4 -0
  187. data/lib/principles/views/prompts/find-a-principle-to-map/ask-about-other-guidance-search-paths.md +6 -0
  188. data/lib/principles/views/prompts/find-a-principle-to-map/ask-the-owner-after-the-table.md +1 -0
  189. data/lib/principles/views/prompts/find-a-principle-to-map/ask-which-principle-to-map.md +2 -0
  190. data/lib/principles/views/prompts/find-a-principle-to-map/choose-an-existing-or-new-principle.md +2 -0
  191. data/lib/principles/views/prompts/find-a-principle-to-map/choose-one-principle.md +11 -5
  192. data/lib/principles/views/prompts/find-a-principle-to-map/compare-with-mapped-principles.md +11 -0
  193. data/lib/principles/views/prompts/find-a-principle-to-map/leave-test-data-out-of-the-survey.md +1 -0
  194. data/lib/principles/views/prompts/find-a-principle-to-map/read-a-cut-section-back.md +3 -0
  195. data/lib/principles/views/prompts/find-a-principle-to-map/read-left-out-files.md +3 -0
  196. data/lib/principles/views/prompts/find-a-principle-to-map/survey-a-later-range.md +3 -0
  197. data/lib/principles/views/prompts/find-a-principle-to-map/what-each-command-writes.md +4 -4
  198. data/lib/principles/views/prompts/find-a-principle-to-map/where-the-inventory-looks.md +5 -4
  199. data/lib/principles/views/prompts/learn-what-a-command-does/add-guidance-search-path.md +17 -0
  200. data/lib/principles/views/prompts/learn-what-a-command-does/add-member.md +35 -6
  201. data/lib/principles/views/prompts/learn-what-a-command-does/create-principle.md +16 -0
  202. data/lib/principles/views/prompts/learn-what-a-command-does/list-candidate-files.md +55 -7
  203. data/lib/principles/views/prompts/learn-what-a-command-does/list-member-problems.md +9 -8
  204. data/lib/principles/views/prompts/learn-what-a-command-does/list-open-findings.md +10 -11
  205. data/lib/principles/views/prompts/learn-what-a-command-does/list-principles.md +1 -2
  206. data/lib/principles/views/prompts/learn-what-a-command-does/move-member.md +5 -0
  207. data/lib/principles/views/prompts/learn-what-a-command-does/remove-guidance-search-path.md +13 -0
  208. data/lib/principles/views/prompts/learn-what-a-command-does/remove-principle.md +25 -0
  209. data/lib/principles/views/prompts/learn-what-a-command-does/show-answer-check.md +27 -1
  210. data/lib/principles/views/prompts/learn-what-a-command-does/show-candidate-outlines.md +21 -0
  211. data/lib/principles/views/prompts/learn-what-a-command-does/show-meta-principle-passage.md +5 -5
  212. data/lib/principles/views/prompts/learn-what-a-command-does/start-audit.md +24 -24
  213. data/lib/principles/views/prompts/learn-what-a-command-does/submit-answer.md +51 -54
  214. data/lib/principles/views/prompts/read-requested-outlines/continue-the-survey.md +7 -0
  215. data/lib/principles/views/prompts/report-after-a-commit/the-principles-skill-is-where-to-start.md +1 -0
  216. data/lib/principles/views/prompts/set-principles-up/keep-them-held-between-audits.md +2 -0
  217. data/lib/principles/views/prompts/set-principles-up/name-the-step-each-member-lacks.md +2 -0
  218. data/lib/principles/views/prompts/set-principles-up/place-the-passage-with-the-user.md +9 -6
  219. data/lib/principles/views/prompts/start-a-session/see-the-earlier-line.md +2 -0
  220. data/lib/principles/views/record_waiting_on_an_upgrade.rb +3 -3
  221. data/lib/principles/views/request_part.rb +16 -8
  222. data/lib/principles/views/request_parts.rb +4 -0
  223. metadata +92 -7
  224. data/lib/principles/models/candidate_listing.rb +0 -32
  225. data/lib/principles/views/prompts/find-a-principle-to-map/ask-the-owner-before-mapping.md +0 -1
  226. data/lib/principles/views/prompts/report-after-a-commit/the-map-and-audit-skill-says-how-to-audit-these-members.md +0 -1
  227. data/lib/principles/views/prompts/set-principles-up/set-up-first.md +0 -2
@@ -20,28 +20,27 @@ module Principles
20
20
  freeze
21
21
  end
22
22
 
23
- # show-principle: each member with where its text is now and its freshness, and each member in broken, the ids
24
- # of those an audit would refuse, with its repair_with commands (#272).
23
+ # show-principle: each member with where its text is now and its freshness, and each member repairs names, those
24
+ # an audit would refuse, with its repair_with commands, from the moves repairs gives it (#272).
25
25
  # hook_settings_not_read names each project settings file whose hooks this tool could not read (#491).
26
26
  # loaded_files lists each file the members load once, with the total of those loading at session start (#483).
27
- #: (PrintedPrinciple, broken: Array[String], ?hook_settings_not_read: Array[Hash[String, String]],
28
- #| ?loaded_files: Hash[String, untyped]) -> Hash[String, untyped]
29
- def shown(principle, broken:, hook_settings_not_read: [], loaded_files: {})
27
+ #: (PrintedPrinciple, repairs: Hash[String, Array[Hash[String, untyped]]],
28
+ #| ?hook_settings_not_read: Array[Hash[String, String]], ?loaded_files: Hash[String, untyped])
29
+ #| -> Hash[String, untyped]
30
+ def shown(principle, repairs:, hook_settings_not_read: [], loaded_files: {})
30
31
  unread = hook_settings_not_read.empty? ? {} : { "hook_settings_not_read" => hook_settings_not_read }
31
32
  { "id" => principle.id, "map_file" => principle.file, **principle.declared,
32
- "members" => principle.members.map { |member| repaired(principle.id, member, broken) },
33
- **loaded_files, **unread, "next_action" => shown_next_action(principle, broken) }
33
+ "members" => principle.members.map { |member| repaired(principle.id, member, repairs) },
34
+ **loaded_files, **unread, "next_action" => shown_next_action(principle, repairs.keys) }
34
35
  end
35
36
 
36
- # list-principles: each entry is { "id", "description", "members_by_freshness" }. Until principles is set_up,
37
- # its next_action puts setting it up first. waiting is each principle whose audits wait on an upgrade, which it
38
- # names, with how to update said once, and an audit is offered only when one is left to audit (#1067, #1081).
39
- #: (Array[Hash[String, untyped]], set_up: bool, ?waiting: Array[RecordWaitingOnAnUpgrade],
40
- #| ?one_to_audit: bool) -> Hash[String, untyped]
41
- def listing(entries, set_up:, waiting: [], one_to_audit: true)
42
- first = set_up ? [] : [set_up_first]
43
- next_action = [*first, *listed_next_action(entries, waiting, one_to_audit)]
44
- { "principles" => entries, "next_action" => next_action.join("\n") }
37
+ # list-principles: each entry is { "id", "description", "members_by_freshness" }. waiting is each principle whose
38
+ # audits wait on an upgrade, which it names, with how to update said once, and an audit is offered only when one
39
+ # is left to audit (#1067, #1081).
40
+ #: (Array[Hash[String, untyped]], ?waiting: Array[RecordWaitingOnAnUpgrade], ?one_to_audit: bool)
41
+ #| -> Hash[String, untyped]
42
+ def listing(entries, waiting: [], one_to_audit: true)
43
+ { "principles" => entries, "next_action" => listed_next_action(entries, waiting, one_to_audit).join("\n") }
45
44
  end
46
45
 
47
46
  # list-principles' note on the meta-principle's map, kept in file, when it has no members, with the two ways on
@@ -56,7 +55,7 @@ module Principles
56
55
 
57
56
  private
58
57
 
59
- # What list-principles' next_action offers after setting up: mapping one when none is listed, else showing one,
58
+ # What list-principles' next_action offers: mapping one when none is listed, else showing one,
60
59
  # auditing one when one is left to audit, and the principles whose audits wait on an upgrade.
61
60
  #: (Array[Hash[String, untyped]], Array[RecordWaitingOnAnUpgrade], bool) -> Array[String]
62
61
  def listed_next_action(entries, waiting, one_to_audit)
@@ -64,7 +63,10 @@ module Principles
64
63
 
65
64
  audit = "To audit it: #{@invocation.in_project("start-audit", usage: "ID")}" if one_to_audit
66
65
  waits = waited_on(waiting) unless waiting.empty?
67
- ["To see a principle's members: #{@invocation.in_project("show-principle", usage: "ID")}", audit, waits].compact
66
+ ["To see a principle's members: #{@invocation.in_project("show-principle", usage: "ID")}", audit,
67
+ "To survey this project: #{@invocation.in_project("list-candidate-files")}",
68
+ "To survey the principles a change carries: " \
69
+ "#{@invocation.in_project("list-candidate-files", usage: "--commits-after REV")}", waits].compact
68
70
  end
69
71
 
70
72
  # The principles whose audits wait on an upgrade, and how to update, once for each way the records name.
@@ -74,17 +76,10 @@ module Principles
74
76
  .join(" ")
75
77
  end
76
78
 
77
- # The line that puts setting principles up first, ending in its command.
78
- #: () -> String
79
- def set_up_first
80
- Prompts.text("set-principles-up/set-up-first",
81
- command: @invocation.in_project("show-meta-principle-passage"))
82
- end
83
-
84
- # member, with its repairs when broken names it.
85
- #: (String, Hash[String, untyped], Array[String]) -> Hash[String, untyped]
86
- def repaired(id, member, broken)
87
- MemberRepairs.new(@invocation).beside(id, member, broken: broken.include?(member.fetch("id")))
79
+ # member, with its repairs when repairs names it.
80
+ #: (String, Hash[String, untyped], Hash[String, Array[Hash[String, untyped]]]) -> Hash[String, untyped]
81
+ def repaired(id, member, repairs)
82
+ MemberRepairs.new(@invocation).beside(id, member, repairs[member.fetch("id")])
88
83
  end
89
84
 
90
85
  # Repair each member in broken, the ids of those an audit would refuse; otherwise audit when one changed or was
@@ -18,12 +18,18 @@ module Principles
18
18
  freeze
19
19
  end
20
20
 
21
+ # The lack of a completed audit, independent of whether the map is committed or has members yet.
21
22
  #: () -> String
22
- def to_s
23
+ def notice
23
24
  one = @ids.length == 1
24
25
  carry = one ? "its members carry it" : "their members carry them"
25
- "No full audit has completed for #{ProseList.new(@ids)}, so whether #{carry} is unknown. " \
26
- "To start #{one ? "one" : "each"}:\n#{@audits.join("\n")}"
26
+ "No full audit has completed for #{ProseList.new(@ids)} (#{@ids.length} principle#{"s" unless one}), " \
27
+ "so whether #{carry} is unknown."
28
+ end
29
+
30
+ #: () -> String
31
+ def to_s
32
+ "#{notice} To start #{@ids.length == 1 ? "one" : "each"}:\n#{@audits.join("\n")}"
27
33
  end
28
34
  end
29
35
  end
@@ -27,8 +27,8 @@ module Principles
27
27
  def part
28
28
  return if @prior.empty?
29
29
 
30
- RequestPart.new(shown: { "prior_findings" => @prior.map { |finding| shown(finding) },
31
- "prior_findings_instruction" => instruction },
30
+ RequestPart.new(shown: { "prior_findings" => @prior.map { |finding| shown(finding) } },
31
+ instructions: [Instruction.new("prior_findings_instruction", instruction)],
32
32
  slots: { "prior_finding_decisions" => @prior.map { |finding| decision(finding) } },
33
33
  help: { "prior_finding_decisions" => @placeholders })
34
34
  end
@@ -52,27 +52,35 @@ module Principles
52
52
  evidence_not_kept?(finding) ? decision.merge("problem_evidence" => []) : decision
53
53
  end
54
54
 
55
- # How to decide the prior findings, naming each one's id, so a new finding is given another (#420), and how to
56
- # give the evidence a finding's record lacks only when one is marked so (D61, D64).
57
- #: () -> String
55
+ # How to decide the prior findings, naming each one's id, so a new finding is given another (#420), each
56
+ # paragraph with whether its case holds: how to keep what a deferral waits on holds only when one carries waits_on
57
+ # (#983), how to claim an earlier first_raised_at never, since no fact marks a finding dated late, so it is read
58
+ # whole (#983), and how to give the evidence a finding's record lacks only when one is marked so (D61, D64).
59
+ #: () -> Array[[String, bool]]
58
60
  def instruction
59
61
  ids = @prior.map { |finding| finding.fetch("finding_id") }.join(", ")
60
- [Prompts.text("assess-every-member/decide-each-prior-finding", ids: ids), *evidence_since,
61
- *(Prompts.text("assess-every-member/give-the-evidence-a-prior-finding-lacks") if marked_evidence_not_kept?)]
62
- .join("\n\n")
62
+ decide = Prompts.text("assess-every-member/decide-each-prior-finding", ids: ids).split("\n\n")
63
+ [*decide.map { [it, true] },
64
+ [Prompts.text("assess-every-member/keep-or-change-what-a-deferral-waits-on"), waits_on?],
65
+ [Prompts.text("assess-every-member/claim-an-earlier-first-raised-at"), false], *evidence_since,
66
+ [Prompts.text("assess-every-member/give-the-evidence-a-prior-finding-lacks"), marked_evidence_not_kept?]]
63
67
  end
64
68
 
65
- # How to read each evidence item's changed_since_last_audit, naming the commit it compares against, only when an
66
- # item carries it (#858, D61).
67
- #: () -> Array[String]
69
+ # How to read each evidence item's changed_since_last_audit, naming the commit it compares against, holding only
70
+ # when an item carries it (#858, D61); none when no commit is named to compare against.
71
+ #: () -> Array[[String, bool]]
68
72
  def evidence_since
69
- said = @prior.any? { |finding| finding["evidence"]&.any? { it.key?("changed_since_last_audit") } }
70
- return [] unless said && @last_audited_commit
73
+ return [] unless @last_audited_commit
71
74
 
72
- [Prompts.text("assess-every-member/read-whether-each-prior-finding-s-evidence-changed",
73
- commit: @last_audited_commit)]
75
+ said = @prior.any? { |finding| finding["evidence"]&.any? { it.key?("changed_since_last_audit") } }
76
+ [[Prompts.text("assess-every-member/read-whether-each-prior-finding-s-evidence-changed",
77
+ commit: @last_audited_commit), said]]
74
78
  end
75
79
 
80
+ # Whether any prior finding carries a waits_on line (D52).
81
+ #: () -> bool
82
+ def waits_on? = @prior.any? { |finding| finding["waits_on"] }
83
+
76
84
  #: () -> bool
77
85
  def marked_evidence_not_kept? = @prior.any? { |finding| evidence_not_kept?(finding) }
78
86
 
@@ -78,7 +78,9 @@ module Principles
78
78
  # principle waiting on an upgrade, whose members are not counted, so they leave counts empty (D85, V8).
79
79
  #: (Hash[String, untyped], String) -> Array[String]
80
80
  def notes(report, nothing_changed)
81
- [(NO_MAPS if report.fetch("counts").empty? && !report.key?("records_waiting_on_an_upgrade")),
81
+ no_maps = report.fetch("counts").empty? && !report.key?("empty_maps") &&
82
+ !report.key?("records_waiting_on_an_upgrade")
83
+ [(NO_MAPS if no_maps),
82
84
  (report.fetch("next_action") unless report.fetch("next_action") == nothing_changed),
83
85
  ("Details: #{@invocation.in_project("list-member-problems")}" unless report.fetch("members").empty?)].compact
84
86
  end
@@ -3,6 +3,7 @@
3
3
 
4
4
  require_relative "invocation"
5
5
  require_relative "members_with_no_baseline"
6
+ require_relative "maps_needing_members_or_audit"
6
7
  require_relative "principles_with_no_completed_audit"
7
8
  require_relative "record_waiting_on_an_upgrade"
8
9
 
@@ -45,8 +46,11 @@ module Principles
45
46
  #| acknowledgeable: Hash[String, Array[String]], waiting: Array[RecordWaitingOnAnUpgrade]) -> String
46
47
  def next_action(report, no_baseline_files:, acknowledgeable:, waiting:)
47
48
  waits = waiting.map(&:principle)
48
- action = [changed_action(report, acknowledgeable, waits), unaudited_action(report, waits),
49
- *no_baseline_actions(report, no_baseline_files).map(&:to_s), *waiting.map(&:to_s)].compact.join("\n")
49
+ mapping = MapsNeedingMembersOrAudit.new(@invocation, report: report, files_to_commit: no_baseline_files,
50
+ waiting: waits)
51
+ action = [changed_action(report, acknowledgeable, waits), unaudited_action(report, waits), mapping.notice,
52
+ *no_baseline_actions(report, no_baseline_files).map(&:to_s), *mapping.actions,
53
+ *waiting.map(&:to_s)].compact.join("\n")
50
54
  action.empty? ? NOTHING_CHANGED : action
51
55
  end
52
56
 
@@ -64,7 +68,8 @@ module Principles
64
68
  next "Audit #{id} in full to judge its changed members: #{full}" if members.empty?
65
69
 
66
70
  [*members.flat_map { |member| acknowledge_lines(id, member) },
67
- "When a change alters what a member of #{id} says, or the member has a check, audit it in full: #{full}"]
71
+ "When a change alters what a member of #{id} says, or its check is new, changed or does not pass, " \
72
+ "audit it in full: #{full}"]
68
73
  end
69
74
  audits.empty? ? nil : audits.join("\n")
70
75
  end
@@ -0,0 +1,3 @@
1
+ Run the member's check, the command member.check names, in the project, then give its exit status, an integer, as
2
+ check_result.exit_status. An acknowledgement keeps only a passing run: a check that fails or cannot be run here is a
3
+ full audit's to judge, so start that audit instead of answering this one.
@@ -1,12 +1,6 @@
1
- Read the change to this member in member_lines: its own lines at its baseline commit and now or, for a long member,
2
- its changed_region with a few lines of context; when even that is too long to show, run the command in read_instead.
3
- Then say
4
- whether the member still says the same thing. Answer `meaning_kept: true` only when it does. A member still says the
5
- same thing after a fixed typo, a reworded sentence or a renumbered citation; an added, dropped, reversed, narrowed or
6
- widened rule changes what it says. Give a one-line `reason` in your own words. Quote one whole line of
7
- the member as it read at the baseline as `old_line`, and one as it reads now as `new_line`. From a long line, such
8
- as a JSON string field, quote instead at least 30 characters that include the edit, which the member on the other
9
- side of the change does not hold. When the meaning
10
- changed, or you are unsure, run a full audit instead. An acknowledgement covers only this change, and the next full
11
- audit lists every acknowledgement made since the last one. Any deferred finding on the member stays deferred and is
12
- named beside the acknowledgement.
1
+ Read the change in member_lines, or by running read_the_change. Answer `meaning_kept: true` only when the member
2
+ still says the same thing. A member still says the same thing after a fixed typo, a reworded sentence or a
3
+ renumbered citation; an added, dropped, reversed, narrowed or widened rule changes what it says. When it changed, or
4
+ you are unsure, run a full audit instead. Give a one-line `reason` in your own words, and fill the template; quotes
5
+ left out read as `first_changed_lines`. Optional: `old_line` and `new_line`, another changed line per side or 30
6
+ characters including the edit; `basis.base_commit`; a check's `check_result.command` and `check_result.review_basis`.
@@ -1,63 +1,82 @@
1
1
  {
2
2
  "finding": {
3
- "id": "F1",
4
- "member_ids": [
5
- "a member id from the map"
6
- ],
7
- "problem": "What is wrong",
8
- "consequence": "What goes wrong for an agent because of it",
9
- "proposed_action": "The concrete change",
10
- "evidence": [
11
- {
12
- "path": "a project file",
13
- "heading": "optional exact heading"
14
- },
15
- {
16
- "path": "a project file",
17
- "starting_at": "text that occurs once",
18
- "ending_at": "optional closing text"
19
- },
20
- {
21
- "path": "a project file with frontmatter",
22
- "query": "$.description"
3
+ "copy_to": "response_template.findings",
4
+ "copy_from": "Append one filled examples.finding object to this array. Do not submit this wrapper or notes.",
5
+ "examples": {
6
+ "finding": {
7
+ "id": "F1",
8
+ "member_ids": [
9
+ "a member id from the map"
10
+ ],
11
+ "problem": "What is wrong",
12
+ "consequence": "What goes wrong for an agent because of it",
13
+ "proposed_action": "The concrete change",
14
+ "evidence": [
15
+ {
16
+ "path": "a project file",
17
+ "heading": "optional exact heading"
18
+ },
19
+ {
20
+ "path": "a project file",
21
+ "starting_at": "text that occurs once",
22
+ "ending_at": "optional closing text"
23
+ },
24
+ {
25
+ "path": "a project file with frontmatter",
26
+ "query": "$.description"
27
+ }
28
+ ]
23
29
  }
24
- ]
30
+ },
31
+ "notes": "Evidence entries illustrate locator choices, not mandatory sample files: replace the example array with the actual located references needed for this finding. Fill every judgement and use mapped member IDs. Submitting findings starts a separate correction stage; it does not complete the audit."
25
32
  },
26
33
  "member_delivery": {
27
- "not_observed": {
28
- "delivery": "not_observed"
34
+ "copy_to": "response_template.member_assessments entry matching member_id",
35
+ "copy_from": "Merge only examples.observed or examples.not_observed into that existing entry, then fill its fields. Do not submit this wrapper or notes.",
36
+ "examples": {
37
+ "not_observed": {
38
+ "delivery": "not_observed"
39
+ },
40
+ "observed": {
41
+ "delivery": "observed",
42
+ "observation": "What you saw the member do, where you saw it, and what you did not see",
43
+ "observed_at": null
44
+ }
29
45
  },
30
- "observed": {
31
- "delivery": "observed",
32
- "observation": "What you saw the member do, where you saw it, and what you did not see",
33
- "observed_at": "Only when you saw it before this audit: when, in UTC as audited_at gives it; omit it, or give null, for a sighting made now. When the sighting is a dated record you read during this audit, such as a note or log of the mechanism acting, give the record's date, not the time you read it"
34
- }
46
+ "notes": "Reading source alone is not observed delivery. With not_observed, omit observation and observed_at; remove any substantive sighting fields from a previous choice. For a sighting now, leave observed_at null or omit it. For an earlier sighting, replace null with its UTC time in audited_at's form. When the sighting is a dated record you read during this audit, such as a note or log of the mechanism acting, give the record's date, not the time you read it"
35
47
  },
36
48
  "recent_decision": {
37
- "assessed": {
38
- "assessment": "How the decision held up against the members' own words; when only a commit message records it, name the commit by its sha and subject here",
39
- "evidence": [
40
- {
41
- "path": "a project file that records the decision; when only a commit message records it, the file that commit changed to carry it out",
42
- "heading": "optional exact heading"
43
- }
44
- ]
45
- },
46
- "unavailable": {
47
- "unavailable_reason": "Why no recent decision under this principle can be checked"
49
+ "copy_to": "response_template.recent_decision",
50
+ "copy_from": "Replace the whole object with only examples.assessed or examples.unavailable, then fill its fields. Do not merge alternatives or submit this wrapper.",
51
+ "examples": {
52
+ "assessed": {
53
+ "assessment": "How the decision held up against the members' own words; when only a commit message records it, name the commit by its sha and subject here",
54
+ "evidence": [
55
+ {
56
+ "path": "a project file that records the decision; when only a commit message records it, the file that commit changed to carry it out",
57
+ "heading": "optional exact heading"
58
+ }
59
+ ]
60
+ },
61
+ "unavailable": {
62
+ "unavailable_reason": "Why no recent decision under this principle can be checked"
63
+ }
48
64
  }
49
65
  },
50
66
  "reassessment": "Give a reassessment only for a fixed finding; omit it for deferred, accepted or disagreed.",
51
67
  "check_result": {
52
- "ran": {
53
- "command": "the member's check, exactly as context.members lists it",
54
- "exit_status": 0,
55
- "review_basis": "One line saying what the review before the run rested on; needed when check_since_last_audit is new or changed"
56
- },
57
- "not_run": {
58
- "command": "the member's check, exactly as context.members lists it",
59
- "not_run_reason": "Why you could not run it here, such as a missing tool or a sandbox"
68
+ "copy_to": "response_template.member_assessments entry matching member_id, inside check_result",
69
+ "copy_from": "Merge only examples.ran or examples.not_run into that existing object, then fill command and outcome. Leave unused fields exactly as that member's template printed them. For a new or changed run, write its review_basis; for an unchanged run, keep its own review_basis placeholder to retain the earlier line, or write a new basis. Do not submit this wrapper or limits.",
70
+ "examples": {
71
+ "ran": {
72
+ "command": "the member's check, exactly as context.members lists it",
73
+ "exit_status": 0
74
+ },
75
+ "not_run": {
76
+ "command": "the member's check, exactly as context.members lists it",
77
+ "not_run_reason": "Instead of exit_status, when you could not run it here: why, such as a missing tool or a sandbox"
78
+ }
60
79
  },
61
- "limits": "Give a checked member's check_result in its own entry in member_assessments, where the template starts it, and none for a member without a check. A check whose check_since_last_audit status is new or changed has not been run by an audit, and anyone who can commit to the project can change it: before you run it, have it reviewed by the project's owner, or confirm it against the project's own documentation, where documentation outside the check's own file counts for more than comments in it, and otherwise report not_run_reason. Beside the exit status of a new or changed check, say in review_basis, in one line, what that review rested on, such as who reviewed it or the document that confirms it; if you did the review yourself, such as confirming against the documentation a check you changed, say so: \"Self-reviewed by the agent: <what you checked it against>\"; if no record of it was kept, say that the basis was not kept. This tool keeps the line and cannot verify it. You may give one beside not_run_reason or for an unchanged check too. A member that names a check asks for it to run at each full audit, however long it takes; if it is too slow to run at every audit, say so as a finding rather than skip it. Do not count on a permission prompt to show the command to anyone first. unchanged means an earlier audit ran this same command, not that it is safe: the audit record is committed too, and can be changed beside the check. Run the command in the project before you report its exit status: nothing runs it automatically, and nothing confirms that a reported run happened, that it ran on the files as they are now, or that the status is the one it returned. A failing check is a fact for your assessment; whether the member delivers stays your judgement."
80
+ "limits": "Give a checked member's check_result in its own entry in member_assessments, where the template starts it, and none for a member without a check. A member that names a check asks for it to run at each full audit, however long it takes; if it is too slow to run at every audit, say so as a finding rather than skip it. Do not count on a permission prompt to show the command to anyone first. unchanged means an earlier audit ran this same command, not that it is safe: the audit record is committed too, and can be changed beside the check. Run the command in the project before you report its exit status: nothing runs it automatically, and nothing confirms that a reported run happened, that it ran on the files as they are now, or that the status is the one it returned. A failing check is a fact for your assessment; whether the member delivers stays your judgement."
62
81
  }
63
82
  }
@@ -6,7 +6,3 @@ each other, is any member never consulted or never updated, do any contradict? C
6
6
  you recently made under this principle against the members' own words, or record why none is
7
7
  available. Each finding needs a consequence and a concrete proposed action. Never treat plausible
8
8
  source as observed operation.
9
- Observed means you saw the member's mechanism act in this project, on a real input, or read a record
10
- of it acting, such as a log or a build run. Reading its source or configuration is not observing it.
11
- When you saw only part of what it does, for example a check accepting good input but never rejecting
12
- bad input, mark it observed for what you saw and say which part you did not see.
@@ -0,0 +1,7 @@
1
+ A finding kept from records written before this tool kept `first_raised_at` is dated late. When the record's git
2
+ history shows an earlier version leaving it open, at `.principles/audits/` or the folder's earlier name
3
+ `.memeplex/audits/`, and you judge it the same finding, give `first_raised_at`, that version's `audited_at`, with
4
+ `raised_in`, the full sha of the commit holding it, in its `still_holds` decision. This tool reads the record at
5
+ that commit only, and refuses the claim unless that version leaves a finding with the same id deferred or accepted,
6
+ its `audited_at` equals the claimed time, and the time is earlier than the one stored; whether it is the same
7
+ finding is yours to judge.
@@ -7,14 +7,7 @@ there is one. A finding marked `text_not_kept` has no statement; judge it from i
7
7
  Decide `still_holds` to keep it. Give `recorded_at` to point at a new write-up, and `problem`, one line, when the
8
8
  finding is marked `text_not_kept` or to restate its problem when a term in it was renamed or a fact it names moved,
9
9
  since a different problem is a new finding; the record keeps its `first_raised_at`, so leave that field out unless an
10
- earlier record held the same finding.
11
-
12
- A deferral may carry `waits_on`, the one line an earlier audit gave saying whom it waits on and to decide what, and
13
- `waits_on_since`, when that was asked. Check that the same person still owes the same decision: leave `waits_on` out
14
- of a `still_holds` decision to keep it as asked then, give a new line when the ask changed, or null when it waits on
15
- no one now. A `still_holds` decision may also give a deferral without one its first `waits_on` line; its
16
- `waits_on_since` is then this audit, while `first_raised_at` keeps how long the finding has waited. A null, or
17
- making the finding `accepted`, drops it, and the completed result names what it dropped.
10
+ earlier record held the same finding; to claim that, read this field whole.
18
11
 
19
12
  To change its `action`, give `action`, `deferred` or `accepted`, with a one-line `reason`. A deferral also gives
20
13
  `recorded_at`, or null when it is written up nowhere; a null drops any pointer the finding had, and the completed
@@ -27,13 +20,8 @@ Decide `raised_again` with `as` set to the id of a new finding in this assessmen
27
20
  audit, which keeps when it was first raised. Two raised again as one new finding are refused: to merge them, raise
28
21
  one again and close the others as `withdrawn`, with a reason naming the new finding.
29
22
 
30
- A finding kept from records written before this tool kept `first_raised_at` is dated late. When the record's git
31
- history shows an earlier version leaving it open, at `.principles/audits/` or the folder's earlier name
32
- `.memeplex/audits/`, and you judge it the same finding, give `first_raised_at`, that version's `audited_at`, with
33
- `raised_in`, the full sha of the commit holding it, in its `still_holds` decision. This tool reads the record at
34
- that commit only, and refuses the claim unless that version leaves a finding with the same id deferred or accepted,
35
- its `audited_at` equals the claimed time, and the time is earlier than the one stored; whether it is the same
36
- finding is yours to judge.
37
-
38
23
  A new finding may not reuse the id of a prior finding you keep. The prior findings are %{ids}, so give new findings
39
24
  other ids.
25
+
26
+ A `still_holds` decision may give a deferral without one its first `waits_on` line, saying whom it waits on and to
27
+ decide what; its `waits_on_since` is then this audit, while `first_raised_at` keeps how long the finding has waited.
@@ -1,10 +1,5 @@
1
- Each member with `carried_forward` is unchanged since the last full audit judged it: its text, its map
2
- entry and when it loads are the same, and so are the description and this question. Its template entry is
3
- the marker `{"member_id", "carried_forward": true}`, which keeps that assessment and its date. Judge
4
- afresh each member with `judge_because`, as `judge_because_instruction` says. Then judge the set with the carried
5
- assessments in view, since a changed member can change how the rest reinforce each other. A carried
6
- assessment is a fact about an earlier reading, not a check of the member now: `evidence_changed` and
7
- `file_changed_outside_member` say what moved around it, and an observed delivery's `observed_at` says how
8
- old its sighting is: judge the member again when that sighting is too old to stand behind. Replace a marker with a fresh assessment
9
- whenever you no longer stand behind the one carried. A member with a check still needs its
10
- `check_result`.
1
+ Each member with `carried_forward` is unchanged since the last full audit judged it: its text, its map entry and when it
2
+ loads are the same, and so are the description and this question. Its template entry is the marker `{"member_id",
3
+ "carried_forward": true}`, which keeps that assessment and its date. Judge afresh each member with `judge_because`, as
4
+ `judge_because_instruction` says. Then judge the set with the carried members in view, since a changed member can change
5
+ how the rest reinforce each other.
@@ -0,0 +1,4 @@
1
+ A deferral may carry `waits_on`, the one line an earlier audit gave saying whom it waits on and to decide what, and
2
+ `waits_on_since`, when that was asked. Check that the same person still owes the same decision: leave `waits_on` out
3
+ of a `still_holds` decision to keep it as asked then, give a new line when the ask changed, or null when it waits on
4
+ no one now. A null, or making the finding `accepted`, drops it, and the completed result names what it dropped.
@@ -0,0 +1,8 @@
1
+ When judging the set needs what a carried member was judged to say, run `show-audit` with this principle's id: a compact
2
+ one prints no assessment. A carried member shows only its `assessed_at`, the facts that say what moved around it, and
3
+ any check, whose `check_result` its template still asks for, unless one of those facts fires: then it prints whole, with
4
+ its stored assessment and evidence. It prints whole when `evidence_changed` or `file_changed_outside_member` is true,
5
+ when a `mapped_elsewhere` entry names `open_finding_ids`, and when this principle leaves a finding open on it: its
6
+ `open_finding_ids` names that finding, the same one the prior findings list. An observed delivery's `observed_at` stays,
7
+ since it says how old its sighting is: judge the member again when that sighting is too old to stand behind. Replace a
8
+ marker with a fresh assessment whenever you no longer stand behind the one carried.
@@ -0,0 +1 @@
1
+ Printed in part: %{fields}. To read one whole, add `--instruction FIELD` to this start-audit.
@@ -0,0 +1,9 @@
1
+ A check whose check_since_last_audit status is new or changed has not been run by an audit, and anyone who can
2
+ commit to the project can change it: before you run it, have it reviewed by the project's owner, or confirm it
3
+ against the project's own documentation, where documentation outside the check's own file counts for more than
4
+ comments in it, and otherwise report not_run_reason. Beside the exit status of a new or changed check, say in
5
+ review_basis, in one line, what that review rested on, such as who reviewed it or the document that confirms it; if
6
+ you did the review yourself, such as confirming against the documentation a check you changed, say so:
7
+ "Self-reviewed by the agent: <what you checked it against>"; if no record of it was kept, say that the basis was not
8
+ kept. This tool keeps the line and cannot verify it. You may give one beside not_run_reason or for an unchanged
9
+ check too.
@@ -0,0 +1,4 @@
1
+ Observed means you saw the member's mechanism act in this project, on a real input, or read a record
2
+ of it acting, such as a log or a build run. Reading its source or configuration is not observing it.
3
+ When you saw only part of what it does, for example a check accepting good input but never rejecting
4
+ bad input, mark it observed for what you saw and say which part you did not see.
@@ -4,6 +4,7 @@
4
4
  "action": "fixed",
5
5
  "reason": "What you changed, in one line",
6
6
  "changed_members": ["the id of each member the fix changed"],
7
+ "removed_members": ["the id of each member the fix removed from the map"],
7
8
  "evidence": [{ "path": "a project file", "starting_at": "text that occurs once in the fixed passage" }],
8
9
  "reassessment": "How the changed member reads now, and any check you ran on it",
9
10
  "recorded_at": null
@@ -10,9 +10,10 @@ or a notes file, set its `recorded_at` to that place, as `{"path": ..., "heading
10
10
  When a deferral waits on someone, set its `waits_on` to one line saying whom it waits on and to decide what, such as
11
11
  "<person>, to approve a CI change", and keep the reason in the write-up. Leave it null when it waits on no one in
12
12
  particular. Only a deferral may give one, and this tool records when it was asked.
13
- If a fix rewrites the heading or the quoted text that locates a member, move the member with
14
- `move-member`, then list the move in the answer as `"moved_members": [{"from": OLD_ID, "to": NEW_ID}]`
15
- and name the new id in the finding's `changed_members`. In git, the move is checked against the map
13
+ If a fix rewrites the heading or the quoted text that locates a member, or the member's passage should be narrower
14
+ or wider, move the member with `move-member`, then list the move in the answer as
15
+ `"moved_members": [{"from": OLD_ID, "to": NEW_ID}]`, or `[{"from": ID, "to": ID}]` when the move kept its id, and
16
+ name the id after the move in the finding's `changed_members`. In git, the move is checked against the map
16
17
  the audit began from.
17
18
  If the fix is to a member's role or check in the map, make it with `change-member-role` or `change-member-check`
18
19
  and list the member's id in the finding's `changed_map_entries`. In git, the change is checked against the map the
@@ -22,3 +23,15 @@ If the fix is to map a member the finding says is missing, add it with `add-memb
22
23
  changed. No assessment has read it, so the record gives it no baseline: the completed result names it under
23
24
  `members_added_awaiting_assessment`, and the next full audit assesses it. Outside git, a member added now is refused:
24
25
  defer the finding and add the member after the audit.
26
+
27
+ If the fix removes obsolete guidance from the map, use `remove-member`, keeping its source file, then list its
28
+ original id in that fixed disposition's optional `removed_members`. In git, the union of those lists must explain
29
+ exactly the map removals; repeated claims are allowed. Each removed id must exist at the audit base, be absent now,
30
+ and appear in neither `moved_members` nor `changed_map_entries`. `changed_members` names current text changes; leave
31
+ it empty for a removal-only fix. Give a substantive reassessment and at least one located evidence pointer about
32
+ the remaining guidance for a fix with only removals. This tool checks the pointer, while you judge its relevance.
33
+ Leave a survivor or add a replacement; a new member still awaits assessment. Existing findings keep their original
34
+ member attribution and age even when their member was removed. An empty endpoint cannot complete this correction:
35
+ retain the correction packet and restore the map entries before reconsidering or deferring, or explicitly deactivate
36
+ the principle while retaining its previous audit history. A removal grants no permission to delete a source file.
37
+ Non-fixed dispositions omit `removed_members` or leave it empty. Without git, map removals cannot be verified.
@@ -0,0 +1,4 @@
1
+ Keep the exact original assessment you submit (or the exact stdin bytes for `--file -`) and this correction
2
+ packet before changing members. Save copies outside the project, including the correction's request_id,
3
+ basis and response_template or correction_template, and fill only its dispositions. Git cannot reconstruct
4
+ your assessment judgements.
@@ -0,0 +1,6 @@
1
+ After the table, ask where else this repository keeps guidance agents follow, including other harness folders,
2
+ linked documents, templates and executable checks. You judge which files carry principles; this inventory does not
3
+ establish that a host loads them. To include a location in a read-only survey now, repeat --also with a quoted
4
+ root-relative glob. This option does not record the location for later surveys.
5
+ After the table, record chosen search paths with add-guidance-search-path; remove-guidance-search-path stops recording one.
6
+ Saved search paths are included automatically and named in recorded_guidance_search_paths when nonempty.
@@ -0,0 +1 @@
1
+ After the table, ask the project's owner:
@@ -0,0 +1,2 @@
1
+ After the table, ask the user which principle to map first. Give it a lower-kebab-case id, and describe it in one
2
+ sentence of your own.
@@ -0,0 +1,2 @@
1
+ After the table, ask which existing principle to extend with add-member, or which distinct principle to map with
2
+ create-principle. For a new map, choose a lower-kebab-case id and describe what the principle is and why it matters.
@@ -1,5 +1,11 @@
1
- Look through this project for a principle that several pieces of agent guidance reinforce together.
2
- Members can be instruction files or their sections, rules, skills, hooks, reminders, scripts, data files or build
3
- checks anywhere in the project; the inventory lists only the usual places. Pick one principle, give it a
4
- lower-kebab-case id, and describe it in one sentence of your own. If nothing here reinforces a principle, say so and
5
- stop.
1
+ Survey this project's principles: the rules that several pieces of its agent guidance reinforce together. Read
2
+ each listed Markdown file's outline, description and opening line printed here, not the files themselves.
3
+ For a selected non-Markdown file listed by path and size, inspect that file only if needed to judge the rule it
4
+ enforces; listing it does not show its contents. Show the user one
5
+ table, with a row for each principle: a name of a word or two, a one-line description, and the files and sections
6
+ that carry it. Members can also be rules, skills, hooks, reminders, scripts, data files or build checks anywhere in
7
+ the project; inventory.scope states what this survey covers. Ask nothing and write nothing until the table is shown. If
8
+ nothing here reinforces a principle, say so and stop.
9
+
10
+ Under the table, name the files that look ticket-local or boilerplate, such as one task's notes or a template left
11
+ as generated, each with why, so the user can say whether to leave them out.
@@ -0,0 +1,11 @@
1
+ Survey this project's principles using each listed Markdown file's outline, description and opening line printed here,
2
+ not the files themselves. For a selected non-Markdown file listed by path and size, inspect that file only if needed
3
+ to judge the rule it enforces; listing it does not show its contents.
4
+ Compare each rule with the id and description in mapped_principles: is it a facet of
5
+ an existing principle, another member carrying that principle, or a distinct principle?
6
+ A row with a refusal has no readable description: resolve its repair before deciding a rule is distinct. You judge; do not create
7
+ a separate map for each wording or file. Show the user one table of principles, each with its description,
8
+ carrying files and sections, and the existing map it belongs to or why it is distinct.
9
+ Ask nothing and write nothing until the table is shown. If nothing here reinforces a principle, say so and stop.
10
+
11
+ Under the table, name ticket-local or boilerplate files with why they may be left out.
@@ -0,0 +1 @@
1
+ Leave the files under possibly_test_data out of the survey, and name them under the table.