@jossuealcala/madre 1.1.2 → 1.1.4
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.en.md +40 -1
- package/CHANGELOG.md +40 -1
- package/README.en.md +3 -3
- package/README.md +3 -3
- package/SECURITY.md +11 -6
- package/TRADEMARKS.md +6 -2
- package/bin/madre.mjs +76 -11
- package/docs/REFERENCE.md +16 -10
- package/docs/SDK.md +36 -9
- package/docs/en/REFERENCE.md +12 -8
- package/docs/en/SDK.md +34 -8
- package/docs/en/training/README.md +1 -1
- package/docs/sdk/connector-module.mjs +1 -1
- package/docs/sdk/hello-module.mjs +39 -4
- package/docs/training/README.md +1 -1
- package/docs/training/train.sh +3 -0
- package/habilidades/explicamelo-facil/HABILIDAD.md +19 -0
- package/habilidades/hojas-de-calculo/HABILIDAD.md +18 -0
- package/habilidades/mensajes-a-clientes/HABILIDAD.md +19 -0
- package/habilidades/publicaciones-para-redes/HABILIDAD.md +19 -0
- package/habilidades/resumen-y-pendientes/HABILIDAD.md +18 -0
- package/habilidades/tu-pagina-paso-a-paso/HABILIDAD.md +19 -0
- package/package.json +7 -4
- package/public/activity.js +66 -22
- package/public/app.js +4947 -894
- package/public/assets/brand/OFL-SpaceGrotesk.txt +93 -0
- package/public/assets/brand/SpaceGrotesk-latin-ext.woff2 +0 -0
- package/public/assets/brand/SpaceGrotesk-latin.woff2 +0 -0
- package/public/assets/brand/madre-app-180.png +0 -0
- package/public/assets/brand/madre-app-192.png +0 -0
- package/public/assets/brand/madre-app-512.png +0 -0
- package/public/assets/brand/madre-app.svg +1 -1
- package/public/assets/brand/madre-favicon.svg +1 -1
- package/public/attribution.js +29 -19
- package/public/auto-open.js +102 -0
- package/public/brands.js +36 -19
- package/public/changes.js +63 -0
- package/public/en.js +1085 -102
- package/public/es.js +2940 -1656
- package/public/i18n.js +11 -0
- package/public/index.html +31 -27
- package/public/loader.js +322 -117
- package/public/macroverso.js +57 -355
- package/public/manual-content.js +69 -9
- package/public/manual.js +21 -6
- package/public/market-view.js +298 -84
- package/public/market.js +25 -2
- package/public/mcp-catalog.js +7 -2
- package/public/missions.js +169 -0
- package/public/news-scenes.js +292 -0
- package/public/nostromo-engine.js +935 -654
- package/public/notices.js +78 -0
- package/public/notifications.js +119 -0
- package/public/power.js +1 -1
- package/public/provider-marks.js +170 -0
- package/public/provider-pick.js +147 -0
- package/public/resay.js +4 -0
- package/public/review-ask.js +16 -13
- package/public/routing.js +29 -3
- package/public/salas-mac.css +467 -47
- package/public/salas-mac.html +8 -5
- package/public/salas-mac.js +805 -109
- package/public/salas.css +2 -2
- package/public/salas.html +2 -2
- package/public/salas.js +1 -1
- package/public/starters.js +128 -0
- package/public/styles.css +3036 -340
- package/public/subscription.js +303 -0
- package/public/terms-field.js +170 -0
- package/public/terms.js +117 -19
- package/public/tips.js +158 -0
- package/public/tour-chapters.js +88 -88
- package/public/tour.js +364 -46
- package/public/troubleshooting.js +313 -27
- package/public/welcome-scene.js +446 -0
- package/public/welcome.js +827 -282
- package/src/adapters/claude.mjs +2 -1
- package/src/adapters/codex.mjs +2 -1
- package/src/adapters/cursor.mjs +9 -6
- package/src/adapters/gemini-rest.mjs +236 -0
- package/src/adapters/gemini.mjs +13 -7
- package/src/adapters/grok.mjs +290 -0
- package/src/adapters/madre.mjs +71 -23
- package/src/adapters/opencode.mjs +15 -2
- package/src/adapters/process.mjs +14 -3
- package/src/adapters/steps.mjs +176 -0
- package/src/app-invite.mjs +90 -0
- package/src/auth-probe.mjs +32 -0
- package/src/billing-key.mjs +8 -0
- package/src/billing.mjs +317 -0
- package/src/bridge/policy.mjs +1 -1
- package/src/capabilities.mjs +46 -10
- package/src/chats.mjs +44 -2
- package/src/checkpoint.mjs +119 -1
- package/src/codex-route.mjs +113 -0
- package/src/commands.mjs +5 -2
- package/src/credentials.mjs +46 -8
- package/src/dataset.mjs +18 -7
- package/src/directives.mjs +1 -0
- package/src/event-store.mjs +25 -2
- package/src/extensions.mjs +5 -1
- package/src/ficha.mjs +158 -0
- package/src/files.mjs +36 -2
- package/src/image-studio.mjs +13 -3
- package/src/install-metrics.mjs +9 -3
- package/src/lease.mjs +6 -1
- package/src/looks.mjs +4 -1
- package/src/market-check.mjs +1 -1
- package/src/market-remote.mjs +135 -1
- package/src/mcp/image-server.mjs +59 -90
- package/src/mcp/memory-server.mjs +10 -0
- package/src/memory-tools.mjs +3 -0
- package/src/memory.mjs +29 -4
- package/src/models.mjs +21 -3
- package/src/modules/ahp.mjs +10 -4
- package/src/modules/bishop-exam.mjs +41 -12
- package/src/modules/bishop.mjs +2 -2
- package/src/modules/choices.mjs +12 -10
- package/src/modules/fetch-alone.mjs +7 -0
- package/src/modules/github.mjs +6 -2
- package/src/modules/helpers.mjs +23 -5
- package/src/modules/image-providers.mjs +281 -0
- package/src/modules/image-studio.mjs +106 -39
- package/src/modules/index.mjs +61 -12
- package/src/modules/intents-observe.mjs +3 -1
- package/src/modules/isolated.mjs +160 -0
- package/src/modules/ollama.mjs +35 -6
- package/src/modules/playwright.mjs +78 -20
- package/src/modules/reminders.mjs +42 -2
- package/src/modules/ripley.mjs +2 -1
- package/src/modules/run-alone.mjs +122 -0
- package/src/modules/runs.mjs +11 -8
- package/src/modules/sdk.mjs +10 -3
- package/src/notices-key.mjs +8 -0
- package/src/notices.mjs +185 -0
- package/src/ollama.mjs +57 -15
- package/src/opencode-health.mjs +1 -1
- package/src/outbound.mjs +124 -13
- package/src/quota-sources.mjs +148 -3
- package/src/review-ask.mjs +55 -31
- package/src/room/archivist.mjs +30 -5
- package/src/room/busy.mjs +16 -0
- package/src/room/changes.mjs +79 -0
- package/src/room/control.mjs +36 -6
- package/src/room/economy.mjs +1 -1
- package/src/room/guard.mjs +39 -2
- package/src/room/prompt.mjs +49 -6
- package/src/room/vectors.mjs +7 -1
- package/src/room.mjs +181 -49
- package/src/router.mjs +1 -1
- package/src/runs.mjs +39 -0
- package/src/runtime-detection.mjs +46 -6
- package/src/salas.mjs +181 -18
- package/src/server.mjs +1101 -118
- package/src/service.mjs +116 -0
- package/src/setup-trouble.mjs +20 -1
- package/src/setup.mjs +1 -1
- package/src/skill-check.mjs +269 -0
- package/src/skills-import.mjs +128 -0
- package/src/skills.mjs +502 -0
- package/src/terms.mjs +23 -5
- package/src/tour.mjs +31 -5
- package/src/updates.mjs +47 -4
- package/src/web-preview.mjs +181 -0
- package/src/whats-new.mjs +121 -1
- package/src/rumbo.mjs +0 -337
package/public/activity.js
CHANGED
|
@@ -37,6 +37,9 @@ const whereOf = (project) => (project.home ? t('Coordinator') : project.name ??
|
|
|
37
37
|
// What runs, counted for the key: a plan once (its steps are inside it), never an outdated project.
|
|
38
38
|
const counted = (one) => one.kind !== 'turn' || !one.planId;
|
|
39
39
|
|
|
40
|
+
// A step's permission in the words the box uses (#1 Just chat … #4 Full access).
|
|
41
|
+
const MODE_WORDS = { 0: () => t('Not saved'), 1: () => t('Just chat'), 2: () => t('Can create'), 3: () => t('Can edit'), 4: () => t('Full access') };
|
|
42
|
+
|
|
40
43
|
function avatar(agent, { busy = false } = {}) {
|
|
41
44
|
const brand = brandOf(agent);
|
|
42
45
|
const face = el('span', `ap-av${busy ? ' busy' : ''}`);
|
|
@@ -59,7 +62,7 @@ function sysAvatar(icon, { busy = false } = {}) {
|
|
|
59
62
|
*/
|
|
60
63
|
export function mountActivity({ key, badge, openChat, toast = () => {} }) {
|
|
61
64
|
if (!key) return null;
|
|
62
|
-
const state = { data: null, said: '', open: false, timer: 0, ticking: 0, opened: new Set(), confirmAll: 0, failing: 0, pressing: false, stale: false };
|
|
65
|
+
const state = { data: null, said: '', open: false, timer: 0, ticking: 0, opened: new Set(), seen: new Set(), confirmAll: 0, failing: 0, pressing: false, stale: false };
|
|
63
66
|
const panel = el('div', 'activity-panel');
|
|
64
67
|
panel.setAttribute('role', 'dialog');
|
|
65
68
|
panel.setAttribute('aria-label', t('Running now'));
|
|
@@ -216,39 +219,69 @@ export function mountActivity({ key, badge, openChat, toast = () => {} }) {
|
|
|
216
219
|
progress: item.timeoutMs ? () => since(item.startedAt)() / item.timeoutMs : null,
|
|
217
220
|
more: (inside) => {
|
|
218
221
|
if (helpers.length) inside.append(subChips(helpers));
|
|
219
|
-
inside.append(el('p', 'ap-meta',
|
|
222
|
+
inside.append(el('p', 'ap-meta', `${t('Permission: {mode}', { mode: `#${item.mode ?? 1} ${MODE_WORDS[item.mode ?? 1]?.() ?? ''}`.trim() })}${item.timeoutMs ? ` · ${t('it has up to {limit} to answer', { limit: clock(item.timeoutMs) })}` : ''}`));
|
|
220
223
|
inside.append(actions([t('Go to the chat'), 'go', () => goTo(project, item.chat, item.messageId)], [t('Stop'), 'stop', () => stop(project, item)]));
|
|
221
224
|
},
|
|
222
225
|
});
|
|
223
226
|
}
|
|
224
227
|
if (item.kind === 'plan') {
|
|
228
|
+
// A plan reads as a road (2026-11-14, the author: «Plan actual is very confusing»): who made it
|
|
229
|
+
// and what it is for, one segment per step on a bar, and each step on a line of its own — the
|
|
230
|
+
// AI's face, what it was asked, with which permission, and whether it is done, at work or
|
|
231
|
+
// waiting its turn. Open by default the first time it shows.
|
|
232
|
+
if (!state.seen.has(uid)) { state.seen.add(uid); state.opened.add(uid); }
|
|
233
|
+
const listed = item.steps ?? [];
|
|
234
|
+
const closes = item.total > listed.length;
|
|
235
|
+
const stepNow = Math.max(1, item.step);
|
|
236
|
+
const working = steps[0] ? brandOf(steps[0].agent).label : null;
|
|
237
|
+
const others = new Set(listed.map((one) => one.agent).filter((one) => one !== item.orchestrator));
|
|
225
238
|
return row({
|
|
226
239
|
id: uid, face: avatar(item.orchestrator, { busy: true }), tint: brandOf(item.orchestrator).color,
|
|
227
|
-
title: t('Plan by {agent} · {n} steps', { agent: brandOf(item.orchestrator).label, n: item.total }),
|
|
228
|
-
sub: `${where} · ${t('Step {step} of {total}', { step:
|
|
240
|
+
title: others.size ? t('{agent} puts {n} AIs to work', { agent: brandOf(item.orchestrator).label, n: others.size }) : t('Plan by {agent} · {n} steps', { agent: brandOf(item.orchestrator).label, n: item.total }),
|
|
241
|
+
sub: `${where} · ${t('Step {step} of {total}', { step: stepNow, total: item.total })}${working ? ` · ${t('{agent} is answering', { agent: working })}` : ''}`,
|
|
229
242
|
time: () => clock(since(item.startedAt)()),
|
|
230
243
|
progress: () => Math.max(0, item.step - 1) / Math.max(1, item.total),
|
|
231
244
|
more: (inside) => {
|
|
232
|
-
|
|
233
|
-
(
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
245
|
+
inside.classList.add('ap-plan');
|
|
246
|
+
inside.append(el('p', 'ap-plan-lead', t('{agent} split the request into {n} steps. Each AI works when the one before it finishes, and its answer reaches the next.', { agent: brandOf(item.orchestrator).label, n: item.total })));
|
|
247
|
+
const road = [...listed.map((step) => ({ agent: step.agent, text: step.text, mode: step.mode })), ...(closes ? [{ agent: item.orchestrator, text: t('reads the answers and gives you the final answer'), closing: true }] : [])];
|
|
248
|
+
// One segment per step, in each AI's colour: full when done, breathing while at work.
|
|
249
|
+
const segs = el('div', 'ap-segs');
|
|
250
|
+
segs.setAttribute('aria-hidden', 'true');
|
|
251
|
+
road.forEach((step, index) => {
|
|
252
|
+
const seg = el('i', index + 1 < stepNow ? 'done' : index + 1 === stepNow ? 'now' : 'wait');
|
|
253
|
+
seg.style.setProperty('--seg', brandOf(step.agent).color);
|
|
254
|
+
segs.append(seg);
|
|
237
255
|
});
|
|
238
|
-
|
|
239
|
-
const
|
|
240
|
-
|
|
241
|
-
const
|
|
242
|
-
li
|
|
256
|
+
inside.append(segs);
|
|
257
|
+
const list = el('ol', 'ap-road');
|
|
258
|
+
road.forEach((step, index) => {
|
|
259
|
+
const at = index + 1 < stepNow ? 'done' : index + 1 === stepNow ? 'now' : 'wait';
|
|
260
|
+
const li = el('li', `ap-step ${at}${step.closing ? ' closing' : ''}`);
|
|
261
|
+
const mark = el('span', 'ap-step-mark');
|
|
262
|
+
mark.append(avatar(step.agent, { busy: at === 'now' }));
|
|
263
|
+
const badge = el('span', `ap-step-badge ${at}`);
|
|
264
|
+
if (at === 'done') badge.innerHTML = trazo('check'); // trusted: our own SVG
|
|
265
|
+
else badge.textContent = String(index + 1);
|
|
266
|
+
mark.append(badge);
|
|
267
|
+
const words = el('div', 'ap-step-words');
|
|
268
|
+
const head = el('div', 'ap-step-head');
|
|
269
|
+
head.append(el('b', null, brandOf(step.agent).label));
|
|
270
|
+
if (Number.isInteger(step.mode)) head.append(el('span', `ap-step-mode m${step.mode}`, MODE_WORDS[step.mode]?.() ?? `#${step.mode}`));
|
|
271
|
+
const said = el('span', `ap-step-state ${at}`);
|
|
272
|
+
const turn = at === 'now' ? steps.find((one) => one.agent === step.agent) : null;
|
|
273
|
+
const sayState = () => (at === 'done' ? t('Done') : at === 'now' ? (turn ? t('Working · {time}', { time: clock(since(turn.startedAt)()) }) : t('Starting…')) : t('Waits its turn'));
|
|
274
|
+
said.textContent = sayState();
|
|
275
|
+
if (at === 'now' && turn) state.tickers.push(() => { said.textContent = sayState(); });
|
|
276
|
+
head.append(said);
|
|
277
|
+
const text = el('p', 'ap-step-text', step.text);
|
|
278
|
+
text.title = step.text;
|
|
279
|
+
words.append(head, text);
|
|
280
|
+
if (turn?.subagents?.length) words.append(subChips(turn.subagents));
|
|
281
|
+
li.append(mark, words);
|
|
243
282
|
list.append(li);
|
|
244
|
-
}
|
|
283
|
+
});
|
|
245
284
|
inside.append(list);
|
|
246
|
-
for (const turn of steps) {
|
|
247
|
-
const said = el('p', 'ap-meta', t('{agent} is answering step {step} · {time}', { agent: brandOf(turn.agent).label, step: item.step, time: clock(since(turn.startedAt)()) }));
|
|
248
|
-
state.tickers.push(() => { said.textContent = t('{agent} is answering step {step} · {time}', { agent: brandOf(turn.agent).label, step: item.step, time: clock(since(turn.startedAt)()) }); });
|
|
249
|
-
inside.append(said);
|
|
250
|
-
if (turn.subagents?.length) inside.append(subChips(turn.subagents));
|
|
251
|
-
}
|
|
252
285
|
inside.append(actions([t('Go to the chat'), 'go', () => goTo(project, item.chat)], [t('Stop the plan'), 'stop', () => stop(project, item)]));
|
|
253
286
|
},
|
|
254
287
|
});
|
|
@@ -276,10 +309,19 @@ export function mountActivity({ key, badge, openChat, toast = () => {} }) {
|
|
|
276
309
|
const title = what.startsWith('agent:') ? t('Installing {name}', { name: brandOf(what.slice(6)).label })
|
|
277
310
|
: what === 'ollama' ? (item.model ? t('Downloading {name}', { name: item.model }) : t('Installing {name}', { name: 'Ollama' }))
|
|
278
311
|
: t('Installing the module {name}', { name: what });
|
|
312
|
+
// Opened, it says what the installer said last and how far it got; a model downloading can be
|
|
313
|
+
// stopped from here, as in the welcome. It opened onto nothing before (2026-11-06, the author).
|
|
314
|
+
const percent = (() => { const all = [...String(item.line ?? '').matchAll(/(\d{1,3}(?:\.\d+)?)\s?%/g)]; return all.length ? Math.min(100, Number(all.at(-1)[1])) : null; })();
|
|
279
315
|
return row({
|
|
280
316
|
id: uid, face: sysAvatar('download', { busy: true }), title,
|
|
281
317
|
sub: `${project.home ? t('Home') : whereOf(project)} · ${t('It ends on its own; you can keep working.')}`,
|
|
282
318
|
time: item.startedAt ? () => clock(since(item.startedAt)()) : '',
|
|
319
|
+
progress: percent === null ? null : () => percent / 100,
|
|
320
|
+
more: (inside) => {
|
|
321
|
+
inside.append(el('p', 'ap-meta', t('It ends on its own; you can keep working.')));
|
|
322
|
+
if (item.line) inside.append(el('pre', 'ap-out', item.line));
|
|
323
|
+
if (item.stoppable) inside.append(actions([t('Stop the download'), 'stop', () => stop(project, item)]));
|
|
324
|
+
},
|
|
283
325
|
});
|
|
284
326
|
}
|
|
285
327
|
|
|
@@ -416,7 +458,9 @@ export function mountActivity({ key, badge, openChat, toast = () => {} }) {
|
|
|
416
458
|
}
|
|
417
459
|
key.addEventListener('click', () => (state.open ? close() : openPanel()));
|
|
418
460
|
document.addEventListener?.('keydown', (event) => { if (event.key === 'Escape' && state.open) { close(); key.focus(); } });
|
|
419
|
-
|
|
461
|
+
// A press on a first-time card (its «Entendido») is not a press outside the panel: closing the card
|
|
462
|
+
// closed «Plan actual» with it (2026-11-17, the author).
|
|
463
|
+
document.addEventListener?.('pointerdown', (event) => { if (state.open && !panel.contains(event.target) && !key.contains(event.target) && !event.target?.closest?.('.hint-card')) close(); }, true);
|
|
420
464
|
globalThis.addEventListener?.('resize', () => { if (state.open) place(); });
|
|
421
465
|
|
|
422
466
|
void load();
|