
Product
Socket MCP Adds Org Alerts, Threat Feed Review, and Package Inspection
Socket MCP now lets AI assistants review org alerts, investigate threats using the Socket threat feed, and inspect package files in addition to dependency scoring.
@composio/embeddings
Advanced tools
TurboPuffer schema definition for the Composio tool lookup system.
This package defines the TurboPuffer schema for storing and searching tools using:
All types extend the official @turbopuffer/turbopuffer SDK types.
TOOL_SCHEMA: TurboPuffer schema configuration using AttributeSchema typeTOOL_DISTANCE_METRIC: Distance metric for vector similarity (cosine_distance)ToolDocumentSchema: TypeScript type for tool documentsToolRow: Query result type extending TurboPuffer's RowRow, Vector, DistanceMetricAttributeSchema, AttributeSchemaConfigNamespaceQueryParams, NamespaceQueryResponseNamespaceWriteParams, NamespaceWriteResponseTurbopuffer clientTOOL_SCHEMA is the single source of truth. All TypeScript types are derived from it.
import type { ToolDocumentSchema } from '@composio/embeddings'
import { TOOL_SCHEMA } from '@composio/embeddings'
// Schema definition (source of truth)
TOOL_SCHEMA = {
text: { type: 'string', full_text_search: true },
tool_name: { type: 'string', filterable: true },
display_name: { type: 'string', filterable: true },
description: { type: 'string' },
toolkit_name: { type: 'string', filterable: true },
created_at: { type: 'string' },
}
// TypeScript type (automatically derived from TOOL_SCHEMA)
type ToolDocumentSchema = {
id: string // Random 10-char identifier
vector: Vector // 3072-dimensional embedding
text: string // Formatted text (BM25 searchable)
tool_name: string // Tool slug (filterable)
display_name: string // Human-readable name (filterable)
description: string // Tool description
toolkit_name: string // App/toolkit name (filterable)
created_at: string // ISO timestamp
}
import {
TOOL_DISTANCE_METRIC,
TOOL_SCHEMA,
Turbopuffer,
} from '@composio/embeddings'
// Use schema when writing to TurboPuffer
const tpuf = new Turbopuffer({ apiKey: process.env.TURBOPUFFER_API_TOKEN })
const namespace = tpuf.namespace('tool-lookup-v3')
await namespace.write({
upsert_rows: [...tools],
schema: TOOL_SCHEMA,
distance_metric: TOOL_DISTANCE_METRIC,
})
CLAUDE.md in this directory for AI assistant context/apps/apollo for tool search API implementationFAQs
TurboPuffer schema definition for the Composio tool lookup system.
We found that @composio/embeddings demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 9 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Socket MCP now lets AI assistants review org alerts, investigate threats using the Socket threat feed, and inspect package files in addition to dependency scoring.

Product
Socket Firewall blocks malicious VS Code and Open VSX extensions before install, protecting developers from compromised editor marketplaces.

Research
More than 140 Mastra npm packages were compromised in a supply chain attack that used a typosquatted dependency to deliver a cross-platform infostealer during installation.