feat(eval): seed unlabelled candidate probes from conversation logs#23
Merged
Conversation
Turn a conversation export into redacted, unlabelled probe stubs (the redacted first user message of each sufficiently deep conversation) so a human can assign expected_pack. Automatic domain/intent labelling is deliberately out of scope — those labels were one operator's personal vocabulary and do not generalise. Redaction is a pluggable rule list; defaults cover only generic PII (email/phone-like/URL). Privacy-first, provider-neutral; tests use synthetic conversations only. Upstream: peterkimpmp/aipm#660 Signed-off-by: peterkimpmp <tykim21@gmail.com>
12992c0 to
2980fe0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds
sillok/eval/probe_seeder.py— turns a conversation export intounlabelled candidate probe stubs (redacted first-user-messages from deep
conversations), ready for a human to assign
expected_pack.Why
Real usage is the best source of eval probes. This seeds the probe set from
actual questions while keeping a human in the loop for labelling — and keeping
private data out via redaction.
How
seed_probes(conversations, min_messages=10) -> list[ProbeStub];ProbeStub.expected_packis alwaysNone(human-assigned).contentlist/str); no vendor-specific parser.redact()with a pluggableRedactionRulelist; defaults are generic PII only (email / phone-like / URL) — no domain or organisation patterns.Validation
ruff/mypy sillok/eval/probe_seeder.pycleanpytest tests/unit/eval/test_probe_seeder.py→ 8 passed (deep/shallow, no-user skip, redaction, content-list shape, truncation, and a guardrail asserting the defaults carry no clinical/domain patterns)Note for reviewer
Also adds an import block to
sillok/eval/__init__.py. If #20 (calibration)merges first, this needs a one-line rebase of that
__init__(both only addadjacent import groups).
Provenance
Reduced from an internal history→golden tool whose domain/intent labels and
clinical-variable redactions were operator-specific. Those were dropped;
only the generic conversation→redacted-stub skeleton remains. PII gate: 0 hits.
Upstream: peterkimpmp/aipm#660 · Plan: peterkimpmp/aipm#647,#656 · Follows: #22