@link-assistant/hive-mind 1.72.1 → 1.72.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.
- package/CHANGELOG.md +8 -0
- package/package.json +1 -1
- package/src/solve.results.lib.mjs +3 -2
- package/src/tool-comments.lib.mjs +15 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @link-assistant/hive-mind
|
|
2
2
|
|
|
3
|
+
## 1.72.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 055a1a0: Fix `--auto-attach-solution-summary` so Codex-authored comments that use the
|
|
8
|
+
visible "Working session summary" heading are counted as AI comments instead of
|
|
9
|
+
being mistaken for hive-mind's automated summary comment.
|
|
10
|
+
|
|
3
11
|
## 1.72.1
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1258,12 +1258,13 @@ export const attachSolutionSummary = async ({ resultSummary, prNumber, issueNumb
|
|
|
1258
1258
|
}
|
|
1259
1259
|
|
|
1260
1260
|
try {
|
|
1261
|
-
const comment =
|
|
1261
|
+
const comment = `${toolComments.WORKING_SESSION_SUMMARY_AUTOMATION_MARKER}
|
|
1262
|
+
## ${toolComments.WORKING_SESSION_SUMMARY_MARKER}
|
|
1262
1263
|
|
|
1263
1264
|
${resultSummary}
|
|
1264
1265
|
|
|
1265
1266
|
---
|
|
1266
|
-
|
|
1267
|
+
*${toolComments.WORKING_SESSION_SUMMARY_AUTOMATED_FOOTER}*`;
|
|
1267
1268
|
|
|
1268
1269
|
const { ok, commentId, stderr } = await postTrackedComment({ $, owner, repo, targetNumber, body: comment });
|
|
1269
1270
|
|
|
@@ -64,10 +64,15 @@ export const CANCELLED_CI_REVIEW_MARKER = 'Cancelled CI/CD Requires Review';
|
|
|
64
64
|
// iteration, or watch-mode iteration). Issue #1728: Renamed from
|
|
65
65
|
// "Solution summary" because not every working session is a solution draft —
|
|
66
66
|
// many are continuation/restart iterations that are part of an in-progress
|
|
67
|
-
// solution.
|
|
68
|
-
//
|
|
69
|
-
// previous iteration's summary for an AI-authored comment.
|
|
67
|
+
// solution. Automation evidence is tracked separately so the visible heading
|
|
68
|
+
// can still be used by real AI-authored comments.
|
|
70
69
|
export const WORKING_SESSION_SUMMARY_MARKER = 'Working session summary';
|
|
70
|
+
// Issue #1813: the visible "Working session summary" heading is natural text
|
|
71
|
+
// that Codex can write in its own PR comment. Do not treat the heading alone as
|
|
72
|
+
// a tool-generated marker. New automated summaries include this hidden marker;
|
|
73
|
+
// legacy automated summaries are still recognized by the footer text below.
|
|
74
|
+
export const WORKING_SESSION_SUMMARY_AUTOMATION_MARKER = '<!-- hive-mind:working-session-summary -->';
|
|
75
|
+
export const WORKING_SESSION_SUMMARY_AUTOMATED_FOOTER = 'This summary was automatically extracted from the AI working session output.';
|
|
71
76
|
|
|
72
77
|
// github.lib.mjs — fork contributor "Allow edits by maintainers" request
|
|
73
78
|
export const MAINTAINER_ACCESS_REQUEST_MARKER = 'Allow edits by maintainers';
|
|
@@ -102,7 +107,7 @@ export const USAGE_LIMIT_REACHED_MARKER = 'Usage Limit Reached';
|
|
|
102
107
|
* named constants above so that adding a new marker only requires adding
|
|
103
108
|
* the constant and appending it here.
|
|
104
109
|
*/
|
|
105
|
-
export const TOOL_GENERATED_COMMENT_MARKERS = [AI_WORK_SESSION_STARTED_MARKER, AI_WORK_SESSION_COMPLETED_MARKER, AI_WORK_SESSION_RESUMED_MARKER, AUTO_RESUME_ON_LIMIT_RESET_MARKER, AUTO_RESTART_ON_LIMIT_RESET_MARKER, SOLUTION_DRAFT_LOG_MARKER, AUTO_RESTART_MARKER, AUTO_RESTART_UNTIL_MERGEABLE_LOG_MARKER, READY_TO_MERGE_MARKER, AUTO_MERGED_MARKER, BILLING_LIMIT_MARKER, CANCELLED_CI_REVIEW_MARKER, MAINTAINER_ACCESS_REQUEST_MARKER, LIVE_PROGRESS_SECTION_START_MARKER, SESSION_FORCE_KILLED_MARKER, REPOSITORY_INITIALIZATION_REQUIRED_MARKER, INTERACTIVE_SESSION_STARTED_MARKER, INTERACTIVE_SESSION_ENDED_MARKER, NOW_WORKING_SESSION_IS_ENDED_MARKER, SOLUTION_DRAFT_FAILED_MARKER, SOLUTION_DRAFT_FINISHED_WITH_ERRORS_MARKER, USAGE_LIMIT_REACHED_MARKER,
|
|
110
|
+
export const TOOL_GENERATED_COMMENT_MARKERS = [AI_WORK_SESSION_STARTED_MARKER, AI_WORK_SESSION_COMPLETED_MARKER, AI_WORK_SESSION_RESUMED_MARKER, AUTO_RESUME_ON_LIMIT_RESET_MARKER, AUTO_RESTART_ON_LIMIT_RESET_MARKER, SOLUTION_DRAFT_LOG_MARKER, AUTO_RESTART_MARKER, AUTO_RESTART_UNTIL_MERGEABLE_LOG_MARKER, READY_TO_MERGE_MARKER, AUTO_MERGED_MARKER, BILLING_LIMIT_MARKER, CANCELLED_CI_REVIEW_MARKER, MAINTAINER_ACCESS_REQUEST_MARKER, LIVE_PROGRESS_SECTION_START_MARKER, SESSION_FORCE_KILLED_MARKER, REPOSITORY_INITIALIZATION_REQUIRED_MARKER, INTERACTIVE_SESSION_STARTED_MARKER, INTERACTIVE_SESSION_ENDED_MARKER, NOW_WORKING_SESSION_IS_ENDED_MARKER, SOLUTION_DRAFT_FAILED_MARKER, SOLUTION_DRAFT_FINISHED_WITH_ERRORS_MARKER, USAGE_LIMIT_REACHED_MARKER, WORKING_SESSION_SUMMARY_AUTOMATION_MARKER];
|
|
106
111
|
|
|
107
112
|
/**
|
|
108
113
|
* Markers that indicate the end of a working session. Used by
|
|
@@ -119,9 +124,14 @@ export const SESSION_ENDING_MARKERS = [NOW_WORKING_SESSION_IS_ENDED_MARKER, AI_W
|
|
|
119
124
|
* @param {string} body - The comment body
|
|
120
125
|
* @returns {boolean} - True if the body contains a tool-generated marker
|
|
121
126
|
*/
|
|
127
|
+
export const isAutomatedWorkingSessionSummaryComment = body => {
|
|
128
|
+
if (!body || typeof body !== 'string') return false;
|
|
129
|
+
return body.includes(WORKING_SESSION_SUMMARY_AUTOMATION_MARKER) || (body.includes(`## ${WORKING_SESSION_SUMMARY_MARKER}`) && body.includes(WORKING_SESSION_SUMMARY_AUTOMATED_FOOTER));
|
|
130
|
+
};
|
|
131
|
+
|
|
122
132
|
export const isToolGeneratedComment = body => {
|
|
123
133
|
if (!body || typeof body !== 'string') return false;
|
|
124
|
-
return TOOL_GENERATED_COMMENT_MARKERS.some(marker => body.includes(marker));
|
|
134
|
+
return isAutomatedWorkingSessionSummaryComment(body) || TOOL_GENERATED_COMMENT_MARKERS.some(marker => body.includes(marker));
|
|
125
135
|
};
|
|
126
136
|
|
|
127
137
|
// ----------------------------------------------------------------------------
|