@yorha2b-lab/autodev 7.0.0 → 7.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/bin/bunker.js CHANGED
@@ -7,6 +7,7 @@ const { program } = require('commander')
7
7
  const local = Intl.DateTimeFormat().resolvedOptions().locale.toUpperCase()
8
8
 
9
9
  const { matchDialog, terminalCollapse } = require('../src/logistics/presenter')
10
+
10
11
  const recruiter = require('../src/headquarters/recruiter')
11
12
  const dialogues = recruiter(path.join(__dirname, '../src/dialogues'))
12
13
  const dialog = matchDialog(local, dialogues) ?? dialogues['EN-US']
@@ -59,7 +60,7 @@ program
59
60
  return
60
61
  }
61
62
  require('../src/headquarters/observer')(bunker)
62
- result.yorha.operator6O.report(result.dialog.operator6O.call2B)
63
+ result.yorha.operator6O.report(dialog.operator6O.call2B)
63
64
  process.on('SIGINT', () => {
64
65
  result.yorha.commander.report(dialog.bunker.systemOffline, 'gray')
65
66
  result.labs?.scout?.close()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yorha2b-lab/autodev",
3
- "version": "7.0.0",
3
+ "version": "7.1.0",
4
4
  "description": "基于 AI 视觉与语义协议的前端 (React+Antd) 代码构筑与旧系统重构引擎",
5
5
  "bin": {
6
6
  "bunker": "bin/bunker.js"
@@ -9,6 +9,8 @@ module.exports = {
9
9
 
10
10
  const recruiter = require('../headquarters/recruiter')
11
11
  const logistics = recruiter(path.join(__dirname, '../logistics'))
12
+ const headquarters = recruiter(path.join(__dirname, '../headquarters'))
13
+
12
14
  const yorha = logistics.presenter.yorha()
13
15
 
14
16
  const builderPath = path.join(__dirname, `../workshop/${template}/builder`)
@@ -22,8 +24,8 @@ module.exports = {
22
24
  dialog,
23
25
  template,
24
26
  logistics,
27
+ headquarters,
25
28
  units: recruiter(path.join(__dirname, '../units')),
26
- designer: require('../headquarters/designer')({ logistics, template }),
27
29
  briefings: recruiter(path.join(__dirname, `../workshop/${template}/briefings`)),
28
30
  }
29
31
 
@@ -43,11 +43,15 @@ module.exports = {
43
43
  desc: 'AI-powered frontend CRUD code generator',
44
44
  dataSynced: 'All data synced to Bunker storage nodes',
45
45
  initDesc: 'Initialize Bunker construction environment',
46
+ missionUnknown: 'Unable to classify mission requirements.',
46
47
  star: 'If it saves you time, feel free to give it a ⭐ on GitHub',
47
48
  copyTemplateError: virus => `Template construction failed: ${virus}`,
48
49
  towerOnline: port => `Signal Intercept Tower Online [Band: ${port}]`,
50
+ confirmEnemy: 'Target confirmed. Deploying the most suitable unit...',
51
+ missionFailed: 'Mission assignment failed. No suitable unit available.',
49
52
  linkSevered: 'Link Severed: Check network status or Black Box resonance',
50
53
  systemOffline: 'Disconnecting Neural Link, Executing Physical Assembly...',
54
+ detectedEnemy: 'Unidentified entity detected. Initiating combat analysis...',
51
55
  accessDenied: 'YoRHa Command Center Access Denied: Invalid API Key or quota exhausted!',
52
56
  bootDesc: 'Start full-channel linked monitoring: Coordinated Page/Part/API construction',
53
57
  copyEnum: `│ Backend Enums detected \n│ Weld the code below into the module's resource center`,
@@ -41,9 +41,13 @@ module.exports = {
41
41
  desc: 'Générateur de code CRUD frontend piloté par IA',
42
42
  envCheck: 'Fichier .env existant détecté. Génération ignorée',
43
43
  configCheck: 'Fichier config.js existant détecté. Génération ignorée',
44
+ missionUnknown: 'Impossible de déterminer les exigences de la mission.',
44
45
  copyTemplateError: virus => `Échec de construction du modèle : ${virus}`,
46
+ confirmEnemy: 'Cible confirmée. Déploiement de l’unité la plus adaptée...',
47
+ detectedEnemy: 'Cible non identifiée détectée. Lancement de l’analyse tactique...',
45
48
  accessDenied: 'Accès au quartier général refusé : clé API invalide ou quota épuisé',
46
49
  towerOnline: port => `Tour d’interception des signaux en ligne [Fréquence : ${port}]`,
50
+ missionFailed: 'Échec de l’attribution de la mission. Aucune unité appropriée trouvée.',
47
51
  bootDesc: 'Démarrer la surveillance multi-canaux : construction coordonnée Page/Part/API',
48
52
  initDesc: 'Initialiser l’environnement de construction du Bunker dans le répertoire actuel',
49
53
  towerConnected: port => `Ordre : configurez votre cible proxy vers http://localhost:${port}`,
@@ -37,18 +37,22 @@ module.exports = {
37
37
  envCopy: '.envストレージ保存完了',
38
38
  systemStandby: 'システム待機状態...',
39
39
  configCopy: 'config.jsストレージ保存完了',
40
+ missionUnknown: 'ミッション要件を特定できません。',
40
41
  desc: 'AI駆動型フロントエンドCRUDコード生成システム',
41
42
  initDesc: '現在のディレクトリにBunker構築環境を初期化',
42
43
  argDesc: 'フロントエンドフレームワークテンプレートを指定',
43
44
  envCheck: '既存の.envファイルを検出。生成処理をスキップ',
45
+ confirmEnemy: '目標を確認。最適戦闘ユニットを展開します...',
46
+ detectedEnemy: '未確認対象を検知。戦術分析を開始します...',
44
47
  dataSynced: '全構築データをBunkerストレージノードへ同期完了',
45
- configCheck: '既存のconfig.jsファイルを検出。生成処理をスキップ',
46
48
  copyTemplateError: virus => `テンプレート構築失敗: ${virus}`,
49
+ configCheck: '既存のconfig.jsファイルを検出。生成処理をスキップ',
47
50
  star: 'このシステムが役立った場合、GitHubでスターをお願いします ⭐',
48
51
  towerOnline: port => `シグナル迎撃塔オンライン [周波数: ${port}]`,
49
52
  bootDesc: '全チャンネル連携監視を開始:Page/Part/API協調構築をサポート',
50
53
  systemOffline: 'ニューラルクラウド接続を切断中。データを物理封印します...',
51
54
  accessDenied: '司令部アクセス拒否:API Keyが無効、または利用上限に達しています',
55
+ missionFailed: 'ミッションの割り当てに失敗。適合する戦闘ユニットが見つかりません。',
52
56
  linkSevered: '接続断絶:ネットワーク状態またはブラックボックス共鳴を確認してください',
53
57
  disclaimer: '解析結果は参考情報です。最終判断は各ユニットが実環境に基づいて行ってください',
54
58
  towerConnected: port => `指令:プロキシ対象を http://localhost:${port} に設定してください`,
@@ -39,9 +39,11 @@ module.exports = {
39
39
  argDesc: 'Указать шаблон frontend-фреймворка',
40
40
  desc: 'AI-система генерации frontend CRUD-кода',
41
41
  systemStandby: 'Система находится в режиме ожидания...',
42
+ missionUnknown: 'Не удалось определить требования миссии.',
42
43
  copyTemplateError: virus => `Ошибка сборки шаблона: ${virus}`,
43
44
  initDesc: 'Инициализация среды сборки Bunker в текущем каталоге',
44
45
  envCheck: 'Обнаружен существующий файл .env. Генерация пропущена',
46
+ detectedEnemy: 'Обнаружена неизвестная цель. Начинаю тактический анализ...',
45
47
  dataSynced: 'Все данные сборки синхронизированы с узлом хранения Bunker',
46
48
  configCheck: 'Обнаружен существующий файл config.js. Генерация пропущена',
47
49
  towerOnline: port => `Башня перехвата сигналов активна [Частота: ${port}]`,
@@ -50,6 +52,8 @@ module.exports = {
50
52
  towerConnected: port => `Приказ: направьте прокси-цель на http://localhost:${port}`,
51
53
  star: 'Если эта система помогла вам сэкономить время, поставьте звезду на GitHub ⭐',
52
54
  linkSevered: 'Соединение разорвано: проверьте состояние сети или резонанс чёрного ящика',
55
+ missionFailed: 'Назначение миссии не удалось. Подходящее боевое подразделение не найдено.',
56
+ confirmEnemy: 'Цель подтверждена. Развёртывание наиболее подходящего боевого подразделения...',
53
57
  systemOffline: 'Отключение нейронного облачного соединения. Физическое запечатывание данных...',
54
58
  frameworkNotSupported: template => `Фреймворк [${template}] пока не поддерживается. Pull Request приветствуются`,
55
59
  disclaimer: 'Результаты сопоставления являются справочными. Каждая единица должна выполнить собственную корректировку',
@@ -39,11 +39,15 @@ module.exports = {
39
39
  systemStandby: '系统待机中...',
40
40
  desc: 'AI驱动的前端CRUD代码生成器',
41
41
  configCopy: 'config.js 存储完毕',
42
+ missionUnknown: '无法解析任务需求。',
42
43
  initDesc: '在当前目录初始化地堡构筑环境',
43
44
  envCheck: '终端已存在 .env 文件,跳过生成',
45
+ confirmEnemy: '目标确认。正在部署最适作战单位...',
44
46
  dataSynced: '所有构筑数据已同步至 Bunker 存储节点',
47
+ missionFailed: '任务分配失败。未找到适配作战单位。',
45
48
  configCheck: '终端已存在 config.js 文件,跳过生成',
46
49
  linkSevered: '连接中断:请检查网络状态或黑盒共鸣情况',
50
+ detectedEnemy: '检测到未知目标。开始执行战术分析...',
47
51
  systemOffline: '正在断开神经云链接,执行数据物理封存...',
48
52
  copyTemplateError: virus => `模板构筑失败: ${virus}`,
49
53
  star: '如果它能帮您节省时间,请在 GitHub 上给它点个赞 ⭐',
@@ -1,20 +1,37 @@
1
+ /**
2
+ * YoRHa Bunker Construction System
3
+ * This file is part of Bunker.
4
+ * Bunker is free software: you can redistribute it and/or modify
5
+ * it under the terms of the GNU Affero General Public License as
6
+ * published by the Free Software Foundation, either version 3 of the
7
+ * License, or (at your option) any later version.
8
+ * (c) 2026 [yorha2b-lab]. Glory to Mankind.
9
+ */
10
+
1
11
  module.exports = bunker => {
2
12
 
3
13
  const acp = bunker.get()
4
- const dispatcher = require('../headquarters/dispatcher')(acp, 2)
14
+ const dispatcher = acp.headquarters.dispatcher(acp, 2)
5
15
 
6
16
  dispatcher.onIdle(() => acp.yorha.commander.report(acp.dialog.bunker.systemStandby, 'gray'))
7
17
 
8
18
  return {
9
19
  receive: async mission => {
10
- const result = await acp.llm.recognizePage({ filePath: mission.input, prompt: acp.briefings.visionType })
11
- const unit = Object.values(acp.units).map(unit => ({ unit, score: unit.meta.capabilities.filter(cap => result.capabilities.includes(cap)).length }))
12
- .filter(item => item.score > 0)
13
- .sort((a, b) => b.score - a.score)[0]?.unit
14
- if (!unit) {
15
- return
20
+ const spinner = acp.yorha.commander.start(acp.dialog.bunker.detectedEnemy)
21
+ try {
22
+ const result = await acp.llm.recognizePage({ filePath: mission.input, prompt: acp.briefings.visionType })
23
+ acp.yorha.commander.success(spinner, acp.dialog.bunker.confirmEnemy)
24
+ const unit = Object.values(acp.units).map(unit => ({ unit, score: unit.meta.capabilities.filter(cap => result.capabilities.includes(cap)).length }))
25
+ .filter(item => item.score > 0)
26
+ .sort((a, b) => b.score - a.score)[0]?.unit
27
+ if (!unit) {
28
+ acp.yorha.commander.fail(spinner, acp.dialog.bunker.missionFailed)
29
+ return
30
+ }
31
+ dispatcher.add(() => unit.execute({ acp, mission }))
32
+ } catch (error) {
33
+ acp.yorha.commander.fail(spinner, acp.dialog.bunker.missionUnknown)
16
34
  }
17
- dispatcher.add(() => unit.execute({ acp, mission }))
18
35
  },
19
36
  }
20
37
  }
@@ -5,7 +5,7 @@ module.exports = ({ template, logistics }) => {
5
5
  const Handlebars = require('handlebars')
6
6
 
7
7
  Handlebars.registerHelper('raw', opt => opt.fn())
8
- Handlebars.registerHelper('stringify', (context, maxLength = 200) => context ? new Handlebars.SafeString(logistics.builder.contextStringify({ context, maxLength })) : '[]')
8
+ Handlebars.registerHelper('stringify', (context, maxLength = 200) => context ? new Handlebars.SafeString(logistics.formater.contextStringify({ context, maxLength })) : '[]')
9
9
 
10
10
  const { hbsDir } = logistics.supporter.getConfig()
11
11
  const tplDir = !!hbsDir ? path.join(process.cwd(), hbsDir) : path.join(__dirname, `../workshop/${template}/blueprint`)
@@ -13,7 +13,7 @@ module.exports = ({ template, logistics }) => {
13
13
 
14
14
  fs.readdirSync(moldsDir).forEach(file => {
15
15
  if (file.endsWith('.hbs')) {
16
- const name = path.basename(file, '.hbs') // 去掉后缀拿名字
16
+ const name = path.basename(file, '.hbs')
17
17
  const content = fs.readFileSync(path.join(moldsDir, file), 'utf-8')
18
18
  Handlebars.registerPartial(name, `${content}\n`)
19
19
  }
@@ -1,4 +1,4 @@
1
- module.exports = ({ yorha, dialog }, concurrency = 1) => {
1
+ module.exports = (acp, concurrency = 1) => {
2
2
 
3
3
  let running = 0
4
4
  let queue = []
@@ -14,7 +14,7 @@ module.exports = ({ yorha, dialog }, concurrency = 1) => {
14
14
  try {
15
15
  await task()
16
16
  } catch (err) {
17
- yorha.pod153.report(dialog.pod153.signalLinkFault(err.message), 'red')
17
+ acp.yorha.pod153.report(acp.dialog.pod153.signalLinkFault(err.message), 'red')
18
18
  } finally {
19
19
  running--
20
20
  next()
@@ -15,7 +15,7 @@ module.exports = bunker => {
15
15
 
16
16
  missionWatcher.on('add', filePath => {
17
17
  if (['.png', '.jpg', '.jpeg', '.webp'].includes(path.extname(filePath))) {
18
- commander.receive({ input: filePath, type: 'file-added' })
18
+ commander.receive({ input: filePath })
19
19
  }
20
20
  })
21
21
 
@@ -0,0 +1,82 @@
1
+ const fs = require('fs')
2
+ const path = require('path')
3
+ const chalk = require('chalk')
4
+
5
+ module.exports = async ({ data, fileName }) => {
6
+
7
+ const { llm, labs, yorha, dialog, logistics } = require('../awakening').get()
8
+
9
+ const { nineS, pod153 } = yorha
10
+ const { alignResponseFields } = llm
11
+ const { cleanCode } = logistics.formater
12
+ const { pagesDir } = logistics.supporter.getConfig()
13
+
14
+ const startTime = Date.now()
15
+ const resourcePath = path.join(process.cwd(), pagesDir, fileName, 'resource.js')
16
+ const enumParams = (await labs?.council)?.[fileName] ?? '{}'
17
+
18
+ const spinner = pod153.start(dialog.pod153.reconEncryptedData(fileName))
19
+
20
+ try {
21
+ if (!fs.existsSync(resourcePath)) {
22
+ pod153.fail(spinner, dialog.pod153.unknownModule(fileName))
23
+ return
24
+ }
25
+
26
+ let resourceStr = fs.readFileSync(resourcePath, 'utf8')
27
+
28
+ nineS.update(spinner, dialog.nineS.scanningField)
29
+
30
+ const extractKeys = str => {
31
+ const keys = []
32
+ const regex = /(dataIndex|name)\s*:\s*['"]([^'"]+)['"]/g
33
+ let match
34
+ while ((match = regex.exec(str)) !== null) {
35
+ keys.push(match[2])
36
+ }
37
+ return Array.from(new Set(keys.filter(key => key !== 'index')))
38
+ }
39
+
40
+ const result = await alignResponseFields({ responseStr: JSON.stringify(data), resourceStr: extractKeys(resourceStr).join(',') })
41
+ let changeCount = 0
42
+ const resultMapping = {}
43
+ Object.entries(result).forEach(([oldField, newField]) => {
44
+ if (oldField === newField) return
45
+ const regex = new RegExp(`(dataIndex|name)\\s*:\\s*['"]${oldField}['"]`, 'g')
46
+ resourceStr = resourceStr.replace(regex, `$1: '${newField}'`)
47
+ changeCount++
48
+ resultMapping[oldField] = newField
49
+ })
50
+
51
+ fs.writeFileSync(resourcePath, resourceStr)
52
+ const endTime = Date.now()
53
+
54
+ pod153.success(spinner, dialog.pod153.bridgeProtocolComplete(changeCount, (endTime - startTime) / 1000))
55
+
56
+ if (changeCount > 0) {
57
+ console.log(chalk.magenta(`\n┌────── [ YoRHa Autonomous Backend Alignment ] ──────┐`))
58
+ const maxOldFieldLength = Math.max(...Object.keys(resultMapping).map(key => key.length))
59
+ Object.entries(resultMapping).forEach(([oldField, newField]) => {
60
+ const padding = ' '.repeat(Math.max(1, maxOldFieldLength + 1 - oldField.length))
61
+ console.log(
62
+ chalk.yellow(` │ `) +
63
+ chalk.yellow(oldField) +
64
+ padding +
65
+ chalk.cyan(` -> `) +
66
+ chalk.white(newField)
67
+ )
68
+ })
69
+ console.log(chalk.magenta(`└────────────────────────────────────────────────────┘`))
70
+ }
71
+
72
+ if (enumParams !== '{}') {
73
+ console.log(chalk.magenta(`\n┌──────── [ YoRHa Physical Assembly: Enum Genomes ] ────────┐`))
74
+ console.log(chalk.gray(dialog.bunker.copyEnum))
75
+ console.log(chalk.white(cleanCode(enumParams)))
76
+ console.log(chalk.magenta(`├───────────────────────────────────────────────────────────┘`))
77
+ }
78
+
79
+ } catch (error) {
80
+ pod153.fail(spinner, dialog.pod153.alignmentFailed(error))
81
+ }
82
+ }
@@ -1,13 +1,3 @@
1
- /**
2
- * YoRHa Bunker Construction System
3
- * This file is part of Bunker.
4
- * Bunker is free software: you can redistribute it and/or modify
5
- * it under the terms of the GNU Affero General Public License as
6
- * published by the Free Software Foundation, either version 3 of the
7
- * License, or (at your option) any later version.
8
- * (c) 2026 [yorha2b-lab]. Glory to Mankind.
9
- */
10
-
11
1
  const fs = require('fs')
12
2
  const path = require('path')
13
3
 
@@ -1,11 +1,11 @@
1
- const fs = require('fs')
2
- const path = require('path')
3
-
4
1
  module.exports = async ({ llm, yorha, dialog, logistics }) => {
5
2
 
3
+ const fs = require('fs')
4
+ const path = require('path')
5
+
6
6
  const { apiParser } = llm
7
7
  const { pod153, commander } = yorha
8
- const { contextStringify } = logistics.builder
8
+ const { contextStringify } = logistics.formater
9
9
  const { apiDoc, pagesDir } = logistics.supporter.getConfig()
10
10
  const { getLocalScore, getSemanticKeywords } = logistics.analyzer
11
11
 
@@ -59,7 +59,7 @@ module.exports = async ({ llm, yorha, dialog, logistics }) => {
59
59
  .slice(0, 20) // 💡 拓宽至前 20 名,给 AI 更多的判别空间
60
60
 
61
61
  const finalCandidates = candidates.map(item => `${item.method} ${item.path} ${item.desc}`).join('\n')
62
- pod153.report(dialog.pod153.inactiveModule(fileName), 'yellow')
62
+ const spinner = pod153.start(dialog.pod153.inactiveModule(fileName), 'yellow')
63
63
  // 3. 驱动 9S 最终裁决
64
64
  const result = await apiParser({ bunkerAnchors, realApis: finalCandidates })
65
65
 
@@ -98,7 +98,7 @@ module.exports = async ({ llm, yorha, dialog, logistics }) => {
98
98
  })
99
99
 
100
100
  fs.writeFileSync(indexPath, indexCode)
101
- pod153.report(dialog.pod153.signalSynchronized(Object.keys(result).length))
101
+ pod153.success(spinner, dialog.pod153.signalSynchronized(Object.keys(result).length))
102
102
  // 💡 战术免责补丁:采用橙黄色高亮,提醒指挥官保持警惕
103
103
  commander.report(dialog.bunker.disclaimer, 'yellow')
104
104
  }
package/src/labs/scout.js CHANGED
@@ -1,10 +1,10 @@
1
- const fs = require('fs')
2
- const path = require('path')
3
-
4
1
  let globalBrowser = null
5
2
 
6
3
  module.exports = ({ yorha, dialog }) => {
7
4
 
5
+ const fs = require('fs')
6
+ const path = require('path')
7
+
8
8
  const { pod042 } = yorha
9
9
 
10
10
  const isHttpURL = str => {
package/src/labs/tower.js CHANGED
@@ -1,4 +1,4 @@
1
- module.exports = ({ units, yorha, dialog, logistics }) => {
1
+ module.exports = ({ units, yorha, dialog, logistics, headquarters }) => {
2
2
 
3
3
  const http = require('http')
4
4
  const zlib = require('zlib')
@@ -39,7 +39,7 @@ module.exports = ({ units, yorha, dialog, logistics }) => {
39
39
  return
40
40
  }
41
41
  pod153.report(dialog.pod153.capturedRuntimeSignal(fileName))
42
- await units.reconciler.execute({ fileName, data: [coreData[0]] })
42
+ await headquarters.reconciler({ fileName, data: [coreData[0]] })
43
43
  hackedRegistry.set(fileName, fingerprint)
44
44
  } catch (e) {
45
45
  // 非 JSON 信号,保持静默
@@ -1,5 +1,3 @@
1
- const fs = require('fs')
2
-
3
1
  module.exports = {
4
2
  meta: {
5
3
  name: 'raider',
@@ -10,6 +8,7 @@ module.exports = {
10
8
  },
11
9
  execute: async ({ acp, mission }) => {
12
10
 
11
+ const fs = require('fs')
13
12
  const chalk = require('chalk')
14
13
  const { llm, yorha, dialog, builder, logistics, briefings } = acp
15
14
 
@@ -17,7 +16,7 @@ module.exports = {
17
16
  const { raider } = briefings
18
17
  const { recognizePage } = llm
19
18
  const { formatFormItemAndColumns } = builder
20
- const { cleanCode, contextStringify } = logistics.builder
19
+ const { cleanCode, contextStringify } = logistics.formater
21
20
 
22
21
  const startTime = Date.now()
23
22
 
@@ -1,6 +1,3 @@
1
- const fs = require('fs')
2
- const path = require('path')
3
-
4
1
  module.exports = {
5
2
  meta: {
6
3
  name: 'striker',
@@ -11,12 +8,15 @@ module.exports = {
11
8
  },
12
9
  execute: async ({ acp, mission }) => {
13
10
 
11
+ const fs = require('fs')
12
+ const path = require('path')
13
+
14
14
  const { llm, yorha, dialog, builder, template, logistics, briefings } = acp
15
15
 
16
16
  const { striker } = briefings
17
17
  const { nineS, pod042 } = yorha
18
18
  const { index, resource } = builder
19
- const { contextStringify } = logistics.builder
19
+ const { contextStringify } = logistics.formater
20
20
  const { generateMock, recognizePage, nameSimilarity } = llm
21
21
  const { useDemo, pagesDir, utilsDir, needMock } = logistics.supporter.getConfig()
22
22
 
@@ -42,10 +42,10 @@ module.exports = {
42
42
  pageConfig = await recognizePage({ prompt: striker, filePath: mission.input, schema: require(`../workshop/${template}/protocols/striker.json`) })
43
43
  }
44
44
 
45
- const { similarity } = await nameSimilarity({ fileName, english: pageConfig.title.english })
45
+ const { similarity } = await nameSimilarity({ fileName, english: pageConfig.title?.english })
46
46
  if (similarity === 0) {
47
- fileName = pageConfig.title.english
48
- targetDir = path.join(process.cwd(), pagesDir, pageConfig.title.english)
47
+ fileName = pageConfig.title?.english
48
+ targetDir = path.join(process.cwd(), pagesDir, pageConfig.title?.english)
49
49
  if (fs.existsSync(targetDir)) {
50
50
  targetDir = `${targetDir}_temp`
51
51
  }
@@ -9,6 +9,9 @@ module.exports = `
9
9
  - **严禁中文**: 绝对禁止在变量名、键名中使用中文字符。
10
10
  - **屏蔽关键字**: 禁止使用 JS 保留字 (export, delete, const, let, class, default 等)。
11
11
 
12
+ ## 页面标题 (title)
13
+ - **格式**: {title:{english:'页面标题[英文]',chinese:'页面标题[中文]'}}
14
+
12
15
  ## 零部件构筑规范 (Component Specifications)
13
16
 
14
17
  ## 标签页 (tabs)
@@ -1,8 +1,8 @@
1
- module.exports = ({ designer, logistics }) => {
1
+ module.exports = ({ template, logistics, headquarters }) => {
2
2
 
3
- const { indexTpl, resourceTpl } = designer
4
- const { wrapCode, cleanCode, contextStringify } = logistics.builder
3
+ const { wrapCode, cleanCode, contextStringify } = logistics.formater
5
4
  const { needMock, responseSuccess } = logistics.supporter.getConfig()
5
+ const { indexTpl, resourceTpl } = headquarters.designer({ template, logistics })
6
6
 
7
7
  const formatFormItemAndColumns = ({ pageConfig }) => {
8
8
 
@@ -87,7 +87,7 @@ module.exports = ({ designer, logistics }) => {
87
87
 
88
88
  const hasTabs = pageConfig.tabs?.length > 0
89
89
  const hasFormItems = pageConfig.formItems?.length > 0
90
- const tabKeys = pageConfig.tabs?.map(tab => tab.key).sort((a, b) => a.length - b.length)
90
+ const tabKeys = pageConfig.tabs?.map(tab => tab.key).sort((a, b) => a.length - b.length) ?? []
91
91
  const optionDict = pageConfig.optionList?.reduce((acc, item) => ({ ...acc, [item.name]: item.options }), {})
92
92
 
93
93
  const columnsData = processedColumns.filter(item => !['操作', 'operation'].includes(item.title?.toLowerCase()))?.map(item => {
@@ -101,10 +101,10 @@ module.exports = ({ designer, logistics }) => {
101
101
  hasFormItems,
102
102
  tabs: pageConfig.tabs,
103
103
  dictBlocks: dictBlocks.map(item => ({ name: item, data: optionDict[item] ?? [] })),
104
- tabColumns: contextStringify({ context: Object.fromEntries(tabKeys.map(tab => [tab, wrapCode('commonColumns')])), maxLength: 100 }),
104
+ tabColumns: contextStringify({ context: Object.fromEntries(tabKeys?.map(tab => [tab, wrapCode('commonColumns')])), maxLength: 100 }),
105
105
  formItemsData: !hasTabs ?
106
106
  `export const formItems = ${contextStringify({ context: formItems, maxLength: 120 })}` :
107
- `const searchItems = ${contextStringify({ context: formItems, maxLength: 120 })}\n\nexport const formItems = ${contextStringify({ context: Object.fromEntries(tabKeys.map(tab => [tab, wrapCode('searchItems')])), maxLength: 100 })}`,
107
+ `const searchItems = ${contextStringify({ context: formItems, maxLength: 120 })}\n\nexport const formItems = ${contextStringify({ context: Object.fromEntries(tabKeys?.map(tab => [tab, wrapCode('searchItems')])), maxLength: 100 })}`,
108
108
  }
109
109
 
110
110
  const bodyCode = resourceTpl(viewData)
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Mock-Datengenerierung abgeschlossen',
4
- scanningField: 'Analyse der Feldabweichungen zwischen Frontend und Backend läuft... Semantische Brücke wird aktiviert',
5
- dataCamouflage: fileName => `Ziel-Firewall wird durchbrochen... Datenverschleierungsprotokoll wird ausgeführt [${fileName}]`,
6
- },
7
- pod042: {
8
- capturedToast: 'Visuelle Daten erfasst. Übertragung wird gestartet...',
9
- startScout: 'Aktivieren des [Taktischen Rechtsklick-Schnappschuss]-Modus...',
10
- partialConstruction: time => `Bericht: Teilkonstruktion abgeschlossen. Dauer: ${time}s`,
11
- extractingUiMetadata: 'UI-Metadaten werden aus dem neuronalen Cloud-Netzwerk extrahiert...',
12
- simulate: 'Echte Anfrage erkannt. Standard-Simulationspaket example.json wird bereitgestellt',
13
- partialRecommendation: '│ Empfehlung: Den obigen Codeblock manuell in die Zieldatei integrieren',
14
- capturedPage: pageName => `Seite erfasst [${pageName}] -> In das Verzeichnis mission übertragen`,
15
- visualPartCaptured: 'Lokales visuelles Fragment erkannt. „Fragment-Konstruktionsprotokoll“ wird gestartet',
16
- uploadVisualMetadata: 'Visuelle Metadaten werden an die Zentrale übertragen. Semantische Analyse wird gestartet...',
17
- partialConstructionAborted: virus => `[Warnung] Fragment-Konstruktion fehlgeschlagen. Logische Störung erkannt: ${virus}`,
18
- constructionAborted: virus => `Konstruktion abgebrochen. Logischer Virus oder Verbindungszeitüberschreitung erkannt: ${virus}`,
19
- scoutReady: '[Rechtsklick-Schnappschuss Bereit] Klicken Sie mit der rechten Maustaste auf eine beliebige Stelle der Webseite.',
20
- intercept: fileName => `Modul [${fileName}] befindet sich bereits in der Bunker-Datenbank. Überschreiben zum Schutz der Daten verhindert`,
21
- visualCaptured: fileName => `Visuelle Erfassung abgeschlossen: [${fileName}]. Bunker-Ressourcen werden geladen und physische Konstruktion gestartet`,
22
- assemblyComplete: (fileName, time) => `Konstruktionsprotokoll abgeschlossen. Modul [${fileName}] erfolgreich implementiert. Dauer: ${time}s, Menü-Routenkonfiguration wird mit Bunker synchronisiert`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `Signalverbindungsfehler: ${virus}`,
26
- signalSynchronized: count => `${count} Knoten synchronisiert. Energieversorgung bestätigt`,
27
- autonomousAddressing: '„Vollkanal-Autoadressierungsprotokoll [Semantische Analyseversion]“ wird aktiviert...',
28
- inactiveModule: fileName => `Nicht aktiviertes Modul [${fileName}] erkannt. Hochpräzise Analyse durch 9S angefordert`,
29
- alignmentFailed: virus => `Signalsynchronisierung fehlgeschlagen. API-Daten durch starke Firewall blockiert: ${virus}`,
30
- reconEncryptedData: fileName => `Verschlüsselte Datenquelle [${fileName}] erkannt. Semantische Synchronisierung wird versucht`,
31
- bridgeProtocolComplete: (count, time) => `Semantische Brücke abgeschlossen. ${count} Feldabweichungen korrigiert. Dauer: ${time}s`,
32
- capturedRuntimeSignal: fileName => `Laufzeitsignal [${fileName}] abgefangen. Automatisches Synchronisationsprotokoll wird gestartet`,
33
- unknownModule: fileName => `Keine Ressourcendaten für Modul [${fileName}] in der Bunker-Datenbank gefunden. Bitte zuerst visuelle Konstruktion ausführen`,
34
- },
35
- bunker: {
36
- exit: 'Systemsignal verloren...',
37
- envCopy: '.env-Speicherung abgeschlossen',
38
- argDesc: 'Frontend-Framework-Template auswählen',
39
- configCopy: 'config.js-Speicherung abgeschlossen',
40
- desc: 'KI-gesteuertes Frontend-CRUD-Codegenerierungssystem',
41
- systemStandby: 'System befindet sich im Bereitschaftsmodus...',
42
- envCheck: 'Vorhandene .env-Datei erkannt. Erstellung übersprungen',
43
- towerOnline: port => `Signal-Abfangturm online [Frequenz: ${port}]`,
44
- configCheck: 'Vorhandene config.js-Datei erkannt. Erstellung übersprungen',
45
- copyTemplateError: virus => `Template-Konstruktion fehlgeschlagen: ${virus}`,
46
- initDesc: 'Bunker-Konstruktionsumgebung im aktuellen Verzeichnis initialisieren',
47
- linkSevered: 'Verbindung getrennt: Netzwerkstatus oder Blackbox-Resonanz prüfen',
48
- towerConnected: port => `Befehl: Proxy-Ziel auf http://localhost:${port} setzen`,
49
- bootDesc: 'Überwachung aller Kanäle starten: Page/Part/API-Konstruktion unterstützt',
50
- accessDenied: 'Zentralzugriff verweigert: API-Key ungültig oder Kontingent erschöpft',
51
- dataSynced: 'Alle Konstruktionsdaten wurden mit dem Bunker-Speicherknoten synchronisiert',
52
- systemOffline: 'Neuronale Cloud-Verbindung wird getrennt. Daten werden physisch versiegelt...',
53
- star: 'Wenn dieses System Ihnen Zeit spart, geben Sie dem Projekt bitte einen Stern auf GitHub ⭐',
54
- frameworkNotSupported: template => `[${template}] Framework wird derzeit nicht unterstützt. Pull Requests willkommen`,
55
- networkInstability: count => `Neuronale Cloud-Verbindung instabil. Wiederverbindung wird versucht... (Versuch ${count})`,
56
- disclaimer: 'Analyseergebnis dient nur als Referenz. Die endgültige Entscheidung muss durch die jeweiligen Einheiten getroffen werden',
57
- copyEnum: '│ Backend-Geninformationen (Enum) erkannt\n│ Empfehlung: Den folgenden Codeblock manuell in das Ressourcenmodul integrieren',
58
- strategicThreshold: (target, current) => `Physische Klonanzahl hat strategischen Schwellenwert ${target} überschritten! Aktuelle Stärke: ${current}`,
59
- initComplete: cmd => `Bunker-Bereitstellung abgeschlossen. Für schnelleren Einsatz bitte [manuell installieren]: ${cmd} zu package.json scripts hinzufügen`,
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? 'Glückwunsch, Kommandant. Ihr Konstruktionsprotokoll ist nun Teil des Ruhms der Menschheit' : `Aktuelle Konstruktionsanzahl: ${current}. Noch ${target - current} Einheiten bis zur Auszeichnung`,
61
- },
62
- operator6O: {
63
- call2B: 'An 2B: Bunker-weite Kanalüberwachung ist aktiviert!',
64
- }
65
- }
@@ -1,64 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Generación de datos Mock completada',
4
- scanningField: 'Analizando diferencias entre campos Frontend/Backend... Ejecutando puente semántico',
5
- dataCamouflage: fileName => `Atravesando el firewall del objetivo... Ejecutando protocolo de camuflaje de datos [${fileName}]`,
6
- },
7
- pod042: {
8
- startScout: 'Activando el modo [Captura Táctica por Clic Derecho]...',
9
- capturedToast: 'Inteligencia visual capturada. Iniciando transmisión...',
10
- extractingUiMetadata: 'Extrayendo metadatos de UI desde la red neuronal en la nube...',
11
- partialConstruction: time => `Informe: construcción parcial completada. Tiempo: ${time}s`,
12
- simulate: 'Solicitud real interceptada. Desplegando paquete simulado estándar: example.json',
13
- capturedPage: pageName => `Página capturada [${pageName}] -> Transmitida al directorio mission`,
14
- uploadVisualMetadata: 'Subiendo metadatos visuales al centro de comando para análisis semántico...',
15
- visualPartCaptured: 'Fragmento visual detectado. Ejecutando protocolo de construcción fragmentada...',
16
- constructionAborted: virus => `Construcción abortada. Virus lógico o tiempo de conexión agotado: ${virus}`,
17
- scoutReady: '[Captura por Clic Derecho Lista] Haga clic derecho en cualquier lugar de la página para capturar.',
18
- partialRecommendation: '│ Recomendación: ensamble manualmente el bloque de código anterior en el archivo objetivo',
19
- partialConstructionAborted: virus => `[Advertencia] Fallo en construcción fragmentada. Interferencia lógica detectada: ${virus}`,
20
- visualCaptured: fileName => `Captura visual completada: [${fileName}]. Asignando recursos del Bunker para construcción física...`,
21
- intercept: fileName => `El módulo [${fileName}] ya existe en la base de datos del Bunker. Protocolo omitido para evitar sobrescritura`,
22
- assemblyComplete: (fileName, time) => `Protocolo de construcción finalizado. Módulo [${fileName}] ensamblado físicamente. Tiempo: ${time}s, Sincronizando configuración de rutas Menu con Bunker...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `Fallo en enlace de señal: ${virus}`,
26
- signalSynchronized: count => `Sincronización completada. ${count} nodos activados`,
27
- alignmentFailed: virus => `Fallo de alineación. Los datos de interfaz encontraron un firewall: ${virus}`,
28
- autonomousAddressing: 'Iniciando protocolo de direccionamiento autónomo multicanal [versión semántica]...',
29
- inactiveModule: fileName => `Módulo sin energía detectado [${fileName}]. Solicitando análisis de precisión a 9S`,
30
- capturedRuntimeSignal: fileName => `Señal en ejecución capturada [${fileName}]. Ejecutando alineación automática...`,
31
- reconEncryptedData: fileName => `Fuente de datos cifrada detectada [${fileName}]. Intentando alineación semántica...`,
32
- unknownModule: fileName => `No se encontró recurso del módulo [${fileName}] en Bunker. Ejecute primero la construcción visual`,
33
- bridgeProtocolComplete: (count, time) => `Protocolo puente semántico completado. ${count} diferencias corregidas. Tiempo: ${time}s`,
34
- },
35
-
36
- bunker: {
37
- exit: 'Señal del sistema perdida...',
38
- systemStandby: 'Sistema en espera...',
39
- envCopy: 'Archivo .env almacenado correctamente',
40
- argDesc: 'Especificar plantilla del framework frontend',
41
- configCopy: 'Archivo config.js almacenado correctamente',
42
- desc: 'Generador de código CRUD frontend impulsado por IA',
43
- envCheck: 'Archivo .env existente detectado. Saltando creación',
44
- star: 'Si este proyecto te ayuda, deja una estrella en GitHub ⭐',
45
- accessDenied: 'Acceso denegado: API Key inválida o límite agotado',
46
- configCheck: 'Archivo config.js existente detectado. Saltando creación',
47
- copyTemplateError: virus => `Fallo en construcción de plantilla: ${virus}`,
48
- linkSevered: 'Conexión perdida: revise la red o la resonancia de Black Box',
49
- initDesc: 'Inicializar entorno de construcción Bunker en el directorio actual',
50
- dataSynced: 'Todos los datos de construcción sincronizados con el nodo Bunker',
51
- towerConnected: port => `Comando: apunta tu proxy hacia http://localhost:${port}`,
52
- bootDesc: 'Iniciar monitorización completa: construcción coordinada Page/Part/API',
53
- towerOnline: port => `Torre de interceptación de señales activa [Frecuencia: ${port}]`,
54
- systemOffline: 'Desconectando enlace neural en la nube. Ejecutando sellado físico de datos...',
55
- disclaimer: 'Los resultados son referencias. Cada unidad debe ajustar según la situación real',
56
- networkInstability: count => `Inestabilidad de red neuronal. Reintentando conexión... (${count})`,
57
- initComplete: cmd => `Despliegue del Bunker completado. Añade ${cmd} a package.json scripts`,
58
- frameworkNotSupported: template => `Framework [${template}] no soportado. Pull Requests son bienvenidos`,
59
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? '¡Enhorabuena, Comandante! Su protocolo de construcción se ha convertido en parte de la gloria de la humanidad.' : `Construcciones totales actuales: ${current}. Faltan ${target - current} para la insignia de ${target}.`
60
- },
61
- operator6O: {
62
- call2B: 'Llamando a 2B. Monitorización global del Bunker lista!',
63
- }
64
- }
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Pembuatan data Mock berhasil',
4
- scanningField: 'Memindai perbedaan field Frontend/Backend... Menjalankan protokol jembatan semantik',
5
- dataCamouflage: fileName => `Menembus firewall target... Menjalankan protokol penyamaran data [${fileName}]`,
6
- },
7
- pod042: {
8
- startScout: 'Mengaktifkan mode [Jepretan Taktis Klik-Kanan]...',
9
- capturedToast: 'Intelijen visual ditangkap. Memulai transmisi...',
10
- extractingUiMetadata: 'Mengekstrak metadata UI dari jaringan saraf cloud...',
11
- partialConstruction: time => `Laporan: konstruksi parsial selesai. Waktu: ${time}s`,
12
- simulate: 'Permintaan nyata terdeteksi. Menurunkan paket simulasi standar: example.json',
13
- visualPartCaptured: 'Sampel visual terdeteksi. Menjalankan protokol konstruksi fragmen...',
14
- uploadVisualMetadata: 'Mengirim metadata visual ke pusat komando untuk analisis semantik...',
15
- partialRecommendation: '│ Rekomendasi: Pasang blok kode di atas secara manual ke file target',
16
- capturedPage: pageName => `Halaman ditangkap [${pageName}] -> Ditransmisikan ke direktori mission`,
17
- scoutReady: '[Mode Jepretan Klik-Kanan Siap] Klik kanan di mana saja pada halaman web untuk mengambil gambar.',
18
- constructionAborted: virus => `Konstruksi dihentikan. Virus logika atau batas waktu koneksi terdeteksi: ${virus}`,
19
- partialConstructionAborted: virus => `[Peringatan] Konstruksi fragmen gagal. Gangguan logika terdeteksi: ${virus}`,
20
- intercept: fileName => `Modul [${fileName}] sudah ada dalam database Bunker. Protokol dilewati untuk mencegah penimpaan`,
21
- visualCaptured: fileName => `Penangkapan visual selesai: [${fileName}]. Menyiapkan sumber daya Bunker untuk konstruksi fisik...`,
22
- assemblyComplete: (fileName, time) => `Protokol konstruksi selesai. Modul [${fileName}] berhasil dirakit secara fisik. Waktu: ${time}s, Sinkronisasi konfigurasi Menu dengan Bunker...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `Gangguan koneksi sinyal: ${virus}`,
26
- signalSynchronized: count => `Sinkronisasi sinyal selesai. ${count} node telah diaktifkan`,
27
- alignmentFailed: virus => `Penyelarasan sinyal gagal. Data API menghadapi firewall: ${virus}`,
28
- autonomousAddressing: 'Memulai protokol pengalamatan otomatis multi-kanal [versi semantik]...',
29
- inactiveModule: fileName => `Modul tidak aktif ditemukan [${fileName}]. Meminta analisis presisi tinggi dari 9S`,
30
- capturedRuntimeSignal: fileName => `Sinyal runtime tertangkap [${fileName}]. Menjalankan penyelarasan otomatis...`,
31
- reconEncryptedData: fileName => `Sumber data terenkripsi ditemukan [${fileName}]. Mencoba protokol penyelarasan semantik...`,
32
- bridgeProtocolComplete: (count, time) => `Protokol jembatan semantik selesai. ${count} perbedaan field telah diperbaiki. Waktu: ${time}s`,
33
- unknownModule: fileName => `Resource modul [${fileName}] tidak ditemukan dalam database Bunker. Jalankan konstruksi visual terlebih dahulu`,
34
- },
35
- bunker: {
36
- exit: 'Sinyal sistem telah hilang...',
37
- envCopy: 'File .env berhasil disimpan',
38
- systemStandby: 'Sistem dalam mode standby...',
39
- configCopy: 'File config.js berhasil disimpan',
40
- desc: 'Generator kode CRUD frontend berbasis AI',
41
- argDesc: 'Menentukan template framework frontend',
42
- envCheck: 'File .env sudah tersedia. Pembuatan dilewati',
43
- configCheck: 'File config.js sudah tersedia. Pembuatan dilewati',
44
- copyTemplateError: virus => `Konstruksi template gagal: ${virus}`,
45
- linkSevered: 'Koneksi terputus: periksa jaringan atau resonansi Black Box',
46
- towerOnline: port => `Menara intersepsi sinyal aktif [Frekuensi: ${port}]`,
47
- initDesc: 'Menginisialisasi lingkungan konstruksi Bunker di direktori saat ini',
48
- accessDenied: 'Akses ditolak pusat komando: API Key tidak valid atau kuota habis',
49
- bootDesc: 'Mengaktifkan pemantauan multi-kanal: konstruksi Page/Part/API terpadu',
50
- star: 'Jika proyek ini membantu menghemat waktu Anda, berikan bintang di GitHub ⭐',
51
- systemOffline: 'Memutus koneksi neural cloud. Menjalankan penyegelan fisik data...',
52
- dataSynced: 'Seluruh data konstruksi telah disinkronkan dengan node penyimpanan Bunker',
53
- towerConnected: port => `Perintah: arahkan target proxy Anda ke http://localhost:${port}`,
54
- frameworkNotSupported: template => `Framework [${template}] belum didukung. Pull Request sangat diterima`,
55
- disclaimer: 'Hasil pencocokan hanya sebagai referensi. Setiap unit harus menyesuaikan dengan kondisi nyata',
56
- initComplete: cmd => `Deploy Bunker selesai. Tambahkan ${cmd} ke scripts package.json untuk akses lebih cepat`,
57
- networkInstability: count => `Jaringan neural cloud tidak stabil. Mencoba koneksi ulang... (percobaan ${count})`,
58
- copyEnum: '│ Kode genetik backend asli (Enum) terdeteksi\n│ Rekomendasi: pasang potongan kode berikut ke pusat resource modul',
59
- strategicThreshold: (target, current) => `Jumlah konstruksi telah melewati ambang strategis ${target}! Kekuatan saat ini: ${current}`,
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? 'Selamat komandan. Protokol konstruksi Anda telah menjadi bagian dari kejayaan umat manusia' : `Jumlah konstruksi saat ini: ${current}. Tersisa ${target - current} operasi menuju medali`,
61
- },
62
- operator6O: {
63
- call2B: 'Memanggil 2B. Sistem pemantauan seluruh kanal Bunker siap!',
64
- }
65
- }
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Generazione dati Mock completata',
4
- scanningField: 'Analisi delle differenze tra campi Frontend/Backend... Avvio del ponte semantico',
5
- dataCamouflage: fileName => `Superamento del firewall del bersaglio... Avvio protocollo di camuffamento dati [${fileName}]`,
6
- },
7
- pod042: {
8
- capturedToast: 'Intelligence visiva catturata. Avvio trasmissione...',
9
- startScout: 'Attivazione modalità [Istantanea Tattica con Tasto Destro]...',
10
- extractingUiMetadata: 'Estrazione dei metadati UI dalla rete neurale cloud...',
11
- partialConstruction: time => `Rapporto: costruzione parziale completata. Tempo: ${time}s`,
12
- uploadVisualMetadata: 'Invio metadati visivi al comando centrale per analisi semantica...',
13
- simulate: 'Richiesta reale intercettata. Lancio pacchetto simulato standard: example.json',
14
- visualPartCaptured: 'Frammento visivo rilevato. Avvio protocollo di costruzione frammentata...',
15
- capturedPage: pageName => `Pagina catturata [${pageName}] -> Trasferita nella directory mission`,
16
- partialRecommendation: '│ Raccomandazione: integra manualmente il blocco di codice sopra nel file destinazione',
17
- constructionAborted: virus => `Costruzione interrotta. Rilevato virus logico o timeout di connessione: ${virus}`,
18
- partialConstructionAborted: virus => `[Avviso] Fallimento costruzione frammentata. Interferenza logica rilevata: ${virus}`,
19
- scoutReady: '[Modalità Istantanea Tasto Destro Pronta] Fai clic con il tasto destro in un punto qualsiasi della pagina web.',
20
- visualCaptured: fileName => `Cattura visiva completata: [${fileName}]. Allocazione risorse del Bunker per costruzione fisica...`,
21
- intercept: fileName => `Il modulo [${fileName}] esiste già nel database del Bunker. Protocollo saltato per evitare sovrascrittura`,
22
- assemblyComplete: (fileName, time) => `Protocollo di costruzione completato. Modulo [${fileName}] assemblato fisicamente. Tempo: ${time}s, Sincronizzazione configurazione Menu con il Bunker...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `Errore collegamento segnale: ${virus}`,
26
- signalSynchronized: count => `Sincronizzazione completata. ${count} nodi attivati`,
27
- alignmentFailed: virus => `Allineamento fallito. I dati API hanno incontrato un firewall: ${virus}`,
28
- autonomousAddressing: 'Avvio protocollo di indirizzamento autonomo multicanale [versione semantica]...',
29
- inactiveModule: fileName => `Modulo inattivo rilevato [${fileName}]. Richiesta analisi ad alta precisione da 9S`,
30
- capturedRuntimeSignal: fileName => `Segnale runtime intercettato [${fileName}]. Avvio allineamento automatico...`,
31
- reconEncryptedData: fileName => `Sorgente dati crittografata rilevata [${fileName}]. Tentativo di allineamento semantico...`,
32
- unknownModule: fileName => `Risorsa del modulo [${fileName}] non trovata nel database Bunker. Eseguire prima la costruzione visiva`,
33
- bridgeProtocolComplete: (count, time) => `Protocollo ponte semantico completato. Corrette ${count} differenze nei campi. Tempo: ${time}s`,
34
- },
35
- bunker: {
36
- envCopy: 'File .env salvato',
37
- exit: 'Segnale di sistema perso...',
38
- configCopy: 'File config.js salvato',
39
- systemStandby: 'Sistema in standby...',
40
- envCheck: 'File .env già presente. Creazione ignorata',
41
- desc: 'Generatore di codice CRUD frontend basato su IA',
42
- argDesc: 'Specificare il template del framework frontend',
43
- configCheck: 'File config.js già presente. Creazione ignorata',
44
- dataSynced: 'Tutti i dati di costruzione sincronizzati con il nodo Bunker',
45
- copyTemplateError: virus => `Errore nella costruzione del template: ${virus}`,
46
- bootDesc: 'Avvia monitoraggio completo: costruzione coordinata Page/Part/API',
47
- initDesc: 'Inizializza ambiente di costruzione Bunker nella directory corrente',
48
- star: 'Se questo progetto ti fa risparmiare tempo, lascia una stella su GitHub ⭐',
49
- towerOnline: port => `Torre di intercettazione segnali online [Frequenza: ${port}]`,
50
- linkSevered: 'Connessione interrotta: controllare rete o risonanza della Black Box',
51
- towerConnected: port => `Comando: indirizzare il proxy verso http://localhost:${port}`,
52
- accessDenied: 'Accesso negato dal comando centrale: API Key non valida o limite esaurito',
53
- systemOffline: 'Disconnessione collegamento neurale cloud. Avvio sigillatura fisica dei dati...',
54
- frameworkNotSupported: template => `Framework [${template}] non supportato. Pull Request benvenute`,
55
- disclaimer: 'I risultati sono solo suggerimenti. Ogni unità deve adattare secondo la situazione reale',
56
- networkInstability: count => `Instabilità rete neurale cloud. Tentativo di riconnessione... (${count})`,
57
- initComplete: cmd => `Distribuzione Bunker completata. Aggiungere ${cmd} agli script di package.json per accesso rapido`,
58
- strategicThreshold: (target, current) => `Il numero di costruzioni ha superato la soglia strategica ${target}! Potenza attuale: ${current}`,
59
- copyEnum: '│ Rilevato codice genetico originale Backend (Enum)\n│ Raccomandazione: saldare manualmente il frammento nel centro risorse del modulo',
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? 'Congratulazioni comandante. Il tuo protocollo di costruzione è diventato parte della gloria dell’umanità' : `Costruzioni attuali: ${current}. Mancano ${target - current} operazioni per ottenere la medaglia`,
61
- },
62
- operator6O: {
63
- call2B: 'Chiamata a 2B. Monitoraggio globale dei canali Bunker pronto!',
64
- }
65
- }
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Mock 데이터 생성 완료',
4
- scanningField: 'Frontend/Backend 필드 차이 스캔 중... 시맨틱 브리지 프로토콜 실행',
5
- dataCamouflage: fileName => `대상 방화벽 돌파 중... 데이터 위장 프로토콜 실행 [${fileName}]`,
6
- },
7
- pod042: {
8
- startScout: '[우클릭 즉시 스냅샷] 모드 가동 중...',
9
- capturedToast: '시각 정보 획득 완료. 전송을 시작합니다...',
10
- simulate: '실제 요청 감지. 표준 시뮬레이션 패키지 투입: example.json',
11
- visualPartCaptured: '부분 시각 샘플 감지. "파편 구축 프로토콜" 실행...',
12
- extractingUiMetadata: '뉴럴 클라우드 네트워크에서 UI 메타데이터 추출 중...',
13
- uploadVisualMetadata: '시각 메타데이터를 본부로 전송 중. 시맨틱 분석 시작...',
14
- partialConstruction: time => `보고: 부분 구축 완료. 소요 시간: ${time}s`,
15
- partialRecommendation: '│ 권장: 아래 코드 블록을 대상 파일에 수동으로 통합하십시오',
16
- partialConstructionAborted: virus => `[경고] 파편 구축 실패. 논리 간섭 감지: ${virus}`,
17
- constructionAborted: virus => `구축 중단. 논리 바이러스 또는 연결 시간 초과 감지: ${virus}`,
18
- capturedPage: pageName => `페이지 획득 [${pageName}] -> mission 디렉터리로 전송 완료`,
19
- scoutReady: '[우클릭 스냅샷 모드 준비 완료] 브라우저 페이지 임의의 위치에서 [우클릭] 시 즉시 캡처됩니다.',
20
- visualCaptured: fileName => `시각 센서 캡처 완료: [${fileName}]. Bunker 자원을 배치하여 물리 구축 시작...`,
21
- intercept: fileName => `모듈 [${fileName}]은(는) 이미 Bunker 데이터베이스에 존재합니다. 덮어쓰기를 방지하기 위해 구축 프로토콜을 건너뜁니다`,
22
- assemblyComplete: (fileName, time) => `구축 프로토콜 완료. 모듈 [${fileName}] 물리적 장착 성공. 소요 시간: ${time}s, Bunker에 Menu 라우팅 설정 동기화 중...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `신호 연결 오류: ${virus}`,
26
- signalSynchronized: count => `${count}개의 노드 동기화 완료. 전원 활성화 확인`,
27
- autonomousAddressing: '「전 채널 자동 주소 지정 프로토콜 [시맨틱 스캔 버전]」 실행...',
28
- inactiveModule: fileName => `비활성 모듈 [${fileName}] 발견. 9S 고정밀 분석 요청`,
29
- alignmentFailed: virus => `신호 정렬 실패. API 데이터가 강력한 방화벽에 의해 차단됨: ${virus}`,
30
- reconEncryptedData: fileName => `암호화 데이터 소스 [${fileName}] 발견. 시맨틱 정렬 시도...`,
31
- capturedRuntimeSignal: fileName => `런타임 신호 [${fileName}] 포착. 자동 정렬 프로토콜 실행...`,
32
- bridgeProtocolComplete: (count, time) => `시맨틱 브리지 프로토콜 완료. ${count}개의 필드 차이 수정. 소요 시간: ${time}s`,
33
- unknownModule: fileName => `Bunker 데이터베이스에서 [${fileName}] 모듈 리소스를 찾을 수 없습니다. 먼저 시각 구축을 실행하십시오`,
34
- },
35
- bunker: {
36
- exit: '시스템 신호 손실...',
37
- envCopy: '.env 저장 완료',
38
- configCopy: 'config.js 저장 완료',
39
- systemStandby: '시스템 대기 상태...',
40
- argDesc: 'Frontend 프레임워크 템플릿 지정',
41
- desc: 'AI 기반 Frontend CRUD 코드 생성기',
42
- envCheck: '기존 .env 파일 발견. 생성을 건너뜁니다',
43
- initDesc: '현재 디렉터리에 Bunker 구축 환경 초기화',
44
- configCheck: '기존 config.js 파일 발견. 생성을 건너뜁니다',
45
- copyTemplateError: virus => `템플릿 구축 실패: ${virus}`,
46
- accessDenied: '본부 접근 거부: API Key 오류 또는 사용량 초과',
47
- dataSynced: '모든 구축 데이터가 Bunker 저장 노드와 동기화되었습니다',
48
- systemOffline: '뉴럴 클라우드 연결 해제 중. 데이터 물리 봉인 실행...',
49
- towerOnline: port => `신호 인터셉트 타워 온라인 [주파수: ${port}]`,
50
- linkSevered: '연결 종료: 네트워크 상태 또는 블랙박스 공명을 확인하십시오',
51
- star: '이 프로젝트가 시간을 절약해 준다면 GitHub에서 Star를 눌러주세요 ⭐',
52
- bootDesc: '전체 채널 연동 모니터링 시작: Page/Part/API 협동 구축 지원',
53
- disclaimer: '매칭 결과는 참고용이며 최종 판단은 각 기체가 실제 상황에 따라 조정해야 합니다',
54
- towerConnected: port => `명령: 프록시 대상을 http://localhost:${port} 로 설정하십시오`,
55
- networkInstability: count => `뉴럴 클라우드 연결 불안정. 재연결 시도 중... (${count}번째 시도)`,
56
- copyEnum: '│ Backend 원본 유전자(Enum) 발견\n│ 권장: 아래 코드를 해당 모듈 리소스 센터에 수동 적용하십시오',
57
- initComplete: cmd => `Bunker 배치 완료. 빠른 전장 진입을 위해 ${cmd} 를 package.json scripts에 추가하십시오`,
58
- frameworkNotSupported: template => `[${template}] 프레임워크는 아직 지원되지 않습니다. Pull Request 환영합니다`,
59
- strategicThreshold: (target, current) => `물리 복제 수가 전략 임계값 ${target}을 초과했습니다! 현재 전력: ${current}`,
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? '축하합니다 지휘관. 당신의 구축 프로토콜은 인류의 영광의 일부가 되었습니다' : `현재 구축 수: ${current}. 업적 달성까지 ${target - current}회 남았습니다`,
61
- },
62
- operator6O: {
63
- call2B: '2B 호출 완료. Bunker 전체 채널 연동 모니터링 시스템 준비 완료!',
64
- }
65
- }
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Geração de dados Mock concluída',
4
- scanningField: 'Analisando diferenças entre campos Frontend/Backend... Executando protocolo de ponte semântica',
5
- dataCamouflage: fileName => `Invadindo firewall do alvo... Executando protocolo de camuflagem de dados [${fileName}]`,
6
- },
7
- pod042: {
8
- startScout: 'Ativando modo [Captura Tática com Clique Direito]...',
9
- capturedToast: 'Inteligência visual capturada. Iniciando transmissão...',
10
- extractingUiMetadata: 'Extraindo metadados de UI da rede neural em nuvem...',
11
- partialConstruction: time => `Relatório: construção parcial concluída. Tempo: ${time}s`,
12
- simulate: 'Requisição real detectada. Implantando pacote de simulação padrão: example.json',
13
- capturedPage: pageName => `Página capturada [${pageName}] -> Transmitida para o diretório mission`,
14
- partialRecommendation: '│ Recomendação: integre manualmente o bloco de código acima no arquivo alvo',
15
- uploadVisualMetadata: 'Enviando metadados visuais ao comando central. Iniciando análise semântica...',
16
- visualPartCaptured: 'Fragmento visual detectado. Executando "Protocolo de Construção Fragmentada"...',
17
- constructionAborted: virus => `Construção interrompida. Vírus lógico ou tempo limite de conexão detectado: ${virus}`,
18
- scoutReady: '[Modo de Captura com Clique Direito Pronto] Clique com o botão direito em qualquer lugar da página web.',
19
- partialConstructionAborted: virus => `[Aviso] Falha na construção fragmentada. Interferência lógica detectada: ${virus}`,
20
- visualCaptured: fileName => `Captura visual concluída: [${fileName}]. Alocando recursos do Bunker para construção física...`,
21
- intercept: fileName => `Módulo [${fileName}] já existe no banco de dados do Bunker. Protocolo de construção ignorado para evitar sobrescrita`,
22
- assemblyComplete: (fileName, time) => `Protocolo de construção finalizado. Módulo [${fileName}] instalado fisicamente. Tempo: ${time}s, Sincronizando configuração de rotas Menu com o Bunker...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `Falha no link de sinal: ${virus}`,
26
- signalSynchronized: count => `Sincronização concluída. ${count} nós energizados`,
27
- alignmentFailed: virus => `Falha no alinhamento do sinal. Dados da API bloqueados pelo firewall: ${virus}`,
28
- autonomousAddressing: 'Iniciando "Protocolo de Endereçamento Autônomo de Todos os Canais [Versão Semântica]"...',
29
- inactiveModule: fileName => `Módulo inativo encontrado [${fileName}]. Solicitando análise de alta precisão pelo 9S`,
30
- reconEncryptedData: fileName => `Fonte de dados criptografada encontrada [${fileName}]. Tentando alinhamento semântico...`,
31
- capturedRuntimeSignal: fileName => `Sinal de execução capturado [${fileName}]. Executando protocolo automático de alinhamento...`,
32
- unknownModule: fileName => `Recurso do módulo [${fileName}] não encontrado no banco do Bunker. Execute primeiro a construção visual`,
33
- bridgeProtocolComplete: (count, time) => `Protocolo de ponte semântica concluído. ${count} diferenças de campos corrigidas. Tempo: ${time}s`,
34
- },
35
- bunker: {
36
- exit: 'Sinal do sistema perdido...',
37
- envCopy: 'Arquivo .env salvo com sucesso',
38
- systemStandby: 'Sistema em modo de espera...',
39
- argDesc: 'Definir template do framework frontend',
40
- configCopy: 'Arquivo config.js salvo com sucesso',
41
- desc: 'Gerador de código CRUD frontend alimentado por IA',
42
- envCheck: 'Arquivo .env existente encontrado. Criação ignorada',
43
- configCheck: 'Arquivo config.js existente encontrado. Criação ignorada',
44
- copyTemplateError: virus => `Falha na construção do template: ${virus}`,
45
- initDesc: 'Inicializar ambiente de construção do Bunker no diretório atual',
46
- towerConnected: port => `Comando: direcione seu proxy para http://localhost:${port}`,
47
- towerOnline: port => `Torre de interceptação de sinais online [Frequência: ${port}]`,
48
- accessDenied: 'Acesso ao comando central negado: API Key inválida ou limite excedido',
49
- star: 'Se este projeto ajudou você a economizar tempo, deixe uma estrela no GitHub ⭐',
50
- bootDesc: 'Iniciar monitoramento de todos os canais: construção integrada de Page/Part/API',
51
- linkSevered: 'Conexão interrompida: verifique o estado da rede ou a ressonância do Black Box',
52
- systemOffline: 'Desconectando conexão neural em nuvem. Executando selamento físico dos dados...',
53
- dataSynced: 'Todos os dados de construção foram sincronizados com o nó de armazenamento do Bunker',
54
- frameworkNotSupported: template => `Framework [${template}] ainda não suportado. Pull Requests são bem-vindos`,
55
- networkInstability: count => `Instabilidade na conexão neural em nuvem. Tentando reconectar... (tentativa ${count})`,
56
- disclaimer: 'Os resultados de correspondência são apenas referências. Cada unidade deve ajustar conforme a situação real',
57
- strategicThreshold: (target, current) => `Número de cópias físicas ultrapassou o limite estratégico ${target}! Poder atual: ${current}`,
58
- initComplete: cmd => `Implantação do Bunker concluída. Para acesso rápido ao campo de batalha, adicione ${cmd} aos scripts do package.json`,
59
- copyEnum: '│ Código genético original do Backend (Enum) detectado\n│ Recomendação: aplique manualmente o trecho abaixo no centro de recursos do módulo',
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? 'Parabéns comandante. Seu protocolo de construção tornou-se parte da glória da humanidade' : `Construções atuais: ${current}. Faltam ${target - current} operações para conquistar a medalha`,
61
- },
62
- operator6O: {
63
- call2B: 'Chamando 2B. Monitoramento global dos canais do Bunker pronto!',
64
- }
65
- }
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Mock veri üretimi tamamlandı',
4
- scanningField: 'Frontend/Backend alan farklılıkları analiz ediliyor... Semantik köprü protokolü başlatılıyor',
5
- dataCamouflage: fileName => `Hedef güvenlik duvarı aşılıyor... Veri kamuflaj protokolü çalıştırılıyor [${fileName}]`,
6
- },
7
- pod042: {
8
- capturedToast: 'Görsel istihbarat yakalandı. Aktarım başlatılıyor...',
9
- startScout: '[Taktik Sağ Tık Anlık Görüntü] modu etkinleştiriliyor...',
10
- partialConstruction: time => `Rapor: Kısmi inşa tamamlandı. Süre: ${time}s`,
11
- extractingUiMetadata: 'Bulut sinir ağından UI meta verileri çıkarılıyor...',
12
- visualPartCaptured: 'Görsel parça algılandı. Parçalı inşa protokolü başlatılıyor...',
13
- capturedPage: pageName => `Sayfa yakalandı [${pageName}] -> mission dizinine aktarıldı`,
14
- simulate: 'Gerçek istek algılandı. Standart simülasyon paketi bırakılıyor: example.json',
15
- partialRecommendation: '│ Öneri: Yukarıdaki kod bloğunu hedef dosyaya manuel olarak entegre edin',
16
- uploadVisualMetadata: 'Görsel meta veriler komuta merkezine gönderiliyor. Semantik analiz başlatılıyor...',
17
- partialConstructionAborted: virus => `[Uyarı] Parçalı inşa başarısız. Mantıksal engel tespit edildi: ${virus}`,
18
- constructionAborted: virus => `İnşa durduruldu. Mantıksal virüs veya bağlantı zaman aşımı tespit edildi: ${virus}`,
19
- scoutReady: '[Sağ Tık Anlık Görüntü Modu Hazır] Anında yakalamak için web sayfasında herhangi bir yere sağ tıklayın.',
20
- intercept: fileName => `[${fileName}] modülü Bunker veritabanında zaten mevcut. Veri kaybını önlemek için işlem atlandı`,
21
- visualCaptured: fileName => `Görsel yakalama tamamlandı: [${fileName}]. Bunker kaynakları fiziksel inşa için hazırlanıyor...`,
22
- assemblyComplete: (fileName, time) => `İnşa protokolü tamamlandı. [${fileName}] modülü fiziksel olarak kuruldu. Süre: ${time}s, Menü rota yapılandırması Bunker ile senkronize ediliyor...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `Sinyal bağlantı hatası: ${virus}`,
26
- signalSynchronized: count => `Sinyal senkronizasyonu tamamlandı. ${count} düğüm aktif edildi`,
27
- autonomousAddressing: 'Çok kanallı otonom adresleme protokolü [semantik sürüm] başlatılıyor...',
28
- alignmentFailed: virus => `Sinyal hizalama başarısız. API verileri güvenlik duvarına takıldı: ${virus}`,
29
- reconEncryptedData: fileName => `Şifrelenmiş veri kaynağı bulundu [${fileName}]. Semantik hizalama deneniyor...`,
30
- inactiveModule: fileName => `[${fileName}] etkin olmayan modül bulundu. 9S yüksek hassasiyetli analiz talep ediyor`,
31
- capturedRuntimeSignal: fileName => `Çalışma zamanı sinyali yakalandı [${fileName}]. Otomatik hizalama başlatılıyor...`,
32
- unknownModule: fileName => `[${fileName}] modül kaynağı Bunker veritabanında bulunamadı. Önce görsel inşa gerçekleştirin`,
33
- bridgeProtocolComplete: (count, time) => `Semantik köprü protokolü tamamlandı. ${count} alan farkı düzeltildi. Süre: ${time}s`,
34
- },
35
- bunker: {
36
- exit: 'Sistem sinyali kaybedildi...',
37
- envCopy: '.env dosyası kaydedildi',
38
- systemStandby: 'Sistem bekleme modunda...',
39
- configCopy: 'config.js dosyası kaydedildi',
40
- argDesc: 'Frontend framework şablonunu belirt',
41
- initDesc: 'Mevcut dizinde Bunker inşa ortamını başlat',
42
- desc: 'Yapay zeka destekli frontend CRUD kod üreticisi',
43
- envCheck: '.env dosyası zaten mevcut. Oluşturma atlandı',
44
- copyTemplateError: virus => `Şablon inşası başarısız: ${virus}`,
45
- configCheck: 'config.js dosyası zaten mevcut. Oluşturma atlandı',
46
- bootDesc: 'Tam kanal izlemeyi başlat: Page/Part/API ortak inşası',
47
- towerOnline: port => `Sinyal yakalama kulesi aktif [Frekans: ${port}]`,
48
- star: 'Bu proje size zaman kazandırdıysa GitHub üzerinde yıldız bırakın ⭐',
49
- dataSynced: 'Tüm inşa verileri Bunker depolama düğümü ile senkronize edildi',
50
- accessDenied: 'Komuta merkezi erişimi reddetti: API Key geçersiz veya limit doldu',
51
- linkSevered: 'Bağlantı kesildi: ağ durumunu veya Black Box rezonansını kontrol edin',
52
- towerConnected: port => `Komut: Proxy hedefinizi http://localhost:${port} adresine yönlendirin`,
53
- networkInstability: count => `Bulut sinir ağı kararsız. Yeniden bağlanılıyor... (${count}. deneme)`,
54
- systemOffline: 'Bulut sinir bağlantısı kesiliyor. Verilerin fiziksel mühürleme işlemi başlatılıyor...',
55
- disclaimer: 'Eşleştirme sonuçları yalnızca referanstır. Birimler gerçek duruma göre ayarlama yapmalıdır',
56
- frameworkNotSupported: template => `Framework [${template}] henüz desteklenmiyor. Pull Request katkıları bekleniyor`,
57
- initComplete: cmd => `Bunker kurulumu tamamlandı. Hızlı erişim için ${cmd} komutunu package.json scripts bölümüne ekleyin`,
58
- strategicThreshold: (target, current) => `Fiziksel kopya sayısı stratejik eşik ${target} değerini geçti! Mevcut güç: ${current}`,
59
- copyEnum: '│ Backend genetik kodu (Enum) tespit edildi\n│ Öneri: Aşağıdaki kod parçasını modül kaynak merkezine manuel olarak ekleyin',
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? 'Tebrikler komutan. İnşa protokolünüz insanlığın görkeminin bir parçası oldu' : `Mevcut inşa sayısı: ${current}. Madalyaya ulaşmak için ${target - current} işlem kaldı`,
61
- },
62
- operator6O: {
63
- call2B: '2B çağrılıyor. Bunker tüm kanal izleme sistemi hazır!',
64
- }
65
- }
@@ -1,65 +0,0 @@
1
- module.exports = {
2
- nineS: {
3
- dataCamouflageComplete: 'Mock 資料生成成功',
4
- scanningField: '正在掃描前後端欄位差異... 執行語意橋接任務',
5
- dataCamouflage: fileName => `正在突破目標防火牆... 執行資料偽裝程序 [${fileName}]`,
6
- },
7
- pod042: {
8
- startScout: '啟動【右鍵一鍵快照】模式...',
9
- capturedToast: '圖像情報已擷取,開始傳輸...',
10
- extractingUiMetadata: '正在從神經雲網路提取 UI 中繼資料...',
11
- simulate: '攔截到實際請求。正在空投標準模擬包: example.json',
12
- partialConstruction: time => `報告:局部構築完成。耗時: ${time}s`,
13
- visualPartCaptured: '偵測到局部視覺樣本。正在執行「碎片構築協議」...',
14
- partialRecommendation: '│ 建議:請手動將上述程式碼區塊整合至目標檔案',
15
- uploadVisualMetadata: '正在上傳視覺中繼資料至司令部,執行語意分析...',
16
- scoutReady: '【右鍵快照模式就緒】在瀏覽器頁面任意位置點擊【滑鼠右鍵】即可秒截屏',
17
- constructionAborted: virus => `構築中斷。偵測到邏輯病毒或連線逾時:${virus}`,
18
- capturedPage: pageName => `擷取頁面【${pageName}】-> 已投遞至 mission 目錄`,
19
- partialConstructionAborted: virus => `[警告] 碎片構築失敗。系統偵測到邏輯干擾:${virus}`,
20
- intercept: fileName => `模組 [${fileName}] 已存在於 Bunker 資料庫中。為避免資料覆蓋,構築協議已跳過`,
21
- visualCaptured: fileName => `視覺感測器捕捉完成: [${fileName}]。正在調配 Bunker 資源進行物理構築...`,
22
- assemblyComplete: (fileName, time) => `構築協議執行完成。模組 [${fileName}] 已完成物理裝配。耗時: ${time}s,開始同步 Menu 路由設定...`,
23
- },
24
- pod153: {
25
- signalLinkFault: virus => `訊號鏈路故障: ${virus}`,
26
- autonomousAddressing: '啟動「全頻道自動尋址協議 [語意掃描版]」...',
27
- signalSynchronized: count => `訊號同步完成,${count} 個節點已通電`,
28
- alignmentFailed: virus => `訊號對齊失敗。API 資料遭遇強力防火牆:${virus}`,
29
- inactiveModule: fileName => `發現未通電模組 [${fileName}],請求 9S 執行高精度對帳...`,
30
- capturedRuntimeSignal: fileName => `截獲執行時訊號 [${fileName}]。執行自動對齊協議...`,
31
- reconEncryptedData: fileName => `發現加密資料源 [${fileName}]。正在嘗試執行語意對齊協議...`,
32
- unknownModule: fileName => `Bunker 資料庫中未找到模組 [${fileName}] 的資源檔案。請先執行視覺構築`,
33
- bridgeProtocolComplete: (count, time) => `語意橋接協議執行完成。已修正 ${count} 處欄位差異。耗時: ${time}s`,
34
- },
35
- bunker: {
36
- exit: '系統訊號已遺失...',
37
- envCopy: '.env 儲存完成',
38
- argDesc: '指定前端框架模板',
39
- systemStandby: '系統待命中...',
40
- desc: 'AI 驅動的前端 CRUD 程式碼生成器',
41
- configCopy: 'config.js 儲存完成',
42
- initDesc: '在目前目錄初始化 Bunker 構築環境',
43
- envCheck: '終端已存在 .env 檔案,跳過生成',
44
- dataSynced: '所有構築資料已同步至 Bunker 儲存節點',
45
- configCheck: '終端已存在 config.js 檔案,跳過生成',
46
- linkSevered: '連線中斷:請檢查網路狀態或黑盒共鳴情況',
47
- systemOffline: '正在斷開神經雲連結,執行資料物理封存...',
48
- copyTemplateError: virus => `模板構築失敗: ${virus}`,
49
- star: '如果它能幫助您節省時間,請在 GitHub 上給它一顆 Star ⭐',
50
- towerOnline: port => `訊號攔截塔已上線 [頻段: ${port}]`,
51
- bootDesc: '開啟全頻道聯動監控:支援 Page/Part/API 協同構築',
52
- accessDenied: '司令部拒絕存取:API Key 無效或額度耗盡,請檢查!',
53
- disclaimer: '匹配結果僅供參考,不構成最終決策,各機體需依照實際情況進行調整',
54
- towerConnected: port => `指令:請將您的代理目標指向 http://localhost:${port}`,
55
- copyEnum: '│ 偵測到後端原始基因(Enum)\n│ 建議:將下方程式碼片段手動焊接至該模組資源中心',
56
- networkInstability: count => `神經雲網路連線不穩定,正在嘗試重新連線... (第 ${count} 次重試)`,
57
- frameworkNotSupported: template => `暫不支援 [${template}] 框架。歡迎提交 Pull Request 貢獻`,
58
- strategicThreshold: (target, current) => `物理複製總數已超越 ${target} 戰略閾值!目前戰力:${current}`,
59
- initComplete: cmd => `Bunker 部署完成,為更快速進入戰場,建議手動將 ${cmd} 加入 package.json scripts`,
60
- isLegendary: (unlockAchievement, current, target) => unlockAchievement ? '恭喜您指揮官,您的構築協議已成為人類榮光的一部分' : `目前構築總數:${current}。距離 ${target} 徽章還剩 ${target - current} 次`,
61
- },
62
- operator6O: {
63
- call2B: '呼叫 2B,Bunker 全頻道聯動監控已準備完成!',
64
- }
65
- }
@@ -1,91 +0,0 @@
1
- const fs = require('fs')
2
- const path = require('path')
3
-
4
- module.exports = {
5
- meta: {
6
- name: 'reconciler',
7
- inputs: ['response'],
8
- outputs: ['aligned-resource'],
9
- capabilities: ['field-alignment', 'resource-update', 'response-analysis'],
10
- description: 'align backend response fields with frontend resource fields',
11
- },
12
- execute: async ({ data, fileName }) => {
13
-
14
- const chalk = require('chalk')
15
- const { llm, labs, yorha, dialog, logistics } = require('../awakening').get()
16
-
17
- const { nineS, pod153 } = yorha
18
- const { alignResponseFields } = llm
19
- const { cleanCode } = logistics.builder
20
- const { pagesDir } = logistics.supporter.getConfig()
21
-
22
- const startTime = Date.now()
23
- const resourcePath = path.join(process.cwd(), pagesDir, fileName, 'resource.js')
24
- const enumParams = (await labs?.council)?.[fileName] ?? '{}'
25
-
26
- const spinner = pod153.start(dialog.pod153.reconEncryptedData(fileName))
27
-
28
- try {
29
- if (!fs.existsSync(resourcePath)) {
30
- pod153.fail(spinner, dialog.pod153.unknownModule(fileName))
31
- return
32
- }
33
-
34
- let resourceStr = fs.readFileSync(resourcePath, 'utf8')
35
-
36
- nineS.update(spinner, dialog.nineS.scanningField)
37
-
38
- const extractKeys = str => {
39
- const keys = []
40
- const regex = /(dataIndex|name)\s*:\s*['"]([^'"]+)['"]/g
41
- let match
42
- while ((match = regex.exec(str)) !== null) {
43
- keys.push(match[2])
44
- }
45
- return Array.from(new Set(keys.filter(key => key !== 'index')))
46
- }
47
-
48
- const result = await alignResponseFields({ responseStr: JSON.stringify(data), resourceStr: extractKeys(resourceStr).join(',') })
49
- let changeCount = 0
50
- const resultMapping = {}
51
- Object.entries(result).forEach(([oldField, newField]) => {
52
- if (oldField === newField) return
53
- const regex = new RegExp(`(dataIndex|name)\\s*:\\s*['"]${oldField}['"]`, 'g')
54
- resourceStr = resourceStr.replace(regex, `$1: '${newField}'`)
55
- changeCount++
56
- resultMapping[oldField] = newField
57
- })
58
-
59
- fs.writeFileSync(resourcePath, resourceStr)
60
- const endTime = Date.now()
61
-
62
- pod153.success(spinner, dialog.pod153.bridgeProtocolComplete(changeCount, (endTime - startTime) / 1000))
63
-
64
- if (changeCount > 0) {
65
- console.log(chalk.magenta(`\n┌────── [ YoRHa Autonomous Backend Alignment ] ──────┐`))
66
- const maxOldFieldLength = Math.max(...Object.keys(resultMapping).map(key => key.length))
67
- Object.entries(resultMapping).forEach(([oldField, newField]) => {
68
- const padding = ' '.repeat(Math.max(1, maxOldFieldLength + 1 - oldField.length))
69
- console.log(
70
- chalk.yellow(` │ `) +
71
- chalk.yellow(oldField) +
72
- padding +
73
- chalk.cyan(` -> `) +
74
- chalk.white(newField)
75
- )
76
- })
77
- console.log(chalk.magenta(`└────────────────────────────────────────────────────┘`))
78
- }
79
-
80
- if (enumParams !== '{}') {
81
- console.log(chalk.magenta(`\n┌──────── [ YoRHa Physical Assembly: Enum Genomes ] ────────┐`))
82
- console.log(chalk.gray(dialog.bunker.copyEnum))
83
- console.log(chalk.white(cleanCode(enumParams)))
84
- console.log(chalk.magenta(`├───────────────────────────────────────────────────────────┘`))
85
- }
86
-
87
- } catch (error) {
88
- pod153.fail(spinner, dialog.pod153.alignmentFailed(error))
89
- }
90
- }
91
- }
File without changes