Write your first rule

Make ParrotFlow write "P0" when you say "P zero". Add a short replace rule to config.yaml, put it in the pipeline, and test it from the terminal.

What you will get

You say You get
This is P zero This is P0
Mark it P one Mark it P1
That can wait, it’s P two That can wait, it’s P2

The rule is a table of phrases. It needs no model and costs nothing at run time.

Let your coding agent write it

The ParrotFlow skill teaches a coding agent how to edit your config and check it. Add it once:

npx skills add znat/parrotflow --skill parrotflow

Then describe the rule in your own words:

/parrotflow When I say P zero, P one or P two, I want the number as a digit.

The agent writes the rule into config.yaml and checks it with --check-config. Read the steps below to know what it should have written. Then run the checks yourself.

Write it by hand

  1. Open ~/.config/parrotflow/config.yaml. From the menu bar, use Settings, then Edit Config.

  2. Add this entry under the transforms: key that is already in the file. Do not add a second transforms: key.

    transforms:
      - name: priorities
        description: spoken priority levels as P0, P1 and P2
        replace:
          'P0': ['P zero']
          'P1': ['P one']
          'P2': ['P two']

    Each key under replace: is the text to write. Its list holds the phrases that become that text. A phrase matches as a whole word, in any case, so “p two” also becomes “P2”.

    The description lets you run the rule by voice with “hey parrot”. Without it, --check-config lists the rule under “not by voice”.

  3. Add a step for it at the end of transcription.pipeline. A transform runs on every dictation only when the pipeline names it. Keep the steps that are already there.

    transcription:
      pipeline:
        # the steps already in your config stay here
        - transform: disfluency
        - transform: priorities
  4. Save the file. The app reloads it at once. No restart.

Check that it worked

The commands below use the full path to the app. If you installed with Homebrew, parrotflow runs the same binary.

Ask the app what it loaded:

/Applications/ParrotFlow.app/Contents/MacOS/ParrotFlow --check-config

Look for two lines. The pipeline line ends with your step, and the replace section counts your rules:

  · pipeline          sentence_repair → vocabulary → … → transform disfluency → transform priorities
      table     priorities — 3 rule(s), spoken priority levels as P0, P1 and P2

Then run one sentence through your pipeline. --replace uses your config and skips the steps that call a model.

/Applications/ParrotFlow.app/Contents/MacOS/ParrotFlow --replace "This is P zero"
This is P0

Try a sentence that must not change too. “Make it P three” comes back as it was, because the table has no rule for it.

Last, dictate “This is P zero” into any text field.

Limits

  • The table only knows the phrases you list. Add one line per level you use.
  • It does not touch a digit the recogniser already wrote. “P 2” stays “P 2”.
  • It runs in every app. To limit it to some apps, add app: to the step. See Apps in pipelines.md.
  • If the step is missing from the pipeline, nothing happens. --replace prints your sentence unchanged.