Extension SDK
RAIQL 1.0 introduces a stable plugin API for teams that need organization-specific artifacts without forking the compiler.
Plugin contract
A plugin is an ES module with a default export declaring name, version and apiVersion: "1". Hooks receive the compiled IR, the current generated-file map and project options.
export default {
name: "architecture-notes",
version: "0.1.0",
apiVersion: "1",
generate({ ir }) {
return { files: {
"ARCHITECTURE.md": "# " + ir.application.name + "
"
}};
}
};Configure plugins
{
"version": "1.0",
"source": "app.raiql",
"output": "generated",
"plugins": [
"./plugins/architecture/index.mjs",
{ "use": "./plugins/policy/index.mjs", "options": { "strict": true } }
]
}Paths are resolved from the RAIQL project root. Plugin options are passed as immutable configuration data.
Create and inspect
raiql plugin:init plugins/architecture --name architecture-notes
raiql plugins
raiql validate
raiql generateSafety boundary
Plugins are trusted local build code and execute with the same operating-system permissions as the CLI. RAIQL 1.0 keeps generator extensions additive: plugins may create new text files but cannot overwrite core-generated files.
SDK package
The downloadable raiql-plugin-sdk package exports definePlugin, the plugin API version and TypeScript declarations for plugin authors.