Newer
Older
TelosDB / src / mcp-tools.js
@楽曲作りまくりおじさん 楽曲作りまくりおじさん 8 days ago 1 KB Add comprehensive test suite (35 tests) and update journal
export function getToolDefinitions() {
  return [
    {
      name: "add_item_text",
      description: "テキストから埋め込みを生成して追加します",
      inputSchema: {
        type: "object",
        properties: {
          content: { type: "string" },
          path: { type: "string" },
        },
        required: ["content"],
      },
    },
    {
      name: "add_item",
      description: "テキストとベクトルを追加します",
      inputSchema: {
        type: "object",
        properties: {
          content: { type: "string" },
          path: { type: "string" },
          vector: { type: "array", items: { type: "number" }, minItems: 3, maxItems: 3 },
        },
        required: ["content", "vector"],
      },
    },
    {
      name: "search_text",
      description: "テキストから埋め込みを生成して検索します",
      inputSchema: {
        type: "object",
        properties: {
          content: { type: "string" },
        },
        required: ["content"],
      },
    },
    {
      name: "search_vector",
      description: "ベクトル検索を実行します",
      inputSchema: {
        type: "object",
        properties: {
          vector: {
            type: "array",
            items: { type: "number" },
            minItems: 3,
            maxItems: 3,
            description: "検索するベクトル (3次元ラベルの例)",
          },
        },
        required: ["vector"],
      },
    },
    {
      name: "llm_generate",
      description: "llama.cpp でテキスト生成を実行します",
      inputSchema: {
        type: "object",
        properties: {
          prompt: { type: "string" },
          n_predict: { type: "number" },
          temperature: { type: "number" },
        },
        required: ["prompt"],
      },
    },
  ];
}