omp packages

any-line-slash0.5.0

Open the slash menu on any line of the pi editor, and render one collapsible card per skill or prompt in one message.

pharaohnie Published 7 days ago MIT ~324 downloads/mo

Untested on omp

This is a pi package. No one has reported whether it works on omp yet. If you try it, add your result below.

Did it work for you?

Result

One report per person. A new report replaces your old one.

Reports 0

No reports yet.

Readme

any-line-slash

Two fixes for pi: the slash menu works on any line, and every skill in one message gets its own card.

1. Slash menu on any line

pi opens the command menu only on the first line. This extension opens it everywhere: at the start of a line, or after a space.

pi alone:
  Fix the parser.
  /              ← nothing happens

with any-line-slash:
  Fix the parser.
  /              ← menu opens here

2. One card per skill and prompt

pi expands one /skill: per message: the one at the start. Every other command stays plain text, so the skill body never loads. A prompt template renders as plain text too.

You type:

/review
/skill:tests
/skill:security
Check both.

Without this extension, no card appears. The template text blends into your message, and both skill commands stay as typed:

(review template text)

/skill:tests
/skill:security
Check both.

With this extension, each part gets its own collapsible card:

[prompt] review (ctrl+o to expand)

[skill] tests (ctrl+o to expand)

[skill] security (ctrl+o to expand)

Check both.

Two commands on one line expand the same way, and each command keeps its own arguments.

Install

pi install npm:any-line-slash

Restart pi, or run /reload.

Limits

  • A command must start a line or follow a space. In /skill:a/skill:b, b stays an argument of a.
  • If the card renderer cannot load, 2 or more skills merge into one card. The message still expands.
  • Prompt templates come from $PI_CODING_AGENT_DIR/prompts (default ~/.pi/agent/prompts). Project templates stay unread.
  • HTML export shows a prompt card as plain text.

Compatibility

Written against pi 1.4.0. Expansion uses the public input hook. The cards and the menu need small patches to pi internals (InteractiveMode.addMessageToChat, Editor), so a future pi release may fall back to merged cards.

License

MIT