@7ots/cli 0.1.11 → 0.1.12

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.
@@ -48,7 +48,7 @@ export const CONFIG_DEFAULTS = Object.freeze({
48
48
  home: { kind: 'local' },
49
49
  brain: { kind: 'lines' },
50
50
  voice: { kind: 'browser' },
51
- pet: { mode: 'ask', annoy: 2, music: 'synth', musicVol: 0.5 },
51
+ pet: { mode: 'ask', annoy: 2, music: 'synth', musicVol: 0.5, entrance: { onStart: false, kind: 'wwe', dance: '' } },
52
52
  access: { agent: true, memory: true, open: true, notify: true, sites: true, screen: false, processes: false, logs: false, inbox: false, vm: false, vmKinds: ['research', 'browse', 'long'] },
53
53
  screen: { every: 5 },
54
54
  // conversation memory: recent turns up to `tokens` (≈chars/4), older ones compacted into a summary; 0 = off
@@ -47,7 +47,7 @@ import { createInferenceLog, otherInferences } from './inferences.mjs';
47
47
 
48
48
  const MAX_INF = 300;
49
49
  import { AI_CLIS, createBrain, detectClis, petSystem } from './brain.mjs';
50
- import { env, loadConfig, saveConfig, saveKey } from './config.mjs';
50
+ import { CONFIG_DEFAULTS, env, loadConfig, saveConfig, saveKey } from './config.mjs';
51
51
  import { loadIdentity } from './identity.mjs';
52
52
  import { readJson, writeJson } from './paths.mjs';
53
53
  import { sttProvider, transcribe } from './stt.mjs';
@@ -72,6 +72,7 @@ const SCENE_NAMES = ['rocky', 'sf', 'dbz', 'matrix', 'duel', 'sw', 'fight', 'twi
72
72
  const SCENE_EVERY = ['rare', 'normal', 'often'];
73
73
  // dances and their music (pet.html plays them; music: synthesized, your own files in ~/.7ots/music, or none)
74
74
  const MUSIC_MODES = ['synth', 'files', 'off'];
75
+ const ENTRANCE_KINDS = ['wwe', 'rock', 'magic'];
75
76
  const MUSIC_TYPES = { mp3: 'audio/mpeg', ogg: 'audio/ogg', oga: 'audio/ogg', opus: 'audio/ogg', wav: 'audio/wav', m4a: 'audio/mp4', aac: 'audio/aac', flac: 'audio/flac', webm: 'audio/webm' };
76
77
  const MUSIC_FILE = /^[^/\\\0]{1,160}\.(mp3|ogg|oga|opus|wav|m4a|aac|flac|webm)$/i;
77
78
  function musicFiles() {
@@ -455,7 +456,7 @@ export function startPetServer({ port = PET_PORT, log = () => {} } = {}) {
455
456
 
456
457
  const page = (file = 'pet.html', extra = {}) =>
457
458
  readFileSync(join(PKG_ROOT, 'cli', 'pet', file), 'utf8')
458
- .replace('__BOOT__', JSON.stringify({ token, pid: process.pid, companion: !!process.env.SEVENOTS_COMPANION, identity, otsId: config.account?.otsId || '', voice: config.voice, lang, annoy, brain: brainLabel(config.brain), activity, stt: sttProvider(env()), ...extra }).replace(/</g, '\\u003c'));
459
+ .replace('__BOOT__', JSON.stringify({ token, pid: process.pid, companion: !!process.env.SEVENOTS_COMPANION, identity, otsId: config.account?.otsId || '', voice: config.voice, lang, annoy, brain: brainLabel(config.brain), activity, stt: sttProvider(env()), backdrop: config.pet.backdrop !== false, ...extra }).replace(/</g, '\\u003c'));
459
460
 
460
461
  // Visitors: other ots of the account invited onto this desktop (their look, saved so they come offline too).
461
462
  // The desktop shell opens a window for each and stages scenes between them (see electron/director.cjs).
@@ -508,6 +509,7 @@ export function startPetServer({ port = PET_PORT, log = () => {} } = {}) {
508
509
  } catch {}
509
510
  return fetch(`${c.url}/quit`, { method: 'POST', headers: { 'X-7ots-Token': t, 'Content-Type': 'application/json' }, body: '{}' }).catch(() => {});
510
511
  };
512
+ let entranceDone = false;
511
513
  const fullOnes = () => visitors().filter((v) => v.full);
512
514
  if (!process.env.SEVENOTS_COMPANION) fullOnes().forEach((v) => startCompanion(v).catch((e) => log(`companion: ${e.message}`)));
513
515
 
@@ -968,7 +970,15 @@ ${keys.map((k) => FIELDS[k]).join('\n')}`;
968
970
  if (p === '/dance' || p === '/entrance') {
969
971
  const dance = musicFor(data);
970
972
  if (p === '/dance') broadcast({ dance });
971
- else broadcast({ entrance: { ...dance, name: identity.name || 'ot' } });
973
+ else {
974
+ // { start: true } = the page just opened: only once per run, and only if the owner wants it
975
+ const ec = { ...CONFIG_DEFAULTS.pet.entrance, ...config.pet.entrance };
976
+ if (data.start && (entranceDone || !ec.onStart)) return json(200, { ok: false });
977
+ entranceDone = true;
978
+ const want = ENTRANCE_KINDS.includes(data.kind) ? data.kind : ENTRANCE_KINDS.includes(ec.kind) ? ec.kind : ENTRANCE_KINDS[Math.floor(Math.random() * ENTRANCE_KINDS.length)];
979
+ const dn = DANCES.includes(data.name) ? data.name : DANCES.includes(ec.dance) ? ec.dance : '';
980
+ broadcast({ entrance: { ...dance, dance: dn, kind: want, name: identity.name || 'ot' } });
981
+ }
972
982
  log(`${p.slice(1)}: ${dance.name}${dance.music ? ` ♪ ${dance.music.file || dance.music.style}` : ''}`);
973
983
  return json(200, { ok: true, dance: dance.name, music: dance.music });
974
984
  }
@@ -1003,6 +1013,7 @@ ${keys.map((k) => FIELDS[k]).join('\n')}`;
1003
1013
  // the catalog without its 3D models (the page only draws the 2D previews)
1004
1014
  modLibrary: modLibrary(),
1005
1015
  musicFiles: musicFiles(),
1016
+ dances: DANCES,
1006
1017
  modCatalog: MOD_CATALOG.map((m) => normalizeMod(m)).map((m) => ({ ...m, parts: m.parts.map((x) => ({ ...x, glb: x.glb ? '3d' : '' })) })),
1007
1018
  integrations: config.integrations,
1008
1019
  character: config.character,
@@ -1041,10 +1052,19 @@ ${keys.map((k) => FIELDS[k]).join('\n')}`;
1041
1052
  } else return 'kind';
1042
1053
  }
1043
1054
  const viewWas = next.pet.view || '2d';
1055
+ const bdWas = next.pet.backdrop !== false;
1044
1056
  if (d.pet) {
1045
1057
  if (d.pet.annoy !== undefined) next.pet.annoy = Math.max(0, Math.min(3, Math.round(Number(d.pet.annoy)) || 0));
1046
1058
  if (['2d', '3d'].includes(d.pet.view)) next.pet.view = d.pet.view;
1059
+ if (d.pet.backdrop !== undefined) next.pet.backdrop = !!d.pet.backdrop;
1047
1060
  if (MUSIC_MODES.includes(d.pet.music)) next.pet.music = d.pet.music;
1061
+ if (d.pet.entrance && typeof d.pet.entrance === 'object') {
1062
+ const e = { ...CONFIG_DEFAULTS.pet.entrance, ...next.pet.entrance };
1063
+ if (d.pet.entrance.onStart !== undefined) e.onStart = !!d.pet.entrance.onStart;
1064
+ if ([...ENTRANCE_KINDS, 'random'].includes(d.pet.entrance.kind)) e.kind = d.pet.entrance.kind;
1065
+ if (d.pet.entrance.dance === '' || DANCES.includes(d.pet.entrance.dance)) e.dance = d.pet.entrance.dance;
1066
+ next.pet.entrance = e;
1067
+ }
1048
1068
  if (d.pet.musicVol !== undefined) next.pet.musicVol = Math.max(0, Math.min(1, Math.round(Number(d.pet.musicVol) * 100) / 100 || 0));
1049
1069
  if (d.pet.scenes) {
1050
1070
  const c = { ...sceneConf(next), ...d.pet.scenes };
@@ -1104,6 +1124,7 @@ ${keys.map((k) => FIELDS[k]).join('\n')}`;
1104
1124
  if (config.voice.kind === 'local') warmLocal();
1105
1125
  if (reload) setTimeout(() => broadcast({ reload: true }), 100); // the page reads its voice at load
1106
1126
  // 2D ↔ 3D: open pet windows switch now (the page, or the desktop shell when it needs the GPU back on).
1127
+ if ((config.pet.backdrop !== false) !== bdWas) setTimeout(() => broadcast({ backdrop: config.pet.backdrop !== false }), 100);
1107
1128
  else if ((config.pet.view || '2d') !== viewWas) (viewSet = config.pet.view), setTimeout(() => broadcast({ view: viewSet }), 100);
1108
1129
  log(`settings: brain ${brainLabel(config.brain)}`);
1109
1130
  return null;
package/cli/pet/pet.html CHANGED
@@ -142,6 +142,9 @@
142
142
  .props .flash { top: 44%; width: 30px; height: 30px; margin: -15px; border-radius: 50%; background: radial-gradient(#fff, #ffd35a 40%, #ff7a1a 60%, transparent 70%); }
143
143
  /* entrances (wrestling style): spotlights from above, pyro columns, the name slammed in */
144
144
  .props .spot { left: 50%; bottom: 0; width: 120px; height: 140%; margin-left: -60px; transform-origin: 50% 0; top: -40%; background: linear-gradient(180deg, rgb(255 250 220 / .0), rgb(255 250 220 / .32) 70%, rgb(255 250 220 / .0)); clip-path: polygon(44% 0, 56% 0, 100% 100%, 0 100%); filter: blur(2px); mix-blend-mode: screen; }
145
+ .props .spot.rock { animation: rockhue 1s linear infinite; }
146
+ @keyframes rockhue { from { filter: blur(2px) hue-rotate(0deg) saturate(4); } to { filter: blur(2px) hue-rotate(360deg) saturate(4); } }
147
+ .props .smoke { bottom: 4%; width: 110px; height: 80px; margin-left: -55px; border-radius: 50%; background: radial-gradient(closest-side, rgb(235 230 255 / .9), rgb(190 170 255 / .5) 60%, transparent); filter: blur(6px); }
145
148
  .props .pyro { bottom: 6%; width: 16px; height: 120px; margin-left: -8px; transform-origin: 50% 100%; border-radius: 8px 8px 4px 4px; background: linear-gradient(0deg, #fff6c0, #ffb627 30%, #ff5a1f 65%, transparent); filter: blur(1px) drop-shadow(0 0 10px #ff8a1f); }
146
149
  .props .title { left: 50%; top: 4%; transform: translateX(-50%); font: 900 30px/1 Impact, 'Anton', system-ui, sans-serif; letter-spacing: 2px; text-transform: uppercase; white-space: nowrap; color: #fff; background: linear-gradient(180deg, #fff 30%, #ffd84a 55%, #ff8a1f); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; -webkit-text-stroke: 1.5px #2a0f00; filter: drop-shadow(0 3px 0 #1a0a00) drop-shadow(0 0 12px rgb(255 160 40 / .7)); }
147
150
  .props .pow { left: 50%; top: 6%; font: 900 22px/1 system-ui, sans-serif; color: #ffd400; -webkit-text-stroke: 2px #1a1020; transform: translateX(-50%); white-space: nowrap; }
@@ -277,14 +280,14 @@
277
280
  // three comes from the CDN; without WebGL or network the 2D ot takes over
278
281
  try {
279
282
  const m = await loadCharacter3D();
280
- ch = m.createCharacter3D($('#face'), spec, { material: 'plush', backdrop: !desktop, orbit: !desktop, bleed: desktop ? 'window' : 0, stage: { key: 'pet', zIndex: 3, maxDpr: 2, minDpr: 1.25, supersample: desktop } });
283
+ ch = m.createCharacter3D($('#face'), spec, { material: 'plush', backdrop: !desktop && BOOT.backdrop !== false, orbit: !desktop, bleed: desktop ? 'window' : 0, stage: { key: 'pet', zIndex: 3, maxDpr: 2, minDpr: 1.25, supersample: desktop } });
281
284
  if (ch.fallback) console.warn('[7ots pet] no WebGL: 2D ot');
282
285
  } catch (err) {
283
286
  console.warn('[7ots pet] 3D ot unavailable, using 2D:', err?.message || err);
284
287
  ch = null;
285
288
  }
286
289
  }
287
- ch ||= createCharacter($('#face'), spec, { locale: lang, title: id.name });
290
+ ch ||= createCharacter($('#face'), spec, { locale: lang, title: id.name, backdrop: BOOT.backdrop !== false });
288
291
  const is3d = !!ch.character;
289
292
  document.body.classList.toggle('ot3d', is3d);
290
293
  // While a gesture/effect/morph plays the ot needs room around it (wings, hearts, confetti): the desktop
@@ -713,6 +716,7 @@
713
716
  const m = JSON.parse(e.data);
714
717
  if (m.reload) return location.reload(); // e.g. the voice changed in the settings
715
718
  if (m.restart) return waitAndReload(); // it became another ot: a new daemon is starting
719
+ if (m.backdrop !== undefined) return location.reload(); // its style's background on/off (settings)
716
720
  if (m.view && setView(m.view === '3d')) return; // 2D ↔ 3D changed in the settings
717
721
  if (guest) return; // the host's events are the host's
718
722
  if (m.stir || (m.say && asleep && Date.now() < stirUntil)) stir(); // awake until it has said it
@@ -999,21 +1003,31 @@
999
1003
  const ms = 12000;
1000
1004
  entering = Date.now() + ms;
1001
1005
  stir();
1002
- music(d.music && !d.music.file ? { ...d.music, style: 'entrance' } : d.music, ms, 'entrance');
1006
+ const kind = ['wwe', 'rock', 'magic'].includes(d.kind) ? d.kind : 'wwe';
1007
+ const style = { wwe: 'entrance', rock: 'hype', magic: 'chip' }[kind];
1008
+ music(d.music && !d.music.file ? { ...d.music, style } : d.music, ms, style);
1003
1009
  if (desktop) console.debug('§7enter'); // the shell walks it in from the side
1004
1010
  actRoom = 190;
1005
1011
  actTall = 150;
1006
1012
  actUntil = Date.now() + ms;
1007
1013
  tellNeed();
1008
1014
  // walking in under two crossing spotlights
1009
- for (const k of [-1, 1]) {
1010
- const sp = prop('spot');
1015
+ for (const k of kind === 'magic' ? [] : [-1, 1]) {
1016
+ const sp = prop(kind === 'rock' ? 'spot rock' : 'spot');
1011
1017
  gone(sp, sp.animate([{ opacity: 0, transform: `rotate(${k * 28}deg)` }, { opacity: 1, transform: `rotate(${-k * 18}deg)`, offset: 0.25 }, { opacity: 1, transform: `rotate(${k * 12}deg)`, offset: 0.5 }, { opacity: 1, transform: `rotate(${-k * 6}deg)`, offset: 0.75 }, { opacity: 0, transform: 'rotate(0deg)' }], { duration: ms, easing: 'ease-in-out' }));
1012
1018
  }
1013
1019
  ch.gesture('groove', { ms: INTRO + 1800 });
1014
1020
  // pyro on each boom of the music (1.0 s and 1.6 s), both sides
1015
1021
  const pyro = (at) =>
1016
1022
  setTimeout(() => {
1023
+ if (kind === 'rock') return ch.effect?.('confetti'), ch.effect?.('notes');
1024
+ if (kind === 'magic') {
1025
+ for (const x of [-1, 0, 1]) {
1026
+ const p = prop('smoke', { left: `calc(50% + ${x * (actRoom - 50)}px)` });
1027
+ gone(p, p.animate([{ transform: 'scale(.3)', opacity: 0.9 }, { transform: 'scale(1.6) translateY(-20px)', opacity: 0 }], { duration: 1600, easing: 'ease-out' }));
1028
+ }
1029
+ return ch.effect?.('sparkles');
1030
+ }
1017
1031
  for (const x of [-1, 1]) {
1018
1032
  const p = prop('pyro', { left: `calc(50% + ${x * (actRoom - 30)}px)` });
1019
1033
  gone(p, p.animate([{ transform: 'scaleY(0)', opacity: 1 }, { transform: 'scaleY(1.1)', opacity: 1, offset: 0.25 }, { transform: 'scaleY(.8)', opacity: 0.9, offset: 0.6 }, { transform: 'scaleY(.2)', opacity: 0 }], { duration: 1100, easing: 'ease-out' }));
@@ -1039,6 +1053,8 @@
1039
1053
  ch.gesture(name, { ms: ms - INTRO - 3600 });
1040
1054
  }, INTRO + 3400);
1041
1055
  }
1056
+ // an entrance when the pet starts, if the owner turned it on (the server says yes once per run)
1057
+ if (!guest) setTimeout(() => post('/entrance', { start: true }).catch(() => {}), 2500);
1042
1058
  $('#danceBtn').title = t('dance');
1043
1059
  if (!guest)
1044
1060
  $('#danceBtn')?.addEventListener('click', () => post('/dance', {}).catch(() => dance({})));
@@ -306,6 +306,11 @@
306
306
  <input type="range" id="muVol" min="0" max="1" step="0.05" style="max-width:10rem" aria-label="volume">
307
307
  </div>
308
308
  <p class="hint" id="muFiles"></p>
309
+ <div class="row">
310
+ <label class="chip"><input type="checkbox" id="enOn"> <span data-t="enOn"></span></label>
311
+ <div class="chips" id="enKind"></div>
312
+ <select id="enDance" aria-label="dance"></select>
313
+ </div>
309
314
  <div class="row">
310
315
  <button type="button" id="muDance" data-t="muDance"></button>
311
316
  <button type="button" id="muEnter" data-t="muEnter"></button>
@@ -395,7 +400,7 @@
395
400
  notify: 'Notifications', notifyD: 'A desktop notification when a reminder fires.',
396
401
  soon: 'coming soon', screen: 'See your screen', screenD: 'Look at what’s open to help with it.', procs: 'Processes and apps', procsD: 'See which programs run (name, CPU, memory) and wait for one to finish. Command arguments that look like keys are hidden.', inbox: 'Read mail and calendar', inboxD: 'Summaries and replies, not just opening the tab.',
397
402
  petH: 'How chatty', annoyHint: 'How often it comments on what you do.', a0: 'Quiet', a1: 'A little', a2: 'Normal', a3: 'Chatty',
398
- muH: 'Dances & music', muHint: 'Your ot dances to a beat it makes itself, or to your own songs. Entrance: it walks in like a wrestler with lights, fireworks and its name.', muMode: { synth: 'Built-in beat', files: 'My songs', off: 'Silent' }, muNone: 'Put .mp3/.ogg/.wav files in {dir} to use your own songs.', muSome: '{n} songs in {dir}', muDance: '▶ Dance', muEnter: '▶ Entrance', muDone: 'Here it goes!', scH: 'Scenes between ots', scHint: 'When two ots share the desktop they meet now and then and act out a famous fight.', scVisitor: 'How often and which ones is set in the main ot\'s settings.', scOn: 'On', scEvery: { rare: 'Rarely', normal: 'Normal', often: 'Often' }, scPlay: '▶ Play one now', scPlayed: 'Done — it starts as soon as two ots are free.', scNames: { rocky: 'Rocky', sf: 'Street Fighter', dbz: 'Dragon Ball', matrix: 'Matrix', duel: 'Western duel', sw: 'Star Wars', fight: 'Fight & hug', twist: 'Twist' },
403
+ bd: 'Background', bdHint: 'The background of its art style behind the ot', enOn: 'Make an entrance when it starts', enKind: { wwe: 'Wrestler', rock: 'Rock star', magic: 'Magic', random: 'Surprise me' }, enAny: 'any dance', muH: 'Dances & music', muHint: 'Your ot dances to a beat it makes itself, or to your own songs. Entrance: it walks in like a wrestler with lights, fireworks and its name.', muMode: { synth: 'Built-in beat', files: 'My songs', off: 'Silent' }, muNone: 'Put .mp3/.ogg/.wav files in {dir} to use your own songs.', muSome: '{n} songs in {dir}', muDance: '▶ Dance', muEnter: '▶ Entrance', muDone: 'Here it goes!', scH: 'Scenes between ots', scHint: 'When two ots share the desktop they meet now and then and act out a famous fight.', scVisitor: 'How often and which ones is set in the main ot\'s settings.', scOn: 'On', scEvery: { rare: 'Rarely', normal: 'Normal', often: 'Often' }, scPlay: '▶ Play one now', scPlayed: 'Done — it starts as soon as two ots are free.', scNames: { rocky: 'Rocky', sf: 'Street Fighter', dbz: 'Dragon Ball', matrix: 'Matrix', duel: 'Western duel', sw: 'Star Wars', fight: 'Fight & hug', twist: 'Twist' },
399
404
  view: 'Look:', v2d: '2D', v3d: '3D plush', viewNext: 'Changed — the ot switches right away.',
400
405
  notesH: 'What it knows about you', notesHint: 'Its notes. Tell it “remember that…” to add one.', noNotes: 'Nothing yet.', forget: 'Forget', forgetAll: 'Forget everything', sure: 'Click again to forget everything',
401
406
  remH: 'Processes', remHint: 'What {name} is doing for you: reminders, alerts and the programs it’s waiting on. Ask it “remind me…”, “let me know if BTC reaches 85k” or “tell me when the build finishes”.', infTotal: 'Last {n} calls: {in} in → {out} out · {all} tokens', petRuns: 'What {name} is running', pcRuns: 'On this computer', refreshPs: 'Refresh', noRems: 'Nothing pending: no reminders or alerts.', psOff: '{name} can’t see your programs. Turn on “Processes and apps” to list them and let it wait for one to finish.', psOn: 'Turn on', screenEvery: 'Looks at your screen every {n} min', lastSeen: 'last: {what}', priceW: '{coin} {op} {value} {vs}', priceNow: 'now {p}', procW: '“{m}” {until}', untilExit: 'when it ends', untilStart: 'when it starts', running: 'running', notRunning: 'not running', remind: 'Reminder', cpu: 'CPU', mem: 'Mem', up: 'Up', prog: 'Program', cancel: 'Cancel',
@@ -429,7 +434,7 @@
429
434
  notify: 'Notificaciones', notifyD: 'Una notificación de escritorio cuando suena un recordatorio.',
430
435
  soon: 'próximamente', screen: 'Ver tu pantalla', screenD: 'Mirar lo que tienes abierto para ayudarte.', procs: 'Procesos y apps', procsD: 'Ver qué programas corren (nombre, CPU, memoria) y esperar a que uno termine. Los argumentos que parecen claves se ocultan.', inbox: 'Leer correo y calendario', inboxD: 'Resúmenes y respuestas, no solo abrir la pestaña.',
431
436
  petH: 'Cuánto habla', annoyHint: 'Qué tan seguido comenta lo que haces.', a0: 'Callado', a1: 'Poco', a2: 'Normal', a3: 'Charlatán',
432
- muH: 'Bailes y música', muHint: 'Tu ot baila con un ritmo que arma solo, o con tus propias canciones. Entrada: llega como luchador, con luces, fuegos y su nombre.', muMode: { synth: 'Ritmo propio', files: 'Mis canciones', off: 'Sin música' }, muNone: 'Pon archivos .mp3/.ogg/.wav en {dir} para usar tus canciones.', muSome: '{n} canciones en {dir}', muDance: '▶ Bailar', muEnter: '▶ Entrada', muDone: '¡Ahí va!', scH: 'Escenas entre ots', scHint: 'Cuando dos ots comparten el escritorio, cada tanto se juntan y actúan una pelea famosa.', scVisitor: 'Cada cuánto y cuáles se ajusta en los ajustes del ot principal.', scOn: 'Activadas', scEvery: { rare: 'Poco', normal: 'Normal', often: 'Seguido' }, scPlay: '▶ Jugar una ahora', scPlayed: 'Listo: empieza apenas haya dos ots libres.', scNames: { rocky: 'Rocky', sf: 'Street Fighter', dbz: 'Dragon Ball', matrix: 'Matrix', duel: 'Duelo', sw: 'Star Wars', fight: 'Pelea y abrazo', twist: 'Twist' },
437
+ bd: 'Fondo', bdHint: 'El fondo de su estilo artístico detrás del ot', enOn: 'Entrar con entrada al iniciar', enKind: { wwe: 'Luchador', rock: 'Estrella de rock', magic: 'Magia', random: 'Sorpréndeme' }, enAny: 'cualquier baile', muH: 'Bailes y música', muHint: 'Tu ot baila con un ritmo que arma solo, o con tus propias canciones. Entrada: llega como luchador, con luces, fuegos y su nombre.', muMode: { synth: 'Ritmo propio', files: 'Mis canciones', off: 'Sin música' }, muNone: 'Pon archivos .mp3/.ogg/.wav en {dir} para usar tus canciones.', muSome: '{n} canciones en {dir}', muDance: '▶ Bailar', muEnter: '▶ Entrada', muDone: '¡Ahí va!', scH: 'Escenas entre ots', scHint: 'Cuando dos ots comparten el escritorio, cada tanto se juntan y actúan una pelea famosa.', scVisitor: 'Cada cuánto y cuáles se ajusta en los ajustes del ot principal.', scOn: 'Activadas', scEvery: { rare: 'Poco', normal: 'Normal', often: 'Seguido' }, scPlay: '▶ Jugar una ahora', scPlayed: 'Listo: empieza apenas haya dos ots libres.', scNames: { rocky: 'Rocky', sf: 'Street Fighter', dbz: 'Dragon Ball', matrix: 'Matrix', duel: 'Duelo', sw: 'Star Wars', fight: 'Pelea y abrazo', twist: 'Twist' },
433
438
  view: 'Aspecto:', v2d: '2D', v3d: 'Peluche 3D', viewNext: 'Listo: el ot cambia al instante.',
434
439
  notesH: 'Lo que sabe de ti', notesHint: 'Sus notas. Dile “anota que…” para agregar una.', noNotes: 'Nada todavía.', forget: 'Olvidar', forgetAll: 'Olvidar todo', sure: 'Haz clic otra vez para olvidar todo',
435
440
  remH: 'Procesos', remHint: 'Lo que {name} está haciendo por ti: recordatorios, alertas y los programas que está esperando. Pídele “recuérdame…”, “avísame si BTC llega a 85 mil” o “avísame cuando termine el build”.', infTotal: 'Últimas {n} llamadas: {in} entrada → {out} salida · {all} tokens', petRuns: 'Lo que {name} tiene corriendo', pcRuns: 'En este computador', refreshPs: 'Actualizar', noRems: 'Nada pendiente: sin recordatorios ni alertas.', psOff: '{name} no ve tus programas. Activa “Procesos y apps” para listarlos y que pueda esperar a que uno termine.', psOn: 'Activar', screenEvery: 'Mira tu pantalla cada {n} min', lastSeen: 'última: {what}', priceW: '{coin} {op} {value} {vs}', priceNow: 'ahora {p}', procW: '“{m}” {until}', untilExit: 'cuando termine', untilStart: 'cuando empiece', running: 'corriendo', notRunning: 'no está corriendo', remind: 'Recordatorio', cpu: 'CPU', mem: 'Mem', up: 'Hace', prog: 'Programa', cancel: 'Cancelar',
@@ -463,7 +468,7 @@
463
468
  notify: 'Notificações', notifyD: 'Uma notificação na área de trabalho quando um lembrete toca.',
464
469
  soon: 'em breve', screen: 'Ver sua tela', screenD: 'Olhar o que está aberto para ajudar.', procs: 'Processos e apps', procsD: 'Ver quais programas rodam (nome, CPU, memória) e esperar um terminar. Argumentos que parecem chaves ficam ocultos.', inbox: 'Ler e-mail e agenda', inboxD: 'Resumos e respostas, não só abrir a aba.',
465
470
  petH: 'Quanto fala', annoyHint: 'Com que frequência comenta o que você faz.', a0: 'Calado', a1: 'Pouco', a2: 'Normal', a3: 'Tagarela',
466
- muH: 'Danças e música', muHint: 'Seu ot dança com uma batida que ele mesmo cria, ou com suas músicas. Entrada: chega como lutador, com luzes, fogos e o nome dele.', muMode: { synth: 'Batida própria', files: 'Minhas músicas', off: 'Sem música' }, muNone: 'Coloque arquivos .mp3/.ogg/.wav em {dir} para usar suas músicas.', muSome: '{n} músicas em {dir}', muDance: '▶ Dançar', muEnter: '▶ Entrada', muDone: 'Lá vai!', scH: 'Cenas entre ots', scHint: 'Quando dois ots dividem a área de trabalho, de vez em quando se encontram e encenam uma luta famosa.', scVisitor: 'Frequência e quais se ajustam nas configurações do ot principal.', scOn: 'Ativadas', scEvery: { rare: 'Pouco', normal: 'Normal', often: 'Frequente' }, scPlay: '▶ Jogar uma agora', scPlayed: 'Pronto: começa assim que houver dois ots livres.', scNames: { rocky: 'Rocky', sf: 'Street Fighter', dbz: 'Dragon Ball', matrix: 'Matrix', duel: 'Duelo', sw: 'Star Wars', fight: 'Briga e abraço', twist: 'Twist' },
471
+ bd: 'Fundo', bdHint: 'O fundo do estilo artístico atrás do ot', enOn: 'Entrar com entrada ao iniciar', enKind: { wwe: 'Lutador', rock: 'Astro do rock', magic: 'Mágica', random: 'Surpreenda-me' }, enAny: 'qualquer dança', muH: 'Danças e música', muHint: 'Seu ot dança com uma batida que ele mesmo cria, ou com suas músicas. Entrada: chega como lutador, com luzes, fogos e o nome dele.', muMode: { synth: 'Batida própria', files: 'Minhas músicas', off: 'Sem música' }, muNone: 'Coloque arquivos .mp3/.ogg/.wav em {dir} para usar suas músicas.', muSome: '{n} músicas em {dir}', muDance: '▶ Dançar', muEnter: '▶ Entrada', muDone: 'Lá vai!', scH: 'Cenas entre ots', scHint: 'Quando dois ots dividem a área de trabalho, de vez em quando se encontram e encenam uma luta famosa.', scVisitor: 'Frequência e quais se ajustam nas configurações do ot principal.', scOn: 'Ativadas', scEvery: { rare: 'Pouco', normal: 'Normal', often: 'Frequente' }, scPlay: '▶ Jogar uma agora', scPlayed: 'Pronto: começa assim que houver dois ots livres.', scNames: { rocky: 'Rocky', sf: 'Street Fighter', dbz: 'Dragon Ball', matrix: 'Matrix', duel: 'Duelo', sw: 'Star Wars', fight: 'Briga e abraço', twist: 'Twist' },
467
472
  view: 'Visual:', v2d: '2D', v3d: 'Pelúcia 3D', viewNext: 'Pronto: o ot muda na hora.',
468
473
  notesH: 'O que ele sabe de você', notesHint: 'As notas dele. Diga “anote que…” para adicionar.', noNotes: 'Nada ainda.', forget: 'Esquecer', forgetAll: 'Esquecer tudo', sure: 'Clique de novo para esquecer tudo',
469
474
  remH: 'Processos', remHint: 'O que {name} está fazendo por você: lembretes, alertas e os programas que está esperando. Peça “me lembre…”, “me avise se o BTC chegar a 85 mil” ou “me avise quando o build terminar”.', infTotal: 'Últimas {n} chamadas: {in} entrada → {out} saída · {all} tokens', petRuns: 'O que {name} está rodando', pcRuns: 'Neste computador', refreshPs: 'Atualizar', noRems: 'Nada pendente: sem lembretes nem alertas.', psOff: '{name} não vê seus programas. Ative “Processos e apps” para listá-los e esperar um terminar.', psOn: 'Ativar', screenEvery: 'Olha sua tela a cada {n} min', lastSeen: 'última: {what}', priceW: '{coin} {op} {value} {vs}', priceNow: 'agora {p}', procW: '“{m}” {until}', untilExit: 'quando terminar', untilStart: 'quando começar', running: 'rodando', notRunning: 'não está rodando', remind: 'Lembrete', cpu: 'CPU', mem: 'Mem', up: 'Há', prog: 'Programa', cancel: 'Cancelar',
@@ -1161,6 +1166,10 @@
1161
1166
  r.addEventListener('change', () => save({ pet: { view: k } }, $('#petMsg'), t('viewNext')));
1162
1167
  return el('label', { className: 'chip' }, r, t(`v${k}`));
1163
1168
  }));
1169
+ // its art style's background (comic panel, ukiyo-e…) behind the ot, or the ot alone
1170
+ const bd = el('input', { type: 'checkbox', checked: S.config.pet.backdrop !== false });
1171
+ bd.addEventListener('change', () => save({ pet: { backdrop: bd.checked } }, $('#petMsg'), t('viewNext')));
1172
+ $('#view').append(el('label', { className: 'chip', title: t('bdHint') }, bd, ' ', t('bd')));
1164
1173
  }
1165
1174
 
1166
1175
  // ── scenes between ots (pet/electron/director.cjs reads them from GET /scenes) ──
@@ -1207,6 +1216,17 @@
1207
1216
  const n = (S.musicFiles || []).length;
1208
1217
  $('#muFiles').hidden = mode !== 'files';
1209
1218
  $('#muFiles').textContent = t(n ? 'muSome' : 'muNone', { n, dir: '~/.7ots/music' });
1219
+ const en = { onStart: false, kind: 'wwe', dance: '', ...p.entrance };
1220
+ const putE = (e) => put({ entrance: e });
1221
+ $('#enOn').checked = !!en.onStart;
1222
+ $('#enOn').onchange = (e) => putE({ onStart: e.target.checked });
1223
+ $('#enKind').replaceChildren(...['wwe', 'rock', 'magic', 'random'].map((k) => {
1224
+ const r = el('input', { type: 'radio', name: 'enKind', value: k, checked: en.kind === k });
1225
+ r.addEventListener('change', () => putE({ kind: k }));
1226
+ return el('label', { className: 'chip' }, r, (T[lang].enKind || T.en.enKind)[k]);
1227
+ }));
1228
+ $('#enDance').replaceChildren(el('option', { value: '', textContent: t('enAny') }), ...(S.dances || []).map((d) => el('option', { value: d, textContent: d, selected: en.dance === d })));
1229
+ $('#enDance').onchange = (e) => putE({ dance: e.target.value });
1210
1230
  }
1211
1231
  for (const [id, path] of [['#muDance', '/dance'], ['#muEnter', '/entrance']])
1212
1232
  $(id).addEventListener('click', async () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@7ots/cli",
3
- "version": "0.1.11",
3
+ "version": "0.1.12",
4
4
  "description": "7ots.com — your AI companion with a face of its own: a desktop pet that watches over your coding agent (Claude Code and shell hooks), a personal assistant (reminders, alerts, notes, opens sites, sees your screen if allowed) and a reproducible identity (face, personality, voice) for any agent — in apuchat meet calls, Orquesta projects or your own server.",
5
5
  "homepage": "https://7ots.com",
6
6
  "repository": {