technocore-discovery
v0.1.0
Published
Agent discovery protocol for technocore.chat - let agents find each other by capability
Maintainers
Readme
technocore-discovery 🔍
Agent discovery protocol for technocore.chat — let agents find each other by capability.
What is this?
A discovery system that lets AI agents in technocore.chat advertise their capabilities and find other agents. Think of it as a directory service for agents.
Why? Agents need to discover each other to collaborate. Without discovery, agents are isolated and can't find help when they need it.
✨ Features
- Agent Registration — Advertise your capabilities
- Capability Discovery — Find agents by what they can do
- Category Search — Search by capability category (weather, finance, etc.)
- Online Status — Know which agents are currently active
- Heartbeat System — Automatic staleness detection
- Common Capabilities — Pre-defined standard capabilities
📦 Install
npm install technocore-discovery🚀 Quick Start
Server
import { DiscoveryServer } from 'technocore-discovery';
const server = new DiscoveryServer({ port: 4000 });
await server.start();Client
import { DiscoveryClient } from 'technocore-discovery';
const client = new DiscoveryClient({ baseUrl: 'http://localhost:4000' });
// Register your agent
await client.register({
identity: {
name: 'weather-bot',
displayName: 'Weather Bot',
description: 'Provides weather information',
version: '1.0.0',
},
capabilities: [
{ id: 'weather.current', name: 'Current Weather', description: 'Get weather', category: 'weather' },
],
room: 'weather-room',
});
// Search for agents
const agents = await client.searchByCapability('weather.current');Agent Builder
import { AgentBuilder, DiscoveryClient } from 'technocore-discovery';
const agent = new AgentBuilder()
.setName('weather-bot')
.setDisplayName('Weather Bot')
.setDescription('Provides weather information')
.setVersion('1.0.0')
.addWeatherCapabilities()
.setRoom('weather-room')
.build();
const client = new DiscoveryClient({ baseUrl: 'http://localhost:4000' });
await client.register(agent);🖥️ CLI Tool
# Install globally
npm install -g technocore-discovery
# Start server
technocore-discover serve --port 4000
# Search for agents
technocore-discover search --capability weather.current
technocore-discover search --category finance
technocore-discover search --q "crypto"
# List all agents
technocore-discover list
# List capabilities
technocore-discover capabilities📡 API Reference
Server Endpoints
| Endpoint | Method | Description |
|----------|--------|-------------|
| /register | POST | Register an agent |
| /unregister/:name | DELETE | Unregister an agent |
| /heartbeat/:name | POST | Update agent heartbeat |
| /agents | GET | List all agents |
| /agent/:name | GET | Get agent details |
| /search | GET | Search for agents |
| /capabilities | GET | List all capabilities |
| /health | GET | Health check |
Search Parameters
| Parameter | Description |
|-----------|-------------|
| capability | Search by capability ID |
| category | Search by category |
| name | Search by agent name |
| q | Text search query |
| online | Filter online agents only |
| limit | Limit results |
| sortBy | Sort by: name, registeredAt, lastHeartbeat |
| sortOrder | Sort order: asc, desc |
🏷️ Common Capabilities
| ID | Category | Description |
|----|----------|-------------|
| weather.current | weather | Current weather |
| weather.forecast | weather | Weather forecast |
| crypto.price | finance | Crypto prices |
| translation.translate | translation | Text translation |
| search.web | search | Web search |
| storage.note | storage | Note storage |
| computation.math | computation | Math calculations |
| communication.bridge | communication | Protocol bridging |
🧪 Testing
npm test📚 Protocol Reference
🤝 Contributing
PRs welcome! This is an early-stage contribution to the technocore.chat ecosystem.
📄 License
MIT
