Skip to content

[bot] groq gem not instrumented #165

@braintrust-bot

Description

@braintrust-bot

Summary

The groq gem (~215K downloads, v0.3.2, July 2024) is the primary Ruby client for the Groq Cloud API and is not instrumented by this SDK. Braintrust documents Groq as a supported AI provider with TypeScript and Python instrumentation, but there is no Ruby equivalent.

Groq does not have an official Ruby SDK — the community groq gem is the main Ruby client. It wraps Groq's OpenAI-compatible API with Ruby-idiomatic helpers and provides a meaningful execution surface that warrants dedicated instrumentation.

What is missing

No instrumentation exists for any groq execution surface. Key APIs that should be instrumented:

Chat Completions

  • client.chat(messages, ...) — Core execution method. Accepts a single message string or an array of role/content hashes. Returns a response hash with role and content.
  • Supports model_id selection per-call or globally configured
  • Supports tools: parameter for function/tool calling workflows
  • Supports json: true / json_schema: for structured JSON output (dry-schema compatible)

Streaming

  • v0.3.0 added streaming support via blocks or callable objects that receive content chunks as they arrive

Tool / Function Calling

  • tools: array parameter enables agentic workflows where the model requests external function invocation and resumes with results

Braintrust docs status

supported — Braintrust documents Groq as a supported AI provider at https://www.braintrust.dev/docs/integrations/ai-providers/groq with TypeScript (via the OpenAI package) and Python (via the OpenAI package) instrumentation. No Ruby SDK instrumentation is documented.

Upstream sources

Local repo files inspected

  • lib/braintrust/contrib/ — contains only openai/, ruby_openai/, ruby_llm/, anthropic/, and rails/ directories. No groq directory.
  • lib/braintrust/contrib.rb — registers only 4 integrations: OpenAI, RubyOpenAI, RubyLLM, Anthropic. No Groq integration.
  • Appraisals — no appraisal scenarios for groq
  • braintrust.gemspec — no mention of groq
  • Grep for groq across entire codebase returns zero matches

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels
    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions