ClickHouse

AI SDK Cpp — AI skill for Claude Code

AI community

The AI Toolkit for Modern C++.

How to install AI SDK Cpp

This entry records only its repository, not the path inside it, so there is no exact command to give. Open ClickHouse/ai-sdk-cpp and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What AI SDK Cpp does

The AI Toolkit for Modern C++. From the engineers at ClickHouse, ai-sdk-cpp is a free, open‑source library for building AI‑powered applications and agents.

Alternatives in AI

  • Axonhub — ⚡️ Open-source AI Gateway — Use any SDK to call 100+ LLMs 3.2k ★
  • Paca — AI-native, free, open-source alternative to Jira, Trello, ClickUp & Monday 1.8k ★
  • My Free Code — Open-source multi-provider AI gateway for Claude Code and other coding agents, with model routing, streaming 633 ★

README

AI SDK CPP

The AI SDK CPP is a modern C++ toolkit designed to help you build AI-powered applications with popular model providers like OpenAI and Anthropic. It provides a unified, easy-to-use API that abstracts away the complexity of different provider implementations.

Motivation

C++ developers have long lacked a first-class, convenient way to interact with modern AI services like OpenAI, Anthropic, and others. AI SDK CPP bridges this gap by providing:

  • Unified API: Work with multiple AI providers through a single, consistent interface
  • Modern C++: Built with C++20 features for clean, expressive code
  • Minimal Dependencies: Minimal external dependencies for easy integration

Installation

You will need a C++20 compatible compiler and CMake 3.16+ installed on your development machine.

Usage

Core API

The AI SDK CPP Core module provides a unified API to interact with model providers like OpenAI and Anthropic.

OpenAI Integration

#include 
#include 
#include 

int main() {
    // Ensure OPENAI_API_KEY environment variable is set
    auto client = ai::openai::create_client();
    
    ai::GenerateOptions options(ai::openai::models::kGpt56,
                                "Why is the sky blue?");
    options.system = "You are a friendly assistant!";
    auto result = client.generate_text(options);
    
    if (result) {
        std::cout << result->text << std::endl;
    }
    
    return 0;
}

Anthropic Integration

#include 
#include 
#include 

int main() {
    // Ensure ANTHROPIC_API_KEY environment variable is set
    auto client = ai::anthropic::create_client();
    ai::GenerateOptions options(ai::anthropic::models::kClaudeSonnet5,
                                "Explain quantum computing in simple terms.");
    options.system = "You are a helpful assistant.";
    auto result = client.generate_text(options);

    if (result) {