KetraTerm
API · v0.3.0All versions

SwingCompletionFeedbackRecorder

class SwingCompletionFeedbackRecorder(recordSuggestionFeedback: (commandLine: String, feedback: TerminalCompletionFeedbackKind, profileId: String?, workingDirectoryUri: String?, feedbackAtEpochMillis: Long) -> Unit, clockEpochMillis: () -> Long = System::currentTimeMillis)

Shared adapter from Swing suggestion feedback to completion statistics.

Hosts inject the exact-feedback sink. This keeps Swing-to-completion vocabulary mapping identical while leaving learning, privacy, persistence, and thread ownership in the product host.

Parameters

recordSuggestionFeedback

host-owned exact-feedback sink.

clockEpochMillis

host wall-clock supplier.

Constructors

Link copied to clipboard
constructor(recordSuggestionFeedback: (commandLine: String, feedback: TerminalCompletionFeedbackKind, profileId: String?, workingDirectoryUri: String?, feedbackAtEpochMillis: Long) -> Unit, clockEpochMillis: () -> Long = System::currentTimeMillis)

Functions

Link copied to clipboard

Creates a handler that records feedback against each suggestion's immutable request context.

Link copied to clipboard

Validates and records one accepted or dismissed suggestion.