2026-06-03 04:34:31 +01:00
#!/usr/bin/env node
import { mkdir , writeFile } from "node:fs/promises" ;
import path from "node:path" ;
const document = {
schema : "gamecult.eve.provider_advertisement.v1" ,
providerId : "aquasynth.service" ,
title : "AquaSynth Service" ,
description :
2026-10-22 20:19:44 +02:00
"AquaSynth accepts .aqua DSL and Weksa utterance handoffs, compiles Faust-native instruments, owns live streaming patch sessions, and publishes controllable synth state through CultMesh." ,
2026-06-03 04:34:31 +01:00
mode : "fixture-read-only" ,
serviceVerse : {
id : "verse.aquasynth.service.v1" ,
cultMeshKey : "aquasynth.service/provider-advertisement" ,
authority : "AquaSynth daemon identity, schema catalog, provider publication, and synth runtime boundary" ,
owns : [
".aqua patch parsing" ,
"patch graph semantics" ,
"Faust source emission" ,
"native Faust compilation" ,
2026-06-15 03:38:32 +01:00
"compiled instrument sessions" ,
"live streaming patch sessions" ,
"live session control state" ,
"live session lifecycle receipts" ,
2026-06-03 04:34:31 +01:00
"sample/render receipts" ,
"learned utterance embeddings and synth-driver controls" ,
] ,
doesNotOwn : [ "Weksa conversational intent" , "Persona canonical state" , "Eve presentation runtime" ] ,
} ,
nestedVerses : [
{
id : "aquasynth.patch" ,
kind : "patch" ,
cultMeshKey : "aquasynth.patch/current" ,
authority : "AquaSynth.Core .aqua parser and patch graph model" ,
schemas : [ "aquasynth.patch_graph.v0" ] ,
} ,
{
id : "aquasynth.compile" ,
kind : "compile" ,
cultMeshKey : "aquasynth.compile/jobs" ,
authority : "AquaSynth.Faust compiler boundary" ,
schemas : [ "aquasynth.faust_source.v0" , "aquasynth.compiled_instrument.v0" ] ,
} ,
{
id : "aquasynth.instrument" ,
kind : "instrument" ,
cultMeshKey : "aquasynth.instrument/sessions" ,
2026-06-15 03:38:32 +01:00
authority : "AquaSynth native host and live-session owner" ,
schemas : [
"aquasynth.compiled_instrument_session.v1" ,
"aquasynth.live_instrument_session.v1" ,
"aquasynth.command.instrument_open.v1" ,
"aquasynth.command.instrument_control.v1" ,
"aquasynth.command.instrument_block.v1" ,
"aquasynth.command.instrument_close.v1" ,
"aquasynth.instrument_open_receipt.v1" ,
"aquasynth.instrument_control_receipt.v1" ,
"aquasynth.instrument_block_receipt.v1" ,
"aquasynth.instrument_close_receipt.v1" ,
] ,
2026-06-03 04:34:31 +01:00
} ,
{
id : "aquasynth.speech" ,
kind : "speech" ,
cultMeshKey : "aquasynth.speech/current" ,
authority : "AquaSynth utterance embedding and synth-driver runtime" ,
schemas : [ "aquasynth.utterance_embedding.v0" , "aquasynth.speech_render_receipt.v0" ] ,
} ,
{
id : "aquasynth.operator" ,
kind : "operator" ,
cultMeshKey : "aquasynth.operator/status" ,
authority : "AquaSynth daemon runtime" ,
2026-10-22 20:19:44 +02:00
schemas : [ "aquasynth.operator_state.v0" ] ,
2026-06-03 04:34:31 +01:00
} ,
] ,
schemaWitnessFamilies : [
{
family : "patch" ,
namespace : "aquasynth.patch.*" ,
witnesses : [ "aquasynth.patch_graph.v0" ] ,
durableShape : ".aquasynth/patches/{patchId}.cc" ,
} ,
{
family : "compile" ,
namespace : "aquasynth.compile.*" ,
witnesses : [ "aquasynth.faust_source.v0" , "aquasynth.compiled_instrument.v0" ] ,
durableShape : ".aquasynth/faust/{compileId}.cc" ,
} ,
{
family : "instrument" ,
namespace : "aquasynth.instrument.*" ,
2026-06-15 03:38:32 +01:00
witnesses : [
"aquasynth.compiled_instrument_session.v1" ,
"aquasynth.live_instrument_session.v1" ,
"aquasynth.instrument_open_receipt.v1" ,
"aquasynth.instrument_control_receipt.v1" ,
"aquasynth.instrument_block_receipt.v1" ,
"aquasynth.instrument_close_receipt.v1" ,
] ,
durableShape : ".aquasynth/sessions/{sessionId}.cc and .aquasynth/live-sessions/{sessionId}.cc" ,
2026-06-03 04:34:31 +01:00
} ,
{
family : "render" ,
namespace : "aquasynth.render.*" ,
witnesses : [ "aquasynth.render_sample.v0" , "aquasynth.render_loss.v0" ] ,
durableShape : ".aquasynth/renders/{renderId}.cc" ,
} ,
{
family : "speech" ,
namespace : "aquasynth.speech.*" ,
witnesses : [ "aquasynth.utterance_embedding.v0" , "aquasynth.speech_render_receipt.v0" ] ,
durableShape : ".aquasynth/speech/{utteranceId}.cc" ,
} ,
] ,
commandBoundaries : [
{
id : "aquasynth.command.patch.compile" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
allowedInputs : [ ".aqua DSL" , "compile target" , "host architecture" ] ,
emits : [ "aquasynth.patch_graph.v0" , "aquasynth.faust_source.v0" , "aquasynth.compiled_instrument.v0" ] ,
} ,
2026-06-15 03:38:32 +01:00
{
id : "aquasynth.command.instrument.open" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
allowedInputs : [ ".aqua DSL" , "block size" , "initial semantic control values" ] ,
emits : [ "aquasynth.compiled_instrument_session.v1" , "aquasynth.live_instrument_session.v1" , "aquasynth.instrument_open_receipt.v1" ] ,
} ,
2026-06-03 04:34:31 +01:00
{
id : "aquasynth.command.instrument.control" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
2026-06-15 03:38:32 +01:00
allowedInputs : [ "live session id" , "semantic control values" ] ,
emits : [ "aquasynth.live_instrument_session.v1" , "aquasynth.instrument_control_receipt.v1" ] ,
} ,
{
id : "aquasynth.command.instrument.block" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
allowedInputs : [ "live session id" , "frame count" , "optional control values" ] ,
emits : [ "aquasynth.live_instrument_session.v1" , "aquasynth.instrument_block_receipt.v1" ] ,
} ,
{
id : "aquasynth.command.instrument.close" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
allowedInputs : [ "live session id" ] ,
emits : [ "aquasynth.live_instrument_session.v1" , "aquasynth.instrument_close_receipt.v1" ] ,
2026-06-03 04:34:31 +01:00
} ,
{
id : "aquasynth.command.instrument.sample" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
2026-06-15 03:38:32 +01:00
allowedInputs : [ ".aqua DSL" , "duration" , "sample format" , "optional semantic control values" ] ,
2026-06-03 04:34:31 +01:00
emits : [ "aquasynth.render_sample.v0" ] ,
} ,
{
id : "aquasynth.command.speech.realize" ,
owner : "AquaSynth" ,
acceptedByFixture : false ,
allowedInputs : [ "weksa.utterance_handoff.v0" , "weksa.utterance_embedding_handoff.v0.1" ] ,
emits : [ "aquasynth.utterance_embedding.v0" , "aquasynth.speech_render_receipt.v0" ] ,
forbiddenTargets : [ "Weksa conversational intent truth" ] ,
} ,
] ,
loweringRules : [
2026-06-15 03:38:32 +01:00
"AquaSynth owns learned embeddings, synth controls, Faust compilation, native binary lifetime, compiled instrument sessions, live streaming patch sessions, and sampled outputs." ,
2026-06-03 04:34:31 +01:00
"Weksa owns writing-to-intent and intent-to-utterance lowering." ,
"Faust source and native binaries are emitted artifacts with typed receipts, not the semantic patch owner." ,
2026-10-22 20:19:44 +02:00
"Dashboards and other renderers control and inspect sessions through CultMesh command documents and retained live-session state; they do not own audio state." ,
2026-06-03 04:34:31 +01:00
] ,
} ;
async function main ( ) {
const args = process . argv . slice ( 2 ) ;
const outIndex = args . indexOf ( "--out" ) ;
const outputPath = outIndex >= 0 ? args [ outIndex + 1 ] : undefined ;
const json = ` ${ JSON . stringify ( document , null , 2 ) } \n ` ;
if ( outputPath ) {
const resolved = path . resolve ( process . cwd ( ) , outputPath ) ;
await mkdir ( path . dirname ( resolved ) , { recursive : true } ) ;
await writeFile ( resolved , json , "utf8" ) ;
return ;
}
process . stdout . write ( json ) ;
}
main ( ) . catch ( ( error ) => {
console . error ( error ) ;
process . exitCode = 1 ;
} ) ;