chore(index): remove contextInjector chat.message hook call

- Remove createContextInjectorHook from imports
- Remove contextInjector variable declaration
- Remove contextInjector["chat.message"] call
- Keep contextInjectorMessagesTransform for synthetic part injection
- Update test: prepend → synthetic part insertion verification
This commit is contained in:
justsisyphus
2026-01-16 17:48:09 +09:00
parent d3e3371a77
commit ea1d604b72
2 changed files with 6 additions and 6 deletions
-3
View File
@@ -34,7 +34,6 @@ import {
} from "./hooks";
import {
contextCollector,
createContextInjectorHook,
createContextInjectorMessagesTransformHook,
} from "./features/context-injector";
import { applyAgentVariant, resolveAgentVariant } from "./shared/agent-variant";
@@ -163,7 +162,6 @@ const OhMyOpenCodePlugin: Plugin = async (ctx) => {
const keywordDetector = isHookEnabled("keyword-detector")
? createKeywordDetectorHook(ctx, contextCollector)
: null;
const contextInjector = createContextInjectorHook(contextCollector);
const contextInjectorMessagesTransform =
createContextInjectorMessagesTransformHook(contextCollector);
const agentUsageReminder = isHookEnabled("agent-usage-reminder")
@@ -327,7 +325,6 @@ const OhMyOpenCodePlugin: Plugin = async (ctx) => {
await keywordDetector?.["chat.message"]?.(input, output);
await claudeCodeHooks["chat.message"]?.(input, output);
await contextInjector["chat.message"]?.(input, output);
await autoSlashCommand?.["chat.message"]?.(input, output);
await startWork?.["chat.message"]?.(input, output);