Skip to content

feedback loop: soft optional ask + one-tap rate page + reader feedback recalled into every build - #43

Merged
stuinfla merged 1 commit into
mainfrom
feat/reader-feedback-loop
Nov 9, 2026
Merged

stuinfla merged 1 commit into
mainfrom
feat/reader-feedback-loop

Conversation

@stuinfla

@stuinfla stuinfla commented Nov 9, 2026

Copy link
Copy Markdown
Owner

What

  • Success email: optional, warm feedback ask with three tap-to-choose buttons. Live-page link stays direct.
  • rate.html: choice preselected from the email, optional comment, optional 1-100; no longer says thanks on a failed POST.
  • tools/feedback-lessons.mjs: pulls ratings from the Netlify form, mirrors into ruflo memory, distils a prompt-safe lessons block (untrusted-data framing per ruflo ADR-445).
  • bin/agentic-runner.mjs: appends that block to every build brief (fail-open).

Tested end to end before this PR

  • 3 real emails sent through SMTP to the owner's inbox and read as delivered (multipart with screenshots; single-part below-bar variant); every link 200.
  • New rate page driven in a real browser on a private Netlify draft deploy: real form POST arrived with the verdict field; empty submit, bad params, injection probe, double-tap, failed POST all behave.
  • Real runner executed with a stand-in claude: the feedback block is inside the brief the agent receives.
  • npm test: 349 pass, 0 fail (3 pre-existing skips). 9 new tests; the marker-forgery test verified to fail when the guard is removed.

After merge

Netlify deploys landing/ (the new rate page); the email change takes effect on the next hosted build. Verify production rate page + one real submission, then clean up the test row.

🤖 Generated with Claude Code

https://claude.ai/code/session_01PRnZSoReTcgUQnF43xaDUf

…der feedback recalled into every build

The success email now ends with a gentle, optional note ("If you have a minute, I'd really
appreciate your feedback") and three tap-to-choose buttons (nailed it / close / missed). The live
page link stays direct; nothing is mandatory.

rate.html: choice preselected from the email, optional one-line comment, 1-100 score tucked behind
"Prefer a number?". Fixes the old bug where it said thanks even when the POST failed. Nothing is
recorded until Send, so mail scanners that prefetch links cannot fake a rating.

tools/feedback-lessons.mjs (new): pulls build-rating submissions straight from the Netlify form
(reachable from CI, unlike the local RuVector store), mirrors them into ruflo memory (feedback ns),
and distils a prompt-safe lessons block. Comments are treated as untrusted data: links, markup,
code fences, control/invisible chars and the frame's own markers are stripped, capped at 260 chars.
The operator's selftest ratings are excluded.

bin/agentic-runner.mjs: runs it before the brief is built (fail-open) and appends the block to the
brief, ahead of the final-status instruction.

tests/feedback-lessons.test.mjs: 9 tests incl. source-shape pins for the runner, email and page.
@netlify

netlify Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for explainmyrepo ready!

Name Link
🔨 Latest commit 4f1cd22
🔍 Latest deploy log https://app.netlify.com/projects/explainmyrepo/deploys/6af20d7744eeb8f4580872d8
😎 Deploy Preview https://deploy-preview-43--explainmyrepo.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@stuinfla
stuinfla merged commit 0a9bcd4 into main Nov 9, 2026
5 checks passed
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