tambo

tambo

Build AI assistants and agents in React with a few lines of code.

Stars: 168

Visit
 screenshot

tambo ai is a React library that simplifies the process of building AI assistants and agents in React by handling thread management, state persistence, streaming responses, AI orchestration, and providing a compatible React UI library. It eliminates React boilerplate for AI features, allowing developers to focus on creating exceptional user experiences with clean React hooks that seamlessly integrate with their codebase.

README:

tambo ai

Build AI assistants and agents in React with a few lines of code.

tambo ai Logo

npm version license GitHub last commit Discord GitHub stars

The Future is Generative

The future of UX is generative and hyper-personalized. But today its really hard to build AI powered generative UI experiences. We are building tools that make this possible without complexity.

tambo ai eliminates React boilerplate for AI features. We handle the hard parts so you can focus on creating exceptional user experiences.

Build AI assistants and agents in React without the headache.

What is tambo ai?

tambo ai is a React library that deals with the boring parts. Get started with an AI assistant in minutes.

  • Thread management
  • State persistence
  • Streaming responses
  • AI Orchestration
  • A Compatabile React UI Library

You get clean React hooks that integrate seamlessly with your codebase.

How It Works

Add tambo ai to your React app with a simple provider pattern:

// Wrap your app with the provider
<TamboProvider apiKey="your-api-key">
  <App />
</TamboProvider>

Core Features

  • Specialized hooks for specific needs:

    • useTamboThreadInput - Input state and submission
    • useTamboSuggestions - AI-powered message suggestions
    • useTamboThreads - Conversation management
    • useTamboComponentState - AI-generated component state
  • Component registration for AI-generated UI

  • Tool integration for your data sources

  • Streaming responses for real-time interactions

Getting Started

Quick Start

# Install the package
npm install @tambo-ai/react

# Or with the CLI for guided setup
npx tambo --full-send

Basic Usage

import { TamboProvider, useTambo } from '@tambo-ai/react';

function MyAIComponent() {
  const { thread, sendThreadMessage } = useTambo();

  return (
    <div>
      <button onClick={() => sendThreadMessage('What's the weather today?')}>
        Ask about weather
      </button>
      {thread.messages.map((message, index) => (
        <div key={index}>
          <div>{message.content}</div>
          {message.component && message.component.renderedComponent}
        </div>
      ))}
    </div>
  );
}

Read our full documentation

Development

Prerequisites

  • Node.js 18.x+
  • npm 10.x+

Quick Commands

# Install
git clone https://github.com/tambo-ai/tambo.git && cd tambo && npm install

# Develop
npm run dev

# Build
npm run build

# Test
npm run test

Resources

License

MIT License - see the LICENSE file for details.

Join the Community

We're building tools for the future of user interfaces. Your contributions matter.

Star this repo to support our work.

Join our Discord to connect with other developers.


Built by developers, for developers.
Because we believe the future of UI is generative and hyper-personalized.

For Tasks:

Click tags to check more tools for each tasks

For Jobs:

Alternative AI tools for tambo

Similar Open Source Tools

For similar tasks

For similar jobs