UNPKG

@justinechang39/maki

Version:

AI-powered CLI agent for file operations, CSV manipulation, todo management, and web content fetching using OpenRouter

36 lines (35 loc) 1.09 kB
import { getCacheInfo } from '../core/prompt-cache.js'; // Tool definitions export const cacheTools = [ { type: 'function', function: { name: 'getCacheStatus', description: 'Get information about prompt caching for the current model', parameters: { type: 'object', properties: {}, required: [] } } } ]; // Tool implementations export const cacheToolImplementations = { getCacheStatus: async () => { const cacheInfo = getCacheInfo(); let status = `Current model caching:\n`; status += `Type: ${cacheInfo.type}\n`; status += `Description: ${cacheInfo.description}\n`; if (cacheInfo.minTokens) { status += `Minimum tokens: ${cacheInfo.minTokens}\n`; } if (cacheInfo.maxBreakpoints) { status += `Max breakpoints: ${cacheInfo.maxBreakpoints}\n`; } if (cacheInfo.ttl) { status += `Cache TTL: ${cacheInfo.ttl}\n`; } return status; } };