Package: ellmer 0.1.1

Hadley Wickham

ellmer: Chat with Large Language Models

Chat with large language models from a range of providers including 'Claude' <https://claude.ai>, 'OpenAI' <https://chatgpt.com>, and more. Supports streaming, asynchronous calls, tool calling, and structured data extraction.

Authors:Hadley Wickham [aut, cre], Joe Cheng [aut], Aaron Jacobs [aut], Posit Software, PBC [cph, fnd]

ellmer_0.1.1.tar.gz
ellmer_0.1.1.zip(r-4.5)ellmer_0.1.1.zip(r-4.4)ellmer_0.1.1.zip(r-4.3)
ellmer_0.1.1.tgz(r-4.5-any)ellmer_0.1.1.tgz(r-4.4-any)ellmer_0.1.1.tgz(r-4.3-any)
ellmer_0.1.1.tar.gz(r-4.5-noble)ellmer_0.1.1.tar.gz(r-4.4-noble)
ellmer_0.1.1.tgz(r-4.4-emscripten)ellmer_0.1.1.tgz(r-4.3-emscripten)
ellmer.pdf |ellmer.html
ellmer/json (API)
NEWS

# Install 'ellmer' in R:
install.packages('ellmer', repos = c('https://tidyverse.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/tidyverse/ellmer/issues

Pkgdown site:https://ellmer.tidyverse.org

On CRAN:

11.30 score 333 stars 3 packages 27 scripts 2.1k downloads 53 exports 21 dependencies

Last updated 2 days agofrom:3e308215eb. Checks:8 OK. Indexed: yes.

TargetResultLatest binary
Doc / VignettesOKFeb 07 2025
R-4.5-winOKFeb 07 2025
R-4.5-macOKFeb 07 2025
R-4.5-linuxOKFeb 07 2025
R-4.4-winOKFeb 07 2025
R-4.4-macOKFeb 07 2025
R-4.3-winOKFeb 07 2025
R-4.3-macOKFeb 07 2025

Exports:chat_azurechat_bedrockchat_claudechat_cortexchat_cortex_analystchat_databrickschat_deepseekchat_geminichat_githubchat_groqchat_ollamachat_openaichat_openrouterchat_perplexitychat_snowflakechat_vllmContentcontent_image_filecontent_image_plotcontent_image_urlcontent_pdf_filecontent_pdf_urlContentImageContentImageInlineContentImageRemoteContentPDFcontents_htmlcontents_markdowncontents_textContentTextContentToolRequestContentToolResultcreate_tool_defhas_credentialsinterpolateinterpolate_filelive_browserlive_consoleProvidertoken_usagetoolTurntype_arraytype_booleantype_enumtype_integertype_numbertype_objecttype_stringTypeArrayTypeBasicTypeEnumTypeObject

Dependencies:askpassclicorocurlfastmapgluehttr2jsonlitelaterlifecyclemagrittropensslpromisesR6rappdirsRcpprlangS7sysvctrswithr

Getting started with ellmer

Rendered fromellmer.Rmdusingknitr::rmarkdownon Feb 07 2025.

Last update: 2025-02-03
Started: 2024-12-19

Prompt design

Rendered fromprompt-design.Rmdusingknitr::rmarkdownon Feb 07 2025.

Last update: 2024-12-19
Started: 2024-11-28

Streaming and async APIs

Rendered fromstreaming-async.Rmdusingknitr::rmarkdownon Feb 07 2025.

Last update: 2025-01-13
Started: 2024-10-07

Structured data

Rendered fromstructured-data.Rmdusingknitr::rmarkdownon Feb 07 2025.

Last update: 2025-02-06
Started: 2024-10-24

Tool/function calling

Rendered fromtool-calling.Rmdusingknitr::rmarkdownon Feb 07 2025.

Last update: 2024-12-19
Started: 2024-10-07

Readme and manuals

Help Manual

Help pageTopics
A chatChat
Chat with a model hosted on Azure OpenAIchat_azure
Chat with an AWS bedrock modelchat_bedrock
Chat with an Anthropic Claude modelchat_claude
Create a chatbot that speaks to the Snowflake Cortex Analystchat_cortex_analyst
Chat with a model hosted on Databrickschat_databricks
Chat with a model hosted on DeepSeekchat_deepseek
Chat with a Google Gemini modelchat_gemini
Chat with a model hosted on the GitHub model marketplacechat_github
Chat with a model hosted on Groqchat_groq
Chat with a local Ollama modelchat_ollama
Chat with an OpenAI modelchat_openai
Chat with one of the many models hosted on OpenRouterchat_openrouter
Chat with a model hosted on perplexity.aichat_perplexity
Chat with a model hosted on Snowflakechat_snowflake
Chat with a model hosted by vLLMchat_vllm
Content types received from and sent to a chatbotContent ContentImage ContentImageInline ContentImageRemote ContentPDF ContentText ContentToolRequest ContentToolResult
Encode images for chat inputcontent_image_file content_image_plot content_image_url
Encode PDFs content for chat inputcontent_pdf_file content_pdf_url
Format contents into a textual representationcontents_html contents_markdown contents_text
Create metadata for a toolcreate_tool_def
Helpers for interpolating data into promptsinterpolate interpolate_file
Open a live chat applicationlive_browser live_console
A chatbot providerProvider
Report on token usage in the current sessiontoken_usage
Define a tooltool
A user or assistant turnTurn
Type definitions for function calling and structured data extraction.Type TypeArray TypeBasic TypeEnum TypeObject
Type specificationstype_array type_boolean type_enum type_integer type_number type_object type_string