Configuration Reference
Plugin config (~/.prism/config.json)
Section titled “Plugin config (~/.prism/config.json)”| Field | Type | Default | Description |
|---|---|---|---|
apiKey | string | — | Your gck_* API key (required) |
prismThreshold | number | 4 | Minimum PQ score before coaching triggers (0–10) |
enableGateway | boolean | true | Route requests through Optra gateway |
File permissions: 600 (owner read-write only) Directory permissions: 700 (owner only)
Plugin userConfig (plugin.json)
Section titled “Plugin userConfig (plugin.json)”These fields are configurable when installing the plugin:
{ "userConfig": { "apiKey": { "type": "string", "sensitive": true, "description": "gck_* key" }, "enableGateway": { "type": "boolean", "description": "Route through Optra gateway (default: true)" }, "prismThreshold": { "type": "number", "description": "Min PQ score 0-10" } }}Session state (${CLAUDE_PLUGIN_DATA}/session-state.json)
Section titled “Session state (${CLAUDE_PLUGIN_DATA}/session-state.json)”Managed automatically by the plugin hooks. Reset on session start and after /compact.
| Field | Type | Description |
|---|---|---|
turnCount | number | Current turn number |
sessionStart | number | Session start timestamp (ms) |
sessionId | string | Unique session identifier |
totalInputTokens | number | Cumulative input tokens |
totalOutputTokens | number | Cumulative output tokens |
firstTurnInputTokens | number | Input tokens on first turn (context baseline) |
lastTurnInputTokens | number | Input tokens on most recent turn |
lastPromptTimestamp | number | Timestamp of last prompt (for response timing) |
modelCounts | object | Per-model usage counts |
opusLowOutputCount | number | Counter for Opus overkill detection |
responseTimes | number[] | Last 50 response times (ms) |
lastVersion | string | Plugin version at last session (for update notifications) |
OTEL settings (~/.claude/settings.json)
Section titled “OTEL settings (~/.claude/settings.json)”The plugin syncs these environment variables on session start:
{ "env": { "OTEL_EXPORTER_OTLP_LOGS_ENDPOINT": "https://ingest.prism.optra-ai.com/v1/logs", "OTEL_EXPORTER_OTLP_METRICS_ENDPOINT": "https://ingest.prism.optra-ai.com/v1/metrics", "OTEL_EXPORTER_OTLP_TRACES_ENDPOINT": "https://ingest.prism.optra-ai.com/v1/traces" }}URLs are resolved from the config endpoint based on your API key.