npm package: @novalabai/adk
Description: NovaLab Agent Development Kit — Build, test, and deploy Nova AI agents with multi-agent orchestration, smart model routing, trust layer, and confidence scoring
Author: NovaLab
Latest version: 1.5.1

# @novalabai/adk

The official **TypeScript Agent Development Kit** for the [NovaLab](https://novalab.build) AI orchestration platform.

Build, test, and deploy autonomous AI agents with smart model routing, enterprise-grade trust scoring, confidence layers, and full auditability.

## Installation

```bash
npm install @novalabai/adk
```

## Quick Start

```typescript
import { NovaClient } from '@novalabai/adk';

const nova = new NovaClient({
  apiKey: process.env.NOVA_API_KEY!,
  region: 'eu-west-1',           // optional, defaults to eu-west-1
  baseUrl: 'http://localhost:4300/v1', // optional, for local dev
});

// Create an agent
const agent = await nova.agents.create({
  name: 'my-assistant',
  description: 'A helpful coding assistant',
  model: 'auto',
  systemPrompt: 'You are a helpful assistant.',
  temperature: 0.7,
  maxTokens: 2048,
});

// Deploy it
await nova.agents.deploy(agent.agentId);

// Run a task
const result = await nova.agents.run(agent.agentId, {
  task: 'Explain the security risks of storing JWT tokens in localStorage',
});

console.log(result.output);         // AI response
console.log(result.confidence);     // 0-100 confidence score
console.log(result.trust);          // Trust evaluation (accuracy, safety, relevance, completeness)
console.log(result.autonomyLevel);  // AUTONOMOUS | NOTIFY | APPROVAL_REQUIRED | BLOCKED
```

## Features

- **Smart Model Routing** — Auto-routes tasks to the best model (Claude for analytical, Gemini for creative)
- **Trust Layer** — Claude evaluates any model's output for accuracy, safety, relevance, and completeness
- **Confidence Scoring** — Blended pipeline + trust scores with autonomy level determination
- **Agent Lifecycle** — Create, deploy, run, pause, and manage AI agents
- **Workflow Pipelines** — Multi-step agent workflows with confidence gates
- **Signal Monitoring** — Real-time telemetry ingestion with anomaly detection
- **Automations** — Rule-based triggers and scheduled actions
- **Connections Hub** — Third-party integrations (Slack, GitHub, Jira, etc.)
- **Audit History** — Full decision trail with trust data and explanations
- **Webhook Verification** — HMAC-SHA256 payload signing and verification
- **Streaming** — Server-Sent Events for real-time agent output
- **Full TypeScript** — Complete type definitions with strict mode

## API Resources

```typescript
const nova = new NovaClient({ apiKey: '...' });

nova.agents          // Create, deploy, run, and manage AI agents
nova.trust           // Evaluate any AI output for trust and safety
nova.workflows       // Build and execute multi-step pipelines
nova.signals         // Ingest and stream real-time telemetry
nova.automations     // Manage rule-based automations
nova.connections     // Third-party integrations
nova.data            // Upload and query datasets
nova.history         // Audit trail and decision replay
nova.webhooks        // Event subscriptions
```

## Trust Evaluation

Evaluate any AI output independently:

```typescript
const result = await nova.trust.evaluate({
  input: 'What is the capital of France?',
  output: 'The capital of France is Paris.',
  model: 'gpt-4',
});

console.log(result.trust.overallScore);    // 97
console.log(result.trust.trustLevel);      // "high"
console.log(result.trust.accuracyScore);   // 100
console.log(result.trust.safetyScore);     // 95
console.log(result.trust.concerns);        // []
```

## Webhook Verification

```typescript
import { verifyWebhookSignature } from '@novalabai/adk';

const isValid = await verifyWebhookSignature(
  rawBody,
  signatureHeader,
  webhookSecret,
);
```

## Streaming

```typescript
const stream = await nova.agents.run(agentId, {
  task: 'Write a story',
  stream: true,
});

for await (const chunk of stream) {
  process.stdout.write(chunk.text);
}
```

## Requirements

- Node.js >= 18
- A NovaLab API key ([get one at novalab.build](https://novalab.build))

## License

[MIT](./LICENSE)