llmreference
Cloudflare Workers AI

Using SQLCoder 7B 2 on Cloudflare Workers AI

Implementation guide · SQLCoder · Defog.ai

Serverless

Quick Start

  1. 1
    Create an account at Cloudflare Workers AI and generate an API key.
  2. 2
    Use the Cloudflare Workers AI SDK or REST API to call sqlcoder-7b-2 — see the documentation for request format.

Code Examples

See Cloudflare Workers AI documentation for integration details.

About Cloudflare Workers AI

Cloudflare Workers AI is a serverless GPU inference platform enabling developers to run machine learning models on Cloudflare's global edge network. It supports diverse AI tasks including text generation, image classification, automatic speech recognition, and real-time language translation. The platform provides pay-per-use pricing and access to a curated library of open-source models from Hugging Face, enabling rapid deployment without complex infrastructure management. Key features include low-latency edge computing, streaming responses for large language models, context length customization, and the AI Gateway for monitoring, caching, and cost optimization.

Cloudflare is a leading connectivity cloud company that provides a comprehensive suite of cloud-native products and developer tools to enhance web performance, security, and reliability. Their services include content delivery network (CDN), DDoS mitigation, DNS services, and zero trust security solutions. While Cloudflare doesn't primarily market itself as an AI platform, they have incorporated AI and machine learning technologies into various aspects of their services to improve performance and security, including threat detection capabilities, content delivery optimization, and intelligent routing decisions across their global network.

Pricing on Cloudflare Workers AI

Capabilities

No model capability flags are currently sourced.

About SQLCoder 7B 2

SQLCoder-7B-2 is a large language model developed by Defog, Inc., designed to translate natural language questions into SQL queries, effectively bridging the gap for non-technical users to interact with databases. With its 7 billion parameters, this model is fine-tuned from the CodeLlama-7B base and operates efficiently on consumer-grade hardware. Its key capabilities include high accuracy in text-to-SQL tasks, particularly with complex queries like joins, while focusing on PostgreSQL syntax. SQLCoder-7B-2 is accessible via open-source platforms like Hugging Face and integrates with tools to facilitate user-friendly database querying interfaces. However, it is primarily a translator and requires schema descriptions for effective query generation, with some limitations such as database system specificity and not functioning as an analyst.

Model Specs

Released2024-02-05
Parameters7B
Context32K
ArchitectureDecoder Only

Provider

Cloudflare Workers AI
Cloudflare Workers AI

Cloudflare

San Francisco, California, United States