ai-agentmanager 1.65.0 → 1.66.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/CHANGELOG.md +7 -0
- package/README.md +2 -0
- package/package.json +1 -1
- package/public/app.js +12 -2
- package/public/groups.js +7 -2
- package/src/cli.js +5 -0
- package/src/config.js +2 -0
- package/src/manager.js +9 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.66.0 (2026-11-23)
|
|
4
|
+
|
|
5
|
+
- **Possibly patentable work is noticed without asking.** When an agent finishes, Insights is now made by itself, so the kind of idea (a task, worth a white paper, possibly patentable) is read for every finished task. `"insights": { "auto": false }` in config.json turns it off; it is one more model call per finished agent.
|
|
6
|
+
- **It waits in your inbox.** Work that Insights reads as possibly patentable, or that the agent flags as new, shows as **Possibly patentable** in the inbox and in `agentmgr inbox`, with **Keep it private** and **Allow sharing**. Until you decide, it is kept private as before.
|
|
7
|
+
|
|
8
|
+
- **Split screen: a view that follows another keeps fitting after the text size changes.** Changing the terminal text size could leave the following view at the full size, measured before the terminal had taken the new size in. It is now fitted again over the next moments.
|
|
9
|
+
|
|
3
10
|
## 1.65.0 (2026-11-23)
|
|
4
11
|
|
|
5
12
|
- **Test the tests: would the agent's tests notice a mistake?** The app breaks the lines the agent changed, one at a time and in a small way (`===` becomes `!==`, `&&` becomes `||`, a number goes up by one), runs the tests on each, and puts the line back. A break the tests still pass on is a line nothing checks. In the agent's **Proof** dialog under **Test the tests**, or `agentmgr test-tests <agent> --run` (`-c` for the test command, `--max` for how many lines). The Results show **Tests tested**, for example "5 of 6 breaks caught".
|
package/README.md
CHANGED
|
@@ -704,6 +704,8 @@ Publishing before filing can cost the right to a patent. So when part of an agen
|
|
|
704
704
|
|
|
705
705
|
The agent is told as well: nothing published outside the repository, no pull request, and its design doc stays a file.
|
|
706
706
|
|
|
707
|
+
**Noticed without asking.** When an agent finishes, Insights is made by itself, so the kind of idea is read for every finished task (`"insights": { "auto": false }` in config.json turns that off; it is one more model call per finished agent). Work read as possibly patentable, or flagged by the agent, then waits in your inbox as **Possibly patentable** with two buttons: **Keep it private** and **Allow sharing**. `agentmgr inbox` lists it too. Until you decide, it is kept private.
|
|
708
|
+
|
|
707
709
|
**Lifting it** is yours alone: **Allow sharing** in the agent's Results, or `agentmgr private <agent> --allow`. An agent's own call is refused. `--reset` goes back to what the agent and Insights say. A white paper is not held.
|
|
708
710
|
|
|
709
711
|
**Limits.** This guards what the app sends. It does not stop an agent from running a command in its terminal that publishes something; the agent is instructed not to, and its permission prompts still apply. Work already pushed or published before it was marked stays where it is. It is a caution based on a first read, not a finding that anything is patentable: talk to a patent attorney.
|
package/package.json
CHANGED
package/public/app.js
CHANGED
|
@@ -1616,7 +1616,7 @@ function loadLimitEngines() {
|
|
|
1616
1616
|
})
|
|
1617
1617
|
.catch(() => (limitEngines = null));
|
|
1618
1618
|
}
|
|
1619
|
-
const NEED_ORDER = { approval: 0, prompt: 0, limit: 1, waiting: 1, plan: 1, acceptance: 1, question: 1, team: 1, rule: 2, auto: 2, review: 2, prereview: 2, autopilot: 2, stuck: 3, conflict: 4, reminder: 5, close: 5, repeat: 5, update: 4 };
|
|
1619
|
+
const NEED_ORDER = { approval: 0, prompt: 0, limit: 1, waiting: 1, plan: 1, acceptance: 1, question: 1, team: 1, rule: 2, auto: 2, review: 2, prereview: 2, autopilot: 2, stuck: 3, conflict: 4, reminder: 5, close: 5, repeat: 5, update: 4 , idea: 2 };
|
|
1620
1620
|
/** What an agent needs from the user. `both`: overlaps on both agents (detail), else only the one that should rebase (inbox). */
|
|
1621
1621
|
function needsFor(a, { both = false } = {}) {
|
|
1622
1622
|
const items = [];
|
|
@@ -1629,6 +1629,8 @@ function needsFor(a, { both = false } = {}) {
|
|
|
1629
1629
|
if (['stalled', 'error'].includes(a.preReview?.status)) items.push({ a, kind: 'prereview', key: `prereview:${a.id}` });
|
|
1630
1630
|
for (const q of a.questions ?? []) if (!q.answer) items.push({ a, kind: 'question', key: `q:${a.id}:${q.id}`, q });
|
|
1631
1631
|
items.push(...autonomyNeeds(a));
|
|
1632
|
+
// Read as possibly worth protecting, and not decided by you yet (private.js).
|
|
1633
|
+
if (a.keptPrivate && a.keptPrivate.from !== 'you') items.push({ a, kind: 'idea', key: `idea:${a.id}` });
|
|
1632
1634
|
for (const f of a.stuck ?? []) items.push({ a, kind: 'stuck', key: `stuck:${a.id}:${f.key}`, f });
|
|
1633
1635
|
if (updateWaits(a)) items.push({ a, kind: 'update', key: `update:${a.id}` });
|
|
1634
1636
|
if (a.followUp) items.push({ a, kind: a.followUp.kind === 'close' ? 'close' : 'reminder', key: `reminder:${a.id}`, r: a.followUp });
|
|
@@ -1667,7 +1669,7 @@ function inboxItems() {
|
|
|
1667
1669
|
.sort((x, y) => NEED_ORDER[x.kind] - NEED_ORDER[y.kind] || (x.a.priority ?? 2) - (y.a.priority ?? 2));
|
|
1668
1670
|
}
|
|
1669
1671
|
|
|
1670
|
-
const NEED_LABEL = { update: 'Update to send', limit: 'Limit', reminder: 'Follow up', close: 'Close session?', repeat: 'Make it a playbook?', autopilot: 'Autopilot held', rule: 'Always allow?', approval: 'Approval', team: 'Team', prompt: 'Needs input', waiting: 'Waiting on you', acceptance: 'Done means', auto: 'Done for you', plan: 'Plan review', question: 'Question', review: 'AI review', prereview: 'Not approved', stuck: 'Stuck?', conflict: 'Overlap' };
|
|
1672
|
+
const NEED_LABEL = { update: 'Update to send', limit: 'Limit', reminder: 'Follow up', close: 'Close session?', repeat: 'Make it a playbook?', autopilot: 'Autopilot held', rule: 'Always allow?', approval: 'Approval', team: 'Team', prompt: 'Needs input', waiting: 'Waiting on you', acceptance: 'Done means', auto: 'Done for you', plan: 'Plan review', question: 'Question', review: 'AI review', prereview: 'Not approved', stuck: 'Stuck?', conflict: 'Overlap' , idea: 'Possibly patentable' };
|
|
1671
1673
|
/** Why the AI judge thinks so, as a small tag. */
|
|
1672
1674
|
const aiTag = (confidence, what = 'AI') => `<span class="tag ai" title="Judged by a model from the agent's activity; your reactions tune later calls">🤖 ${what}${confidence != null ? ` ${Math.round(confidence * 100)}%` : ''}</span>`;
|
|
1673
1675
|
/** What a permission prompt asks about: the command, file or tool. */
|
|
@@ -1782,6 +1784,10 @@ function needCard(it, { inDetail = false } = {}) {
|
|
|
1782
1784
|
<div class="need-actions"><button class="small primary" data-ib="team-open" data-team="${t.id}">${t.stage !== 'ready' ? 'Decide' : t.gaps ? 'See the gaps' : 'Review and finalize'}</button></div>`;
|
|
1783
1785
|
} else if (it.kind === 'auto') {
|
|
1784
1786
|
body = autoNeedHtml(it, { esc, ago });
|
|
1787
|
+
} else if (it.kind === 'idea') {
|
|
1788
|
+
body = `<p class="need-title">🔒 ${esc(a.keptPrivate.why)}</p>
|
|
1789
|
+
<p class="hint">Kept private until you decide: the app does not publish or send it, and opens no pull request. Publishing before filing can cost the right to a patent. This is a first read without a search for prior art, not a finding.</p>
|
|
1790
|
+
<div class="need-actions"><button class="small primary" data-ib="idea-keep" title="It stays private until you allow sharing; this card goes away">Keep it private</button><button class="small" data-ib="idea-allow" title="It is not worth protecting, or it is already filed: the holds are lifted">Allow sharing</button></div>`;
|
|
1785
1791
|
} else if (it.kind === 'acceptance') {
|
|
1786
1792
|
const pts = a.acceptance.points;
|
|
1787
1793
|
body = `<p class="need-title">What done means: ${pts.length} point${pts.length === 1 ? '' : 's'}</p>
|
|
@@ -2047,6 +2053,10 @@ async function onNeed(e) {
|
|
|
2047
2053
|
return openPlan(id);
|
|
2048
2054
|
case 'accept-open':
|
|
2049
2055
|
return acceptUi.open(id);
|
|
2056
|
+
case 'idea-keep':
|
|
2057
|
+
return act(async () => upsert(await api('POST', `/agents/${id}/private`, { private: true })), 'Kept private until you allow sharing');
|
|
2058
|
+
case 'idea-allow':
|
|
2059
|
+
return act(async () => upsert(await api('POST', `/agents/${id}/private`, { private: false })), 'Sharing allowed');
|
|
2050
2060
|
case 'auto-ok':
|
|
2051
2061
|
return autoUi.ok(id, el.dataset.entry);
|
|
2052
2062
|
case 'auto-change':
|
package/public/groups.js
CHANGED
|
@@ -49,8 +49,13 @@ export function ownFont(v) {
|
|
|
49
49
|
/** The text size was changed in the menu. */
|
|
50
50
|
export function newFont(v, fit, box) {
|
|
51
51
|
v.xterm.options.fontSize = termFont();
|
|
52
|
-
if (v.follow)
|
|
53
|
-
|
|
52
|
+
if (v.follow) {
|
|
53
|
+
// xterm takes the new size in over the next frames: measured too early, the view would stay
|
|
54
|
+
// at the full size and no longer fit. Fitting again is harmless once it does.
|
|
55
|
+
const again = () => scaleToFit(v, box);
|
|
56
|
+
requestAnimationFrame(again);
|
|
57
|
+
for (const ms of [120, 400, 1000]) setTimeout(again, ms);
|
|
58
|
+
} else fit();
|
|
54
59
|
}
|
|
55
60
|
|
|
56
61
|
/** This view sets the size again: its own font, fitted to its panel, sent to the session. */
|
package/src/cli.js
CHANGED
|
@@ -2145,6 +2145,11 @@ export async function main(argv) {
|
|
|
2145
2145
|
console.log(dim(' agentmgr rules'));
|
|
2146
2146
|
continue;
|
|
2147
2147
|
}
|
|
2148
|
+
if (it.kind === 'idea') {
|
|
2149
|
+
console.log(`${yellow('possibly patentable')} ${bold(it.agentName)} ${dim(it.agentId)} ${it.title}`);
|
|
2150
|
+
console.log(dim(` Kept private until you decide. agentmgr private ${it.agentId} --keep · agentmgr private ${it.agentId} --allow · agentmgr insights ${it.agentId}`));
|
|
2151
|
+
continue;
|
|
2152
|
+
}
|
|
2148
2153
|
if (it.kind === 'auto') {
|
|
2149
2154
|
console.log(`${cyan('done for you')} ${bold(it.agentName)} ${dim(it.agentId)} ${it.title}`);
|
|
2150
2155
|
if (it.entry?.answer) console.log(dim(` → ${it.entry.answer}\n agentmgr autonomy ${it.agentId} --ok · agentmgr autonomy ${it.agentId} --change ${it.entry.id}="your answer"`));
|
package/src/config.js
CHANGED
|
@@ -57,6 +57,8 @@ const DEFAULTS = {
|
|
|
57
57
|
premortem: true,
|
|
58
58
|
// With the brief: when there is more than one way, ask for the options ranked by value now and later (## Options).
|
|
59
59
|
valueLens: true,
|
|
60
|
+
// Insights (why, what, how, now; value now and later, the kind of idea, the paths ranked) made by itself when an agent finishes.
|
|
61
|
+
insights: { auto: true },
|
|
60
62
|
// Test the tests (mutate.js): how many changed lines are broken in one run, the longest the tests may take, and one run in all.
|
|
61
63
|
testTheTests: { max: 8, timeoutMs: 300_000, budgetMs: 900_000 },
|
|
62
64
|
// Backlog: items worked on at once per project (overridable per project), and overall.
|
package/src/manager.js
CHANGED
|
@@ -2585,6 +2585,9 @@ export class AgentManager extends EventEmitter {
|
|
|
2585
2585
|
// The points were agreed (or changed) after the last score: the brief saying done again is checked against them.
|
|
2586
2586
|
const reagreed = brief.status === 'done' && agent.acceptance?.status === 'agreed' && agent.docs?.scorecard?.data && agent.docs.scorecard.acceptanceAt !== agent.acceptance.agreedAt;
|
|
2587
2587
|
if ((improved || reagreed || (finished && this.config.scorecard?.auto !== false && !rounds)) && !NO_REPO.has(agent.kind) && this.changesSource) this.summarize(id, 'scorecard').catch(() => {});
|
|
2588
|
+
// ...and read it for what it is worth and what kind of idea it is (Insights), so work that may be worth
|
|
2589
|
+
// protecting is noticed without anyone asking ("insights": { "auto": false } in config.json turns this off).
|
|
2590
|
+
if (finished && this.config.insights?.auto !== false && !NO_REPO.has(agent.kind)) this.summarize(id, 'insights').catch(() => {});
|
|
2588
2591
|
}
|
|
2589
2592
|
// Its points for what done means, written or revised in the spec: they wait for the person.
|
|
2590
2593
|
if (this.acceptanceWaits(agent)) {
|
|
@@ -3916,9 +3919,14 @@ export class AgentManager extends EventEmitter {
|
|
|
3916
3919
|
}
|
|
3917
3920
|
// Commands you keep allowing in a repo: offer to always allow them there.
|
|
3918
3921
|
for (const r of this.rules.view().suggestions) items.push({ kind: 'rule', key: `rule:${r.repo}:${r.rule}`, title: `Always allow ${r.label}${r.everywhere ? ' in every repo' : ''}?`, priority: 2, ...r });
|
|
3922
|
+
// Work read as possibly worth protecting (private.js) that you have not decided on: keep it private, or allow sharing.
|
|
3923
|
+
for (const agent of this.store.list()) {
|
|
3924
|
+
const kept = keptPrivate(agent);
|
|
3925
|
+
if (kept && kept.from !== 'you') items.push({ kind: 'idea', key: `idea:${agent.id}`, agentId: agent.id, agentName: agent.name, priority: agent.priority ?? 2, title: kept.why, from: kept.from, at: agent.insights?.at ?? agent.brief?.updatedAt ?? null });
|
|
3926
|
+
}
|
|
3919
3927
|
// Others' items (autopilot's held backlog work).
|
|
3920
3928
|
for (const source of this.inboxSources) items.push(...source());
|
|
3921
|
-
const order = { prompt: 0, limit: 1, waiting: 1, question: 1, rule: 2, review: 2, prereview: 2, autopilot: 2, stuck: 3, conflict: 4, reminder: 5, repeat: 5 };
|
|
3929
|
+
const order = { prompt: 0, limit: 1, waiting: 1, question: 1, rule: 2, review: 2, prereview: 2, autopilot: 2, idea: 2, stuck: 3, conflict: 4, reminder: 5, repeat: 5 };
|
|
3922
3930
|
return items.sort((a, b) => order[a.kind] - order[b.kind] || a.priority - b.priority);
|
|
3923
3931
|
}
|
|
3924
3932
|
|