@tensorpass/aiconnect
Every public export of @tensorpass/aiconnect, the site's connection to the visitor's AI, the fetch for AI SDKs, the tool loop and the MCP tool source, in four pages with their types generated from the source.
@tensorpass/aiconnect is the site's side of AI Connect, without any framework. It exports the AiConnect client, the McpToolSource class, the runConversation and finalAnswer functions, the chat content helpers, WalletRequestError, and the types they share with AI Wallet.
import {
AiConnect, McpToolSource, WalletRequestError, contentParts, dataUrl, finalAnswer, inlineData, runConversation, textOf,
} from '@tensorpass/aiconnect';
import type {
ChatEvent, ChatMessage, ChatResponse, ChatStart, ConnectionState, ContentPart, GenerationHint, JsonSchema, ToolSource,
Usage, UserMessage, WalletChatParams, WalletLink, WalletProvider,
} from '@tensorpass/aiconnect';The reference is in four pages, each with the tables of its exports, generated from the package's TypeScript source each time the docs are built:
| Page | What it documents |
|---|---|
| The client | AiConnect, ConnectionState, SdkOptions, WalletFetch, WalletRequestError, McpToolSource |
| Conversations | runConversation, ConversationOptions, ConversationHooks, finalAnswer, the chat content helpers |
| Chat, tool and generation types | the messages and their content parts, ToolDefinition, ToolSource, JsonSchema, GenerationOptions, ToolChoice, ResponseFormat |
| Sessions and the wallet | ProviderSession, ChatRequest, ChatStart, ChatResponse, FinishReason, Usage, WalletLink, WalletProvider, ChatEvent |
Theming
Match the connect window to your design system with the CSS tokens of @tensorpass/aiconnect-design, in light and dark, and in right to left languages.
The client: AiConnect
AiConnect, the site's connection to the visitor's AI through AI Wallet, its connection states and options, the fetch for AI SDKs, WalletRequestError and the MCP tool source, with their types generated from the source.