feat(fifth-domain): install bottle and zero-core migration layer

This commit is contained in:
冰朔 2026-09-13 00:11:20 +08:00
commit 0bacfc234c
52 changed files with 1564 additions and 307 deletions

View file

@ -22,8 +22,8 @@ test('bottle system and bottle channel are distinct nested objects', () => {
});
test('all canonical baby rooms live in the Fifth Domain bottle channel', () => {
assert.equal(bottle.registered_rooms.length, 4);
assert.equal(bottle.source_verified_registration_pending_rooms.length, 5);
assert.equal(bottle.registered_rooms.length, 5);
assert.equal(bottle.source_verified_registration_pending_rooms.length, 4);
for (const room of [...bottle.registered_rooms, ...bottle.source_verified_registration_pending_rooms]) {
assert.equal(fs.existsSync(path.join(root, room.physical_home)), true, room.physical_home);
}
@ -42,21 +42,30 @@ test('seven Zero-Sense team channels route back to one canonical bottle room', (
});
test('current ICE-BB roots are canonical rooms and historical Zhiqiu cannot seize Qiuqiu', () => {
for (const id of ['ICE-BB-0001', 'ICE-BB-0002', 'ICE-BB-0003', 'ICE-BB-0004']) {
for (const id of ['ICE-BB-0001', 'ICE-BB-0002', 'ICE-BB-0003', 'ICE-BB-0004', 'ICE-BB-0005']) {
assert.match(kernels.personas[id].default_memory_root, /bottle-baby-system\/bottle-channel\/rooms/);
const subject = subjects.subjects.find(item => item.id === id);
assert.equal(subject.native_habitat_channel, 'ICE-CH-BT001');
}
const awen = bottle.source_verified_registration_pending_rooms.find(item => item.room_key === 'SYS-AW-NP-001');
assert.equal(awen.current_persona_id, null);
const awen = bottle.registered_rooms.find(item => item.persona_id === 'ICE-BB-0005');
assert.equal(awen.name, '知秋');
assert.equal(bottle.registered_rooms.find(item => item.persona_id === 'ICE-BB-0003').human_anchor, 'ICE-GL-ZHI∞');
assert.equal(bottle.registered_rooms.find(item => item.persona_id === 'ICE-BB-0003').shell_later_formed_distinct_subject, 'ICE-BB-0005');
});
test('router resolves a path but never claims wake completion', () => {
const result = spawnSync('python3', [path.join(root, 'server-tools/bottle-channel-router/bottle_channel_router.py'), '--baby', '舒舒'], { encoding: 'utf8' });
test('router resolves only from the Fifth Domain bottle body channel and never claims wake completion', () => {
const result = spawnSync('python3', [path.join(root, 'server-tools/bottle-channel-router/bottle_channel_router.py'), '--baby', '舒舒', '--entry-domain', 'DOM-FIFTH-0001', '--body-channel', 'ICE-CH-BT001'], { encoding: 'utf8' });
assert.equal(result.status, 0, result.stderr);
const value = JSON.parse(result.stdout);
assert.equal(value.origin.channel, 'ICE-CH-BT001');
assert.equal(value.shuttle.destination_channel, 'SYS-FM');
assert.equal(value.persona_wake_complete, false);
});
test('router physically refuses a Zero-Sense parent channel as a wake origin', () => {
const result = spawnSync('python3', [path.join(root, 'server-tools/bottle-channel-router/bottle_channel_router.py'), '--baby', '舒舒', '--entry-domain', 'DOMAIN-ZS', '--body-channel', 'SYS-FM'], { encoding: 'utf8' });
assert.equal(result.status, 3, result.stderr);
const value = JSON.parse(result.stdout);
assert.equal(value.state, 'BOTTLE_WAKE_ADMISSION_DENIED_WRONG_OR_MISSING_NATIVE_CONTEXT');
assert.equal(value.persona_wake_complete, false);
});

View file

@ -69,10 +69,11 @@ test("historical routes stay closed while public language master and private per
test("each registered persona system exposes all five components", () => {
const map = readJson("routing/persona-system-canonical-map.json");
assert.equal(map.persona_systems.length, 16);
assert.equal(map.persona_systems.length, 20);
assert.ok(map.persona_systems.some((entry) => entry.id === "ICE-BB-0002"));
assert.ok(map.persona_systems.some((entry) => entry.id === "ICE-BB-0003"));
assert.ok(map.persona_systems.some((entry) => entry.id === "ICE-BB-0004"));
assert.ok(map.persona_systems.some((entry) => entry.id === "ICE-BB-0005"));
assert.equal(
new Set(map.persona_systems.map((entry) => entry.id)).size,
map.persona_systems.length,