Skip to content

feat(roadie): wordpress chat platform plugin - #773

Merged
chubes4 merged 1 commit into
mainfrom
fix/issue-771-wordpress-platform
Oct 17, 2026
Merged

chubes4 merged 1 commit into
mainfrom
fix/issue-771-wordpress-platform

Conversation

@chubes4

@chubes4 chubes4 commented Oct 17, 2026

Copy link
Copy Markdown
Member

Closes #771. Stacked on #772: base is fix/issue-770-runtime-chat-handler; retarget to main after #772 merges.

bridges/roadie/roadie-plugins/wordpress-platform.mjs registers a wordpress chat platform through Roadie's platform registry (Extra-Chill/roadie#298) and does nothing without wordpress-context.json. It starts only when wordpress is in --platform, and it's added to the managed ROADIE_PLUGINS set (snapshots updated).

  • Ingress: a loopback HMAC-signed endpoint (127.0.0.1:3712/wordpress/events) receives chat_message / chat_input / chat_cancel. scripts/inbound-event-connector.py gains deliver_wordpress, and the Slack signing code is refactored into a shared post_signed.
  • ChatThread: writes through the claim-bound abilities from feat(channels): claim-bound write abilities for external chat runtimes Automattic/agents-api#586.
    • sendPart / sendMessage / sendNotice → append-chat-run-messages
    • editMessageText → update-chat-run-message
    • marker / rename / lifecycle → append-chat-run-events
  • Interactions: questions become input_required, and answers come back via claim-chat-run-input.
  • Run status: follows Roadie session-state actions through set-chat-run-status. A cancel, delivered by the queue or seen in the status response, aborts the session.
  • Claim token: the Route runtime-backed WordPress agents to Roadie via the inbound queue #770 handler now forwards the run claim token to the claiming runtime in the event (≤191 chars; anything longer is dropped).
  • Identity: the actor is the event's WP user, resolved via the existing resolve-chat-person path with platform wordpress.

Review focus

  • loadRuntimeApi() imports Roadie dist modules by filename (conversation-intake.js, session-handler/thread-session-runtime.js, …) to reach getOrCreateRuntime. That's fragile coupling. The better fix is for the roadie#298 plugin API to hand platforms a runtime/ingress handle; I'm happy to follow up there.
  • The claim token rides the durable inbound event. It's scoped to the claiming runtime, but it's stored in the queue table until acked.

Verification (local, on this branch)

  • Pass: node tests/roadie-wordpress-platform.mjs (new, against stubbed Roadie and WP), bash tests/roadie-wordpress-platform.sh, php tests/smoke-runtime-chat-handler.php, php tests/smoke-inbound-event-bridge.php, python3 tests/inbound-event-connector.py, bash tests/inbound-event-bridge.sh, bash tests/roadie-wordpress-context.sh, bash tests/ci-coverage.sh, bash tests/roadie-managed-env.sh, bash tests/roadie-speaker-context-gate.sh.
  • bash tests/bridge-render.sh fails on roadie-systemd snapshot drift, identically on origin/main, so it's pre-existing.

Finalized outside Homeboy: the cook's gate roadie-wordpress-context.sh failed in the Lab gate environment but passes locally on this branch. Continuation is closed (homeboy#16088), so I re-applied the cook's patch on top of #772 and verified it by hand.

AI disclosure: written by a Pi coding agent via Homeboy cook, verified and opened by Extra Chill Bot, authorized by @chubes4.

@chubes4
chubes4 force-pushed the fix/issue-771-wordpress-platform branch from 7f2b3e2 to b949944 Compare October 17, 2026 04:30
@chubes4
chubes4 changed the base branch from fix/issue-770-runtime-chat-handler to main October 17, 2026 04:30
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.

Roadie 'wordpress' chat platform plugin

1 participant