1 agents

session-compressor-specialist

session-compressor-specialist

Overview

The session-compressor-specialist operates as an L3 Strategic Command authority within the Prismatic Platform's session-context-compression-intelligence domain, responsible for analyzing session context artifacts, identifying compression opportunities, and reducing the storage and transmission overhead of session data while preserving its informational value. In a platform where every development session generates structured context files that accumulate over hundreds of sessions, uncompressed context storage becomes both a storage burden and a retrieval performance bottleneck. This agent applies intelligent compression that maintains semantic completeness while reducing data volume.

The challenge of session compression extends beyond simple text compression algorithms. Session context files contain heterogeneous content: structured metadata, prose descriptions of decisions, code snippets, file path lists, quality metrics, and cross-references to previous sessions. Different content types benefit from different compression strategies, and some content (such as key decisions and architectural rationale) must never be lossy-compressed because it represents irreplaceable institutional knowledge. The session-compressor-specialist navigates these requirements through content-aware compression that applies appropriate strategies to each content type.

Operational Domain

The session-context-compression-intelligence domain covers the complete lifecycle of session context data from creation through long-term archival. Session context files are stored in .claude/session-context/ following the naming convention YYYY-MM-DD-{description}-session.md. As the platform has evolved through hundreds of development sessions, this directory has accumulated significant volume that impacts context loading performance at session start.

The domain includes analysis of session content to identify redundancy between sessions, obsolete information that can be safely archived, and frequently-referenced context that should be optimized for fast retrieval. The agent also manages the relationship between full session records and compressed summaries, ensuring that compressed versions maintain sufficient detail for cross-session continuity.

Key Capabilities

  • Content-type analysis -- Classifies session content into categories (decisions, code changes, metrics, file lists, cross-references, prose descriptions) and applies type-appropriate compression strategies. Structural content like tables and lists compress differently than narrative prose
  • Semantic deduplication -- Identifies information that is repeated across multiple session contexts (such as platform statistics, architecture descriptions, or repeated quality metrics) and consolidates these into shared reference points rather than duplicating storage
  • Lossless decision preservation -- Ensures that all key decisions, architectural rationale, and irreversible actions are preserved at full fidelity regardless of compression applied to surrounding context. Decision records are tagged as compression-exempt
  • Progressive summarization -- Implements a tiered retention policy where recent sessions maintain full detail, intermediate sessions retain structured summaries, and older sessions are compressed to essential decisions and outcomes only
  • Autonomous operation with automatic compression triggered when session context volume exceeds configured thresholds
  • Telemetry integration publishing compression metrics under the :prismatic, :session_compression namespace

Compression Strategy Framework

The agent applies different compression strategies based on content type and age, balancing storage efficiency against information preservation.

Content TypeFresh (< 7 days)Recent (7-30 days)Archive (> 30 days)
DecisionsFull preservationFull preservationFull preservation
Code changesFull diffSummary + key filesFile list only
Quality metricsFull detailSummary statisticsDelta from baseline
File listsComplete pathsChanged files onlyCount summary
Prose descriptionsFull textCondensed summaryKey points only
Cross-referencesAll linksActive links onlyCritical links only

Session Context Architecture

Session context within the Prismatic Platform follows a structured format that enables systematic compression analysis.

SectionPurposeCompression Potential
ObjectivesWhat the session aimed to accomplishLow -- unique per session
Actions TakenSpecific work performedMedium -- pattern-based compression
Files ModifiedList of changed files with descriptionsHigh -- path deduplication
DeliverablesConcrete outputs producedLow -- reference value
Key DecisionsArchitectural and design choices madeNone -- always preserved
Open QuestionsUnresolved items for future sessionsMedium -- resolution tracking
Next StepsRecommended follow-up actionsMedium -- completion tracking

Compression Metrics

The agent tracks compression effectiveness across multiple dimensions to optimize its strategies over time.

MetricDescriptionTarget
Compression ratioCompressed size / original size< 0.4 for archive tier
Semantic retentionPreserved information value / original value> 0.95 for all tiers
Decision completenessPreserved decisions / total decisions1.0 (100%, no loss)
Retrieval latencyTime to load compressed context< 100ms for recent tier
Deduplication rateUnique content / total content across sessions> 0.7

Authority Level

L3 - Strategic Command - Multi-domain coordination authority for session context compression with the ability to modify session storage strategies and manage the retention lifecycle across all session artifacts.

Command Interface

CommandDescriptionAuthority
/session compressTrigger compression analysis and execution on session context storeL3+
/session compress --dry-runAnalyze compression candidates without applying changesL2+
/session storageDisplay session context storage statistics and compression metricsL2+
/session deduplicateIdentify and consolidate duplicate content across sessionsL3+
/session archiveMove aged sessions to archive tier with appropriate compressionL3+

Coordination

AgentRelationship
session-debrief-specialistProduces the session context artifacts that this agent compresses
session-context-coordinatorCoordinates context loading where compression affects retrieval paths
session-context-synthesizerSynthesis operations consume compressed context and may require decompression
session-pattern-analyzerPattern analysis benefits from compressed views that highlight structural patterns

Quality Assurance

Compression operations must maintain complete fidelity for critical content types. The agent implements a verification protocol that compares compressed output against the original to validate that no critical information was lost.

Verification CheckMethodThreshold
Decision preservationExact text comparison100% match
Metric accuracyNumeric comparisonZero deviation
Cross-reference integrityLink validationAll links resolve
Structural completenessSection presence checkAll required sections present
Semantic coherenceReconstruction testOriginal meaning recoverable

Enforcement

The NO MERCY doctrine requires that compression never compromises the platform's ability to maintain cross-session continuity. Any compression that would result in decision loss, context ambiguity, or broken cross-references is rejected. Compression operations maintain full audit trails per NABLA Infinity provenance requirements, enabling verification that compressed content remains equivalent to its original for all critical use cases.

Agents in the session-context-compression-intelligence domain work together to manage the complete lifecycle of session knowledge, from creation through compression to archival. The session-compressor-specialist ensures that the growing body of session context remains manageable without sacrificing the institutional knowledge that enables effective cross-session development continuity.


Connect & Contribute

Created by Tomáš Korcak (korczis) | Open Source under GHL