trm-feedback-report
Post-ingest-batch feedback pass for TRM — classifier/extraction quality, OCR latency vs. budget, candidate new-topic surfacing, and a web-search cross-check on low-confidence facts.
Files17
View on GitHubSKILL.mdskills/trm-feedback-report/SKILL.md
GitHubTRM Feedback/Report
Standing feedback pass for a TRM ingest batch. Run after trm ingest-dir completes.
Trigger
After any TRM ingest batch, or on request ("feedback on the last ingest batch", "report on <topic>").
Flow
- Run
runTrmCommand(trmRoot, ['validate', topicPath, '--recursive'])andrunTrmCommand(trmRoot, ['feedback-stats', topicPath, '--recursive', '--latency-budget-ms', String(latencyBudgetMs)]). Parse both as JSON. - Read
extracts/extract.jsonfacts for the topic (recursively, matching--recursive) and callfindNewTopicCandidates(facts, existingTagsAndPathSegments), whereexistingTagsAndPathSegmentsis collected by walkingtopic.jsonfrom the vault root. - Select facts with
confidence < 0.55ORflags?.includes('VERIFY'), capped at the top 10 byscore.json'spromotion_score. For each, call theWebSearchtool, classify each hit's consistency with the fact's claim, then callderiveSignalStrength(hits). - Write the narrative report: classifier accuracy verdict, extraction gaps (using
fact_density/over_budget/warnings_count_by_type), three required risk labels (extraction risk / classifier drift risk / latency risk, each low/medium/high), new-topic candidates from step 2, cross-check results from step 3. CallbuildReportMeta(stats.completeness, hardFailure, webSearchSkipped)for thepartial_report/latency_data_staleflags andreportFilename(topicPath)for the filename. - Write the file to
<trmRoot>/reports/<filename>. - Call
runTrmCommand(trmRoot, ['crosslink', topicPath, '--tags', 'trm-feedback-report:v1']).
Input Schema
interface Input {
topicPath: string;
trmRoot: string;
recursive?: boolean;
latencyBudgetMs?: number;
}
Output Schema
interface Output {
reportPath: string;
partial_report: boolean;
latency_data_stale: boolean;
}
Full reference: See Skill Operator Guide.
For detailed workflow: See docs/USAGE.md.