Rho.Models (rho v0.1.0)

Copy Markdown View Source

The models rho can call right now (like omp's /models): the static catalog filtered to the providers that have a credential (Rho.Auth).

  • Claude (anthropic:), OpenAI (openai:) and Gemini (google:): llm_db's models (the catalog req_llm resolves them through; rho ships it trimmed to these providers, Rho.LLMCatalog), retired and deprecated ones left out. Claude: newest first within Opus, Sonnet, Haiku, then the rest. OpenAI and Gemini: the chat models that take tools, newest release first.
  • ChatGPT (openai_codex:): the Codex backend serves its own set, which llm_db doesn't list; priv/models/openai_codex.json is omp's list (its source and version are in the file).

Summary

Functions

[{provider, signed_in?, models}] for every provider, in Rho.Auth.providers/0 order; a provider without a credential has no models.

Every model of provider in the catalog, whether signed in or not.

Does spec take pictures?

What spec takes as input (:text, :image, :pdf, ...): llm_db's modalities.input, looked up once per spec and kept (the loop asks on every request). Every model on the Codex backend takes text and pictures (omp's catalog); a Claude model llm_db doesn't know (a custom id) takes pictures and PDFs like every Claude; anything else unknown, text only.

Whether two model specs name the same model, ignoring a dated snapshot suffix (claude-haiku-4-5 is claude-haiku-4-5-20251001).

Types

model()

@type model() :: %{
  provider: Rho.Auth.provider(),
  spec: String.t(),
  name: String.t(),
  context: pos_integer() | nil
}

Functions

by_provider(status \\ Auth.status())

@spec by_provider(map()) :: [{Rho.Auth.provider(), boolean(), [model()]}]

[{provider, signed_in?, models}] for every provider, in Rho.Auth.providers/0 order; a provider without a credential has no models.

catalog(provider)

@spec catalog(Rho.Auth.provider()) :: [model()]

Every model of provider in the catalog, whether signed in or not.

images?(spec)

@spec images?(String.t()) :: boolean()

Does spec take pictures?

inputs(spec)

@spec inputs(String.t()) :: [atom()]

What spec takes as input (:text, :image, :pdf, ...): llm_db's modalities.input, looked up once per spec and kept (the loop asks on every request). Every model on the Codex backend takes text and pictures (omp's catalog); a Claude model llm_db doesn't know (a custom id) takes pictures and PDFs like every Claude; anything else unknown, text only.

same?(a, b)

@spec same?(String.t(), String.t()) :: boolean()

Whether two model specs name the same model, ignoring a dated snapshot suffix (claude-haiku-4-5 is claude-haiku-4-5-20251001).