mcpField
E
egm-resolve

egm-resolve

github.com/googleDocuments4.7k60 installsUpdated today
Repository

About egm-resolve

A skill that processes aggregated findings from Goldfish reviewers against a target document. It classifies critiques as contested or valid, prepares a review report, and supports user-directed resolution of proposed text changes.

Key features

  1. 01Parse reviewer findings
  2. 02Contest or validate each critique
  3. 03Create a prioritized review report
  4. 04Offer interactive resolution choices
  5. 05Apply approved textual fixes

Use cases

  1. 01Triage findings on a document
  2. 02Defend text using code or design evidence
  3. 03Prepare proposed edits for review
  4. 04Apply approved fixes in a batch

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/google/elephant-goldfish-model --skill egm-resolve

After installing, type/egm-resolvein Claude Code to confirm it loaded.

Bundled filestest_scenarios.yamlTEST.md

Details

From the project README

Goldfish Review: Resolve

When running in Codex or ChatGPT Work, first read Codex integration. In Claude Code or Cowork, read ${CLAUDE_PLUGIN_ROOT}/docs/claude.md first.

Overview

This skill instructs the agent on how to operate within the primary Elephant context window to parse flat deficiency reports from concurrent Goldfish reviewers. It defends accurate design choices, applies automated textual repairs, and manages interactive negotiation checkpoints.

Prerequisites & Context Strategy

  • Context Recommendation (Elephant Memory): This skill should be run in the persistent conversation session that generated the target document (the Elephant) to recall earlier reasoning and craft higher-quality fixes.

Inputs

The caller or orchestration driver provides exactly these parameters:

  • TargetFile: Absolute or relative path to target document.
  • LineRange: Exact line numbers (or full file).
  • FindingsList: Aggregated flat list of findings from Goldfish reviewers.

Execution Workflow

Step 1: Intake Validation & Gather Context
  1. Hybrid Execution UX: Detect if execution arguments are present:

    • Automated Mode: If all parameters are provided, execute silently as a subprocess.
    • Standalone Human Mode: If parameters are omitted, trigger a friendly onboarding flow. Prompt for one piece of input at a time, waiting for the user's response after each turn. Once all inputs are specified, display the final setup and verify the user is ready to continue.
  2. Read TargetFile at LineRange by reading it and parse the FindingsList.

Step 2: Evaluate & Categorize

For each finding in the list, determine:

  • CONTEST: The critique is inaccurate or relies on a misunderstanding of the codebase. Provide exact code or design doc evidence defending current text.
  • PROPOSE FIX: The critique is valid. Define precise textual replacements or structural formatting adjustments to resolve the gap.
Step 3: Report Fixes

Construct the final report and save it named goldfish_review_report.md in the working directory (or your harness's artifact directory, if it has one) using your file-writing tool. Use this layout:

# Goldfish Annotated Review Report

**Target:** `[TargetFile]` (`[LineRange]`)

## Prioritized Findings & AI Suggestions

{{range findings, ordered by Severity}}
### [Issue 1] [`[ReviewerPersona]`] - Severity: [High | Medium | Low]
*   **Affected Scope:** [Lines Start-End]([RelativePath]#L[Start]-L[End]) ([Sub-header])
*   **Discrepancy Description:** [copied from FindingsList]
*   **Rationale:** [copied from FindingsList]
*   ***AI Suggestion:*** [CONTEST | PROPOSE FIX]
*   ***Justification:*** [Detailed reason]
*   ***Proposed Edit:***
    *   Location: [Line/Header]
    *   Change: [Precise replacement string or deletion note]
{{end}}
Step 4: Interactive Resolution Gate

Before proceeding, output a visible chat message to the user: *"I have compiled the audit findings into goldfish_review_report.md. Please review the findings there and choose how you would like to proceed:

  • Comment directly on the file: Review goldfish_review_report.md in chat or the file and leave comments/edits to approve, reject, or contest specific items.
  • Auto accept: Reply "auto accept" to batch-apply all proposed fixes (skipping contested items).
  • Continue to next phase: Reply "continue" or "no changes" to proceed without applying fixes.
  • Interactive breakdown: Reply "interactive breakdown" for a guided, item-by-item walkthrough in chat with detailed explanations for each proposed edit or contested finding before making decisions.
  • Custom instruction / Wildcard request: Reply with any custom instruction, question, or out-of-band request."*

You MUST immediately yield active execution by calling zero tools in this turn payload. You must stop execution and go idle, waiting for the human developer to comment on/edit the artifact or reply in the chat.

Interpret the user's action/response as follows:

  • "Auto accept" / "Accept all suggestions" / User clicks "Proceed" without contesting: Apply all fixes where the AI suggestion was PROPOSE FIX directly to TargetFile at LineRange in a single batch using your file-editing tool. Any items categorized as CONTEST are explicitly bypassed. Then proceed to Step 5.

  • "Continue to next phase" / "No changes": Do not apply any automated fixes. Then proceed to Step 5.

  • "Interactive breakdown": Enter a sequential breakdown loop over ALL finding items (both PROPOSE FIX and CONTEST):

    1. For each item i, output a visible chat message formatting the full finding details and explanation in rich markdown:

      ### Breakdown Item [i]: [Issue Title] [`[ReviewerPersona]`]
      * **Scope:** [Lines Start-End]([RelativePath]#L[Start]-L[End]) ([Sub-header])
      * **Description:** [Description]
      * **AI Suggestion:** [CONTEST | PROPOSE FIX]
      * **Explanation & Justification:** [Detailed reason and background explaining why the fix is proposed or why the finding is contested]
      * **Proposed Edit:** [Precise replacement text or deletion note]
      

      Then prompt the user in chat for their decision on this item (calling zero tools and going idle):

      • If PROPOSE FIX: Ask the user to reply with Accept proposed fix, Skip / ignore, or Discuss.
      • If CONTEST: Ask the user to reply with Skip / agree with contest, Overrule contest (propose fix), or Discuss.
    2. Record the user's decisions in an internal memory checklist (e.g., Item 1: Accepted, Item 2: Ignored, Item 3: Overruled). Do NOT call any file editing tools during this sequential loop.

    3. Once all items have been decided, summarize the accepted edits, execute them using your file-editing tool, and proceed to Step 5.

  • Custom instruction / Out-of-band edit: If the user provides targeted instructions, apply them and proceed.

Step 5: Post-Resolution Synchronization & Exit
  1. Re-verify Lines: If changes were made to TargetFile, verify that the file remains structurally coherent and valid markdown.
  2. Mark the report as resolved (add a Status: resolved line at the top).
  3. Handoff: Exit cleanly back to the caller (such as egm-review-loop) with the count of accepted fixes, contested items, and remaining unaddressed issues.

Comments

Markdown supported