
Product
Introducing Repository Access Permissions and Custom Roles
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.
@archships/dim-plugin-auto-compact
Advanced tools
Official supported auto compaction plugin for dim-agent-sdk.
SessionCompactorController.compact(...)summaryModel instead of the session modelCompactionExecutionRequest<continuation_summary>...</continuation_summary> blockcompaction.prune: true, older tool outputs are omitted with character counts while recent/error outputs render bounded previewssession.messages intact for UI and restorepluginState['auto-compact'], including semantic lastResult diagnostics for the controller call onlycompaction: {} or an explicit safetyRatio) on the agentModelCapabilities.contextWindow on the model adapter so the gate can derive threshold = contextWindow − max(effectiveO, contextWindow × safetyRatio) (where effectiveO caps plannedOutput at max(DEFAULT_OUTPUT_CAP_TOKENS, contextWindow × safetyRatio) and falls back to the safety floor when plannedOutput / contextWindow > 0.6)compaction.compactorPluginId: 'auto-compact'import { createAgent, createModel } from '@archships/dim-agent-sdk'
import { createAutoCompactPlugin } from '@archships/dim-plugin-auto-compact'
const agent = createAgent({
model: createModel(adapter),
plugins: [
createAutoCompactPlugin({
summaryModel: { provider: 'openai', modelId: 'gpt-4.1-mini' },
retainMessages: 6,
compaction: {
auto: true,
prune: true,
reserved: 10_000,
},
}),
],
compaction: {
safetyRatio: 0.2,
compactorPluginId: 'auto-compact',
},
})
summaryModel is optional; the plugin defaults to context.status.modelmaxSummaryTokens is optional; the plugin defaults summary requests to 1024auto_compaction, and session.compact() summary calls record manual_compactioncompaction.prune defaults to true; set it to false only when the summary model should receive full tool text and structured content before chunking/truncation<continuation_summary>...</continuation_summary> block before replay, including wrapped blocks, merged multi-block outputs, and malformed-tag fragments that still yield a non-empty semantic bodyinvalid_summary_contractlastResult is updated on every controller call with compacted / skipped / failed, plus summary normalization and summary-call diagnostics when availablecontext.compacted.metadata.resolution can be summary or last_message_fallback; controller failures use context.compaction.failed.metadata.attemptStage = 'default_summary'pluginStatecontext.compacted notifications now include compacted / retained message counts plus estimator-based before / after / saved token fields when budgeting is enabledretainMessages remains a preferred target, but the planner adjusts to legal message boundaries and can use terminal compaction when the visible history ends with assistant/tool messagesuser messages for the auto-compact environment note and the compaction summary before retained messagespnpm run demo:auto-compact in the repo for the scripted walkthroughFAQs
Official auto compaction plugin for dim-agent-sdk.
The npm package @archships/dim-plugin-auto-compact receives a total of 32 weekly downloads. As such, @archships/dim-plugin-auto-compact popularity was classified as not popular.
We found that @archships/dim-plugin-auto-compact demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket now supports Custom Roles and Repository Access Permissions so organizations can control who can access specific repositories and actions.

Product
Socket MCP now lets AI assistants review org alerts, investigate threats using the Socket threat feed, and inspect package files in addition to dependency scoring.

Product
Socket Firewall blocks malicious VS Code and Open VSX extensions before install, protecting developers from compromised editor marketplaces.