create-byan-agent 2.54.0 → 2.58.1

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.
@@ -200,6 +200,15 @@ class ByanApp {
200
200
  <label for="cfg-name">Your Name</label>
201
201
  <input id="cfg-name" type="text" value="${this.escapeHtml(this.config.userName)}" placeholder="Yan">
202
202
  </div>
203
+ <div class="form-group">
204
+ <label for="cfg-project-name">Project Name</label>
205
+ <input id="cfg-project-name" type="text" value="${this.escapeHtml(this.config.projectName || '')}" placeholder="mon-projet">
206
+ </div>
207
+ <div class="form-group">
208
+ <label for="cfg-project-dir">Project Directory</label>
209
+ <input id="cfg-project-dir" type="text" value="${this.escapeHtml(this.config.projectDir || this.status?.projectRoot || '')}" placeholder="/chemin/vers/le/projet">
210
+ <div class="form-hint">Defaults to the directory the wizard was launched from.</div>
211
+ </div>
203
212
  <div class="form-group">
204
213
  <label for="cfg-lang">Communication Language</label>
205
214
  <select id="cfg-lang">
@@ -239,9 +248,13 @@ class ByanApp {
239
248
  readConfigForm() {
240
249
  const nameEl = document.getElementById('cfg-name');
241
250
  const langEl = document.getElementById('cfg-lang');
251
+ const projNameEl = document.getElementById('cfg-project-name');
252
+ const projDirEl = document.getElementById('cfg-project-dir');
242
253
 
243
254
  if (nameEl) this.config.userName = nameEl.value.trim() || 'User';
244
255
  if (langEl) this.config.language = langEl.value;
256
+ if (projNameEl) this.config.projectName = projNameEl.value.trim();
257
+ if (projDirEl) this.config.projectDir = projDirEl.value.trim();
245
258
 
246
259
  const platforms = [];
247
260
  document.querySelectorAll('input[name="platform"]:checked').forEach(el => platforms.push(el.value));
@@ -264,7 +277,8 @@ class ByanApp {
264
277
  ['Language', this.config.language],
265
278
  ['Platforms', this.config.platforms.join(', ') || 'auto-detect'],
266
279
  ['Modules', this.config.modules.join(', ')],
267
- ['Project Root', this.status?.projectRoot || '(auto)']
280
+ ['Project Name', this.config.projectName || '(nom du dossier)'],
281
+ ['Project Root', this.config.projectDir || this.status?.projectRoot || '(auto)']
268
282
  ];
269
283
 
270
284
  container.innerHTML = rows.map(([k, v]) =>
@@ -50,7 +50,12 @@ class ByanWebUI {
50
50
  });
51
51
 
52
52
  return new Promise((resolve) => {
53
- this.server.listen(this.port, () => {
53
+ // Bind to loopback ONLY. Without a host argument Node binds to :: (every
54
+ // interface), which made the installer LAN-reachable — and since it runs
55
+ // the real install engine (file writes + child processes), that exposed
56
+ // an arbitrary-write surface to the local network. A local installer has
57
+ // no business listening off-host.
58
+ this.server.listen(this.port, '127.0.0.1', () => {
54
59
  const addr = this.server.address();
55
60
  const assignedPort = (addr && typeof addr === 'object') ? addr.port : this.port;
56
61
  const url = `http://localhost:${assignedPort}`;
@@ -61,6 +61,25 @@ const METAPHOR_OFFENDERS = Object.freeze([
61
61
  label: 'outil "vivant/mort"',
62
62
  good: 'le fait observe : "repond" / "ne repond pas" + le resultat exact',
63
63
  },
64
+ {
65
+ // BYAN in-house doctrine shorthand dropped raw in prose (field complaint,
66
+ // 2026-07-21). "le rail" means the byan-auto-dispatch workflow; a reader
67
+ // without the internal doctrine cannot decode it — same offence as raw
68
+ // English jargon (IA-26). The article-bound match spares ordinary French
69
+ // ("un rail de guidage", "rail ferroviaire").
70
+ id: 'jargon-doctrine-rail',
71
+ re: /\b(?:le|ce|du)\s+rail\b(?!\s+(?:de|d'|ferroviaire))/i,
72
+ label: '"le rail" (jargon doctrine)',
73
+ good: 'dis-le en clair : le workflow automatique de dispatch (byan-auto-dispatch)',
74
+ },
75
+ {
76
+ // "voie/option armee" means: option enabled AND Codex linked. Say the fact.
77
+ // The noun-bound match spares the ordinary word ("l'armee").
78
+ id: 'jargon-doctrine-armee',
79
+ re: /\b(?:voie|option|lane)\s+(?:est\s+|n'est\s+pas\s+)?arm[ée]e?s?\b/i,
80
+ label: 'voie/option "armee" (jargon doctrine)',
81
+ good: 'dis le fait : option activee ET Codex connecte (ou pas)',
82
+ },
64
83
  ]);
65
84
 
66
85
  // A word boundary that treats accented letters as part of a word, so \btier\b
@@ -21,6 +21,12 @@
21
21
  // format against projets.acadenice.com. Items tagged VERIFY@F0 are the ones the
22
22
  // recon could not confirm without a live call.
23
23
 
24
+ // Config resolution goes through resolve-config (env -> ~/.byan/credentials.json
25
+ // -> empty), the same chain the rest of the server uses. Reading process.env
26
+ // directly here was the gap that made the per-user credentials file invisible
27
+ // to the Leantime client.
28
+ import { resolveConfig } from './resolve-config.js';
29
+
24
30
  const DEFAULT_TIMEOUT_MS = 5000;
25
31
  const RPC_PATH = '/api/jsonrpc';
26
32
 
@@ -62,11 +68,11 @@ const DEFAULT_STATUS_MAP = {
62
68
  };
63
69
 
64
70
  function apiBase() {
65
- return (process.env.LEANTIME_API_URL || '').replace(/\/+$/, '');
71
+ return (resolveConfig().LEANTIME_API_URL || '').replace(/\/+$/, '');
66
72
  }
67
73
 
68
74
  function apiToken() {
69
- return process.env.LEANTIME_API_TOKEN || '';
75
+ return resolveConfig().LEANTIME_API_TOKEN || '';
70
76
  }
71
77
 
72
78
  // Leantime authenticates the JSON-RPC API with its own header, NOT an
@@ -86,3 +86,14 @@ dev leaf holds the Bash tool and is what actually invokes `codex exec`.
86
86
  `codex mcp-server` is wired, Codex becomes a tool Claude can call mid-reasoning
87
87
  (and Codex can call BYAN tools back) — the closest thing to live. It drops in as a
88
88
  new transport behind the same F2 seam, with no change to F1 or the loop.
89
+
90
+ ## Config des integrations (Leantime, Google) — une seule memoire
91
+
92
+ Depuis 2.56.0, le client Leantime du serveur MCP resout sa config par la meme
93
+ chaine que le reste du serveur : variables d'environnement d'abord, puis
94
+ `~/.byan/credentials.json`, ecrit par l'installeur a la premiere saisie. Google
95
+ suit le meme fichier (`GOOGLE_APPLICATION_CREDENTIALS`, `GDOC_TEMPLATE_ID`,
96
+ `GDOC_LOGO_PNG_URL`, deja compris par `resolve-config.js`) : l'acces Google
97
+ passe par une cle de service account dont le CHEMIN est memorise — le portage
98
+ d'un OAuth interactif complet dans le serveur MCP reste hors perimetre (le
99
+ serveur tourne sans navigateur), c'est le cadrage assume.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-byan-agent",
3
- "version": "2.54.0",
3
+ "version": "2.58.1",
4
4
  "description": "BYAN v2.8 - Intelligent AI agent creator with ELO trust system + scientific fact-check + Hermes universal dispatcher + native Claude Code integration (hooks, skills, MCP server). Multi-platform (Claude Code, Codex). Merise Agile + TDD + 71 Mantras. ~54% LLM cost savings.",
5
5
  "main": "src/index.js",
6
6
  "bin": {