@roomi-fields/grillhouse 0.49.0 → 0.50.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.
Files changed (315) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/CHANGELOG.md +38 -0
  3. package/bin/grillhouse.mjs +2 -0
  4. package/cadre/templates/projet/.github/workflows/ci.yml +5 -0
  5. package/cadre/templates/projet/.github/workflows/nuit.yml +6 -4
  6. package/cadre/templates/projet/CLAUDE.md +13 -96
  7. package/cadre/templates/projet/docs/agents/issue-tracker.md +5 -5
  8. package/charte.md +88 -96
  9. package/dist/temporal/acte.d.ts +9 -0
  10. package/dist/temporal/acte.js +45 -21
  11. package/dist/temporal/acte.js.map +1 -1
  12. package/dist/temporal/circuit/activites.js +2 -1
  13. package/dist/temporal/circuit/activites.js.map +1 -1
  14. package/dist/temporal/circuit/appel.js +2 -2
  15. package/dist/temporal/circuit/appel.js.map +1 -1
  16. package/dist/temporal/circuit/client.d.ts +2 -4
  17. package/dist/temporal/circuit/client.js +5 -8
  18. package/dist/temporal/circuit/client.js.map +1 -1
  19. package/dist/temporal/circuit/commande.js +5 -4
  20. package/dist/temporal/circuit/commande.js.map +1 -1
  21. package/dist/temporal/circuit/contrat.d.ts +3 -3
  22. package/dist/temporal/circuit/contrat.js +2 -2
  23. package/dist/temporal/circuit/contrat.js.map +1 -1
  24. package/dist/temporal/circuit/deroule.js +4 -4
  25. package/dist/temporal/circuit/deroule.js.map +1 -1
  26. package/dist/temporal/commande.js +1 -1
  27. package/dist/temporal/commande.js.map +1 -1
  28. package/dist/temporal/deroules.js +3 -4
  29. package/dist/temporal/deroules.js.map +1 -1
  30. package/dist/temporal/etat.js +1 -1
  31. package/dist/temporal/etat.js.map +1 -1
  32. package/dist/temporal/file/activites.js +2 -1
  33. package/dist/temporal/file/activites.js.map +1 -1
  34. package/dist/temporal/file/client.js.map +1 -1
  35. package/dist/temporal/file/contrat.js +3 -2
  36. package/dist/temporal/file/contrat.js.map +1 -1
  37. package/dist/temporal/file/deroule.js +2 -1
  38. package/dist/temporal/file/deroule.js.map +1 -1
  39. package/dist/temporal/installation.js +2 -0
  40. package/dist/temporal/installation.js.map +1 -1
  41. package/dist/temporal/nuits/activites.js +4 -3
  42. package/dist/temporal/nuits/activites.js.map +1 -1
  43. package/dist/temporal/nuits/appel.js +2 -1
  44. package/dist/temporal/nuits/appel.js.map +1 -1
  45. package/dist/temporal/nuits/choix.js +2 -1
  46. package/dist/temporal/nuits/choix.js.map +1 -1
  47. package/dist/temporal/nuits/client.js +2 -1
  48. package/dist/temporal/nuits/client.js.map +1 -1
  49. package/dist/temporal/nuits/commande.js +2 -1
  50. package/dist/temporal/nuits/commande.js.map +1 -1
  51. package/dist/temporal/nuits/contrat.js +2 -1
  52. package/dist/temporal/nuits/contrat.js.map +1 -1
  53. package/dist/temporal/nuits/deroule.js +2 -1
  54. package/dist/temporal/nuits/deroule.js.map +1 -1
  55. package/dist/temporal/places/activites.js +2 -1
  56. package/dist/temporal/places/activites.js.map +1 -1
  57. package/dist/temporal/places/client.js +1 -0
  58. package/dist/temporal/places/client.js.map +1 -1
  59. package/dist/temporal/places/deroule.js +4 -5
  60. package/dist/temporal/places/deroule.js.map +1 -1
  61. package/dist/temporal/tickets/activites.js +1 -1
  62. package/dist/temporal/tickets/activites.js.map +1 -1
  63. package/dist/temporal/tickets/deroule.js +4 -4
  64. package/dist/temporal/tickets/deroule.js.map +1 -1
  65. package/docs/ARCHITECTURE.md +35 -13
  66. package/docs/CADRE.md +10 -68
  67. package/docs/INTERFACE.md +59 -179
  68. package/docs/architecture/circuit.md +440 -0
  69. package/docs/architecture/entree.md +281 -0
  70. package/docs/architecture/greffon.md +284 -0
  71. package/docs/architecture/installation.md +306 -0
  72. package/docs/architecture/machine.md +383 -0
  73. package/docs/architecture/tests.md +337 -0
  74. package/package.json +1 -1
  75. package/scripts/abi-des-dependances.mjs +2 -1
  76. package/scripts/activites.mjs +8 -8
  77. package/scripts/aiguillage.mjs +4 -4
  78. package/scripts/arbitrages.mjs +1 -1
  79. package/scripts/arbres-juges.mjs +2 -1
  80. package/scripts/attente-de-la-machine.mjs +10 -16
  81. package/scripts/avancement.mjs +2 -0
  82. package/scripts/base-des-workflows.mjs +2 -1
  83. package/scripts/binaires.mjs +2 -1
  84. package/scripts/branche-de-nuit.mjs +2 -1
  85. package/scripts/cadre.mjs +12 -3
  86. package/scripts/ci-de-main.mjs +2 -1
  87. package/scripts/circuit.mjs +101 -618
  88. package/scripts/circuits-cles.mjs +4 -6
  89. package/scripts/circuits-du-serveur.mjs +1 -1
  90. package/scripts/codes-de-sortie.mjs +1 -1
  91. package/scripts/coeurs-dedies.mjs +2 -4
  92. package/scripts/commande-du-langage.mjs +2 -0
  93. package/scripts/commandes-composees.mjs +3 -3
  94. package/scripts/commandes-du-path.mjs +1 -1
  95. package/scripts/composants-affectes.mjs +3 -1
  96. package/scripts/composition-des-langages.mjs +2 -0
  97. package/scripts/conformite.d.ts +2 -1
  98. package/scripts/conformite.mjs +2 -0
  99. package/scripts/consommation-des-passes.mjs +5 -4
  100. package/scripts/consommation.mjs +1 -0
  101. package/scripts/copies-finies.mjs +9 -10
  102. package/scripts/crochets.mjs +2 -1
  103. package/scripts/depart-du-ticket.mjs +2 -2
  104. package/scripts/dependances-internes.mjs +4 -2
  105. package/scripts/dernier-vert.mjs +3 -3
  106. package/scripts/dette.d.ts +2 -1
  107. package/scripts/dette.mjs +2 -0
  108. package/scripts/direct.mjs +2 -1
  109. package/scripts/disque-des-copies.mjs +1 -1
  110. package/scripts/donnees-cles.mjs +2 -0
  111. package/scripts/droits.mjs +12 -10
  112. package/scripts/echantillonneur-de-la-passe.mjs +1 -1
  113. package/scripts/effets.mjs +3 -3
  114. package/scripts/engendres.mjs +1 -1
  115. package/scripts/enveloppe/codes.mjs +1 -0
  116. package/scripts/enveloppe/enveloppe.mjs +113 -89
  117. package/scripts/enveloppe/lancer.sh +5 -3
  118. package/scripts/enveloppe/paquets-du-plan.mjs +4 -6
  119. package/scripts/enveloppe/travail-de-la-copie.mjs +11 -16
  120. package/scripts/etapes.mjs +10 -9
  121. package/scripts/etat-du-depot.mjs +2 -1
  122. package/scripts/faits-du-circuit.mjs +19 -19
  123. package/scripts/fermeture-de-la-machine.mjs +2 -2
  124. package/scripts/fichier-du-poste.mjs +3 -4
  125. package/scripts/fichiers-nommes.mjs +2 -1
  126. package/scripts/file-des-tickets.mjs +3 -1
  127. package/scripts/flux-de-la-nuit.mjs +39 -0
  128. package/scripts/flux-des-paquets.mjs +2 -1
  129. package/scripts/fusion-du-changelog.mjs +2 -1
  130. package/scripts/garde-de-la-memoire.mjs +1 -1
  131. package/scripts/gardes-du-cadre.mjs +2 -0
  132. package/scripts/greffons.mjs +2 -2
  133. package/scripts/grillhouse-maj.mjs +55 -150
  134. package/scripts/groupe-cles.mjs +2 -1
  135. package/scripts/index-interfaces.mjs +2 -0
  136. package/scripts/init.mjs +2 -1
  137. package/scripts/integration/file.mjs +3 -3
  138. package/scripts/integration/integrer.mjs +5 -6
  139. package/scripts/integration/rejeu.mjs +4 -2
  140. package/scripts/integration/verdict.mjs +2 -1
  141. package/scripts/jointure.d.ts +5 -1
  142. package/scripts/journal-des-etats.mjs +2 -2
  143. package/scripts/langages/cargo/binaires.mjs +3 -2
  144. package/scripts/langages/cargo/clippy.mjs +2 -0
  145. package/scripts/langages/cargo/commandes.mjs +72 -17
  146. package/scripts/langages/cargo/composants.mjs +4 -3
  147. package/scripts/langages/cargo/elements-du-lot.mjs +2 -0
  148. package/scripts/langages/cargo/etiquettes.mjs +87 -0
  149. package/scripts/langages/cargo/executables-de-tests.mjs +3 -1
  150. package/scripts/langages/cargo/exemples.mjs +6 -4
  151. package/scripts/langages/cargo/frontieres.mjs +2 -0
  152. package/scripts/langages/cargo/index-interfaces.mjs +2 -0
  153. package/scripts/langages/cargo/index.mjs +8 -9
  154. package/scripts/langages/cargo/migrations/0.28.4-tailles-des-tests.mjs +8 -8
  155. package/scripts/langages/cargo/migrations/0.34.0-executables-de-tests.mjs +7 -8
  156. package/scripts/langages/cargo/mise-a-jour.mjs +6 -3
  157. package/scripts/langages/cargo/sccache.mjs +10 -6
  158. package/scripts/langages/cargo/squelette.mjs +2 -0
  159. package/scripts/langages/cargo/tailles-des-tests.mjs +2 -0
  160. package/scripts/langages/cargo/verdict.mjs +8 -6
  161. package/scripts/langages/typescript/chemins-des-tests.mjs +2 -1
  162. package/scripts/langages/typescript/code-mort.mjs +2 -1
  163. package/scripts/langages/typescript/composants.mjs +7 -5
  164. package/scripts/langages/typescript/consommateurs-arbitres.mjs +17 -4
  165. package/scripts/langages/typescript/consommateurs.d.ts +2 -1
  166. package/scripts/langages/typescript/consommateurs.mjs +5 -7
  167. package/scripts/langages/typescript/construire.mjs +2 -1
  168. package/scripts/langages/typescript/elements-du-lot.mjs +2 -1
  169. package/scripts/langages/typescript/exemples.mjs +2 -1
  170. package/scripts/langages/typescript/frontieres.mjs +3 -2
  171. package/scripts/langages/typescript/index-interfaces.mjs +3 -2
  172. package/scripts/langages/typescript/index.mjs +3 -2
  173. package/scripts/langages/typescript/interfaces-contre-code.mjs +2 -1
  174. package/scripts/langages/typescript/lecteurs.mjs +2 -1
  175. package/scripts/langages/typescript/migrations/0.23.0-config-vitest.mjs +5 -6
  176. package/scripts/langages/typescript/migrations/0.24.4-noms-declares-inutilises.mjs +4 -8
  177. package/scripts/langages/typescript/migrations/0.24.6-lignes-mal-formees.mjs +5 -9
  178. package/scripts/langages/typescript/migrations/0.24.7-matiere-dans-les-tests.mjs +6 -10
  179. package/scripts/langages/typescript/migrations/0.25.0-chemins-des-tests.mjs +5 -6
  180. package/scripts/langages/typescript/migrations/0.25.0-tailles-des-tests.mjs +6 -8
  181. package/scripts/langages/typescript/migrations/0.30.0-prefixe-des-tickets.mjs +5 -4
  182. package/scripts/langages/typescript/migrations/0.30.0-tailles-des-outils-lourds.mjs +7 -7
  183. package/scripts/langages/typescript/migrations/0.30.0-titres-nommant-un-ticket.mjs +5 -6
  184. package/scripts/langages/typescript/migrations/0.33.0-binaire-de-jour.mjs +6 -6
  185. package/scripts/langages/typescript/migrations/0.33.0-tests-du-poste.mjs +5 -5
  186. package/scripts/langages/typescript/migrations/0.34.1-cache-des-outils.mjs +4 -4
  187. package/scripts/langages/typescript/migrations/0.49.0-tests-equipes.mjs +7 -7
  188. package/scripts/langages/typescript/mise-a-jour.mjs +5 -5
  189. package/scripts/langages/typescript/module-absent.mjs +2 -1
  190. package/scripts/langages/typescript/parcours.mjs +2 -1
  191. package/scripts/langages/typescript/references-par-les-types.mjs +2 -1
  192. package/scripts/langages/typescript/regle-des-tests.mjs +2 -1
  193. package/scripts/langages/typescript/resume-du-lanceur.mjs +1 -1
  194. package/scripts/langages/typescript/resumes.mjs +2 -1
  195. package/scripts/langages/typescript/squelette.mjs +2 -1
  196. package/scripts/langages/typescript/tailles-des-tests.mjs +5 -4
  197. package/scripts/langages/typescript/tests-de-nuit.mjs +12 -5
  198. package/scripts/langages/typescript/tests-du-poste.mjs +60 -21
  199. package/scripts/langages/typescript/tests.mjs +44 -66
  200. package/scripts/langages/typescript/titres-de-tests.mjs +2 -2
  201. package/scripts/langages/typescript/tranches.mjs +2 -1
  202. package/scripts/langages/typescript/turbo-des-paquets.mjs +87 -148
  203. package/scripts/langages/typescript/verdict.mjs +2 -1
  204. package/scripts/langages/typescript/verifier.mjs +64 -99
  205. package/scripts/langages/typescript/verrou-des-dependances.mjs +2 -1
  206. package/scripts/langages/typescript/vitest-config/avancement.reporter.mjs +1 -0
  207. package/scripts/langages/typescript/vitest-config/base.mjs +5 -5
  208. package/scripts/langages/typescript/vitest-config/bornes.mjs +1 -0
  209. package/scripts/langages/typescript/vitest-config/changements.mjs +6 -10
  210. package/scripts/langages/typescript/vitest-config/cibles.mjs +3 -3
  211. package/scripts/langages/typescript/vitest-config/delais.mjs +1 -0
  212. package/scripts/langages/typescript/vitest-config/delais.setup.mjs +1 -0
  213. package/scripts/langages/typescript/vitest-config/duree.classement.mjs +1 -1
  214. package/scripts/langages/typescript/vitest-config/duree.reporter.mjs +4 -3
  215. package/scripts/langages/typescript/vitest-config/lances.mjs +3 -2
  216. package/scripts/langages/typescript/vitest-config/machine.setup.mjs +1 -0
  217. package/scripts/langages/typescript/vitest-config/mesure.mjs +1 -1
  218. package/scripts/langages/typescript/vitest-config/mesure.setup.mjs +1 -0
  219. package/scripts/langages/typescript/vitest-config/registre.setup.mjs +1 -0
  220. package/scripts/langages/typescript/vitest-config/resultats.mjs +2 -1
  221. package/scripts/langages/typescript/vitest-config/resultats.setup.mjs +1 -0
  222. package/scripts/langages/typescript/vitest.nuit.config.mjs +3 -2
  223. package/scripts/langages-des-paquets.mjs +3 -1
  224. package/scripts/langages.mjs +5 -3
  225. package/scripts/lecture-unique.mjs +2 -1
  226. package/scripts/lint-des-scripts.mjs +1 -0
  227. package/scripts/machine.mjs +4 -4
  228. package/scripts/matiere-de-test.d.ts +2 -1
  229. package/scripts/matieres-lues.mjs +2 -0
  230. package/scripts/mesure/avancement.mjs +1 -1
  231. package/scripts/mesure/base-de-passe.mjs +10 -13
  232. package/scripts/mesure/pression.mjs +3 -4
  233. package/scripts/mesure-de-la-machine.mjs +2 -1
  234. package/scripts/migrations/0.23.0-charte-importee.mjs +7 -13
  235. package/scripts/migrations/0.23.0-crochets-de-seance.mjs +6 -8
  236. package/scripts/migrations/0.23.0-marche-du-projet.mjs +8 -12
  237. package/scripts/migrations/0.23.2-copies-du-cadre.mjs +9 -32
  238. package/scripts/migrations/0.24.0-circuit-simplifie.mjs +11 -39
  239. package/scripts/migrations/0.24.12-tri-des-decouvertes.mjs +6 -9
  240. package/scripts/migrations/0.24.2-api-extractor-du-paquet.mjs +8 -19
  241. package/scripts/migrations/0.25.0-script-des-tests.mjs +7 -13
  242. package/scripts/migrations/0.27.0-langages-dans-l-architecture.mjs +9 -23
  243. package/scripts/migrations/0.30.0-ci-appelle-la-verification.mjs +7 -9
  244. package/scripts/migrations/0.31.0-paquets-dans-le-graphe.mjs +7 -18
  245. package/scripts/migrations/0.33.0-cache-distant.mjs +6 -9
  246. package/scripts/migrations/0.33.0-ci-du-cadre.mjs +5 -8
  247. package/scripts/migrations/0.33.0-node-26.mjs +5 -8
  248. package/scripts/migrations/0.35.0-greffon-mattpocock-retire.mjs +5 -10
  249. package/scripts/migrations/0.44.0-node-26-seul.mjs +6 -9
  250. package/scripts/migrations/0.44.0-seuil-des-codes-de-tickets.mjs +6 -7
  251. package/scripts/migrations/0.47.0-ci-de-main.mjs +6 -7
  252. package/scripts/migrations/0.48.0-ci-declenchee-par-la-file.mjs +6 -6
  253. package/scripts/migrations/0.48.0-poussee-retiree.mjs +3 -5
  254. package/scripts/migrations/0.49.0-reservation-de-trois-coeurs.mjs +3 -4
  255. package/scripts/migrations/0.50.0-reglages-hors-de-la-charte.mjs +81 -0
  256. package/scripts/migrations-des-gardes.mjs +2 -0
  257. package/scripts/migrations.mjs +4 -0
  258. package/scripts/nuit.sh +48 -15
  259. package/scripts/outil.mjs +2 -1
  260. package/scripts/outils-cles.mjs +6 -6
  261. package/scripts/paquet-npm.mjs +3 -2
  262. package/scripts/paquet.mjs +3 -4
  263. package/scripts/paquets.d.ts +1 -1
  264. package/scripts/paquets.mjs +2 -0
  265. package/scripts/passe-de-la-machine.mjs +9 -12
  266. package/scripts/places-de-la-machine.mjs +36 -53
  267. package/scripts/places-du-serveur.mjs +5 -4
  268. package/scripts/plafond-de-la-machine.mjs +19 -19
  269. package/scripts/poussee-retiree.mjs +2 -1
  270. package/scripts/prefixe-des-tickets.mjs +1 -0
  271. package/scripts/preparation.mjs +2 -1
  272. package/scripts/recommencer.mjs +2 -2
  273. package/scripts/references-changees.mjs +1 -1
  274. package/scripts/registre-des-resultats.mjs +3 -1
  275. package/scripts/regles-des-places.mjs +4 -6
  276. package/scripts/repli-de-la-nuit.mjs +107 -35
  277. package/scripts/reponses-du-circuit.mjs +4 -3
  278. package/scripts/reprise.mjs +3 -2
  279. package/scripts/resultats.mjs +71 -93
  280. package/scripts/retirer-copie.sh +2 -1
  281. package/scripts/retirer-les-copies-finies.mjs +2 -1
  282. package/scripts/seances.mjs +3 -2
  283. package/scripts/services-du-noyau.mjs +3 -0
  284. package/scripts/session-start.sh +0 -6
  285. package/scripts/sortie.mjs +2 -1
  286. package/scripts/sources.mjs +2 -0
  287. package/scripts/sous-commandes.mjs +2 -1
  288. package/scripts/sous-modules.sh +24 -43
  289. package/scripts/style-a-l-ecriture.mjs +2 -0
  290. package/scripts/tableau-des-composants.mjs +5 -7
  291. package/scripts/tableau.mjs +6 -5
  292. package/scripts/taches-du-graphe.mjs +3 -0
  293. package/scripts/ticket-du-circuit.mjs +1 -1
  294. package/scripts/ticket.mjs +3 -0
  295. package/scripts/transitions.mjs +30 -19
  296. package/scripts/un-commit-par-ticket.mjs +2 -1
  297. package/scripts/verdict-de-la-nuit.mjs +2 -1
  298. package/scripts/verrou-de-fichier.mjs +1 -0
  299. package/scripts/verrous/commande.mjs +2 -1
  300. package/scripts/verrous/ecriture-hors-enveloppe.mjs +1 -0
  301. package/scripts/verrous/ticket-du-sous-agent.mjs +1 -0
  302. package/scripts/verrous/verrou.mjs +3 -3
  303. package/scripts/workflows-du-cadre.mjs +2 -1
  304. package/skills/architecte/SKILL.md +203 -0
  305. package/skills/architecte/references/exemple-d-architecture.md +159 -0
  306. package/skills/developpeur/SKILL.md +6 -10
  307. package/skills/explorateur/SKILL.md +1 -1
  308. package/skills/grill/SKILL.md +4 -5
  309. package/skills/grill/references/paquets.md +5 -8
  310. package/skills/pitmaster/SKILL.md +179 -268
  311. package/skills/pitmaster/references/cadre.md +7 -6
  312. package/skills/pitmaster/references/consigne-agent.md +36 -32
  313. package/skills/pitmaster/references/tour.md +2 -2
  314. package/skills/redacteur/references/documents-d-un-composant.md +10 -8
  315. package/skills/testwriter/SKILL.md +8 -11
@@ -0,0 +1,159 @@
1
+ > Exemple : copie de `docs/ARCHITECTURE.md` du projet osc-bridge, donnée ici en exemple d'un document d'architecture abouti ; elle décrit osc-bridge, pas le cadre.
2
+
3
+ # osc-bridge — architecture
4
+
5
+ osc-bridge is an OSC bridge: it lets an agent or a piece of software drive a music device, by translating between OSC messages and the device's MIDI or OSC. Its core translates, one session per device, without touching ports or networks; its transports carry the messages to the wire; its application serves the command line, the MCP server of the local tools and the orchestrator. A device is described by a **card**: one file in the OSD format, read through the `osd` reader, that the person gives. This document describes the target construction of the workspace; the current code (one crate, `crates/osc-bridge/src/`) reaches it by the internal split of section 9, then by the core epic.
6
+
7
+ ## 1. Context
8
+
9
+ ```mermaid
10
+ flowchart LR
11
+ agent[Agent] -- MCP stdio or HTTP --> app[osc-bridge]
12
+ sw[Software, controllers] -- OSC UDP, WebSocket --> app
13
+ app -- MIDI 1, MIDI 2, OSC --> dev[Devices]
14
+ cards[Cards: a file, a folder, a web address] -- OSD, through osd --> app
15
+ prog[Programs built on the bridge] -. take the crates .-> app
16
+ ```
17
+
18
+ What crosses the workspace's edges:
19
+
20
+ - **cards**, from a file, a folder of files, or a web address that returns a card, each given by the person or by the program that calls the bridge;
21
+ - **messages** from agents and software (MCP calls, OSC) and **MIDI or OSC** to and from devices;
22
+ - **the crates** `synth-core`, `synth-io` and the library of `crates/osc-bridge`, which another repository takes at a git tag. Translating between OSD and other formats (MIDNAM, OSCQuery, Electra One, the pencilresearch/midi CSV) is `osd-formats`, in the OSD repository, which the application calls.
23
+
24
+ Each crate's role and refusals live in its `CADRE.md`, what crosses its edges in its `INTERFACE.md`.
25
+
26
+ ## 2. Strategy
27
+
28
+ 1. **The core performs no I/O.** `synth-core` turns messages into MIDI or OSC messages and back, keeps a session per device (script state, dynamic routes), and returns its faults; ports, sockets and clocks are given to it. Reason: the same core runs in this application, in the programs built on it and in a browser, as `quinn-proto` runs under any transport.
29
+ 2. **A device is compiled once.** A resolved card becomes a compiled device whose value encodings, checksums and address templates are parsed when it loads; a template naming an unknown capture is a load fault. Reason: no step re-parses strings while playing, a card that cannot be read is refused at load, and a part that cannot be built is reported at load and refused when used, never in silence mid-performance.
30
+ 3. **The wire is a transport.** MIDI 1, MIDI 2 (UMP) and OSC are adapters of `synth-io` around the same core messages. Reason: a device's description says what it understands, not how the cable carries it.
31
+ 4. **The bridge reads a card from the place it is given.** A card is named by a path or by a web address, and the caller chooses it; what orders two cards of the same device, each from its own place, is a value the caller gives, and two cards of one folder that claim the same device are an error that names both. Reason: the bridge works with any source of OSD cards, and a program that keeps a catalogue hands the bridge a path or an address, as `quinn-proto` receives its congestion controller from its caller.
32
+ 5. **A program builds on the bridge.** The dependency goes one way: a program takes the crates of this workspace, envelops the MCP server (it answers its own tools and hands every other request to the bridge), and adds its commands beside the bridge's. Reason: the bridge is complete alone, and each program adds its service without changing it, as `quinn` depends on `quinn-proto`.
33
+
34
+ ## 3. Components
35
+
36
+ ```mermaid
37
+ flowchart TB
38
+ app[osc-bridge app and library] --> core[synth-core] & io[synth-io]
39
+ io --> core
40
+ core --> osd[osd]
41
+ app --> fmt[osd-formats, in the OSD repository]
42
+ prog[a program, in its own repository] -.-> app & core & io
43
+ ```
44
+
45
+ | Crate | Responsibility | Owns | Calls | Language |
46
+ |---|---|---|---|---|
47
+ | `synth-core` | the session of a device: messages ↔ MIDI or OSC messages, replies, recognition (the request a card names and the reading of the reply), programs, the Lua capability, a virtual device that answers | the compiled device, the session state | `osd` | |
48
+ | `synth-io` | carry core messages: MIDI 1 ports, MIDI 2, OSC over UDP, WebSocket, OSCQuery, output pacing | ports, sockets | `synth-core` (types) | |
49
+ | `crates/osc-bridge` | the application and its library: the command line, the MCP server of the 16 local tools (stdio, HTTP with a token), the orchestrator of several devices with routes between them, the reading of a card from a file, a folder or a web address, the recognition of the plugged devices against the cards given, the dump and restore of sounds, and the putting of an export on a plugged device through its own MIDI port type | the configuration the person gives (options, `bridge.toml`) | both, and `osd-formats` for writing a card in other formats | cargo |
50
+
51
+ The single-device mode is the orchestrator with one device: one dispatch path.
52
+
53
+ The workspace is the root `Cargo.toml`, a virtual workspace, as in rust-analyzer: the application is the crate `crates/osc-bridge` (it builds the `osc-bridge` binary and the `osc_bridge` library), and each crate under `crates/` is listed in its `members` once it has its own `Cargo.toml`. The members take their version, edition and licence from `[workspace.package]`, their lints from `[workspace.lints]` and their shared dependencies from `[workspace.dependencies]`; so the version that `scripts/sync_version.py` mirrors is the workspace's. `cargo build --release` builds the `osc-bridge` binary; `cargo test --workspace` and `cargo clippy --workspace --all-targets -- -D warnings` cover every member.
54
+
55
+ ### 3.1 An illustration: the bridge used by SyntHub, its first client
56
+
57
+ This section illustrates the use of the bridge by a program, with SyntHub, its first and historical client: the program `synthub`, in its own repository, is built on the bridge. Each line says what the bridge does and what the program adds.
58
+
59
+ | Matter | The bridge | The program |
60
+ |---|---|---|
61
+ | where a card comes from | reads the file, the folder or the web address it is given, and keeps a copy of a card read from a web address | turns a catalogue id or a short name into a path or an address, keeps its cache, and orders the sources of a card |
62
+ | recognition | compares the ports, the USB ids and the identity replies with the cards given | adds the candidates of its service, listens to an unknown device (learn mode) and shares its fingerprint |
63
+ | agents | serves the 16 local tools | envelops that server and adds the tools of its service |
64
+ | sounds | dumps and restores by the card, puts an export on a device | takes a sound through its service's librarian |
65
+ | the person's devices from outside | serves OSC and MCP on the person's machine | opens the relay door, keeps the account and the privacy settings |
66
+ | contract with a service | exchanges OSC, MIDI, MCP and OSD only | holds `synthub-protocol` |
67
+
68
+ ### 3.2 The guard of the frontier
69
+
70
+ Two checks hold the frontier, and a lot that breaks one is refused before main.
71
+
72
+ - **The graph of the crates.** No manifest of the workspace names a crate of a program or of a service; Cargo then refuses any import of one, as it refuses `quinn-proto` importing `quinn`.
73
+ - **The sources.** A test of `crates/osc-bridge` reads the code of the workspace and refuses the name or the host name of a service: every web address the bridge opens comes from the person. During the internal split (section 9) the same test refuses, in every module of the bridge, an import of the one module that holds the link to the service.
74
+
75
+ ## 4. Data
76
+
77
+ | Data | Shape | Made by | Read by | Lifetime |
78
+ |---|---|---|---|---|
79
+ | card source | a path or a web address | the person, a program | the application | one load |
80
+ | copy of a web card | the card as the address returned it | the application | the application | on disk |
81
+ | resolved device | `osd` types | `osd::resolve` | `synth-core` | one load |
82
+ | compiled device | encodings, checksums and templates parsed | `synth-core` | the session | the session |
83
+ | session | script state, dynamic routes, pending replies | `synth-core` | the application, the programs built on the core | while the device is connected |
84
+ | core message | address and typed arguments, or a MIDI message | callers, `synth-io` | `synth-core` | one message |
85
+
86
+ Bytes stay bytes between crates; hexadecimal exists only at the edges a human or a client reads, written one way (upper case, spaced).
87
+
88
+ ## 5. Flow
89
+
90
+ **An agent sets a parameter through the local MCP server.**
91
+
92
+ ```mermaid
93
+ sequenceDiagram
94
+ participant A as Agent
95
+ participant M as osc-bridge (MCP)
96
+ participant C as synth-core session
97
+ participant I as synth-io
98
+ participant D as Device
99
+ A->>M: tools/call (address, value)
100
+ M->>C: core message
101
+ C-->>M: MIDI messages, or a consent request
102
+ M->>I: MIDI messages
103
+ I->>D: bytes on the port
104
+ D-->>I: reply
105
+ I-->>C: MIDI message
106
+ C-->>M: core messages
107
+ M-->>A: structured result
108
+ ```
109
+
110
+ **The application loads a card from a web address.**
111
+
112
+ ```mermaid
113
+ sequenceDiagram
114
+ participant P as Person
115
+ participant M as osc-bridge
116
+ participant W as Web address
117
+ participant O as osd
118
+ participant C as synth-core
119
+ P->>M: a command naming the address
120
+ M->>W: GET, redirections followed
121
+ W-->>M: a card, or an answer that is no card
122
+ M->>M: keep a copy of the card
123
+ M->>O: resolve
124
+ O-->>M: resolved device, or a fault
125
+ M->>C: compile
126
+ C-->>M: compiled device, or a load fault
127
+ M-->>P: the bridge runs, or an error naming the address and the cause
128
+ ```
129
+
130
+ The card an address returns is complete: it names no parent, and `osd` resolves it alone. When the network does not answer, the application loads the copy it kept of that address.
131
+
132
+ ## 6. Runtime
133
+
134
+ - The application runs on the person's machine or one they choose; the MCP server listens on stdio, or on HTTP with a token, local by default.
135
+ - With cards given as files or folders the application opens no connection to the network; a card named by a web address is read when it loads, and the application keeps a copy of it, from which it starts again without the network. That copy holds only the cards the person named by an address: it is no cache of a service, and it carries no catalogue id and no short name.
136
+ - A folder of cards is required to recognise the plugged devices and to serve agents: `detect` and `mcp` read the cards of the folder the person gives, and nothing else.
137
+ - `synth-core` and `osd` compile to `wasm32-unknown-unknown`; `synth-io` and the application are native.
138
+ - Output to a device is paced by `synth-io`; nothing on the playing path waits on the network.
139
+
140
+ ## 7. Cross-cutting concepts
141
+
142
+ - **Safety**: every SysEx that may overwrite a device's memory is a consent request the caller must answer; only the identity request goes out without it.
143
+ - **Faults**: each crate returns typed faults; nothing is reported only on standard error. The faults of a message return to the one who sent it.
144
+ - **Capabilities**: a card that needs Lua declares it; the core runs scripts in a sandbox with time and memory budgets.
145
+
146
+ ## 8. Quality
147
+
148
+ - **Live play**: a bench measures the core's delay from message to bytes; budget under 1 ms per message.
149
+ - **One test surface**: the session is tested through its interface with the shared cases (card, inputs, expected outputs), never by opening a module's inside.
150
+ - **Compatibility**: a published surface has one form; a valid card stays readable by later versions.
151
+ - **The frontier**: the guard of section 3.2 runs with the tests of `crates/osc-bridge`.
152
+
153
+ ## 9. Risks
154
+
155
+ - The current code reaches this construction by steps. The internal split comes first: the link to the SyntHub service (its client, the relay door, the account, the privacy settings, the cache, the learn mode, the tools of the service) moves into one module of `crates/osc-bridge`, the dependencies that cross the frontier are inverted, and the behaviour of the binary stays the same; that module stays one module of the crate until the repository of the program is born, then leaves for it. `crates/osc-bridge/src/mcp.rs` and `crates/osc-bridge/src/runtime.rs` hold most of today's logic and split across the crates during the core epic.
156
+ - A repository that takes the library at a tag reads modules that leave with the link; it follows at the tag where they leave. The SyntHub service reads such modules, so the link leaves the bridge after the repository of the program is born.
157
+ - A card read from a web address is complete today; the address of a parent outside a folder waits for the OSD specification.
158
+ - MIDI 2 is carried by no device of the catalogue today; its transport opens when one needs it.
159
+ - The Lua budgets are measured per frame; a device whose scripts exceed them in live play is not yet observed.
@@ -82,7 +82,7 @@ après lui, écrit le rapport d'API et la part générée des paquets du plan. L
82
82
  partagée, en lecture seule pour toi, arrive construite : `npm test -- <un test de la matière>` la
83
83
  joue sans la construire, et les journaux et le cache du lancement restent dans ta séance. Les
84
84
  gardes du cadre (frontières, consommateurs, index des interfaces, rapports d'API) tournent à côté
85
- des tests, dans la passe complète que l'intégration joue ; le relecteur les joue seules sur la
85
+ des tests, dans la passe finale ; le relecteur les joue seules sur la
86
86
  copie ; leur refus nomme la commande qui corrige. Le jour ne mesure aucun temps : un délai dépassé
87
87
  est un rouge. Un lancement qui nomme une mesure de temps (un banc, un témoin de temps) ou un test
88
88
  de nuit et sort en 75, « à repasser », n'a vu que des échecs de durée sous charge (la pression CPU
@@ -136,8 +136,7 @@ son adresse) : le circuit la consigne fermée sous ton ticket, et tu continues.
136
136
  ## Vérifier et livrer
137
137
 
138
138
  - **Le circuit contrôle après toi** : ta séance finie, le circuit du ticket joue les tests du lot
139
- et de chaque paquet du plan, puis les gardes dans l'enveloppe du plan ; puis la passe finale, la
140
- passe complète que joue l'intégration. Un rouge te relance avec sa sortie quand il est dans un
139
+ et de chaque paquet du plan, puis les gardes dans l'enveloppe du plan ; puis la passe finale. Un rouge te relance avec sa sortie quand il est dans un
141
140
  paquet du plan ; hors du plan, il attend la passe finale, où il monte au superviseur. Tu es lancé
142
141
  sur un rouge (de la preuve, un `rouge existant` compris, ou des contrôles), sur un constat du
143
142
  relecteur ouvert pour toi, ou directement sur un plan qui ne porte aucun test (aucun paquet qui
@@ -151,15 +150,12 @@ son adresse) : le circuit la consigne fermée sous ton ticket, et tu continues.
151
150
  RÉFÉRENCES QUE LE CIRCUIT RÉGÉNÈRE » se réécrivent à l'étape 4.2, sur la copie entière : l'index
152
151
  des interfaces, les `turbo.json`, les rapports d'API, la dette des gardes, et celles que le
153
152
  projet déclare, un plafond par exemple. Leur rouge n'est pas le tien : ta séance ne s'arrête pas sur elles,
154
- et ta fiche finit FAIT sur ta part. Exemple : en 320.8 de BPScript, un développeur aux tests
155
- verts s'est arrêté sur le plafond des mots, la dette et l'index, que 4.2 a régénérés ensuite.
153
+ et ta fiche finit FAIT sur ta part.
156
154
  Le circuit les régénère avant de te rendre tes rouges : un test qui les lit, sous « Tes rouges »,
157
- a déjà été jugé sur elles régénérées. Exemple : en 320.6.5 de BPScript, un test qui lisait les
158
- `turbo.json` périmés est allé au développeur, qui ne pouvait pas les écrire.
155
+ a déjà été jugé sur elles régénérées.
159
156
  Un constat de leur garde sur ton code reste le tien, sous « Tes rouges », comme le refus de leur
160
- commande qu'il cause : un plafond ne monte jamais. Exemple : en 320.10 de BPScript, le mot
161
- « door » écrit dans 030-binder dépassait le plafond des mots. Ainsi le geste mécanique reste au
162
- circuit, et ton code à toi.
157
+ commande qu'il cause : un plafond ne monte jamais (un mot neuf de ton code qui dépasse le plafond
158
+ des mots est à toi). Ainsi le geste mécanique reste au circuit, et ton code à toi.
163
159
  - **Un rouge qui reste dans les tests va au testwriter** : quand le rouge qui reste est dans les
164
160
  tests du lot (un test existant que ton changement de type casse), ta fiche porte `renvoi`, le
165
161
  rôle testwriter. Le circuit relance le testwriter, ta `raison` et ta passation pour rapport, avec
@@ -193,7 +193,7 @@ fois, et seules celles qui comptent attendent le responsable.
193
193
  `cd` ni enchaînement, ma séance tournant déjà dans l'arbre principal (hors de lui,
194
194
  `git -C <depot> show <commit>`, `git -C <depot> log --oneline --grep <ticket>`). Une commande
195
195
  refusée, je la relance sous sa forme simple. Ainsi une découverte n'attend jamais le
196
- responsable sur un refus de forme (BP 320.39 : trois `non-confirmee` sur une boucle refusée).
196
+ responsable sur un refus de forme.
197
197
 
198
198
  2. **Le verdict.** Ma fiche du tri porte une ligne par découverte de ma consigne, ni plus ni moins
199
199
  (`verdicts`), chacune avec son `texte` :
@@ -146,12 +146,11 @@ remplace jamais le grill. Les branches de l'arbre :
146
146
  sauf `--heure <0-23>`) lance la nuit de chaque projet du registre
147
147
  qui a bougé depuis sa dernière nuit verte, l'un après l'autre ; `npx grillhouse nuit <racine>`
148
148
  la demande à la main. La nuit rejoue pour de vrai la passe complète, puis les tests de nuit et
149
- les bancs de budget, que le jour ne joue pas. La passe
150
- finale du circuit joue `npm run verifier` en entier (les gardes, le typage de chaque paquet et
151
- les tests) sur le lot posé sur la pointe de main avant que main avance ; la CI du projet joue
152
- ensuite sur main, chaque heure, par paquets.
149
+ les bancs de budget, que le jour ne joue pas (le document de l'entrée sur main, §5.3). Main
150
+ n'avance que sur un lot que la passe finale a jugé vert, et la CI du projet joue ensuite sur
151
+ main (le même document, §5.1, §5.2).
153
152
  Restent des choix selon la taille du projet, que le responsable tranche :
154
- - **le contrôle de l'interface contre le code** (`packages/grillhouse/scripts/langages/typescript/interfaces-contre-code.mjs`) : une
153
+ - **le contrôle de l'interface contre le code** (la garde `interfaces-contre-code`) : une
155
154
  seule passe avant les tests (petit projet), ou un banc par composant qui appelle
156
155
  `verifierComposant`, rejoué seulement quand son composant l'est (grand projet).
157
156
  - **les sous-modules partagés** : un sous-module qu'aucun ticket n'écrit (un moteur de
@@ -37,14 +37,11 @@ son propre paquet, dont il importe l'entrée construite, et de tout ce qu'il imp
37
37
  inchangée se restaure de son cache. Une construction ne compte que ce qu'elle lit : le
38
38
  `package.json`, le `tsconfig.build.json` du paquet, ce qu'il étend et les dossiers qu'il inclut
39
39
  (un fichier listé, son dossier) ; un fichier de test changé ne rejoue ni elle ni ses dépendants.
40
- Le `turbo.json` de la racine est au projet : la mise à jour
41
- du cadre l'écrit une fois, depuis le gabarit de sa forme (`templates/turbo/paquets.json` quand
42
- le `package.json` déclare `workspaces`), puis n'y écrit que ce que le cadre en tient (les
43
- dépendances des gardes, la variable des passes ciblées, l'exclusion `!$TURBO_ROOT$/<chemin>/.git`
44
- à côté d'une entrée qui couvre un sous-module, dont le `.git` nomme la copie). Celui de chaque paquet est
45
- généré depuis son `package.json` (`npx grillhouse turbo-des-paquets --ecrire`, que la mise à
46
- jour lance) et `grillhouse:gardes` refuse un fichier absent ou périmé : une dépendance s'écrit
47
- au `package.json` seul. Chaque paquet testé porte son script
40
+ Le `turbo.json` de la racine est au projet, la mise à jour du
41
+ cadre n'y écrivant que ce que le cadre en tient ; celui de chaque paquet est engendré depuis son
42
+ `package.json` (`npx grillhouse turbo-des-paquets --ecrire`), et la garde `turbo-des-paquets`
43
+ refuse un fichier absent ou périmé : une dépendance s'écrit au `package.json` seul (le document
44
+ des tests, §3.1, §3.4). Chaque paquet testé porte son script
48
45
  `test:unit` et sa configuration Vitest, qui étend la configuration de base du cadre, le
49
46
  `@roomi-fields/grillhouse/vitest-config`, que le paquet du cadre exporte (par `mergeConfig`) : les
50
47
  exclusions du jour (tests de nuit, bancs de budget) et l'environnement commun y sont, sans