Skip to content

[RSM] Blog Talks Back > Add reader-chat entry point with page context and suggestions#110024

Draft
kat3samsin wants to merge 2 commits intotrunkfrom
add/jetpack-reader-chat
Draft

[RSM] Blog Talks Back > Add reader-chat entry point with page context and suggestions#110024
kat3samsin wants to merge 2 commits intotrunkfrom
add/jetpack-reader-chat

Conversation

@kat3samsin
Copy link
Copy Markdown
Contributor

Summary

  • reader-chat.js entry point — self-contained React bundle (no WP script loader needed)
  • Webpack config builds without DependencyExtractionWebpackPlugin
  • Sets agentsManagerData.agentId from JetpackReaderChatConfig
  • Sends current post context (title, URL, excerpt) to agent
  • Generates contextual suggested prompts based on current page

Related PRs

  • wpcom: Automattic/wpcom#212114
  • jetpack: add/jetpack-reader-chat

Test plan

  • Build and deploy to sandbox
  • Verify reader-chat.min.js loads on blog frontend
  • Verify suggestions change based on post vs homepage
  • Verify agentId is sent correctly to API

@matticbot
Copy link
Copy Markdown
Contributor

matticbot commented Apr 17, 2026

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • agents-manager
  • help-center
  • odyssey-stats

To test WordPress.com changes, run install-plugin.sh $pluginSlug add/jetpack-reader-chat on your sandbox.

@kat3samsin kat3samsin changed the base branch from trunk to add/jetpack-ai April 17, 2026 14:14
@kat3samsin kat3samsin changed the title Add reader-chat entry point with page context and suggestions [RSM] Blog Talks Back > Add reader-chat entry point with page context and suggestions Apr 17, 2026
Base automatically changed from add/jetpack-ai to trunk April 17, 2026 14:24
- reader-chat.js: minimal React entry reading from window.JetpackReaderChatConfig,
  mounts AgentsManager to #jetpack-reader-chat for frontend readers
- webpack.config.js: add getReaderConfig() without DependencyExtractionWebpackPlugin
  so all WP deps are bundled inline (no wp.element/wp.data on frontend)
- Set agentsManagerData.currentPost from JetpackReaderChatConfig
- Generate contextual suggestions based on current page (post-specific
  or general blog prompts for archives/home)
- Wire agentId through agentsManagerData for useAgentConfig()
@kat3samsin kat3samsin force-pushed the add/jetpack-reader-chat branch from 46eb229 to 68a7582 Compare April 17, 2026 15:12
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.

2 participants