@davothebigafro/core
v0.0.0
Published
Shared primitives for defining, registering, composing, and testing Shipwright agent templates.
Readme
@davothebigafro/core
Shared primitives for defining, registering, composing, and testing Shipwright agent templates.
Install
pnpm add @davothebigafro/core --filter <your-package>Inside this workspace, keep local dependencies on workspace:*. For unreleased local installs, use the tarball workflow in the root contributing guide.
Minimal Usage
import { LlmAgent, type BaseLlm } from '@google/adk';
import { defineAgentTemplate } from '@davothebigafro/core';
import { z } from 'zod';
declare const model: BaseLlm;
export const assistantTemplate = defineAgentTemplate({
id: 'assistant',
name: 'Assistant',
description: 'Builds the default assistant agent.',
configSchema: z.object({
name: z.string().default('assistant'),
}),
build(config) {
return new LlmAgent({
name: config.name,
model,
instruction: 'Answer concisely.',
});
},
});
const config = assistantTemplate.parseConfig({ name: 'support_assistant' });
const agent = assistantTemplate.build(config, { templateId: assistantTemplate.id });The package also exports AgentTemplateRegistry, composition validation errors, workflow-state reference helpers, and shared ADK test utilities such as ScriptedLlm and runComposition.
