Packages
20 packages organized into 6 layers. Each package is independently installable, fully typed, and ships with ESM + CJS builds.
Where to Start
Most projects need just 1-2 packages. Here are the recommended starting points:
@waymakerai/aicofounder-guard@waymakerai/aicofounder-agent-sdk@waymakerai/aicofounder-guard + @waymakerai/aicofounder-compliance@waymakerai/aicofounder-policies@waymakerai/aicofounder-core + @waymakerai/aicofounder-guardCore
Foundation packages. Start here.
@waymakerai/aicofounder-guard
NEWPII detection, prompt injection blocking, toxicity filtering, budget enforcement, rate limiting, and model gating. The primary security package.
Key Exports
createGuardguarddetectPIIredactPIIdetectInjectiondetectToxicityBudgetEnforcerRateLimiterModelGateQuick Example
import { createGuard } from '@waymakerai/aicofounder-guard';
const guard = createGuard({
pii: 'redact',
injection: 'block',
toxicity: 'block',
budget: { limit: 50, period: 'day', warningAt: 0.8, action: 'block' },
});
const result = guard.check(userInput, { model: 'claude-sonnet-4-20250514' });
if (result.blocked) {
console.log('Blocked:', result.reason);
} else {
const safeInput = result.redacted || userInput;
// Send safeInput to LLM
}@waymakerai/aicofounder-core
Main SDK client with multi-provider support, cost tracking, caching, retries, rate limiting, and fallbacks. Supports Anthropic, OpenAI, and Google.
Key Exports
createCoFounderCostTrackerwithRetryRateLimiterProviderManagerCacheManagerQuick Example
import { createCoFounder } from '@waymakerai/aicofounder-core';
const cofounder = createCoFounder({
providers: {
anthropic: process.env.ANTHROPIC_API_KEY!,
openai: process.env.OPENAI_API_KEY!,
},
cache: true,
optimize: 'cost',
});
const response = await cofounder.chat('Explain quantum computing');@waymakerai/aicofounder-policies
NEWDeclarative policy engine with 9 industry presets (HIPAA, GDPR, CCPA, SEC, PCI, FERPA, SOX, safety, enterprise). Composable rules for PII, content, models, costs, and data retention.
Key Exports
PolicyEnginecomposeevaluatePolicyhipaaPolicygdprPolicysecPolicyPolicyBuilderALL_PII_PATTERNSQuick Example
import { PolicyEngine, hipaaPolicy, gdprPolicy, compose } from '@waymakerai/aicofounder-policies';
const policy = compose([hipaaPolicy, gdprPolicy], 'strict');
const engine = new PolicyEngine([policy]);
const result = engine.evaluate(text, { model: 'claude-sonnet-4-20250514', direction: 'output' });
console.log(result.allowed, result.violations);Security & Compliance
Enterprise compliance, guidelines, and content control.
@waymakerai/aicofounder-compliance
NEW9 preset compliance rules for HIPAA, SEC/FINRA, GDPR, CCPA, legal, safety, and security. Rules can block, redact, replace, or append disclaimers to AI output.
Key Exports
ComplianceEnforcercreateComplianceEnforcerPresetRulescreateComplianceRuledetectPIIredactPIIQuick Example
import { ComplianceEnforcer, PresetRules } from '@waymakerai/aicofounder-compliance';
const enforcer = new ComplianceEnforcer({
rules: [PresetRules.hipaaNoMedicalAdvice(), PresetRules.secFinancialDisclaimer()],
strictMode: true,
});
const result = await enforcer.enforce(userInput, aiOutput, { topic: 'medical' });
if (!result.compliant) {
console.log('Violations:', result.violations);
}@waymakerai/aicofounder-guidelines
NEWDynamic behavioral control with context-aware rules. Define guidelines that match based on topic, user role, or custom conditions. Includes 8+ presets.
Key Exports
GuidelineManagercreateGuidelinePresetGuidelinesConditionsQuick Example
import { GuidelineManager, PresetGuidelines } from '@waymakerai/aicofounder-guidelines';
const manager = new GuidelineManager();
await manager.addGuideline(PresetGuidelines.noMedicalAdvice());
const matched = await manager.match({ topic: 'medical', message: 'I have a headache' });@waymakerai/aicofounder-soc2
NEWSOC2 audit evidence collection and report generation. Automatically generates compliance reports with timestamps and evidence trails.
Key Exports
EvidenceCollectorReportGeneratorSOC2TemplatesQuick Example
import { EvidenceCollector, ReportGenerator } from '@waymakerai/aicofounder-soc2';
const collector = new EvidenceCollector();
const report = new ReportGenerator(collector);
const pdf = await report.generate('Type II', { period: 'Q1 2026' });Agent
Build guarded AI agents with interceptors and factories.
@waymakerai/aicofounder-agent-sdk
NEWGuardrail wrapper for the Anthropic Agent SDK. 7 interceptors (PII, injection, compliance, content, cost, audit, rate limit) and 4 pre-built factories (HIPAA, Financial, GDPR, Safe).
Key Exports
createGuardedAgentcreateHIPAAAgentcreateFinancialAgentcreateGDPRAgentcreateSafeAgentGuardPipelineguardToolDependencies
@waymakerai/aicofounder-guardQuick Example
import { createGuardedAgent } from '@waymakerai/aicofounder-agent-sdk';
const agent = createGuardedAgent({
model: 'claude-sonnet-4-20250514',
instructions: 'You are a helpful assistant.',
guards: {
pii: { mode: 'redact', onDetection: 'redact' },
injection: { sensitivity: 'medium', onDetection: 'block' },
cost: { budgetPeriod: 'day', warningThreshold: 0.8 },
audit: { destination: 'file', filePath: './audit.log', tamperProof: true },
},
});
const result = await agent.run('Help me with my account');@waymakerai/aicofounder-agents
Multi-agent orchestration with typed messaging, pub/sub channels, request/response patterns, and delivery guarantees.
Key Exports
createMessageBrokercreateChannelcreateRequestChannelBaseAgentLLMAgentQuick Example
import { createMessageBroker, createChannel } from '@waymakerai/aicofounder-agents';
const broker = createMessageBroker({ deliveryGuarantee: 'at-least-once' });
const tasks = createChannel<{ task: string }>({ name: 'tasks', type: 'topic' });
broker.subscribe(tasks, async (msg, ctx) => {
console.log('Task:', msg.payload.task);
await ctx.acknowledge();
});Data & AI
RAG, helpers, prompts, context optimization.
@waymakerai/aicofounder-helpers
10 one-line AI functions: summarize, translate, classify, extract, sentiment, answer, rewrite, generate, compare, moderate.
Key Exports
summarizetranslateclassifyextractsentimentanswerrewritegeneratecomparemoderateQuick Example
import { summarize, classify, extract } from '@waymakerai/aicofounder-helpers';
const summary = await summarize(document, { style: 'brief' });
const category = await classify(email, ['support', 'sales', 'billing']);
const data = await extract(resume, { name: 'string', skills: 'string[]' });@waymakerai/aicofounder-prompts
Enterprise prompt management with versioning, A/B testing, analytics, and React hooks.
Key Exports
PromptManagerregisterexecutecreateABTestgetAnalyticsusePromptQuick Example
import { PromptManager } from '@waymakerai/aicofounder-prompts';
const pm = new PromptManager({ workspace: 'my-app' });
await pm.register('greeting', { template: 'Hello {{name}}!', variables: ['name'] });
const result = await pm.execute('greeting', { variables: { name: 'World' } });@waymakerai/aicofounder-rag
Advanced RAG with presets (balanced, fast, accurate, code), hybrid retrieval, cross-encoder re-ranking, and automatic citations.
Key Exports
RAGPresetscreateRAGPipelineSemanticChunkerHybridRetrieverCrossEncoderRerankerQuick Example
import { RAGPresets } from '@waymakerai/aicofounder-rag';
const pipeline = RAGPresets.balanced();
await pipeline.index([{ id: 'doc1', content: 'Your docs...' }]);
const result = await pipeline.query({ query: 'How does auth work?' });
console.log(result.answer, result.citations);@waymakerai/aicofounder-context-optimizer
NEWHandle 400K+ token contexts with ~70% cost savings. Smart chunking, file prioritization, and quality scoring.
Key Exports
ContextOptimizeroptimizeprioritizeFileschunkRepositoryscoreQualityQuick Example
import { ContextOptimizer } from '@waymakerai/aicofounder-context-optimizer';
const optimizer = new ContextOptimizer({ strategy: 'hybrid', maxTokens: 400000 });
const result = await optimizer.optimize({ files: repoFiles, query: 'Explain auth flow' });
console.log(result.tokens, result.costSavings);DevOps
CLI tools, CI/CD, testing, streaming, and observability.
@waymakerai/aicofounder-cli
25+ CLI commands for project setup, code generation, testing, dashboard, and deployment.
Key Exports
rana initrana generaterana testrana dashboardrana deployQuick Example
# Create a new project npx @waymakerai/aicofounder-cli init my-app # Generate code rana generate api --schema ./schema.yml # Run AI tests rana test --semantic --coverage
@waymakerai/aicofounder-ci
CI/CD static analysis scanner with 7 built-in rules: hardcoded secrets, PII in prompts, prompt injection, model approval, cost estimation, safe defaults, and exposed asset detection (source maps, env var leaks, debug modes, CORS, GraphQL introspection, CI/CD secret leaks).
Key Exports
scannoHardcodedKeysnoExposedAssetsnoInjectionVulnnoPiiInPromptsapprovedModelscostEstimationsafeDefaultsQuick Example
# Scan your codebase
npx @waymakerai/aicofounder-ci scan --rules all --fail-on high
# GitHub Actions
- uses: waymaker-ai/cofounder-ci@v1
with:
rules: all
fail-on: high
comment-on-pr: true@waymakerai/aicofounder-testing
AI-aware testing framework with semantic matching, statistical assertions, and cost tracking per test suite.
Key Exports
TestRunnersemanticMatchassertSimilartrackCostQuick Example
import { TestRunner } from '@waymakerai/aicofounder-testing';
const runner = new TestRunner({ semantic: true });
await runner.run([
{ input: 'Summarize this...', expected: 'A brief overview...', threshold: 0.8 },
]);@waymakerai/aicofounder-streaming
NEWStreaming guards for Anthropic, OpenAI, and SSE streams. Real-time content detection on streaming responses.
Key Exports
StreamGuardAnthropicAdapterOpenAIAdapterSSEAdapterStreamBufferQuick Example
import { StreamGuard, AnthropicAdapter } from '@waymakerai/aicofounder-streaming';
const guard = new StreamGuard({ pii: 'redact', injection: 'block' });
const stream = guard.wrap(anthropicStream, new AnthropicAdapter());Enterprise
Production-grade infrastructure packages.
@waymakerai/aicofounder-react
React hooks and provider for CoFounder. useChat, useRAG, usePrompt, useGuard hooks with built-in state management.
Key Exports
CoFounderProvideruseChatuseRAGusePromptuseGuardQuick Example
import { CoFounderProvider, useChat } from '@waymakerai/aicofounder-react';
function App() {
return (
<CoFounderProvider config={{ apiKey: '...' }}>
<ChatComponent />
</CoFounderProvider>
);
}@waymakerai/aicofounder-dashboard
Real-time monitoring dashboard for costs, usage, compliance violations, and guard activity.
Key Exports
DashboardFileStorageDashboardAPIQuick Example
import { Dashboard } from '@waymakerai/aicofounder-dashboard';
const dashboard = new Dashboard({ port: 3001, storage: 'file' });
await dashboard.start();
// Open http://localhost:3001@waymakerai/aicofounder-mcp-server
Model Context Protocol server for exposing CoFounder tools to MCP-compatible clients.
Key Exports
MCPServerScaffoldingToolsQuick Example
import { MCPServer } from '@waymakerai/aicofounder-mcp-server';
const server = new MCPServer({ tools: ['guard', 'compliance', 'rag'] });
await server.start();@waymakerai/aicofounder-benchmark
NEWPerformance benchmarking for LLM operations. Measure latency, throughput, cost efficiency, and quality across providers.
Key Exports
BenchmarkRunnerBenchmarkSuitecompareProvidersQuick Example
import { BenchmarkRunner } from '@waymakerai/aicofounder-benchmark';
const runner = new BenchmarkRunner();
const results = await runner.compare(['claude-sonnet-4-20250514', 'gpt-4o'], {
prompts: testPrompts,
metrics: ['latency', 'cost', 'quality'],
});Package Dependencies
All packages are independently installable. Here are the key dependency relationships:
agent-sdkdepends onguard (for interceptors)agent-sdkoptionally uses@anthropic-ai/sdk (peer dependency)compliancestandalone(no CoFounder dependencies)policiesstandalone(no CoFounder dependencies)guardstandalone(no CoFounder dependencies)corestandalone(no CoFounder dependencies)helpers / prompts / ragoptionally usecore (for provider management)streamingdepends onguard (for stream detection)