@reminix/runtime
v0.5.0
Published
Reminix runtime for building handlers
Maintainers
Readme
@reminix/runtime
Reminix runtime for building handlers that run on Reminix.
Installation
npm install @reminix/runtime
# or
pnpm add @reminix/runtime
# or
yarn add @reminix/runtimeUsage
import type { AgentHandler, Context, Request, Response } from '@reminix/runtime';
const myAgent: AgentHandler = async (context: Context, request: Request): Promise<Response> => {
// Your handler logic here
return {
messages: [
{
role: 'assistant',
content: 'Hello from my handler!',
},
],
};
};Components
Types
Message- Conversation messageToolCall- Tool call made by an agentContext- Persistent resources provided to handlersRequest- Current invocation requestResponse- Handler responseMemoryStore- Memory store interfaceKnowledgeBase- Knowledge base interfaceToolRegistry- Tool registry interfaceAgentHandler- Agent handler function typeToolHandler- Tool handler function type
Utilities
load_handler(handlerPath)- Load a handler from a filediscover_registry(handlerPath)- Auto-discover handlers from a directory structureexecute_handler(handler, context, request)- Execute a handler with context and request
License
MIT
