Skip to content

Quickstart

This procedure creates a package with one post-pitch control.

Use scaffold and SDK versions published for the same Amadeus release.

Run the scaffold tool in an empty working directory:

Terminal window
npx create-amadeus-plugin my-pitch-package
cd my-pitch-package
npm install
npm run build

The scaffold creates plugin.toml, source files, a build command, and a type-check command. When prompted, choose TypeScript or JavaScript and one supported bundler.

Replace the generated entry with a minimal processor:

import { param, plugin } from "@amsvs/api";
plugin("com.example.pitch")
.name("Pitch adjustment")
.params(
{
amount: param.number({
default: 0,
min: -100,
max: 100,
step: 1,
label: "Shift (cents)",
help: "Relative pitch shift. 0 = unchanged.",
cacheScope: "f0_and_later",
}),
},
{ label: "Pitch adjustment", stages: ["pitch"] },
)
.hooks({
stage: "post_pitch",
postPitch(ctx) {
const factor = Math.pow(2, this.params.amount / 1200);
for (let frame = 0; frame < ctx.f0.length; frame++) {
if (ctx.f0[frame] > 0) ctx.f0[frame] *= factor;
}
return ctx.f0;
},
})
.register();

At 0 cents, the hook leaves the contour unchanged. Positive values raise voiced pitch and negative values lower it; unvoiced frames remain zero. Build the package after each source change. The output entry must match the entry path in plugin.toml; otherwise Amadeus cannot load the package.

  1. In Amadeus, open View → Plugins… and choose Open folder.
  2. Copy the package directory into the displayed plugin directory.
  3. Choose Reload, enable the package, and open a project with a voice.
  4. In Pitch mode, confirm that the parameter group appears, then bake and audition the result.

If the parameter group does not appear, confirm that the package is enabled and that its manifest entry and checksum match the built file. Before distribution, set the package version and SHA-256 checksum. See Publishing.