Skip to content

examples: richer per-rule comment headers in sample policy.yaml #7

Description

@CodewithJha

👋 New to open source?
Thanks for considering contributing to Mutiny.
This issue is intentionally beginner-friendly.
If you get stuck, ask questions in the comments.
We're happy to help.

Context

examples/openai_support_agent/policy.yaml is the first policy people read. It already has one-line comments per rule. The scaffold template in mutiny init (POLICY_YAML in init_cmd.py) uses richer boxed headers (what it checks / what to edit). The sample should teach at that level.

Goal

Upgrade sample rule comments to clear per-rule headers (intent + operator/kind + edit hint) without changing YAML behavior.

Why it matters

Comments are the cheapest operator tutorial. Aligning sample ↔ scaffold reduces “which file is the real example?” confusion.

Acceptance criteria

  • Each rule has a short header comment explaining intent / kind / what a newcomer might edit
  • YAML remains valid; cd examples/openai_support_agent && uv run mutiny run --no-hosted still works (or dry-parse / existing sample path)
  • No behavior or rule semantic changes (same ids, tools, thresholds)
  • PR description links this issue

Suggested files

  • examples/openai_support_agent/policy.yaml
  • Optional reference: header style in packages/mutiny_cli/src/mutiny_cli/init_cmd.py (POLICY_YAML)

Out of scope

  • Adding/removing rules, Core changes, rewriting examples/policies/demo_support.json

Hints

  • Copy the boxed-comment style from the init stub, then tailor wording to the three sample rules (refund_limit, delete_requires_confirm, deny_send_email).
  • Keep the top-of-file banner that explains Hosted vs examples/policies/ harness.

Difficulty

XS · examples / docs · comments only

Docs

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation improvementsexamplesSample projects and policy packsgood first issueGood for newcomers

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions