Skip to main content

cjm-harness-transcripts

Harness-transcript extraction library: reads Claude Code session transcripts (JSONL DAGs), walks the active path, and extracts the user-facing prose — assistant markdown bodies, cleaned user prompts, and curated tool-parameter prose (e.g. SendUserFile captions) — as ExtractedMessages ready to mint onto a context-graph session spine.

Modules

  • cjm_harness_transcripts — cjm-harness-transcripts: parse agent-harness session transcripts (Claude Code
  • cjm_harness_transcripts.extract — User-facing prose extraction — both sides, one truth.
  • cjm_harness_transcripts.mapping — Transcript ↔ session-key mapping, derived at pull time.
  • cjm_harness_transcripts.records — The transcript record layer: tolerant JSONL loading + the append-only DAG.

API

cjm_harness_transcripts.extract

  • ExtractedMessage class — One user-facing message off the active path, ready to become a Message node.
  • clean_user_text function — Strip harness wrapper blocks from a user prompt, unwrap paste fences (the inside
  • extract_messages function — The active path's user-facing messages, chronological.

cjm_harness_transcripts.mapping

  • BootInfo class — The first user prose of a transcript — the mapping's evidence.
  • TranscriptMatch class — One ranked candidate pairing for a session key.
  • find_transcripts_for_key function — All plausible transcripts for a session key, best first.
  • parse_record_timestamp function — A transcript record timestamp (ISO-8601, trailing Z) as an aware datetime.
  • parse_session_key function — A session key (local start timestamp, e.g. 2026-08-20_17-05-20) as an aware datetime.
  • read_boot_info function — The transcript's first user record bearing prose, or None (empty/tool-only file).

cjm_harness_transcripts.records

  • TranscriptDag class — The uuid-addressable view of a transcript: parent edges, forks, active path.
  • TranscriptRecord class — One JSONL record, uuid-addressable or not, with the raw dict preserved.
  • load_records function — Load a transcript JSONL tolerantly, in file order.

Dependencies

Used by: cjm-context-graph-projection, cjm-session-scratchpad-qt, cjm-substrate-qt-kit

Metadata

Release files for cjm-harness-transcripts 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cjm-harness-transcripts 0.0.3
File Size Uploaded
cjm_harness_transcripts-0.0.3.tar.gz 14.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for cjm-harness-transcripts 0.0.3
File Interpreter ABI Platform
cjm_harness_transcripts-0.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 25.2 kB

Release files / cjm_harness_transcripts-0.0.3.tar.gz

Download URL cjm_harness_transcripts-0.0.3.tar.gz
Size 14.0 kB
Tags Source
SHA-256 checksum
How to use checksums
b6a99bd46bcf5fc4e4b666c630f1e8237051973fc54a675e8f884c4e359c1e14
BLAKE2b-256 checksum
How to use checksums
a8cda9bee289a1c615b80cfb5e563315fd81d8e11c564c45f0051cea28b32b0f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.12

Release files / cjm_harness_transcripts-0.0.3-py3-none-any.whl

Download URL cjm_harness_transcripts-0.0.3-py3-none-any.whl
Size 11.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1e268fba3ead0d16bccc02b11e390c73b34b2bb343d4c328f97a2c813d6df975
BLAKE2b-256 checksum
How to use checksums
2b8c69d2ec45e120fa3207ab7769ff1267dcbafb46fb9dd59e1a9b5b4d89a14c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.12

Release history Release notifications | RSS feed

This release

0.0.3 This release

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page