Complete documentation system for LLM consumption: primary LLM_CONTEXT.md (27KB system overview), 4 module deep-dives (composer, reaper-builder, reaper-scripting, calibrator), 2 JSON Schema draft-07 contracts, CLI reference, and README correction (FL Studio -> REAPER identity).
3.2 KiB
Tasks: LLM-Ready Documentation
Phase 1: Primary Entry Point
- 1.1
docs/LLM_CONTEXT.md— Write full entry-point (~35KB). Sections: system identity (REAPER.rpp), ASCII architecture diagram, all 11 dataclasses fromsrc/core/schema.py, pipeline (compose → build → calibrate → validate → ReaScript), module map (src/dirs → roles), plugin system (PLUGIN_REGISTRY,ALIAS_MAP, presets), ReaScript protocol, CLI reference (compose.py, generate.py, run_in_reaper.py), naming conventions, extension guide. Valid markdown, under 40KB.
Phase 2: Module Deep-Dives
-
2.1
docs/modules/composer.md— Documentsrc/composer/: pattern generators (patterns.py,rhythm.py), chord engine (chords.py), melody engine (melody_engine.py), converters, templates, variation. Public API signatures, data flow, dependencies. Link toLLM_CONTEXT.md. -
2.2
docs/modules/reaper-builder.md— DocumentRPPBuilderclass,PLUGIN_REGISTRY(~150 entries: key→display_name,filename,uid_guid),ALIAS_MAP,PLUGIN_PRESETS, preset transformer,render.pyheadless render.write()signature. Dependency onsrc/core/schema.py. Link toLLM_CONTEXT.md. -
2.3
docs/modules/reaper-scripting.md— DocumentReaScriptCommand,ReaScriptResult(fromsrc/reaper_scripting/commands.py),ReaScriptGenerator, command/result JSON contract,ProtocolVersionError. Link toLLM_CONTEXT.md. -
2.4
docs/modules/calibrator.md— DocumentCalibrator.apply()post-processing pipeline, mix calibration presets (src/calibrator/presets.py). Link toLLM_CONTEXT.md.
Phase 3: Schemas and CLI Reference
-
3.1
docs/schemas/song-definition.json— JSON Schema draft-07 forSongDefinition+ all nested dataclasses (SongMeta,TrackDef,ClipDef,MidiNote,SectionDef,PluginDef,PatternDef,ArrangementItemDef,CCEvent,ArrangementTrack). Match field names and types exactly fromsrc/core/schema.py. -
3.2
docs/schemas/reascript-protocol.json— JSON Schema draft-07 forReaScriptCommandandReaScriptResult. Match field names and types fromsrc/reaper_scripting/commands.py. -
3.3
docs/CLI.md— Complete CLI reference:compose.py(--bpm, --key, --output, --seed, --emotion, --inversion, --no-calibrate),generate.py(--bpm, --key, --output, --seed, --emotion, --inversion, --validate),run_in_reaper.py(<rpp_path>, --output, --timeout, --plugins-config, --action). Link toLLM_CONTEXT.md.
Phase 4: README Correction and Verification
-
4.1
README.md— Replace FL Studio/.flpwith REAPER/.rpp. Remove all MCP server references. List real CLI scripts. Link todocs/LLM_CONTEXT.md. -
4.2 Verify all internal links — Extract every
[text](path)and[text](#heading)from all doc files; confirm each target file/heading exists. -
4.3 Validate JSON schemas — Validate
song-definition.jsonandreascript-protocol.jsonagainst JSON Schema draft-07 meta-schema. Validate sampleSongDefinition.to_json()output againstsong-definition.json. -
4.4 Verify field names match code —
grepeach dataclass field name found in docs againstsrc/core/schema.py.grep -i "fl studio|\.flp|mcp" README.mdmust return empty.