coord

package module
v0.0.0-...-3a5371b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 28, 2024 License: MIT Imports: 6 Imported by: 0

README

Coord

GitHub Go Reference

Coord

What is Coord?

Coord is a Go library designed to simplify interactions with various AI services, providing a unified interface for Large Language Models (LLMs), Text-to-Speech (TTS) systems, and Embedding models.

This allows developers to seamlessly integrate and utilize different AI services without grappling with the complexities of each provider's specific APIs and requirements.

Key Features

  • Unified Interface: Interact with LLMs, TTS, and Embedding models using a consistent API, reducing code complexity and learning curves.
  • Abstraction: Coord handles the intricacies of model communication, data formatting, and result processing, letting you focus on your application logic.
  • Flexibility: Easily switch between different LLM, TTS, or Embedding providers without significant code changes.

Use Cases

Coord is ideal for a wide range of AI-powered applications, including:

  • Chatbots and Conversational AI: Build interactive chatbots that leverage the power of LLMs for natural language understanding and generation.
  • Content Generation: Generate high-quality text, articles, summaries, and more using various LLM providers.
  • Speech Synthesis: Integrate natural-sounding speech into your applications with support for different TTS engines.
  • Semantic Search and Recommendation: Utilize embedding models to power features like semantic search, similarity comparisons, and personalized recommendations.

Modules

LLM
  • Provides a standardized way to interact with various LLMs.
  • Supports streaming responses, chat history management, and function calling for enhanced interaction design.
TTS
  • Offers a unified interface for text-to-speech synthesis.
  • Supports different audio formats (MP3, WAV, OGG, etc.) for flexible output.
Embedding
  • Simplifies working with embedding models for text representation.
  • Supports various embedding tasks, including semantic similarity, classification, and clustering.

Getting Started

Contributions

Contributions to Coord are welcome! Please submit issues or pull requests to help improve and expand the library.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoSuchProvider = errors.New("coord: no such provider")

Functions

func ListEmbeddingProviders

func ListEmbeddingProviders() []string

ListEmbeddingProviders returns the names of the registered embedding providers.

func ListLLMProviders

func ListLLMProviders() []string

ListLLMProviders returns the names of the registered llm providers.

func ListTTSProviders

func ListTTSProviders() []string

ListTTSProviders returns the names of the registered tts providers.

func NewEmbeddingClient

func NewEmbeddingClient(ctx context.Context, provider string, configs ...pconf.Config) (provider.EmbeddingClient, error)

func NewLLMClient

func NewLLMClient(ctx context.Context, provider string, configs ...pconf.Config) (provider.LLMClient, error)

func NewTTSClient

func NewTTSClient(ctx context.Context, provider string, configs ...pconf.Config) (provider.TTSClient, error)

func RegisterEmbeddingProvider

func RegisterEmbeddingProvider(name string, p provider.EmbeddingProvider)

RegisterEmbeddingProvider registers an embedding provider.

func RegisterLLMProvider

func RegisterLLMProvider(name string, p provider.LLMProvider)

RegisterLLMProvider registers a llm provider.

func RegisterTTSProvider

func RegisterTTSProvider(name string, p provider.TTSProvider)

RegisterTTSProvider registers a tts provider.

func RemoveEmbeddingProvider

func RemoveEmbeddingProvider(name string)

RemoveEmbeddingProvider removes an embedding provider.

func RemoveLLMProvider

func RemoveLLMProvider(name string)

RemoveLLMProvider removes a llm provider.

func RemoveTTSProvider

func RemoveTTSProvider(name string)

RemoveTTSProvider removes a tts provider.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL