@jossuealcala/madre 1.0.5 → 1.1.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/ADDITIONAL-TERMS.md +7 -2
- package/CHANGELOG.en.md +47 -1
- package/CHANGELOG.md +47 -1
- package/CONTRIBUTING.md +2 -2
- package/LICENSE +111 -661
- package/NOTICE +28 -23
- package/README.en.md +30 -101
- package/README.md +30 -103
- package/SECURITY.md +1 -0
- package/TRADEMARKS.en.md +13 -14
- package/TRADEMARKS.md +24 -26
- package/bin/madre.cjs +2 -2
- package/bin/madre.mjs +112 -40
- package/docs/REFERENCE.md +52 -5
- package/docs/SDK.md +21 -3
- package/docs/en/REFERENCE.md +52 -5
- package/docs/en/SDK.md +22 -3
- package/docs/sdk/hello-module.mjs +3 -0
- package/package.json +3 -2
- package/public/abduction.js +6 -6
- package/public/activity.js +425 -0
- package/public/app.js +2468 -435
- package/public/assets/abduction-cat-blink.webp +0 -0
- package/public/assets/abduction-cat-control-left.webp +0 -0
- package/public/assets/abduction-cat-control-right.webp +0 -0
- package/public/assets/abduction-cat.webp +0 -0
- package/public/assets/manual/shots/en-agents.webp +0 -0
- package/public/assets/manual/shots/en-chats.webp +0 -0
- package/public/assets/manual/shots/en-code.webp +0 -0
- package/public/assets/manual/shots/en-composer.webp +0 -0
- package/public/assets/manual/shots/en-connectors.webp +0 -0
- package/public/assets/manual/shots/en-continuity.webp +0 -0
- package/public/assets/manual/shots/en-coordinator.webp +0 -0
- package/public/assets/manual/shots/en-copilot.webp +0 -0
- package/public/assets/manual/shots/en-diagnostics.webp +0 -0
- package/public/assets/manual/shots/en-home.webp +0 -0
- package/public/assets/manual/shots/en-local.webp +0 -0
- package/public/assets/manual/shots/en-market.webp +0 -0
- package/public/assets/manual/shots/en-memory.webp +0 -0
- package/public/assets/manual/shots/en-modes.webp +0 -0
- package/public/assets/manual/shots/en-notes.webp +0 -0
- package/public/assets/manual/shots/en-settings.webp +0 -0
- package/public/assets/manual/shots/en-welcome.webp +0 -0
- package/public/assets/manual/shots/en-windows.webp +0 -0
- package/public/assets/manual/shots/es-agents.webp +0 -0
- package/public/assets/manual/shots/es-chats.webp +0 -0
- package/public/assets/manual/shots/es-code.webp +0 -0
- package/public/assets/manual/shots/es-composer.webp +0 -0
- package/public/assets/manual/shots/es-connectors.webp +0 -0
- package/public/assets/manual/shots/es-continuity.webp +0 -0
- package/public/assets/manual/shots/es-coordinator.webp +0 -0
- package/public/assets/manual/shots/es-copilot.webp +0 -0
- package/public/assets/manual/shots/es-diagnostics.webp +0 -0
- package/public/assets/manual/shots/es-home.webp +0 -0
- package/public/assets/manual/shots/es-local.webp +0 -0
- package/public/assets/manual/shots/es-market.webp +0 -0
- package/public/assets/manual/shots/es-memory.webp +0 -0
- package/public/assets/manual/shots/es-modes.webp +0 -0
- package/public/assets/manual/shots/es-notes.webp +0 -0
- package/public/assets/manual/shots/es-settings.webp +0 -0
- package/public/assets/manual/shots/es-welcome.webp +0 -0
- package/public/assets/manual/shots/es-windows.webp +0 -0
- package/public/assets/news/1.1/en/chats.webp +0 -0
- package/public/assets/news/1.1/en/home.webp +0 -0
- package/public/assets/news/1.1/en/maps.webp +0 -0
- package/public/assets/news/1.1/en/market.webp +0 -0
- package/public/assets/news/1.1/en/permissions.webp +0 -0
- package/public/assets/news/1.1/en/privacy.webp +0 -0
- package/public/assets/news/1.1/en/welcome.webp +0 -0
- package/public/assets/news/1.1/es/chats.webp +0 -0
- package/public/assets/news/1.1/es/home.webp +0 -0
- package/public/assets/news/1.1/es/maps.webp +0 -0
- package/public/assets/news/1.1/es/market.webp +0 -0
- package/public/assets/news/1.1/es/permissions.webp +0 -0
- package/public/assets/news/1.1/es/privacy.webp +0 -0
- package/public/assets/news/1.1/es/welcome.webp +0 -0
- package/public/attribution.js +15 -16
- package/public/brands.js +2 -2
- package/public/code-tools.js +2 -2
- package/public/editor.js +13 -13
- package/public/en.js +413 -4
- package/public/es.js +1345 -483
- package/public/hardware.js +2 -2
- package/public/i18n.js +2 -2
- package/public/icons.js +158 -0
- package/public/index.html +66 -48
- package/public/inquiry.js +2 -2
- package/public/loader.js +271 -2
- package/public/macroverso.js +60 -21
- package/public/manual-content.js +412 -169
- package/public/manual-shots.js +38 -34
- package/public/manual.css +20 -2
- package/public/manual.html +1 -1
- package/public/manual.js +54 -25
- package/public/market-art.js +47 -45
- package/public/market-view.js +111 -33
- package/public/market.js +132 -30
- package/public/mcp-catalog.js +2 -2
- package/public/neural.js +64 -8
- package/public/nostromo-engine.js +709 -40
- package/public/page-errors.js +29 -0
- package/public/power.js +350 -11
- package/public/remedy.js +89 -0
- package/public/resay.js +3 -2
- package/public/review-ask.js +12 -7
- package/public/routing.js +3 -3
- package/public/salas-mac.css +703 -24
- package/public/salas-mac.html +26 -14
- package/public/salas-mac.js +1254 -289
- package/public/salas.css +2 -2
- package/public/salas.html +3 -3
- package/public/salas.js +3 -3
- package/public/styles.css +2404 -291
- package/public/syntax.js +2 -2
- package/public/terms.js +152 -0
- package/public/touch.js +2 -2
- package/public/tour-chapters.js +10 -10
- package/public/tour.js +56 -8
- package/public/troubleshooting.js +182 -11
- package/public/wallpaper.js +4 -3
- package/public/welcome.js +923 -0
- package/src/activity.mjs +85 -0
- package/src/adapters/claude.mjs +61 -35
- package/src/adapters/codex.mjs +18 -5
- package/src/adapters/cursor.mjs +5 -3
- package/src/adapters/gemini.mjs +5 -3
- package/src/adapters/madre.mjs +3 -3
- package/src/adapters/opencode.mjs +73 -10
- package/src/adapters/process.mjs +14 -13
- package/src/adapters/subagents.mjs +159 -0
- package/src/asking.mjs +8 -2
- package/src/auth-probe.mjs +27 -10
- package/src/bridge/devices.mjs +2 -2
- package/src/bridge/handoff.mjs +2 -2
- package/src/bridge/host.mjs +2 -2
- package/src/bridge/network.mjs +2 -2
- package/src/bridge/policy.mjs +3 -3
- package/src/bridge/qr.mjs +2 -2
- package/src/bridge/server.mjs +2 -2
- package/src/builtin-updates.mjs +87 -0
- package/src/capabilities.mjs +2 -2
- package/src/chats.mjs +51 -2
- package/src/checkpoint.mjs +67 -9
- package/src/choices.mjs +2 -2
- package/src/cli-args.mjs +2 -2
- package/src/cold.mjs +2 -2
- package/src/commands.mjs +2 -2
- package/src/config.mjs +2 -2
- package/src/conversation-context.mjs +2 -2
- package/src/credentials.mjs +56 -16
- package/src/dataset.mjs +2 -2
- package/src/directives.mjs +2 -2
- package/src/distiller.mjs +2 -2
- package/src/embeddings.mjs +2 -2
- package/src/enlaces.mjs +2 -2
- package/src/environment.mjs +147 -0
- package/src/event-store.mjs +2 -2
- package/src/exam.mjs +2 -2
- package/src/extensions.mjs +2 -2
- package/src/eyecat-watch.mjs +2 -2
- package/src/eyecat.mjs +2 -2
- package/src/file-ops.mjs +2 -2
- package/src/files.mjs +2 -2
- package/src/github.mjs +2 -2
- package/src/heartbeat.mjs +2 -2
- package/src/history.mjs +2 -2
- package/src/i18n.mjs +9 -2
- package/src/image-studio.mjs +2 -2
- package/src/install-metrics.mjs +109 -0
- package/src/json-file.mjs +2 -2
- package/src/launch.mjs +2 -2
- package/src/lease.mjs +15 -4
- package/src/lobby-work.mjs +11 -4
- package/src/local-ai.mjs +2 -2
- package/src/looks.mjs +2 -2
- package/src/market-check.mjs +165 -0
- package/src/market-key.mjs +10 -2
- package/src/market-license.mjs +4 -4
- package/src/market-remote.mjs +54 -12
- package/src/maturity.mjs +2 -2
- package/src/mcp/connect.mjs +2 -2
- package/src/mcp/github-server.mjs +2 -2
- package/src/mcp/image-server.mjs +2 -2
- package/src/mcp/memory-server.mjs +2 -2
- package/src/mcp/proxy.mjs +2 -2
- package/src/mcp/smtp-server.mjs +2 -2
- package/src/memory-dashboard.mjs +2 -2
- package/src/memory-tools.mjs +2 -2
- package/src/memory.mjs +2 -2
- package/src/models.mjs +33 -3
- package/src/module-scope.mjs +2 -2
- package/src/modules/ahp.mjs +2 -2
- package/src/modules/ash-policy.mjs +2 -2
- package/src/modules/ash.mjs +2 -2
- package/src/modules/bishop-exam.mjs +2 -2
- package/src/modules/bishop-plan.mjs +2 -2
- package/src/modules/bishop.mjs +9 -3
- package/src/modules/choices.mjs +2 -2
- package/src/modules/correo.mjs +2 -2
- package/src/modules/enlaces.mjs +2 -2
- package/src/modules/git-pulse.mjs +2 -2
- package/src/modules/github.mjs +2 -2
- package/src/modules/helpers.mjs +2 -2
- package/src/modules/image-studio.mjs +2 -2
- package/src/modules/index.mjs +90 -5
- package/src/modules/intents-calibration.mjs +2 -2
- package/src/modules/intents-desk.mjs +4 -3
- package/src/modules/intents-observe.mjs +2 -2
- package/src/modules/intents-policy.mjs +2 -2
- package/src/modules/intents-try.mjs +2 -2
- package/src/modules/intents.mjs +2 -2
- package/src/modules/local-models.mjs +14 -11
- package/src/modules/mcp-connect.mjs +2 -2
- package/src/modules/notes.mjs +159 -20
- package/src/modules/ollama.mjs +9 -3
- package/src/modules/playwright.mjs +2 -2
- package/src/modules/reminders.mjs +356 -37
- package/src/modules/ripley.mjs +3 -3
- package/src/modules/runs.mjs +2 -2
- package/src/modules/sdk.mjs +38 -6
- package/src/modules/updates.mjs +2 -2
- package/src/mother.mjs +2 -2
- package/src/npm-launch.mjs +2 -2
- package/src/ollama.mjs +6 -4
- package/src/opencode-health.mjs +26 -6
- package/src/outbound.mjs +10 -2
- package/src/override.mjs +27 -22
- package/src/ports.mjs +2 -2
- package/src/prices.mjs +2 -2
- package/src/privacy.mjs +2 -2
- package/src/quota-monitor.mjs +2 -2
- package/src/quota-sources.mjs +2 -2
- package/src/request-guard.mjs +2 -2
- package/src/review-ask.mjs +4 -3
- package/src/room/archivist.mjs +2 -2
- package/src/room/attachments.mjs +2 -2
- package/src/room/budget.mjs +2 -2
- package/src/room/context.mjs +2 -2
- package/src/room/control.mjs +2 -2
- package/src/room/copilot.mjs +2 -2
- package/src/room/economy.mjs +2 -2
- package/src/room/escalation.mjs +2 -2
- package/src/room/ghost.mjs +2 -2
- package/src/room/guard.mjs +6 -4
- package/src/room/prompt.mjs +3 -3
- package/src/room/returns.mjs +2 -2
- package/src/room/runs.mjs +6 -4
- package/src/room/vectors.mjs +2 -2
- package/src/room.mjs +127 -31
- package/src/router.mjs +2 -2
- package/src/runs.mjs +2 -2
- package/src/runtime-detection.mjs +31 -5
- package/src/salas.mjs +31 -6
- package/src/sentinel-errors.mjs +13 -4
- package/src/server-sentinel.mjs +2 -2
- package/src/server.mjs +689 -80
- package/src/setup-trouble.mjs +33 -0
- package/src/setup.mjs +4 -4
- package/src/smtp.mjs +2 -2
- package/src/telemetry.mjs +266 -0
- package/src/terms.mjs +43 -0
- package/src/tour.mjs +39 -5
- package/src/uninstall.mjs +225 -0
- package/src/updates.mjs +2 -2
- package/src/usage-sentinel.mjs +2 -2
- package/src/vault.mjs +2 -2
- package/src/verdict.mjs +13 -10
- package/src/whats-new.mjs +97 -3
- package/public/assets/abduction-cat-blink.png +0 -0
- package/public/assets/abduction-cat-control-left.png +0 -0
- package/public/assets/abduction-cat-control-right.png +0 -0
- package/public/assets/abduction-cat.png +0 -0
- package/public/assets/manual/madre-manual-en.pdf +0 -0
- package/public/assets/manual/madre-manual-es.pdf +0 -0
- package/public/assets/manual/shots/en-modules.webp +0 -0
- package/public/assets/manual/shots/es-modules.webp +0 -0
- package/src/mcp/notes-server.mjs +0 -120
- package/src/reminder-time.mjs +0 -127
package/public/syntax.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// SPDX-License-Identifier:
|
|
2
|
-
// MADRE · © 2026 Jossue Alcalá ·
|
|
1
|
+
// SPDX-License-Identifier: BUSL-1.1
|
|
2
|
+
// MADRE · © 2026 Jossue Alcalá · Business Source License 1.1: LICENSE
|
|
3
3
|
// The names below are the names of formats — JavaScript, JSON, CSS, Markdown — and a format is
|
|
4
4
|
// called the same in every language, so they never pass through the catalogue.
|
|
5
5
|
//
|
package/public/terms.js
ADDED
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
// SPDX-License-Identifier: BUSL-1.1
|
|
2
|
+
// MADRE · © 2026 Jossue Alcalá · Business Source License 1.1: LICENSE
|
|
3
|
+
// BEFORE YOU START (2026-10-30, src/terms.mjs): MADRE's license and privacy notice, accepted once per
|
|
4
|
+
// version of their text on this computer, before Home or a project can be used. A new person reads it
|
|
5
|
+
// as the first thing MADRE says; whoever came from a MADRE before 1.1.0 reads what changed. The
|
|
6
|
+
// anonymous diagnostics come on and are said in plain words, why they help and what never goes; they
|
|
7
|
+
// are no condition: the switch is right there, and in Settings later. Without accepting, MADRE does
|
|
8
|
+
// not start: the page says so and offers to read it again or to close MADRE.
|
|
9
|
+
//
|
|
10
|
+
// app.js and salas-mac.js wait on it before anything else is drawn (`await ensureTerms()`).
|
|
11
|
+
|
|
12
|
+
import { browserLanguage, language, setLanguage, t } from './i18n.js';
|
|
13
|
+
import { MADRE_LOGO, playOpening } from './loader.js';
|
|
14
|
+
|
|
15
|
+
const el = (tag, className = null, text = null) => {
|
|
16
|
+
const node = document.createElement(tag);
|
|
17
|
+
if (className) node.className = className;
|
|
18
|
+
if (text !== null && text !== undefined) node.textContent = text;
|
|
19
|
+
return node;
|
|
20
|
+
};
|
|
21
|
+
const link = (href, words) => {
|
|
22
|
+
const node = el('a', 'terms-link', words);
|
|
23
|
+
node.href = href;
|
|
24
|
+
node.target = '_blank';
|
|
25
|
+
node.rel = 'noopener';
|
|
26
|
+
return node;
|
|
27
|
+
};
|
|
28
|
+
const pick = (pair) => pair?.[language()] ?? pair?.es ?? '#';
|
|
29
|
+
|
|
30
|
+
export async function ensureTerms() {
|
|
31
|
+
if (typeof document === 'undefined' || typeof fetch !== 'function') return;
|
|
32
|
+
let answer = null;
|
|
33
|
+
try { answer = await fetch('/api/terms', { cache: 'no-store' }).then((response) => (response.ok ? response.json() : null)); } catch { return; }
|
|
34
|
+
// Only an explicit «not accepted» stops the page: an older room, or no answer, never locks anyone out.
|
|
35
|
+
if (answer?.accepted !== false) return;
|
|
36
|
+
setLanguage(answer.languageChosen ? answer.language : browserLanguage());
|
|
37
|
+
await new Promise((done) => askTerms(answer, done));
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
function askTerms(answer, done) {
|
|
41
|
+
const dialog = el('dialog', 'terms-gate');
|
|
42
|
+
dialog.setAttribute('aria-labelledby', 'terms-title');
|
|
43
|
+
const card = el('div', 'terms-card');
|
|
44
|
+
// The dialog's first focus goes to the card, never to a link or a key with the browser's ring on it.
|
|
45
|
+
card.tabIndex = -1;
|
|
46
|
+
card.setAttribute('autofocus', '');
|
|
47
|
+
dialog.append(card);
|
|
48
|
+
// Esc is no answer here: without accepting, MADRE does not start.
|
|
49
|
+
dialog.addEventListener('cancel', (event) => event.preventDefault());
|
|
50
|
+
let diagnostics = answer.diagnosticsFixed ? false : answer.diagnostics !== false;
|
|
51
|
+
const returning = answer.before === true;
|
|
52
|
+
|
|
53
|
+
const paintAsk = () => {
|
|
54
|
+
card.replaceChildren();
|
|
55
|
+
const logo = el('div', 'terms-logo');
|
|
56
|
+
logo.innerHTML = MADRE_LOGO; // trusted: our own SVG string
|
|
57
|
+
const title = el('h1', 'terms-title', returning ? t('MADRE 1.1 has a new license') : t('Before you start'));
|
|
58
|
+
title.id = 'terms-title';
|
|
59
|
+
const lead = el('p', 'terms-lead', returning
|
|
60
|
+
? t('It is still free for you and for teams of up to 10 people. To keep using it, accept the license and the privacy notice.')
|
|
61
|
+
: t('MADRE is free for you and for teams of up to 10 people, also when you use it to work for your clients.'));
|
|
62
|
+
|
|
63
|
+
const license = el('section', 'terms-block');
|
|
64
|
+
license.append(
|
|
65
|
+
el('h2', null, t('Personal license')),
|
|
66
|
+
el('p', null, t('You can use MADRE, change it and share it; an organization of more than 10 people, or whoever offers MADRE as a service, needs a commercial license.')),
|
|
67
|
+
link(pick(answer.links?.license), t('Read the license')),
|
|
68
|
+
);
|
|
69
|
+
|
|
70
|
+
const help = el('section', 'terms-block terms-help');
|
|
71
|
+
const head = el('div', 'terms-help-head');
|
|
72
|
+
const words = el('div');
|
|
73
|
+
words.append(el('h2', null, t('Help make MADRE better')), el('p', null, returning
|
|
74
|
+
? t('MADRE is made by one person. From this version your copy can share its errors with me anonymously, so the next versions fix first what fails for you. It is optional and you can turn it off whenever you like in Settings.')
|
|
75
|
+
: t('MADRE is made by one person. Your copy can share its errors with me anonymously, so each version fixes first what fails for you. It is optional and you can turn it off whenever you like in Settings.')));
|
|
76
|
+
const knob = el('button', 'terms-switch');
|
|
77
|
+
knob.type = 'button';
|
|
78
|
+
knob.setAttribute('role', 'switch');
|
|
79
|
+
knob.setAttribute('aria-label', t('Help make MADRE better'));
|
|
80
|
+
knob.append(el('span', 'terms-knob'));
|
|
81
|
+
const said = el('p', 'terms-said');
|
|
82
|
+
const paintKnob = () => {
|
|
83
|
+
knob.setAttribute('aria-checked', String(diagnostics));
|
|
84
|
+
knob.disabled = Boolean(answer.diagnosticsFixed);
|
|
85
|
+
said.replaceChildren();
|
|
86
|
+
if (answer.diagnosticsFixed) said.append(t('Off: MADRE was started with PULSE_TELEMETRY=0.'));
|
|
87
|
+
else if (diagnostics) said.append(link(pick(answer.links?.privacy), t('See what is sent')));
|
|
88
|
+
else said.append(t('Off: the author will not know when something fails for you, and it may take longer to fix.'));
|
|
89
|
+
};
|
|
90
|
+
knob.addEventListener('click', () => { diagnostics = !diagnostics; paintKnob(); });
|
|
91
|
+
paintKnob();
|
|
92
|
+
head.append(words, knob);
|
|
93
|
+
help.append(head, said);
|
|
94
|
+
|
|
95
|
+
const foot = el('p', 'terms-foot');
|
|
96
|
+
foot.append(t('By continuing you accept MADRE\'s'), ' ', link(pick(answer.links?.license), t('license')), ' ', t('and its'), ' ', link(pick(answer.links?.privacy), t('privacy notice')), '.');
|
|
97
|
+
const error = el('p', 'terms-error');
|
|
98
|
+
const actions = el('div', 'terms-actions');
|
|
99
|
+
const no = el('button', 'terms-btn quiet', t('I do not accept'));
|
|
100
|
+
no.type = 'button';
|
|
101
|
+
no.addEventListener('click', paintDeclined);
|
|
102
|
+
const yes = el('button', 'terms-btn primary', returning ? t('Accept and continue') : t('Accept and start'));
|
|
103
|
+
yes.type = 'button';
|
|
104
|
+
yes.addEventListener('click', async () => {
|
|
105
|
+
yes.disabled = true;
|
|
106
|
+
no.disabled = true;
|
|
107
|
+
error.textContent = '';
|
|
108
|
+
const saved = await fetch('/api/terms', { method: 'POST', headers: { 'content-type': 'application/json' }, body: JSON.stringify({ accept: true, diagnostics }) }).then((response) => response.ok).catch(() => false);
|
|
109
|
+
if (!saved) { yes.disabled = false; no.disabled = false; error.textContent = t('It could not be saved. Try again.'); return; }
|
|
110
|
+
// Whoever updated meets MADRE's opening here, before Home is drawn behind it (2026-10-30): drawn
|
|
111
|
+
// first and the opening over it, it looked like a jump. Someone new meets it in the welcome.
|
|
112
|
+
if (returning) { card.style.visibility = 'hidden'; await playOpening(dialog, { skipLabel: t('Skip') }); }
|
|
113
|
+
dialog.classList.add('leaving');
|
|
114
|
+
setTimeout(() => { dialog.close(); dialog.remove(); done(); }, 260);
|
|
115
|
+
});
|
|
116
|
+
actions.append(no, yes);
|
|
117
|
+
card.append(logo, title, lead, license, help, foot, error, actions);
|
|
118
|
+
setTimeout(() => card.focus({ preventScroll: true }), 0);
|
|
119
|
+
};
|
|
120
|
+
|
|
121
|
+
const paintDeclined = () => {
|
|
122
|
+
card.replaceChildren();
|
|
123
|
+
const logo = el('div', 'terms-logo');
|
|
124
|
+
logo.innerHTML = MADRE_LOGO; // trusted: our own SVG string
|
|
125
|
+
const title = el('h1', 'terms-title', t('MADRE cannot start without it'));
|
|
126
|
+
title.id = 'terms-title';
|
|
127
|
+
const lead = el('p', 'terms-lead', t('The license is what lets you use MADRE for free. If you change your mind, accept it here; or close MADRE.'));
|
|
128
|
+
const said = el('p', 'terms-error');
|
|
129
|
+
const actions = el('div', 'terms-actions');
|
|
130
|
+
const back = el('button', 'terms-btn primary', t('Read it again'));
|
|
131
|
+
back.type = 'button';
|
|
132
|
+
back.addEventListener('click', paintAsk);
|
|
133
|
+
const shut = el('button', 'terms-btn quiet', t('Close MADRE'));
|
|
134
|
+
shut.type = 'button';
|
|
135
|
+
shut.addEventListener('click', async () => {
|
|
136
|
+
shut.disabled = true;
|
|
137
|
+
back.disabled = true;
|
|
138
|
+
const closed = await fetch('/api/madre/shutdown', { method: 'POST', headers: { 'content-type': 'application/json' }, body: '{}' }).then((response) => response.ok).catch(() => false);
|
|
139
|
+
if (closed) { actions.remove(); lead.textContent = t('MADRE is closed. You can close this tab.'); return; }
|
|
140
|
+
shut.disabled = false;
|
|
141
|
+
back.disabled = false;
|
|
142
|
+
said.textContent = t('MADRE could not be closed from here. Close the terminal where it runs.');
|
|
143
|
+
});
|
|
144
|
+
actions.append(shut, back);
|
|
145
|
+
card.append(logo, title, lead, said, actions);
|
|
146
|
+
setTimeout(() => card.focus({ preventScroll: true }), 0);
|
|
147
|
+
};
|
|
148
|
+
|
|
149
|
+
paintAsk();
|
|
150
|
+
document.body.append(dialog);
|
|
151
|
+
if (typeof dialog.showModal === 'function') dialog.showModal(); else dialog.setAttribute('open', '');
|
|
152
|
+
}
|
package/public/touch.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// SPDX-License-Identifier:
|
|
2
|
-
// MADRE · © 2026 Jossue Alcalá ·
|
|
1
|
+
// SPDX-License-Identifier: BUSL-1.1
|
|
2
|
+
// MADRE · © 2026 Jossue Alcalá · Business Source License 1.1: LICENSE
|
|
3
3
|
// A tap is not a hover (2026-10-11). On a screen with no pointer (a phone, a tablet without a
|
|
4
4
|
// trackpad), the browser gives :hover to whatever was tapped and keeps it until the next tap lands
|
|
5
5
|
// somewhere else: a button looked pressed after it was let go. So, where nothing can hover, the
|
package/public/tour-chapters.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// SPDX-License-Identifier:
|
|
2
|
-
// MADRE · © 2026 Jossue Alcalá ·
|
|
1
|
+
// SPDX-License-Identifier: BUSL-1.1
|
|
2
|
+
// MADRE · © 2026 Jossue Alcalá · Business Source License 1.1: LICENSE
|
|
3
3
|
// What the welcome of MADRE 1.0 says (2026-10-11): twelve chapters and the sheet of gestures, in
|
|
4
4
|
// both languages side by side, as the cards of What's new are (src/whats-new.mjs). Each chapter
|
|
5
5
|
// fits on one view: a short scene, a line, three sentences, its gestures and «Take me there».
|
|
@@ -252,12 +252,12 @@ export const CHAPTERS = [
|
|
|
252
252
|
es: [
|
|
253
253
|
'Tú firmas cada conexión: qué puede consultar, por cuánto tiempo y si el Coordinador puede dar instrucciones.',
|
|
254
254
|
'Solo se comparten notas que ya se usan, sin datos privados. Tus archivos y tus chats nunca salen del proyecto.',
|
|
255
|
-
'
|
|
255
|
+
'En Conexiones, en Inicio, cada una se ve como en el mapa: quién consulta a quién, qué comparte y hasta cuándo. Cada opción dice qué hace, y «Cancelar conexión» la termina cuando quieras.',
|
|
256
256
|
],
|
|
257
257
|
en: [
|
|
258
258
|
'You sign every connection: what it may look up, for how long and whether the Coordinator may give instructions.',
|
|
259
259
|
'Only notes already in use are shared, without private data. Your files and your chats never leave the project.',
|
|
260
|
-
'
|
|
260
|
+
'In Connections, in Home, each one reads as on the map: who looks up whom, what it shares and until when. Each option says what it does, and «Cancel the connection» ends it whenever you want.',
|
|
261
261
|
],
|
|
262
262
|
},
|
|
263
263
|
since: { kind: 'changed', es: 'El mapa de Conexiones en Inicio ahora es un cielo: cada proyecto es una estrella y cada conexión, un flujo de luz. Ábrelo en una ventana para explorarlo.', en: 'The Connections map in Home is now a sky: every project is a star and every connection a flow of light. Open it in a window to explore it.' },
|
|
@@ -299,12 +299,12 @@ export const CHAPTERS = [
|
|
|
299
299
|
es: [
|
|
300
300
|
'Ábrelos con ⌘ , y escribe / para buscar cualquier ajuste. Lo que cambias se aplica en ese momento.',
|
|
301
301
|
'En Apariencia eliges los colores, el fondo, el tema claro u oscuro y el idioma.',
|
|
302
|
-
'Si algo no funciona, abre Diagnóstico y cuéntale qué pasa con tus palabras: te dice qué hacer y te da el botón para arreglarlo.',
|
|
302
|
+
'Si algo no funciona, abre Diagnóstico y cuéntale qué pasa con tus palabras: te dice qué hacer y te da el botón para arreglarlo. Cuando algo falla al instalar, «Ver cómo arreglarlo» te da los pasos para tu sistema.',
|
|
303
303
|
],
|
|
304
304
|
en: [
|
|
305
305
|
'Open them with ⌘ , and type / to find any setting. What you change applies right away.',
|
|
306
306
|
'In Appearance you choose the colours, the background, light or dark and the language.',
|
|
307
|
-
'If something does not work, open Diagnostics and tell it what happens in your own words: it says what to do and gives you the key that fixes it.',
|
|
307
|
+
'If something does not work, open Diagnostics and tell it what happens in your own words: it says what to do and gives you the key that fixes it. When an install fails, «See how to fix it» gives you the steps for your system.',
|
|
308
308
|
],
|
|
309
309
|
},
|
|
310
310
|
keys: [
|
|
@@ -342,13 +342,13 @@ export const CHAPTERS = [
|
|
|
342
342
|
since: { kind: 'new', es: 'En 1.0 la IA local era todo o nada; ahora se elige proyecto por proyecto.', en: 'In 1.0 the local AI was all or nothing; now it is chosen project by project.' },
|
|
343
343
|
points: {
|
|
344
344
|
es: [
|
|
345
|
-
'Se configura en Inicio › Ajustes › IA local. Ahí eliges si la usan todos tus proyectos, solo los que tú enciendas, o si cada proyecto lo decide en
|
|
346
|
-
'MADRE te recomienda los modelos que caben en tu equipo y te dice cuánto pesan antes de descargarlos.',
|
|
345
|
+
'Se configura en Inicio › Ajustes › IA local. Ahí eliges si la usan todos tus proyectos, solo los que tú enciendas, o si cada proyecto lo decide; y en «Dirección de Ollama», la de otra computadora de tu red.',
|
|
346
|
+
'MADRE te recomienda los modelos que caben en tu equipo y te dice cuánto pesan antes de descargarlos. Una descarga se puede cancelar: lo que ya bajó se queda y sigue desde ahí.',
|
|
347
347
|
'Un proyecto sin IA local sigue trabajando con tus agentes. Solo deja de buscar por significado, de resumir su memoria y de usar a @madre.',
|
|
348
348
|
],
|
|
349
349
|
en: [
|
|
350
|
-
'It is set in Home › Settings › Local AI. There you choose whether all your projects use it, only the ones you switch on, or each project decides in
|
|
351
|
-
'MADRE recommends the models that fit your computer and tells you how big they are before you download them.',
|
|
350
|
+
'It is set in Home › Settings › Local AI. There you choose whether all your projects use it, only the ones you switch on, or each project decides; and in «Ollama address», another computer\'s on your network.',
|
|
351
|
+
'MADRE recommends the models that fit your computer and tells you how big they are before you download them. A download can be cancelled: what arrived stays, and it picks up from there.',
|
|
352
352
|
'A project without the local AI keeps working with your agents. It only stops searching by meaning, summing up its memory and using @madre.',
|
|
353
353
|
],
|
|
354
354
|
},
|
package/public/tour.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// SPDX-License-Identifier:
|
|
2
|
-
// MADRE · © 2026 Jossue Alcalá ·
|
|
1
|
+
// SPDX-License-Identifier: BUSL-1.1
|
|
2
|
+
// MADRE · © 2026 Jossue Alcalá · Business Source License 1.1: LICENSE
|
|
3
3
|
// The welcome of MADRE 1.0 (2026-10-11), in Home and in every project: option B of «Recorrido de
|
|
4
4
|
// MADRE 1.0» — a bonjour, then a window of chapters read at the person's own pace — with two
|
|
5
5
|
// pieces of option C: a one-line hint the first time someone reaches a place that confuses, and
|
|
@@ -17,9 +17,10 @@
|
|
|
17
17
|
// assistant that connects agents and adds projects; then the chapters tell the essentials, in the
|
|
18
18
|
// order they are used (public/tour-chapters.js, ORDER).
|
|
19
19
|
|
|
20
|
-
import { LOADER_MARK, finishLoader, makeLoader, setLoader } from './loader.js';
|
|
20
|
+
import { LOADER_MARK, MADRE_LOGO, finishLoader, makeLoader, setLoader } from './loader.js';
|
|
21
21
|
import { hostWords, keyWords, language, t } from './i18n.js';
|
|
22
22
|
import { CHAPTERS, GESTURES, ORDER } from './tour-chapters.js';
|
|
23
|
+
import { trazo } from './icons.js';
|
|
23
24
|
|
|
24
25
|
const say = (pair) => (typeof pair === 'string' ? pair : pair?.[language()] ?? pair?.es ?? '');
|
|
25
26
|
// The chapters' own words, said of the computer and the keyboard in front of the person: «tu Mac» is
|
|
@@ -28,10 +29,10 @@ const plain = (text) => hostWords(keyWords(text));
|
|
|
28
29
|
const fill = (template, vars) => template.replace(/\{(\w+)\}/g, (whole, name) => (Object.hasOwn(vars, name) ? String(vars[name]) : whole));
|
|
29
30
|
const still = () => typeof matchMedia === 'function' && matchMedia('(prefers-reduced-motion: reduce)').matches;
|
|
30
31
|
// Up, turned for down: the way to a hint whose place is out of view.
|
|
31
|
-
const ARROW_UP = '
|
|
32
|
-
const CLOSE_ICON = '
|
|
32
|
+
const ARROW_UP = trazo('arrow-up');
|
|
33
|
+
const CLOSE_ICON = trazo('close');
|
|
33
34
|
const FOLDER = '<svg viewBox="0 0 32 26" aria-hidden="true"><path d="M2 5.5A2.5 2.5 0 0 1 4.5 3h7.2l3 3.2h12.8A2.5 2.5 0 0 1 30 8.7v12.8a2.5 2.5 0 0 1-2.5 2.5h-23A2.5 2.5 0 0 1 2 21.5z" fill="currentColor"/></svg>';
|
|
34
|
-
const ROBOT = '
|
|
35
|
+
const ROBOT = trazo('robot');
|
|
35
36
|
|
|
36
37
|
function el(tag, className = null, text = null) {
|
|
37
38
|
const node = document.createElement(tag);
|
|
@@ -247,6 +248,20 @@ export function startTour({ page, go = {}, ready = () => true, phone = false, de
|
|
|
247
248
|
if (fresh?.state) state = fresh.state;
|
|
248
249
|
if (!fresh?.owed) return false;
|
|
249
250
|
if (heldElsewhere(fresh.state)) { elsewhere(); return false; }
|
|
251
|
+
// Someone new in Home meets the welcome itself (2026-10-28, public/welcome.js), with no bonjour
|
|
252
|
+
// before it to put off: it is what leaves MADRE ready, and its last step leads to the chapters.
|
|
253
|
+
// Whoever updated from a MADRE before 1.1.0 is not new (2026-10-30): the board of news, with
|
|
254
|
+
// MADRE's opening, is their way in (salas-mac.js, homeNews); no welcome, no bonjour on top of it.
|
|
255
|
+
if (info?.upgraded) {
|
|
256
|
+
await keep({ path: path() === 'new' ? 'back' : path(), bonjour: true });
|
|
257
|
+
return false;
|
|
258
|
+
}
|
|
259
|
+
if (page === 'home' && path() === 'new' && welcome?.instead) {
|
|
260
|
+
await keep({ path: 'new', bonjour: true });
|
|
261
|
+
void fetch('/api/whats-new/seen', { method: 'POST' }).catch(() => null);
|
|
262
|
+
welcome.open(() => openChapters('home'));
|
|
263
|
+
return true;
|
|
264
|
+
}
|
|
250
265
|
showBonjour();
|
|
251
266
|
return true;
|
|
252
267
|
}
|
|
@@ -352,7 +367,11 @@ export function startTour({ page, go = {}, ready = () => true, phone = false, de
|
|
|
352
367
|
const words = el('div', 'tour-head-words');
|
|
353
368
|
const title = el('h2');
|
|
354
369
|
title.id = 'tour-window-title';
|
|
355
|
-
|
|
370
|
+
// MADRE's own logo over the chapters (2026-10-28), as the welcome wears it.
|
|
371
|
+
const logo = el('span', 'tour-logo');
|
|
372
|
+
logo.setAttribute('aria-hidden', 'true');
|
|
373
|
+
logo.innerHTML = MADRE_LOGO; // trusted: our own SVG string
|
|
374
|
+
words.append(logo, el('span', 'wn-eyebrow'), title);
|
|
356
375
|
const close = key('tour-close', null, () => windowNode.close());
|
|
357
376
|
close.innerHTML = CLOSE_ICON; // trusted: our own SVG string
|
|
358
377
|
close.setAttribute('aria-label', t('Close'));
|
|
@@ -545,13 +564,19 @@ export function startTour({ page, go = {}, ready = () => true, phone = false, de
|
|
|
545
564
|
const card = el('section', `tour-hint${inside ? ' inline' : ''}`);
|
|
546
565
|
card.setAttribute('role', 'note');
|
|
547
566
|
const walking = step > 0 && of > 1;
|
|
548
|
-
|
|
567
|
+
const eyebrow = el('span', 'tour-hint-eyebrow', walking ? t('{n} of {total}', { n: step, total: of }) : t('The first time'));
|
|
568
|
+
// Inside a window its words go together, so its key can sit beside them or, where the window is
|
|
569
|
+
// narrow, under them — never squeezing the words into a column (2026-10-28, #4's key).
|
|
570
|
+
if (inside) { const words = el('div', 'tour-hint-words'); words.append(eyebrow, el('b', null, title), el('p', null, text)); card.append(words); }
|
|
571
|
+
else card.append(eyebrow, el('b', null, title), el('p', null, text));
|
|
549
572
|
let spot = null;
|
|
550
573
|
let away = null;
|
|
551
574
|
let follow = null;
|
|
552
575
|
let skipped = false;
|
|
576
|
+
let coverTimer = 0;
|
|
553
577
|
const done = () => {
|
|
554
578
|
if (!hintNode) return;
|
|
579
|
+
clearInterval(coverTimer);
|
|
555
580
|
spot?.remove();
|
|
556
581
|
card.remove();
|
|
557
582
|
away?.remove();
|
|
@@ -596,6 +621,25 @@ export function startTour({ page, go = {}, ready = () => true, phone = false, de
|
|
|
596
621
|
away.append(el('b', null, title), el('span', null, up ? t('Scroll up to see it') : t('Scroll down to see it')));
|
|
597
622
|
away.setAttribute('aria-label', `${title} · ${up ? t('Scroll up to see it') : t('Scroll down to see it')}`);
|
|
598
623
|
};
|
|
624
|
+
// Under a window (2026-10-28): a window opened over the page covers what the hint speaks of — the
|
|
625
|
+
// Market over Home's cards — and the hint, in the top layer, was drawn over that window pointing
|
|
626
|
+
// at nothing anyone could see. While its place is covered, the hint and its ring wait out of
|
|
627
|
+
// sight, and come back when the window closes.
|
|
628
|
+
const covered = () => {
|
|
629
|
+
const at = anchor.getBoundingClientRect();
|
|
630
|
+
const x = at.left + at.width / 2;
|
|
631
|
+
const y = at.top + Math.min(at.height / 2, 24);
|
|
632
|
+
// Out of view is said by the key at the edge (place), and a place that lets clicks through
|
|
633
|
+
// cannot be asked what covers it.
|
|
634
|
+
if (x < 0 || y < 0 || x >= window.innerWidth || y >= window.innerHeight || getComputedStyle(anchor).pointerEvents === 'none') return false;
|
|
635
|
+
const top = document.elementsFromPoint(x, y).find((node) => !card.contains(node) && !away.contains(node) && node !== spot?.node);
|
|
636
|
+
return Boolean(top) && top !== anchor && !anchor.contains(top) && !top.contains(anchor);
|
|
637
|
+
};
|
|
638
|
+
const watchCover = () => {
|
|
639
|
+
if (!anchor.isConnected) return;
|
|
640
|
+
const hide = covered();
|
|
641
|
+
for (const node of [card, away, spot?.node]) node?.toggleAttribute('data-covered', hide);
|
|
642
|
+
};
|
|
599
643
|
const place = () => {
|
|
600
644
|
if (!anchor.isConnected) { done(); return; }
|
|
601
645
|
const at = anchor.getBoundingClientRect();
|
|
@@ -620,6 +664,8 @@ export function startTour({ page, go = {}, ready = () => true, phone = false, de
|
|
|
620
664
|
window.addEventListener('scroll', follow, true);
|
|
621
665
|
window.addEventListener('resize', follow);
|
|
622
666
|
place();
|
|
667
|
+
watchCover();
|
|
668
|
+
coverTimer = setInterval(watchCover, 350);
|
|
623
669
|
// Where it points: on the page, or on a layer over it (Home's Project map). A layer opened over
|
|
624
670
|
// the page hides the hints that point under it, and they come back when it closes (salas-mac.css).
|
|
625
671
|
const layer = anchor.closest?.('.mv') ? 'map' : 'page';
|
|
@@ -659,6 +705,8 @@ export function startTour({ page, go = {}, ready = () => true, phone = false, de
|
|
|
659
705
|
hint,
|
|
660
706
|
returning,
|
|
661
707
|
newcomer,
|
|
708
|
+
// Updated from a MADRE before 1.1.0 (src/terms.mjs): never the welcome of someone new.
|
|
709
|
+
upgraded: () => Boolean(info?.upgraded),
|
|
662
710
|
// A card the page shows itself (app.js: first touches and news) is kept as seen here, per person.
|
|
663
711
|
seen: (id) => keep({ hint: id }),
|
|
664
712
|
state: () => state,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// SPDX-License-Identifier:
|
|
2
|
-
// MADRE · © 2026 Jossue Alcalá ·
|
|
1
|
+
// SPDX-License-Identifier: BUSL-1.1
|
|
2
|
+
// MADRE · © 2026 Jossue Alcalá · Business Source License 1.1: LICENSE
|
|
3
3
|
import { t } from './i18n.js';
|
|
4
4
|
|
|
5
5
|
// MU/TH/UR knowledge base: known conditions, how to recognise them in the
|
|
@@ -8,10 +8,15 @@ import { t } from './i18n.js';
|
|
|
8
8
|
// Pure module (no DOM) so the catalog can be unit-tested and reused by the CLI.
|
|
9
9
|
|
|
10
10
|
// The two MADRE is tested on. Every remedy below is a command written for one of these two
|
|
11
|
-
// shells; a third set that nobody has ever run would be worse than none.
|
|
11
|
+
// shells; a third set that nobody has ever run would be worse than none. Since 2026-10-28 (D-001,
|
|
12
|
+
// docs/WINDOWS.md) two more columns are read from those: WSL is Linux inside Windows, so it reads
|
|
13
|
+
// Linux's unless a card has a line of its own; and Windows says one thing — on Windows MADRE runs
|
|
14
|
+
// inside WSL2 (1.1.0) — before Linux's commands (fixesFor).
|
|
12
15
|
export const PLATFORMS = {
|
|
13
16
|
darwin: { label: 'macOS', shell: 'zsh' },
|
|
14
17
|
linux: { label: 'Linux', shell: 'bash' },
|
|
18
|
+
wsl: { label: 'WSL', shell: 'bash' },
|
|
19
|
+
win32: { label: 'Windows', shell: 'PowerShell · WSL' },
|
|
15
20
|
};
|
|
16
21
|
|
|
17
22
|
const envExport = (name, value) => ({
|
|
@@ -175,6 +180,17 @@ export const CONDITIONS = [
|
|
|
175
180
|
remedy: 'Top up that API account, or give OpenCode a model whose provider has a session that works: your ChatGPT account (openai/…), GitHub Copilot, or OpenCode\'s own free models (opencode/…). Change the default in Settings › Agents › OpenCode, or pick another model in the Write box for one turn.',
|
|
176
181
|
fixes: same(['# Anthropic API: https://console.anthropic.com/settings/billing', '# OpenAI API: https://platform.openai.com/settings/organization/billing', '# OpenCode, one turn on its own free model:', 'PULSE_OPENCODE_MODEL=opencode/big-pickle madre start', '# or take the key with no balance out of OpenCode:', 'opencode auth logout anthropic']),
|
|
177
182
|
},
|
|
183
|
+
{
|
|
184
|
+
id: 'opencode-free-limit',
|
|
185
|
+
code: 'MU-073',
|
|
186
|
+
agent: 'opencode',
|
|
187
|
+
severity: 'blocking',
|
|
188
|
+
title: 'OpenCode\'s free models have run out for now',
|
|
189
|
+
match: /Free usage limit reached|free use of OpenCode ran out/i,
|
|
190
|
+
diagnosis: 'OpenCode\'s own free models (opencode/…) answer without an account, but only up to a limit; when it is reached OpenCode retries in silence and never answers. MADRE now stops the turn as soon as OpenCode says so, instead of waiting for the clock. Nothing in the project is wrong.',
|
|
191
|
+
remedy: 'Connect a provider of yours to OpenCode in Settings › Agents › OpenCode (your ChatGPT account, GitHub Copilot or an API key), ask another agent, or ask @madre, which runs on this computer. The free use comes back after a while.',
|
|
192
|
+
fixes: same(['# the providers OpenCode can use:', 'opencode auth login', '# subscription for more free use: https://opencode.ai/go']),
|
|
193
|
+
},
|
|
178
194
|
{
|
|
179
195
|
id: 'cursor-usage-limit',
|
|
180
196
|
code: 'MU-060',
|
|
@@ -194,7 +210,7 @@ export const CONDITIONS = [
|
|
|
194
210
|
title: 'Agent installed but signed out',
|
|
195
211
|
match: /not logged in|sign in required|Error authenticating|unauthorized|please (?:log|sign) ?in|no credentials/i,
|
|
196
212
|
diagnosis: 'The CLI is on this computer but has no session for its provider. MADRE never stores credentials; each agent keeps its own.',
|
|
197
|
-
remedy: '
|
|
213
|
+
remedy: 'This agent has no session yet. Connect it once in Settings › Agents (MADRE runs its sign-in for you, nothing to type in a terminal), or ask the same of an agent that is connected.',
|
|
198
214
|
fixes: same(['npx @jossuealcala/madre setup', '# or directly:', 'codex login', 'claude auth login', 'opencode auth login', 'gemini # then /auth']),
|
|
199
215
|
perAgent: loginAgent,
|
|
200
216
|
},
|
|
@@ -533,7 +549,7 @@ export const CONDITIONS = [
|
|
|
533
549
|
// Older rooms recorded @madre leaving as "madre is not installed": it is this condition, not MU-009.
|
|
534
550
|
match: /@madre|madre-local|needs Ollama running with a chat model|\bmadre is not installed on this computer|@madre left the (room|project)/i,
|
|
535
551
|
diagnosis: 'When Ollama runs with a chat model, a fifth agent joins the project: @madre. It answers from the whole archive (distilled notes and exact quotes, cited as [#n]) and from what the message carries, locally, for free. It never writes, draws, browses or makes plans; when the project never discussed something it says so. Other agents may give it a plan step to check what was decided. It leaves the project when Ollama stops, and Diagnostics says so.',
|
|
536
|
-
remedy: 'Start Ollama and download a chat model
|
|
552
|
+
remedy: 'Start Ollama and download a chat model in Settings › Local AI; its @madre switch there turns the agent off if you do not want it. Ask it "what did we decide about …" or "did we ever discuss …".',
|
|
537
553
|
fixes: same(['ollama serve', 'ollama pull qwen2.5:3b', '@madre what did we decide about the webhook?']),
|
|
538
554
|
},
|
|
539
555
|
{
|
|
@@ -543,10 +559,10 @@ export const CONDITIONS = [
|
|
|
543
559
|
severity: 'informational',
|
|
544
560
|
title: 'Ollama: local smart search and a local archivist',
|
|
545
561
|
match: /ollama|11434|local model|nomic-embed|qwen|llama3/i,
|
|
546
|
-
diagnosis: 'When Ollama runs on this machine with an embedding model and a chat model, MADRE embeds the memory locally (recall by meaning without any key) and distils memories with the local model first, before Gemini and the others. Nothing leaves the machine for remembering. Off or absent, everything falls back to the providers.
|
|
547
|
-
remedy: 'Install Ollama (ollama.com), start it, then open Local AI
|
|
562
|
+
diagnosis: 'When Ollama runs on this machine with an embedding model and a chat model, MADRE embeds the memory locally (recall by meaning without any key) and distils memories with the local model first, before Gemini and the others. Nothing leaves the machine for remembering. Off or absent, everything falls back to the providers. Local AI, in Settings, shows what Ollama has, downloads the recommended models, and switches each role.',
|
|
563
|
+
remedy: 'Install Ollama (ollama.com), start it, then open Settings › Local AI and download the models it suggests. Set PULSE_OLLAMA_MODEL or PULSE_OLLAMA_EMBED_MODEL to prefer others; PULSE_EMBED_PROVIDER=gemini keeps embeddings on Gemini even with Ollama running.',
|
|
548
564
|
fixes: {
|
|
549
|
-
darwin: ['brew install ollama', 'ollama serve', 'ollama pull nomic-embed-text', 'ollama pull qwen2.5:3b'],
|
|
565
|
+
darwin: ['# the official app, which opens by itself with the Mac: https://ollama.com/download', '# or with Homebrew:', 'brew install ollama', 'ollama serve', 'ollama pull nomic-embed-text', 'ollama pull qwen2.5:3b'],
|
|
550
566
|
linux: ['curl -fsSL https://ollama.com/install.sh | sh', 'ollama serve', 'ollama pull nomic-embed-text', 'ollama pull qwen2.5:3b']
|
|
551
567
|
},
|
|
552
568
|
},
|
|
@@ -705,6 +721,154 @@ export const CONDITIONS = [
|
|
|
705
721
|
'PULSE_UPDATE_CHECK=0 madre start # no version checks at all',
|
|
706
722
|
]),
|
|
707
723
|
},
|
|
724
|
+
// THE WELCOME OF 1.0.6 (2026-10-28, docs/private/BIENVENIDA-1.0.6.md): what goes wrong on the way
|
|
725
|
+
// from `npx madre` to a MADRE that is ready, each with the steps for the system it happens on. The
|
|
726
|
+
// welcome and Home open these from the step where it went wrong («See how to fix it»).
|
|
727
|
+
{
|
|
728
|
+
id: 'no-browser',
|
|
729
|
+
code: 'MU-061',
|
|
730
|
+
severity: 'common',
|
|
731
|
+
title: 'The browser did not open',
|
|
732
|
+
match: /could not open (?:the|a) browser|no browser (?:opened|found)|Open this address in (?:a browser on this computer|your Windows browser)|xdg-open|wslview/i,
|
|
733
|
+
diagnosis: 'MADRE opens its page in the browser of the computer it runs on. A Linux without a screen has none, a virtual machine may have none, and from inside WSL it asks Windows for its own, which does not always answer. When no browser opens, the terminal prints the address to open by hand: MADRE is running all the same.',
|
|
734
|
+
remedy: 'Copy the address the terminal printed (it ends in /salas) and open it in your browser. In WSL, open it in your Windows browser, with localhost instead of 127.0.0.1.',
|
|
735
|
+
fixes: {
|
|
736
|
+
darwin: ['# the port is the one the terminal printed', 'open http://127.0.0.1:5317/salas'],
|
|
737
|
+
linux: ['# the port is the one the terminal printed', 'xdg-open http://127.0.0.1:5317/salas', '# with no screen here, open that address in a browser on this computer'],
|
|
738
|
+
wsl: ['# the port is the one the terminal printed', 'explorer.exe http://localhost:5317/salas', '# so MADRE opens it by itself next time:', 'sudo apt install wslu'],
|
|
739
|
+
},
|
|
740
|
+
},
|
|
741
|
+
{
|
|
742
|
+
id: 'ssh-tunnel',
|
|
743
|
+
code: 'MU-062',
|
|
744
|
+
severity: 'informational',
|
|
745
|
+
title: 'MADRE runs on another computer (SSH)',
|
|
746
|
+
match: /\bSSH_CONNECTION\b|connected to this computer from another one|the browser is over there|ssh -L \d+:127\.0\.0\.1/i,
|
|
747
|
+
diagnosis: 'You reached the computer where MADRE runs from another one, over SSH. MADRE listens only on its own computer (127.0.0.1), on purpose: nothing on your network can reach it. So the browser on your computer needs a tunnel, which SSH makes with one command. The terminal printed it with your user, your server and the port.',
|
|
748
|
+
remedy: 'On your own computer, open a new terminal, paste the command, leave it open, and open the address in your browser. Each project you open uses one more port: add it to the same command.',
|
|
749
|
+
fixes: same(['# on YOUR computer, in a new terminal (leave it open):', 'ssh -L 5317:127.0.0.1:5317 user@server', '# then open http://127.0.0.1:5317/salas', '# one more -L for each open project:', 'ssh -L 5317:127.0.0.1:5317 -L 5318:127.0.0.1:5318 user@server']),
|
|
750
|
+
},
|
|
751
|
+
{
|
|
752
|
+
id: 'tunnel-ipv6',
|
|
753
|
+
code: 'MU-063',
|
|
754
|
+
severity: 'common',
|
|
755
|
+
title: 'The tunnel connects but the page does not load',
|
|
756
|
+
match: /channel \d+: open failed|connect failed: Connection refused|bind \[::1\]|cannot assign requested address/i,
|
|
757
|
+
diagnosis: 'A tunnel written with «localhost» can land on the server\'s IPv6 address (::1), where MADRE does not listen: SSH says «open failed» and the browser stays blank. MADRE listens on 127.0.0.1.',
|
|
758
|
+
remedy: 'Write 127.0.0.1 in the tunnel instead of localhost, and open http://127.0.0.1 with the same port in your browser.',
|
|
759
|
+
fixes: same(['# 127.0.0.1, not localhost, on both sides of the tunnel:', 'ssh -L 5317:127.0.0.1:5317 user@server']),
|
|
760
|
+
},
|
|
761
|
+
{
|
|
762
|
+
id: 'install-offline',
|
|
763
|
+
code: 'MU-064',
|
|
764
|
+
severity: 'transient',
|
|
765
|
+
title: 'An install could not download',
|
|
766
|
+
match: /ENOTFOUND|EAI_AGAIN|getaddrinfo|ECONNRESET|network (?:is )?unreachable|unable to get local issuer certificate|self[- ]signed certificate in certificate chain|request to https?:\/\/registry\.npmjs\.org\S* failed/i,
|
|
767
|
+
diagnosis: 'Installing an agent or a model downloads it from the internet: agents from npm, models from Ollama. The download did not get through: there is no connection, the server\'s name could not be found, or something on this network (a VPN, a proxy, a company firewall) stopped it. Nothing was left half installed.',
|
|
768
|
+
remedy: 'Check that this computer has internet and try again. On a company network or a VPN, try from another one, or ask whoever runs it to allow registry.npmjs.org and ollama.com.',
|
|
769
|
+
fixes: same(['npm ping', 'curl -I https://registry.npmjs.org', '# behind a proxy, npm has to be told:', 'npm config set proxy http://proxy:port']),
|
|
770
|
+
},
|
|
771
|
+
{
|
|
772
|
+
id: 'node-missing',
|
|
773
|
+
code: 'MU-065',
|
|
774
|
+
severity: 'blocking',
|
|
775
|
+
title: 'An agent needs Node and npm',
|
|
776
|
+
match: /spawn npm(?:\.cmd)? ENOENT|npm(?:\.cmd)?: (?:command )?not found|'npm' is not recognized|command not found: npm/i,
|
|
777
|
+
diagnosis: 'Codex, Claude, Gemini and OpenCode install with npm, the installer that comes with Node, and this computer does not have it where MADRE looks.',
|
|
778
|
+
remedy: 'Install Node 22 or newer (it brings npm), open MADRE again, and press Install.',
|
|
779
|
+
fixes: {
|
|
780
|
+
darwin: ['brew install node', '# or the installer from https://nodejs.org'],
|
|
781
|
+
linux: ['# Node 22 or newer (the one in your system\'s packages may be older):', 'curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -', 'sudo apt install -y nodejs', '# or nvm, with no administrator: https://github.com/nvm-sh/nvm'],
|
|
782
|
+
},
|
|
783
|
+
},
|
|
784
|
+
{
|
|
785
|
+
id: 'sign-in-unfinished',
|
|
786
|
+
code: 'MU-066',
|
|
787
|
+
severity: 'transient',
|
|
788
|
+
title: 'The sign-in did not finish',
|
|
789
|
+
match: /sign-in (?:was )?cancell?ed|login (?:was )?cancell?ed|sign-in timed out|login timed out|device code (?:has )?expired|authorization (?:was )?denied/i,
|
|
790
|
+
diagnosis: 'Connecting an agent opens its page and waits for you to finish there. It stops if it waits too long (15 minutes), if you cancel it, or if the page was opened on another computer and its code never came back. Nothing is wrong with the account.',
|
|
791
|
+
remedy: 'Start it again from Settings › Agents and finish it on the page that opens. If MADRE runs on another computer, choose «With a code» (Codex) or paste back the code the page gives you (Claude); for Gemini, paste an API key instead.',
|
|
792
|
+
fixes: same(['# Home → Settings → Agents → Sign in again', '# or in a terminal on the computer where MADRE runs:', 'codex login --device-auth', 'claude auth login']),
|
|
793
|
+
},
|
|
794
|
+
{
|
|
795
|
+
id: 'ollama-not-starting',
|
|
796
|
+
code: 'MU-067',
|
|
797
|
+
severity: 'blocking',
|
|
798
|
+
title: 'Ollama does not start',
|
|
799
|
+
match: /Ollama did not answer|listen tcp 127\.0\.0\.1:11434: bind|address already in use[^\n]*11434|could not connect to ollama/i,
|
|
800
|
+
diagnosis: 'Ollama is installed but nothing answers on its port (11434). Usually it is closed (on a Mac, the app is not open), another copy of Ollama already holds the port, or on Linux its service did not start.',
|
|
801
|
+
remedy: 'On a Mac, open the Ollama app. On Linux, start its service. Then press «I did it», or Check again in Settings › Local AI.',
|
|
802
|
+
fixes: {
|
|
803
|
+
darwin: ['open -a Ollama', 'curl http://127.0.0.1:11434/api/version'],
|
|
804
|
+
linux: ['sudo systemctl start ollama', 'systemctl status ollama --no-pager', '# without systemd (WSL without it, a container):', 'ollama serve', 'curl http://127.0.0.1:11434/api/version'],
|
|
805
|
+
},
|
|
806
|
+
},
|
|
807
|
+
{
|
|
808
|
+
id: 'model-download',
|
|
809
|
+
code: 'MU-068',
|
|
810
|
+
severity: 'transient',
|
|
811
|
+
title: 'A model download stopped',
|
|
812
|
+
match: /Ollama pull HTTP|pull model manifest|max retries exceeded/i,
|
|
813
|
+
diagnosis: 'Models are big (from half a GB to dozens) and come down in pieces. A cut connection or a full disk stops the download; what already arrived stays, and trying again picks up where it stopped.',
|
|
814
|
+
remedy: 'Try again from the same place. If it stops at the same point, check the free space (the model needs its size plus some room) or choose a smaller model.',
|
|
815
|
+
fixes: same(['ollama pull qwen2.5:3b # the model you chose; it resumes where it stopped', 'ollama list', 'df -h ~']),
|
|
816
|
+
},
|
|
817
|
+
{
|
|
818
|
+
id: 'disk-full',
|
|
819
|
+
code: 'MU-069',
|
|
820
|
+
severity: 'blocking',
|
|
821
|
+
title: 'Not enough free space',
|
|
822
|
+
match: /ENOSPC|no space left on device/i,
|
|
823
|
+
diagnosis: 'The computer ran out of room while installing or downloading. An AI on your computer takes the most: each model is a file of one to several GB, kept by Ollama in its own folder.',
|
|
824
|
+
remedy: 'Free some space, or remove models you do not use, and try again. A smaller model needs less.',
|
|
825
|
+
fixes: {
|
|
826
|
+
darwin: ['df -h ~', 'du -sh ~/.ollama/models', 'ollama list', 'ollama rm qwen2.5:7b # a model you do not use'],
|
|
827
|
+
linux: ['df -h ~', 'du -sh ~/.ollama/models /usr/share/ollama/.ollama/models 2>/dev/null', 'ollama list', 'ollama rm qwen2.5:7b # a model you do not use'],
|
|
828
|
+
},
|
|
829
|
+
},
|
|
830
|
+
{
|
|
831
|
+
id: 'ollama-remote',
|
|
832
|
+
code: 'MU-070',
|
|
833
|
+
severity: 'common',
|
|
834
|
+
title: 'Another computer\'s Ollama does not answer',
|
|
835
|
+
match: /Nothing answers at http|Expose Ollama to the network|OLLAMA_HOST=0\.0\.0\.0/i,
|
|
836
|
+
diagnosis: 'MADRE can use the AI of another computer on your network: Windows\' own from inside WSL, or one with a graphics card. Ollama only listens on its own computer unless it is told otherwise, and a firewall may close its port (11434).',
|
|
837
|
+
remedy: 'On the computer with Ollama, turn on «Expose Ollama to the network» in the app\'s settings (or start it with OLLAMA_HOST=0.0.0.0), let port 11434 through its firewall, and test the address again in Settings › Local AI.',
|
|
838
|
+
fixes: {
|
|
839
|
+
darwin: ['# on the computer that has Ollama:', 'OLLAMA_HOST=0.0.0.0 ollama serve', '# from here, check that it answers:', 'curl http://192.168.1.40:11434/api/version'],
|
|
840
|
+
linux: ['# on the computer that has Ollama:', 'OLLAMA_HOST=0.0.0.0 ollama serve', '# from here, check that it answers:', 'curl http://192.168.1.40:11434/api/version'],
|
|
841
|
+
wsl: ['# in Windows: the Ollama app → Settings → Expose Ollama to the network', '# from Ubuntu, Windows is where WSL\'s network goes out (the address after «via»):', 'ip route show default', 'curl http://172.28.80.1:11434/api/version # with that address'],
|
|
842
|
+
},
|
|
843
|
+
},
|
|
844
|
+
{
|
|
845
|
+
id: 'wsl-windows-folder',
|
|
846
|
+
code: 'MU-071',
|
|
847
|
+
severity: 'degraded',
|
|
848
|
+
title: 'A project in a Windows folder (/mnt/c)',
|
|
849
|
+
match: /\/mnt\/[a-z]\//i,
|
|
850
|
+
diagnosis: 'Inside WSL, the Windows disk shows up as /mnt/c. It works, but every file goes through a bridge between the two systems: MADRE reads slower there, and the protections Linux gives a project (which agent may write where) do not hold on Windows files.',
|
|
851
|
+
remedy: 'Keep projects inside Linux, in your folder in /home. Copy the project once and add the copy in Home.',
|
|
852
|
+
fixes: {
|
|
853
|
+
darwin: ['# this only happens inside WSL, on Windows'],
|
|
854
|
+
linux: ['# inside WSL: keep the project in Linux', 'mkdir -p ~/projects', 'cp -r "/mnt/c/Users/<you>/<project>" ~/projects/', '# then add ~/projects/<project> in Home'],
|
|
855
|
+
},
|
|
856
|
+
},
|
|
857
|
+
{
|
|
858
|
+
id: 'windows-use-wsl',
|
|
859
|
+
code: 'MU-072',
|
|
860
|
+
severity: 'informational',
|
|
861
|
+
title: 'MADRE on Windows',
|
|
862
|
+
match: /\bwin32\b|native Windows|Windows nativo|wsl --install/i,
|
|
863
|
+
diagnosis: 'On Windows, MADRE runs inside WSL2 (Windows Subsystem for Linux), the Linux that comes with Windows 10 and 11. Inside it MADRE works as on any Linux, and opens in your Windows browser. It does not run on Windows directly.',
|
|
864
|
+
remedy: 'Install WSL once (it asks for an administrator and a restart), open Ubuntu from the Start menu, and start MADRE there. Keep your projects inside Linux, not in /mnt/c.',
|
|
865
|
+
fixes: {
|
|
866
|
+
darwin: ['# this is for Windows'],
|
|
867
|
+
linux: ['# this is for Windows'],
|
|
868
|
+
wsl: ['# you are already in WSL: MADRE runs here as on any Linux'],
|
|
869
|
+
win32: ['# in PowerShell, as administrator, once:', 'wsl --install', '# restart, open «Ubuntu» from the Start menu, and in it:', 'curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -', 'sudo apt install -y nodejs', 'npx @jossuealcala/madre'],
|
|
870
|
+
},
|
|
871
|
+
},
|
|
708
872
|
];
|
|
709
873
|
|
|
710
874
|
// Which of the two sets of commands to show first. Anything else gets macOS, and the panel says
|
|
@@ -867,8 +1031,15 @@ export function findConditions(query) {
|
|
|
867
1031
|
return unique.length ? unique : looseConditions(query);
|
|
868
1032
|
}
|
|
869
1033
|
|
|
1034
|
+
// A column of commands for a system: its own, or for WSL and Windows Linux's, which is what runs
|
|
1035
|
+
// there; macOS's only when nothing else was written.
|
|
1036
|
+
const columnFor = (fixes, platform) => fixes?.[platform] ?? (platform === 'wsl' || platform === 'win32' ? fixes?.linux : null) ?? fixes?.darwin ?? null;
|
|
1037
|
+
// On Windows a card that has no line of its own says first where those commands run (D-001).
|
|
1038
|
+
export const WINDOWS_FIRST = ['# On Windows, MADRE runs inside WSL2, Linux inside Windows: see «MADRE on Windows».', '# in Ubuntu (WSL):'];
|
|
870
1039
|
export function fixesFor(condition, platform, agent = null) {
|
|
871
|
-
const base = condition.fixes
|
|
872
|
-
const perAgent = condition.perAgent?.[agent]
|
|
873
|
-
|
|
1040
|
+
const base = columnFor(condition.fixes, platform) ?? [];
|
|
1041
|
+
const perAgent = condition.perAgent?.[agent] ? columnFor(condition.perAgent[agent], platform) : null;
|
|
1042
|
+
const lines = perAgent ? [...perAgent, ...(base.length && !base[0].startsWith('#') ? base : [])] : base;
|
|
1043
|
+
const ownWindows = condition.fixes?.win32 || condition.perAgent?.[agent]?.win32;
|
|
1044
|
+
return platform === 'win32' && !ownWindows && lines.length ? [...WINDOWS_FIRST, ...lines] : lines;
|
|
874
1045
|
}
|