gptr 1.0.0 is a complete rewrite: an agent harness that runs inside the live R session and works on the objects already in memory.
get_response() and dataframe_to_text(), is removed with no aliases.get_response(), use
session = peter("your prompt", model = "openai/gpt-6-sol"), which returns a session object;
its answer is session$text, and session |> peter("next prompt") continues the conversation.
The key comes from OPENAI_API_KEY (or a .env file read with gptr_env()) instead of the
api_key argument, instructions that went into system_specification go into the prompt or
the project instructions file .gptr/vignette.Rmd, and answers stream to the console when a
person is present instead of through print_response.dataframe_to_text(), pass the data frame to peter() as context, for example
peter("Which variables are correlated?", mtcars): gptr describes the object compactly and
the model computes on it in your session.model argument or with gptr_config().peter() is the single entry point. Without a prompt it opens a chat in the console; with a
prompt it runs the agent loop and returns the session. The pipe steers one session:
peter("...") |> peter("...") adds turns to the same object. gptr_fork() is the only way to
branch. Sessions are saved in the project and resumed with gptr_sessions(),
gptr_resume() and gptr_last().gptr_providers(check_login = TRUE) shows CLI sign-in status.peter$grep(), peter$find() and peter$ls(); shell, Python, SQL and knitr engines
are reached through peter$sh(), peter$py(), peter$sql() and peter$knit().claude command-line tool, experimental) and the ChatGPT plan (through codex) are
supported without keys. See gptr_providers() and gptr_models().peter() returns logical, choice or score vectors with
their probabilities (gptr_prob()) that work inside if, for and while, one element per
input. A generative model can emulate them; emulated answers are marked as uncalibrated.manual (default), edits, auto and plan, rules with
gptr_permissions(), and an advisory risk classifier, gptr_risk(). A permission question
without a person present stops the run with a classed condition.peter()
call in .R, .Rmd, .qmd and .ipynb documents and replays without model calls
(gptr_doc(), gptr_source(), gptr_blocks(), gptr_cache()).gptr_init() creates a .gptr/ project workspace with the project instructions file
.gptr/vignette.Rmd; gptr_config() and gptr_trust() manage settings and trust.gptr_rewind(), gptr_checkpoints() and /undo restore objects, files and the
conversation.agents =, parallel =, gptr_parallel()), across
providers.gptr_register(), gptr_spec() and the spec constructors).gptr_mcp(), gptr_mcp_add()) that exposes server
tools as R functions, and gptr_mcp_serve(), which serves the live session to other agents.gptr_artifacts()).gptr_login() signs in to
providers and MCP servers, gptr_env() loads .env files (including the jev-key alias) and
gptr_scrub() cleans files that captured a key.gptr_usage(), gptr_prompt(), gptr_describe() and the
budget argument.background = TRUE) are experimental.?gptr_security and ?gptr_egress for what gptr does on your behalf and what it sends to
model providers, and ?gptr_options for every option.gptr_message_billing_env condition with the removed names, never their values. Handlers
use muffleMessage; the notice respects gptr.quiet. Actual billing refusals remain errors.get_response() and dataframe_to_text() for the
OpenAI 'ChatGPT' API (released 2025-04-05, after 0.5.0 and 0.6.0 in May 2024).