credit-note-fixer

Fix credit-note formatting to keep label credit and amount positive.

3.6k|897|Updated May 31, 2025
One-click install
npx skills add https://github.com/openai/openai-agents-js --skill credit-note-fixer-openai
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: credit-note-fixer
Source: https://github.com/openai/openai-agents-js/tree/main/examples/sandbox/data/coding-task/skills/credit-note-fixer
Command: npx skills add https://github.com/openai/openai-agents-js --skill credit-note-fixer-openai

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

The tiny credit-note formatting bug caused incorrect labeling or negative amount in tests; fix is to adjust the code to ensure the output label remains "credit" and the amount stays positive.

Core Features & Use Cases

  • Smallest correct patch to align output label with "credit" and guarantee positive amount.
  • Deterministic test workflow using the existing repository tests, with workspace-relative paths when applying patches.
  • Use case: a developer quickly patches a failing credit-note test and verifies with the targeted test script.

Quick Start

Apply the smallest correct change so the output label remains credit and the amount is positive, then run exactly sh tests/test_credit_note.sh from repo/ to verify.

Frequently Asked Questions about credit-note-fixer

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix a credit-note formatting bug that mislabels the output or produces a negative amount?

To fix a credit-note formatting bug, apply the smallest correct patch to ensure the output label remains "credit" and the amount stays strictly positive. The fix is scoped to the minimal necessary code change to align the output formatting.

What's the best way to verify a credit-note bug fix using a targeted test script?

The best way to verify a credit-note bug fix is by running the exact repository test script sh tests/test_credit_note.sh from the repo directory. This deterministic workflow validates that the label and positive amount constraints are met.

Why does my credit-note test fail with incorrect labeling or negative amounts?

A credit-note test fails with incorrect labeling or negative amounts because the underlying code does not enforce the output label as "credit" or constrain the amount to a positive value. Adjusting the code to enforce these constraints resolves the failure.

Do I need any external dependencies to patch a failing credit-note test?

No external dependencies are required to patch a failing credit-note test. The patch uses workspace-relative paths and verifies the fix by running the existing repository test script, ensuring a self-contained and deterministic workflow.

Can I apply a minimal patch to correct credit-note output formatting without breaking existing tests?

Yes, you can apply a minimal patch to correct credit-note output formatting by scoping the change to the smallest possible adjustment. Running the targeted test script confirms the label and positive amount fixes without breaking existing tests.

Are there limitations to using a smallest-change patch for credit-note bug fixes?

A limitation of the smallest-change patch for credit-note bug fixes is that it strictly scopes adjustments to the immediate formatting error. It does not address broader architectural issues if the negative amount or mislabeling stems from deeper logic flaws.