Conversation
RamananVr
force-pushed
the
feature/ess-diagnostics-skills-v2
branch
from
September 17, 2026 23:51
4c5c91c to
345782f
Compare
Replace the standalone Python diagnostics tool with a single self-contained Claude skill (tools/ESS-Diagnostics-Skills/SKILL.md) that walks a Field Engineer through a Copilot Studio / PVA transcript turn-by-turn, runs a 5-check diagnostic with quoted evidence, and writes a Debug Report plus a normalized-diagnostic JSON and a faithful full-transcript JSON to the OS temp directory (never the repo — transcripts contain PII). Highlights: - Step 0 hard gate: confirm file path + problem statement before parsing. - Interactive per-turn walkthrough: structured summary, section drill-down, verdict override, continue / run all. - Real-schema parse map (Trace/p.data.kind, SynchronousIncomingActivity, AnalyticsAiMetricsSignalTraceData / KnowledgeTraceData). - 5 checks with divergence + root cause; search results show source text for every result. - scripts/transcript-to-json.js: lossless transcript-to-JSON helper. - Design + implementation docs under docs/plans/. Co-Authored-By: Claude <[email protected]>
RamananVr
force-pushed
the
feature/ess-diagnostics-skills-v2
branch
from
September 17, 2026 23:55
345782f to
1b0e8bb
Compare
Design doc for converting scripts/transcript-to-json.js to a stdlib-only Python drop-in (transcript_to_json.py) with exact behavioral parity, plus SKILL.md invocation updates and removal of the JS file. Co-Authored-By: Claude <[email protected]>
Co-Authored-By: Claude <[email protected]>
Co-Authored-By: Claude <[email protected]>
Co-Authored-By: Claude <[email protected]>
Co-Authored-By: Claude <[email protected]>
…entation Merge the v4-skill and Node->Python-port design docs into a single design doc, and their two implementation plans into a single implementation doc (each split into Part 1 / Part 2). No content lost. Co-Authored-By: Claude <[email protected]>
AdwaitRaut
reviewed
Sep 18, 2026
There was a problem hiding this comment.
The per-turn walkthrough is solid. N/A-on-failed-precondition and the FDE override path are the right calls.
One fix before merge: the output contract disagrees with itself across the Rules block, Step 4, and the README (two files vs three). Open question on invocation plus a few nits below — none of those need to hold it up.
- Make the output contract consistently say three files (Debug Report, normalized JSON, faithful transcript JSON) across SKILL.md Rules + Step 4 and the README; previously the Rules block and README said two, which would lead an LLM to skip the faithful dump Step 4 promises. - transcript_to_json.py: add the Microsoft copyright/license header; refuse to overwrite the source transcript when it is passed as the output path; and on POSIX restrict the PII-bearing temp dir/file to the owner (0700/0600). - README: clarify how the skill is invoked (point Claude at the skill dir; no wired slash command yet). - Replace a real user-alias path with a placeholder in the implementation plan. Co-Authored-By: Claude <[email protected]>
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.
Summary
Replaces the standalone ESS Diagnostics Python tool with a single self-contained Claude skill (
tools/ESS-Diagnostics-Skills/SKILL.md) that walks a Field Engineer (FDE) through a Copilot Studio / PVA transcript interactively and produces evidence-cited outputs. The entire Python pipeline (src/,tests/,pyproject.toml) is removed.What the skill does
continue, orrun allto finish without pausing.Tracediscriminated byp.data.kind(LlmIntentRecognized,PluginStart,PluginResponse,AnalyticsAiMetricsSignalTraceData,KnowledgeTraceData); user turns areSynchronousIncomingActivity; grounding/rewrite come fromcompletionState/rewrittenMessage/verifiedSearchResults[].rankScore. Missing fields degrade to N/A rather than guessing.Outputs (three files, written to the OS temp dir — never the repo, since transcripts contain employee PII)
<name>-debug-report.md— human-readable diagnosis: per-turn verdicts with evidence, FDE overrides, divergence point, root cause.<name>-normalized.json— compact diagnostic view (only the fields the checks use; no verdicts).<name>-transcript.json— faithful, lossless full transcript converted to JSON (every event and field preserved,_turn/_indexannotated), produced by the bundled helperscripts/transcript_to_json.py.Transcript helper is Python (ported from Node.js)
The bundled faithful-dump helper is
scripts/transcript_to_json.py— a stdlib-only Python script, so the toolkit stays Python-only with no Node.js dependency. It began as a Node.js helper (transcript-to-json.js) and was ported to Python within this PR as an exact behavioral drop-in: identical CLI contract (<transcript.txt> [outFile.json]), same_turn/_indexannotation, same temp-dir output path, sameError:/exit-1 failures, and content byte-identical output (ensure_ascii=Falsepreserves raw Unicode). The Node.js version has been removed andSKILL.mdnow invokes the Python helper.How to invoke the skill
From a Claude Code session in the repo, either invoke it by name:
or point Claude at it directly:
The skill then (1) stops and asks for the file path + the specific problem, (2) parses and walks each turn — pausing so you can drill in, override a verdict,
continue, orrun all, and (3) writes the three output files to your OS temp dir and reports their absolute paths.To convert a transcript to faithful JSON directly (also used internally by the skill) — use
pythonon Windows,python3on POSIX:Validation
Dry-run against a real (redacted) transcript confirmed the Step 0 gate, per-turn hard stops, real-schema extraction, drill-down/override, and temp-dir outputs. The run surfaced a genuine search relevancy/ranking defect — the correct KB was retrieved but under-ranked (all
rankScore=0) and not cited — validating that the checks + FDE override mechanism work. No automated test suite (the skill is prose); the Python helper was validated manually (run against a real transcript, output diffed byte-for-byte against the original Node.js helper, and error-path spot-checked).Notes
tools/ESS-Diagnostics-Skills/docs/plans/, consolidated into two files that each cover both efforts (the v4 skill and the Node→Python helper port) in a Part 1 / Part 2 split:2026-09-17-ess-diagnostics-design.md(combined design) and2026-09-17-ess-diagnostics-implementation.md(combined implementation plan).🤖 Generated with Claude Code