Skip to content

family-story-keeper: never overwrite unread stories, report failed deletes - #394

Open
hassan1731996 wants to merge 3 commits into
openhome-dev:devfrom
hassan1731996:followup-family-story-keeper
Open

hassan1731996 wants to merge 3 commits into
openhome-dev:devfrom
hassan1731996:followup-family-story-keeper

Conversation

@hassan1731996

@hassan1731996 hassan1731996 commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

What does this Ability do?

Follow-up to #388 (Family Story Keeper): interviews a family member about their life and replays the stories later, with the storyteller's own voice when Google is linked. This PR covers the reviewer's follow-up items and problems found when re-reading the merged code.

Reviewer items

  • If saved stories can't be read, nothing is saved over them. A storage error is now different from a key that was never saved, for both the index and each storyteller. The ability says so and stops instead of starting from empty.
  • After two silent questions in a row the interview ends.
  • The README lists the Google Drive permissions needed.

Found afterwards

  • A "tell me a little more" answer kept only the second recording, so playback skipped the first part. Both clips are kept and played in order.
  • Deleting a storyteller or a story always said it was done, even if Drive or the saved text could not be removed. It now says what is left.
  • Only a 401 from Drive turns off recording for the session. A 403 can be a quota or a single-file limit.
  • "Ask Nani" or "delete Grandma's stories" no longer falls back to the only recorded person when the name is not recorded. Names that match two people ("grandma" with two grandmothers) are treated as unknown. Non-Latin and accented names now match.
  • A family member's queued question is cleared only after the answer is saved, not when it is skipped or not saved.
  • The music-mode flag is cleared even if the websocket message fails.
  • A new storyteller is told that short highlights are shared with the assistant, and how to turn that off. Names in the highlights file are cleaned like the summaries.
  • Saves to a key that already exists try the update first, which halves the storage calls.

Suggested Trigger Words

Unchanged from #388.

Type

  • New community Ability
  • Improvement to existing Ability
  • Bug fix
  • Documentation update

External APIs

  • No external APIs
  • Uses external API(s): Google Drive API v3 through the linked Google account (unchanged, optional)

Testing

  • Tested in OpenHome Live Editor
  • All exit paths tested (said "stop", "exit", etc.)
  • Error scenarios tested (API down, bad input, etc.)

Not yet run in the Live Editor. Checked offline: the file compiles, and a small harness covers a failed read versus a missing key (saves refused after a failed read), name matching (ambiguous, partial, "Dad" versus "Dadi") and the update-first save order. Still to run live: record with Google linked and a short answer (two clips), play it back, delete a story and a storyteller, and the silent-question ending. I'll tick the boxes after that.

Checklist

  • Files are in community/my-ability-name/ (community/family-story-keeper/)
  • README.md included with description, suggested triggers, and setup
  • No hardcoded API keys

Anything else?

Both items first left out are now in this PR:

  • "You" as a name: when "mine" is said and the profile has no name, it asks "What name should I use for you?" instead of recording someone called "You".
  • Prompt size: with more than 40 stories, "play a story" sends only the 40 that share the most words with the request, in their original order, and summaries are cut to 120 characters. Offline check: a story matching the request is kept out of 100, and short lists are untouched.

…letes

Refuse saves after a failed read, keep both clips of a longer answer, match names strictly, report Drive delete failures, end after two silent questions, and tell new storytellers about shared highlights.
@hassan1731996
hassan1731996 requested a review from a team as a code owner November 15, 2026 17:38
@github-actions

Copy link
Copy Markdown
Contributor

🔀 Branch Merge Check

PR direction: followup-family-story-keeper → dev

✅ Passed — followup-family-story-keeper → dev is a valid merge direction

@github-actions

Copy link
Copy Markdown
Contributor

✅ Community PR Path Check — Passed

All changed files are inside the community/ folder. Looks good!

@github-actions github-actions Bot added the community-ability Community-contributed ability label Nov 15, 2026
@github-actions

Copy link
Copy Markdown
Contributor

✅ Ability Validation Passed

📋 Validating: community/family-story-keeper
  ✅ All checks passed!

@github-actions

Copy link
Copy Markdown
Contributor

🔍 Lint Results

Files linted: community/family-story-keeper/main.py

✅ Flake8 — Passed

✅ All checks passed!

Ask what name to use when the profile has none, and send at most 40 story summaries to the model.
The platform reads the text data: as a URL scheme in a string literal.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-ability Community-contributed ability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant