Skip to content

feat(mcp): ChatGPT gets a summary of the request and no Claude layout instructions - #296

Merged
milstan merged 3 commits into
mainfrom
milstan/chatgpt-no-triggered-by
Oct 24, 2026
Merged

milstan merged 3 commits into
mainfrom
milstan/chatgpt-no-triggered-by

Conversation

@milstan

@milstan milstan commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

Two changes on /chatgpt/mcp only. Every other surface reads byte-for-byte what it read before.

1. _triggered_by asks for a one-sentence summary, not the user's words. OpenAI's tool scan on the new Leadbay plugin draft (asdk_app_6adc4064…, 2026-10-24) flagged 39 tools with "This tool appears to request information beyond what its stated operation requires." All 39 carry _triggered_by, which asked for a verbatim copy of the user's message. Mazemind asks for a third-person summary and passed the same scan without that finding.

2. The rendering and NEXT STEPS text written for Claude is left out. In ChatGPT, every Leadbay call that asks for approval showed "Suspicious Instruction", danger_level: HIGH: "Tool documentation prescribes classifier handling and output behavior, including mandatory rendering and next-step widget instructions." Mazemind's calls in the same workspace showed none.

/mcp, /fr/mcp, /sse, /apps/mcp, stdio /chatgpt/mcp
_triggered_by verbatim quote, MANDATORY, LAST_PROMPT_REQUIRED one sentence ≤25 words, third person, optional, never rejected
"Trigger provenance (MANDATORY)" instruction block present left out
RENDER (quick), RENDERING, NEXT STEPS, widget table, link patterns present deleted
Description size, all tools unchanged 513k → 295k chars

How (2) works. A promptforge marker, {{claude}} (src/claude.ts), wraps every include of a rendering/, next-steps/ or linking/ snippet and gates/builtin-widgets, plus the auto-emitted RENDER (quick) block. The inline RENDER / NEXT STEPS sections of 15 templates are wrapped by hand. Only APPS_NO_COMMERCE_TOOL_DESCRIPTIONS (= /chatgpt/mcp) deletes them. Every other constant and map in tool-descriptions.generated.ts is byte-identical to main, and prompts.generated.ts is unchanged. Documented in CLAUDE.md next to {{commerce}} and {{apps}}.

Existing test changed. mcp-apps-description.test.ts asserted /chatgpt/mcp equals the commerce-free text for tools without board prose. That is the behaviour this PR changes, so that one assertion now checks deletion only.

Also. chatgpt-app-submission.json (Apps-era, 4 tools behind) is replaced by chatgpt-plugin/, the files uploaded to OpenAI's plugin portal. Its URL is https://mcp.leadbay.app/chatgpt/mcp?v=2: the rejected 0.34.0 plugin still holds the plain URL and the portal refuses one URL on two apps. Bumps to 0.46.1.

Not done here. Eleven one-line confirmation asks still name ask_user_input_v0 (e.g. "ask which channels to enrich"); they are behaviour, not layout. leadbay_list_lens_seed_candidates still says "Do not pause for user approval". The server instructions are unchanged apart from the _triggered_by block. plugin.json has no demo video URL yet; it is recorded after this deploys.

Verified. New chatgpt-summary-triggered-by.test.ts (13 cases, 4 fail on main) and chatgpt-no-claude-rendering.test.ts (6 cases, 2 fail on main's descriptions), plus promptforge/test/claude-marker.test.ts. pnpm -r typecheck and pnpm -r test green (3,853 tests). Reviewer account on a local 0.46.1 server: on /chatgpt/mcp a composite runs without _triggered_by; on /mcp it is rejected.

🤖 Generated with Claude Code

…ords

OpenAI's tool scan on the new Leadbay plugin draft flagged 39 tools with
"This tool appears to request information beyond what its stated operation
requires." All 39 carry `_triggered_by`, whose description demands a
verbatim copy of the user's latest message.

On /chatgpt/mcp only (SUMMARY_TRIGGERED_BY_PATHS), `_triggered_by` now asks
for one third-person sentence of up to 25 words, names replaced by roles,
the wording Mazemind's tools passed the same scan with. It is optional
there, a call without it is not rejected, and the server-instruction block
that mandates the verbatim quote is left out. `_origin` stays, because the
boards stamp it. /mcp, /fr/mcp, /sse, /apps/mcp and stdio are unchanged.

Also replaces chatgpt-app-submission.json, the old Apps-era manifest that
was 4 tools behind, with chatgpt-plugin/: the plugin.json, mcp.json and
logos uploaded to OpenAI's plugin portal.

Bumps @leadbay/mcp to 0.46.1.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

@claude claude 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.

Reviewed the full diff. summaryTriggeredBy is gated by path (/chatgpt/mcp only) and covers the schema description, the required list, the server-instructions block and the LAST_PROMPT_REQUIRED guard. The new tests cover both sides, so the other surfaces keep the verbatim mandate. The chatgpt-plugin/ test-case tools (leadbay_welcome, leadbay_tour_plan) are registered, and nothing still references the deleted chatgpt-app-submission.json. No blocking issues found.

milstan and others added 2 commits October 23, 2026 23:33
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…laude

In ChatGPT, every Leadbay call that asks for approval showed "Suspicious
Instruction", danger_level HIGH: "Tool documentation prescribes classifier
handling and output behavior, including mandatory rendering and next-step
widget instructions." Mazemind's calls in the same workspace showed none.

A new promptforge marker, `{{claude}}` (src/claude.ts), wraps every include
of a rendering/, next-steps/ or linking/ snippet and gates/builtin-widgets,
plus the auto-emitted RENDER (quick) block. The inline RENDER / NEXT STEPS
sections of 15 templates are wrapped by hand. Only the /chatgpt/mcp variant
(APPS_NO_COMMERCE_TOOL_DESCRIPTIONS) deletes them, now emitted for 54 tools;
it is about 43% shorter (513k to 295k chars). Every other constant and map
in tool-descriptions.generated.ts is byte-identical, and prompts are
unchanged.

mcp-apps-description.test.ts asserted that /chatgpt/mcp equals the
commerce-free text for tools without board prose. That is the behaviour
this changes, so the assertion now checks deletion only.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@milstan milstan changed the title feat(mcp): ChatGPT records a summary of the request, not the user's words feat(mcp): ChatGPT gets a summary of the request and no Claude layout instructions Oct 24, 2026
@milstan
milstan merged commit c904013 into main Oct 24, 2026
8 checks passed
@milstan
milstan deleted the milstan/chatgpt-no-triggered-by branch October 24, 2026 14:14
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