Conversation
|
Maintainer review requested. This is opt-in (default empty) and fixes a live-reproduced cross-session memory bleed: messages explicitly marked “this conversation only” were promoted into Honcho peer representation and recalled in a new session. Validated locally: |
|
Correction to my validation note: a late adversarial review exercised the real pinned |
ea5b337 to
ee9e42b
Compare
|
Updated head |
ee9e42b to
a265d0d
Compare
|
Rebased onto latest
|
feat(honcho): add per-turn observation opt-out phrases
The casefold-vs-lower decision and the real-SDK regression test (dict, not |
a265d0d to
f661493
Compare
|
Rebased onto latest Rebase ( Not a trivial replay —
Both are preserved; Review point 1 — match the sanitized string, not the raw input Agreed, and the risk runs in the direction you flagged plus one more. Review point 2 — silent disable on a config typo Fixed. Review points 3 and 4 3 (repeated-failure warning on a stuck flush queue) is a real gap, but it belongs to the general flush path rather than this feature, so I would rather not widen this PR's surface for it. Happy to follow up separately. 4 — confirming the asymmetry is intentional: the user is the one who asks for a turn to be off the record, and the assistant reply is part of that same turn, so both chunks are flagged. The inverse case (a sensitive assistant reply with no user phrase) is a different feature and would need its own signal. Validation
Formatting note: |
f661493 to
7003fac
Compare
|
Review follow-up pushed after rebasing onto current Review-point status
Verification after rebase
PR HEAD: |
|
Maintainer ping: this PR is mergeable and locally verified, but all GitHub Actions runs are still waiting for repository approval ( Could a maintainer please approve and run the workflows when convenient? This addresses a cross-session privacy/correctness gap: an operator-configured conversation-only phrase can remain searchable in session history while being excluded from Honcho representation reasoning. The default remains behavior-neutral. |
Per-turn Honcho observation opt-out via config.observationOptOutPhrases (Unicode-casefold substring match on user content, so non-ASCII case folds like German STRASSE/straße match correctly while Korean and other scripts without case keep working as before). Matched turns are still written/searchable but flagged no_observe=True, reusing existing HonchoSession.add_message/_message_configuration_for wire mechanism. Provider-local only, no core agent/ changes. Fail-closed on the opt-out contract: if a no_observe message's MessageConfiguration/ReasoningConfiguration cannot be imported/ constructed, _message_configuration_for now raises instead of quietly returning None. _flush_session's outer try/except catches this, sends no batch, returns False, and leaves the message unsynced for retry — never dropped, never sent as fully observed. observationOptOutPhrases host precedence fails closed: host presence (even an explicit non-list, null, or empty list) overrides root entirely rather than falling back to root phrases on an invalid host value, so a malformed host block can never unexpectedly activate root opt-out phrases. Tests: 316 passed in tests/honcho_plugin/ (added regression coverage for the fail-closed path, Unicode casefold matching, and host-vs-root opt-out phrase precedence).
7003fac to
c91ce1e
Compare
Summary
observationOptOutPhrasesconfigurationconfiguration.reasoning.enabled=falsesaveMessagessemantics unchangedWhy
A user can explicitly mark a fact as conversation-only, yet Honcho's peer representation can currently absorb it and recall it in a new conversation. Session routing remains correct; the leak occurs in cross-session representation derivation. This adds a narrow, operator-configured boundary without disabling useful observation globally.
Verification
python -m pytest tests/honcho_plugin/ -q— 316 passedruff check plugins/memory/honcho tests/honcho_plugin— cleangit diff origin/main...HEAD --check— cleanThe default phrase list is empty, so this is behavior-neutral until explicitly configured.