SOURCE / PINNED RELEASE
Made of little things.
Outbreak: Soycoon City
- Release
- db7750b1d009…
- Author-recorded commit
- 3ee3f5fd27a6…
- License
- LICENSE
- Author’s source reference
- nostr://npub182jczunncwe0jn6frpqwq3e0qjws7yqqnc3auccqv9nte2dnd63scjm4rf/wss%3A%2F%2Fgit.napplet.soy%2F/n-b87c04571a9
Archive hash verified: dbebdc772b142a1c…. The source-to-build association is the author’s claim; it has not been independently rebuilt.
import { readFile, access } from 'node:fs/promises';
import { createHash } from 'node:crypto';
import assert from 'node:assert/strict';
const catalogue=JSON.parse(await readFile('sounds/demo.json','utf8')),ids=new Set(),paths=new Set();
assert.equal(catalogue.schema,'soyindent.sound-catalogue');assert.equal(catalogue.version,1);assert(catalogue.baseDirection);
for(const sound of catalogue.sounds){
assert(/^[a-z0-9_]+$/.test(sound.id)&&!ids.has(sound.id));ids.add(sound.id);
assert(sound.prompt.length>30&&sound.cue);assert(['demo','polish','later'].includes(sound.priority));
assert(sound.durationSeconds>0&&sound.durationSeconds<=180);assert.equal(typeof sound.loop,'boolean');
assert.equal(sound.output.format,'mp3');assert([1,2].includes(sound.output.channels));assert([64,80].includes(sound.output.bitrateKbps));assert.equal(sound.files.length,sound.variants);
for(const file of sound.files){
assert(/^src\/audio\/generated\/[a-z0-9_-]+\.mp3$/.test(file.path)&&!paths.has(file.path));paths.add(file.path);
if(file.status==='planned'){assert.equal(file.sha256,null);await assert.rejects(access(file.path));}
else {assert.equal(file.status,'generated');assert.equal(createHash('sha256').update(await readFile(file.path)).digest('hex'),file.sha256);}
}
}
console.log(`${ids.size} sound cues / ${paths.size} output files validated; planned files are not presented as generated.`);
