Plugin

file-agent

Public

Forked from neil/file-agent

src / promptPreprocessor.ts

import { type ChatMessage, type PromptPreprocessorController } from "@lmstudio/sdk";
export async function preprocess(ctl: PromptPreprocessorController, userMessage: ChatMessage) {
  const textContent = userMessage.getText();
  // Here is where you can modify the user message.
  // Learn more about prompt-preprocessors: https://lmstudio.ai/docs/typescript/plugins/prompt-preprocessor
  return textContent;
}