Expose categories listing, category filter on review queue, and invalidate
feed caches when ops hides a published post.
Co-authored-by: Cursor <cursoragent@cursor.com>
Quick Plaza publish resolves existing chat pages by session/message id; production remote adapter rejected the RPC because the binding contract omitted this method.
Co-authored-by: Cursor <cursoragent@cursor.com>
Speed up the quick-plaza path with session snapshot reads, publish timeouts, and a modal fix so parent re-renders no longer abort in-flight requests.
Co-authored-by: Cursor <cursoragent@cursor.com>
Return 404/401/403 from MindSpace RPC for known publication errors and
preserve error codes through the Portal remote adapter.
Co-authored-by: Cursor <cursoragent@cursor.com>
Subscribe session SSE as soon as the Goosed session is known, keep request
context during waiting, and poll session snapshots so page results appear
in the conversation while generation is still running.
Co-authored-by: Cursor <cursoragent@cursor.com>
Add id/created defaults for user_message, ensure metadata in agent-run
gateway before submit, and kickstart the agent-run worker after portal deploy
so queued page-generation runs use the latest runtime bundle.
Co-authored-by: Cursor <cursoragent@cursor.com>
Goosed rejects /sessions/:id/reply when user_message.metadata lacks
userVisible. Normalize metadata before submit and during agent orchestration
so page-generation runs no longer fail before streaming starts.
Co-authored-by: Cursor <cursoragent@cursor.com>
Avoid importing mindspace-public-finish-sync in production runtime so release
link repair can copy oa docx files or strip broken anchors without extra deps.
Co-authored-by: Cursor <cursoragent@cursor.com>
- Free stale Memind listeners on 8081 before startup and exit cleanly on EADDRINUSE
- Backfill owned sessions missing from Goose via h5_conversation_messages summaries
- Strip Memind task orchestration prefixes from user-facing chat text
- Repair missing public docx links before release MindSpace link checks
Co-authored-by: Cursor <cursoragent@cursor.com>
Prevent portal direct-chat history from being lost when snapshot cache
is invalidated on Goosed submit by writing non-empty messages to DB first,
and stop caching empty Goose placeholder messages in snapshots.
Co-authored-by: Cursor <cursoragent@cursor.com>
Portal direct chat → goosed escalation can leave hollow Goose messages while
h5_conversation_messages retains the full dialogue. Backfill session detail
from DB, extend snapshot list fallback, and keep stored session id on transient
boot failures so refresh no longer looks like a blank new chat.
Co-authored-by: Cursor <cursoragent@cursor.com>
Ensure page sync runs via pageSyncService in remote mode, fall back to
workspace HTML when storage assets are missing, and prevent production
Portal from linking to loopback Plaza URLs baked in at build time.
Co-authored-by: Cursor <cursoragent@cursor.com>
Route themed page/article prompts to agent orchestration, reject them
from portal direct chat, and finalize regular sessions to idle when a
direct chat turn already completed.
Co-authored-by: Cursor <cursoragent@cursor.com>
When a session starts with LLM direct chat then escalates to goosed,
invalidate the portal-direct-chat snapshot and stop replaying stale SSE
so page-generation turns stream and finish correctly.
Co-authored-by: Cursor <cursoragent@cursor.com>
Wire chat intent routing with direct_chat on regular sessions, skill-selected
short-circuit to Agent, memory light/heavy intervention tiers, and fix direct
chat UI stuck streaming after completion.
Co-authored-by: Cursor <cursoragent@cursor.com>
Inject serve-time CSS so author styles cannot hide TKMind · 智趣 with
low opacity, which made pages like weather.html look brandless.
Co-authored-by: Cursor <cursoragent@cursor.com>
Backfill missing platform-brand footer at serve time and block service-
account links when the HTML file omits data-mindspace-page-tag.
Co-authored-by: Cursor <cursoragent@cursor.com>
WeChat link cards were pointing og:image at mindspace-cover paths that
never landed on disk; serve-time injection now uses thumbnail.png instead.
Co-authored-by: Cursor <cursoragent@cursor.com>
Mock HTML in wechat-mp tests now includes mindspace-cover metadata so
page link delivery assertions match production guard behavior.
Co-authored-by: Cursor <cursoragent@cursor.com>
Block service-account page links when HTML lacks mindspace-cover and
description so WeChat forwards always get TKMind branding and thumbnail.
Co-authored-by: Cursor <cursoragent@cursor.com>
Extract schedule, greeting/status/connectivity replies, chat-general prompt, and display-name helpers from wechat-mp.mjs. Route sync intents via classifyWechatIntent and add channel isolation CI check.
Co-authored-by: Cursor <cursoragent@cursor.com>
Notify users when HTML publish guards reject stub pages instead of silently
failing, send real page links when non-stub files exist, and split wechat-mp
into wechat-mp.bundle.mjs for fast production updates without full portal rebuilds.
Co-authored-by: Cursor <cursoragent@cursor.com>
When Goose surfaces session poison errors as assistant text instead of Error events,
assertWechatAgentReplyIsSendable now throws to trigger session recreation. Outbound
sanitization prevents raw API errors from reaching WeChat users.
Co-authored-by: Cursor <cursoragent@cursor.com>
Use session snapshot message counts alongside WeChat route counts so long-lived dedicated sessions rotate before Goose history bloats, and refresh snapshots asynchronously so customer replies are not blocked.
Co-authored-by: Cursor <cursoragent@cursor.com>
When a dedicated WeChat session history leaves unmatched tool_calls, the next reply fails with a 400 LLM validation error; detect that pattern and recreate the session before retrying.
Co-authored-by: Cursor <cursoragent@cursor.com>