8000 fix(math): document registered check tool by Mnehmos · Pull Request #106 · Mnehmos/mnehmos.rpg.mcp · GitHub
[go: up one dir, main page]

Skip to content

fix(math): document registered check tool - #106

Merged
Mnehmos merged 1 commit into
mainfrom
codex/check-tool-docs
Aug 26, 2026
Merged

Mnehmos merged 1 commit into
mainfrom
codex/check-tool-docs

Conversation

@Mnehmos
@Mnehmos Mnehmos commented Aug 26, 2026 •
Copy link
Copy Markdown
Owner

Risk

R1 (tool documentation only); no runtime state, auth, billing, secrets, or migration changes.

Scope

Correct math_manage guidance so the DM is pointed at the tool that actually exists for non-combat ability and skill checks: improvisation_manage with action: "stunt". Remove references to nonexistent standalone roll tools and clarify that saves are resolved by the applicable combat/effect tool.

Acceptance criteria

  • The math tool description names the registered stunt adjudicator.
  • The description no longer instructs callers to use nonexistent roll_skill_check, roll_ability_check, or roll_saving_throw tools.
  • The focused tool tests and build pass.

Verification

  • npm test -- tests/server/consolidated/math-manage.test.ts tests/server/consolidated/improvisation-manage.test.ts (75 tests)
  • npm test -- --reporter=basic (2,276 passed, 7 skipped)
  • npm run build
  • git diff --check

Persistence or migration

None.

Rollback

Revert the squash commit.

Summary by CodeRabbit

  • Bug Fixes

    • Updated RPG check guidance to use the correct improvisation and combat/effect tools.
    • Removed outdated instructions referencing standalone skill, ability, and saving-throw tools.
    • Prevented unsupported tool calls from being suggested.
  • Tests

    • Added coverage confirming the updated RPG check guidance and tool references.

@repowise-bot
repowise-bot Bot commented Aug 26, 2026
Copy link
Copy Markdown

✅ Health of changed files: 6.9 (unchanged)

📋 At a glance
2 hotspots touched · 1 file with recent fix history · 7 dead-code findings.

Files & modules (2)
  • src (1 file)
    • .../consolidated/math-manage.ts
  • tests (1 file)
    • .../consolidated/math-manage.test.ts

✅ Health gate: passed

🔎 More signals (3)

🗺️ Change map

flowchart LR
  subgraph PR ["Changed in this PR (1 with dependents)"]
    f_src_server_consolidated_math_manage_ts[".../consolidated/math-manage.ts 🔥"]:::changed
  end
  f_src_server_consolidated_index_ts[".../consolidated/index.ts"]
  f_src_server_consolidated_math_manage_ts --> f_src_server_consolidated_index_ts
  classDef changed fill:#dbeafe,stroke:#1d4ed8,color:#1e3a5f
  classDef warn fill:#fef3c7,stroke:#b45309,color:#78350f
  classDef guard fill:#dcfce7,stroke:#15803d,color:#14532d
Loading

Solid arrows: code that imports the changed files (1 direct dependent, from the last indexed snapshot). Dashed: history/tests.

🔥 Hotspots touched (2)

  • .../consolidated/math-manage.ts: 3 commits/90d, 2 dependents
  • .../consolidated/math-manage.test.ts: 0 commits/90d, 0 dependents

💀 Dead code (10 findings)

  • 💀 .../consolidated/math-manage.ts ACTIONS (confidence 0.65)
  • 💀 .../consolidated/math-manage.ts RollSchema (confidence 0.65)
  • 💀 .../consolidated/math-manage.ts ProbabilitySchema (confidence 0.65)
7 more
  • 💀 .../consolidated/math-manage.ts SolveSchema (confidence 0.65)
  • 💀 .../consolidated/math-manage.ts SimplifySchema (confidence 0.65)
  • 💀 .../consolidated/math-manage.ts ProjectileSchema (confidence 0.65)
  • 💀 .../consolidated/math-manage.ts definitions (confidence 0.65)
  • ✅ Removed: ProjectileSchema in .../consolidated/math-manage.ts
  • ✅ Removed: SolveSchema in .../consolidated/math-manage.ts
  • ✅ Removed: RollSchema in .../consolidated/math-manage.ts

📊 See the full report for this PR
Your repo map with this PR's blast radius lit up, every caller of the contracts it changes, and health before and after. No sign-in. · ⭐ Star Repowise · 📥 Install bot · Silence on a single PR with [skip repowise] in the title · Per-repo toggle on repowise.dev/settings?tab=bot · Updated 2026-08-26 03:16 UTC

@coderabbitai
coderabbitai Bot commented Aug 26, 2026 •
Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 8caa39d7-bd1f-4bce-b74f-f3ded8338b11

📥 Commits

Reviewing files that changed from the base of the PR and between 494f649 and 032fa8f.

📒 Files selected for processing (2)
  • src/server/consolidated/math-manage.ts
  • tests/server/consolidated/math-manage.test.ts

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The change updates RPG check routing guidance in math_manage and adds a regression test for the new improvisation_manage and saving-throw tool references.

Changes

RPG Check Routing

Layer / File(s) Summary
Routing guidance and regression coverage
src/server/consolidated/math-manage.ts, tests/server/consolidated/math-manage.test.ts
Ability and skill checks now use improvisation_manage with the stunt action. Saving throws use the applicable combat or effect tool. The test verifies the new guidance and excludes obsolete standalone tool names.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Merge Risk: ⚪ Minimal · up to 032fa

This change only corrects guidance for invoking an existing check tool and removes references to nonexistent tools; no runtime behavior or production state changes. No actionable merge-blocking risk remains after normal checks and review.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the documentation fix that directs checks to the registered tool.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2 files.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/check-tool-docs

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 032fa8fe2d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

- Saving throws → Use the combat/effect tool that requires the save; there is no standalone roll_saving_throw tool on this MCP surface

These specialized tools look up character stats and apply bonuses automatically!
The DM chooses the appropriate skill and DC, and the stunt action rolls the d20 and applies the character's skill modifier automatically. Do not invent or call roll_skill_check, roll_ability_check, or roll_saving_throw; those tools are not registered here.
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Do not claim stunt applies full skill modifiers

When a character is proficient or has expertise in the selected skill, this guidance produces an incorrect check total: getSkillModifier in improvisation-manage.ts derives only the associated ability modifier and handleStunt never reads the persisted skillProficiencies or expertise fields. Redirecting general skill checks here while claiming the character's skill modifier is applied will therefore silently omit proficiency and expertise bonuses; either add those bonuses to stunt resolution or avoid presenting it as the general skill-check replacement.

Useful? React with 👍 / 👎.

- Skill checks → Use roll_skill_check (auto-applies proficiency)
- Ability checks → Use roll_ability_check (auto-applies modifier)
- Saving throws → Use roll_saving_throw (auto-applies save proficiency)
- Ability or skill checks → Use improvisation_manage { action: "stunt", actorId, skill, dc, effectType: "none" }
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep raw ability checks out of the skill-only stunt route

When the DM needs a raw Constitution ability check, this redirect cannot represent it: StuntSchema requires one of the 18 skills, and SKILL_TO_ABILITY maps none of them to Constitution, so passing constitution is rejected and choosing an allowed skill uses a different ability. The blanket ability-check guidance should point to a route that accepts an ability or be narrowed until stunt supports raw ability checks.

Useful? React with 👍 / 👎.

@Mnehmos
Mnehmos merged commit f2539dc into main Aug 26, 2026
5 checks passed
zxrfire pushed a commit to zxrfire/mnehmos.rpg.mcp that referenced this pull request Sep 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0