Welcome to the Positron Assistant demo for posit::conf 2025 in Atlanta!
With the help of Positron Assistant, this demo will guide you through exploring two datasets:
-
the Georgia Aquarium Species dataset using Python
-
the Atlanta Falcons football team datasets using R
If you're running this demo in a guided workshop, your interpreters and packages should already be set up for you in the demo environment. Please jump ahead to either the Python demo or R demo section and follow the steps!
Otherwise, click to expand the pre-requisites section below and follow the steps to set up your environment.
Pre-requisites if you're running this demo on your own machine
-
Install and open Positron. We recommend the latest stable Positron version 2025.09.0-139.
-
Copy this repository's GitHub URL to your clipboard:
https://github.com/posit-dev/posit-conf-2025-positron-assistant-demo.git
-
Clone this repository and open the folder in Positron
-
Run the command "Workspaces: New Folder from Git..." in the Command Palette
-
Paste in the repository URL you copied
-
Select a local directory to clone the repository into
-
Click OK
-
-
Use the Positron Assistant guide to set up Positron Assistant with an Anthropic API key.
-
Ensure you have a Python interpreter (3.9 through 3.13) installed on your machine
-
Create a virtual environment for this project
-
Run the command "Python: Create Environment..." in the Command Palette
-
Select
Venv
as the environment type -
Pick a base interpreter (we recommend the latest version of Python)
-
Select the
requirements.txt
file in the dropdown to install the required packages -
Click OK
-
Wait for the environment to be created and packages to be installed
-
-
You're all set! Jump to the Python demo section and follow the steps!
-
Ensure you have R (R 4.2 and higher) installed on your machine.
-
Install the required packages by running the following commands in the R Console:
install.packages("tidyverse")
-
You're all set! Jump to the R demo section and follow the steps!
-
Open up the Python script python-demo.py in an editor
-
Run the script by clicking the Play button in the Editor Actions bar
-
Once all the code has been run, you should see:
-
code executed in the Console
-
data loaded into the Variables pane
-
a plot rendered in the Plots pane
-
-
Follow these steps to view data tables in the Data Explorer:
-
Run the command "Session: Focus on Variables View", which will open up the Variables View if it is not already open.
-
In the Variables View, double-click on the
species
variable or click the "View Data Table" icon to open the table in the Data Explorer. -
Play around with the Data Explorer to filter, sort, and visualize the data. For more information, see the Data Explorer documentation.
-
Open the "Summary Panel", which columns are missing data?
-
Use the "Summary Panel" to see the distribution of
conservation_status
. What is the most common status? -
Sort the data by
conservation_status
andscientific_name
by right clicking on the column name and clicking "Sort Ascending" or "Sort Descending".
-
-
Open the Positron Assistant pane by clicking on the Positron Assistant robot icon in the sidebar, or by opening the Command Palette (Cmd/Ctrl + Shift + P) and running the command "View: Show Chat".
-
In the Positron Assistant pane, ensure your chat is in
Ask
mode. You can switch modes by clicking on the mode selector at the bottom of the chat pane. Positron Assistant offers three modes:Ask
for questions and help (default),Edit
for collaborative code modifications, andAgent
for autonomous task execution including file management and code execution. -
We recommend selecting the Claude 4 Sonnet model for this activity. You can change the model by clicking on the model name at the bottom of the chat pane.
-
Use the example messages below to explore the Georgia Aquarium Species dataset.
Try out these example prompts in Ask
mode!
Please summarize the `species` data table
What do you see in the current plot?
Explain the values of the `conservation_status` column. Is there a hierarchy?
Based on data tables in my session, please suggest some starter code for interesting analyses or visualizations
-
Try out the code snippets Positron Assistant suggests by clicking the Play button on the code blocks.
-
If you run into issues, it's a good time to switch over to
Agent
mode (see optional next step) to let Positron Assistant help you debug!
You're done! π
Additional prompts for `Agent` mode
Agent
mode allows Positron Assistant to modify and run code in the Console, making it possible to perform more complex tasks.
-
Start a new chat by clicking on the "+" icon at the top of the Positron Assistant sidebar chat.
-
Switch to
Agent
mode by clicking on the mode selector at the bottom of the chat pane and selectingAgent
. -
Ensure you have python-demo.py attached to the chat context. If it is not already attached:
-
Open the file in the editor
-
Drag the file tab to the sidebar chat; or in the Command Palette (Cmd/Ctrl + Shift + P), run the command "Chat: Add File to Chat".
-
-
Then, try these additional prompts:
Update the script to change the colour scheme to oceanic colours.
- Run the script to see the changes reflected in the plot. If you're satisfied with the changes, you can "Keep" the changes.
Create a heatmap of the conservation risk by region.
- Positron Assistant may prompt you to "Run Code" to better understand the data and execute code in the Console. Click "Run Code" to execute the code in the Console.
-
Open up the R script r-demo.R in an editor
-
Run the script by clicking the Play button in the Editor Actions bar
-
Once all the code has been run, you should see:
-
code executed in the Console
-
data loaded into the Environment pane
-
a plot rendered in the Plots pane
-
-
Follow these steps to view data tables in the Data Explorer:
-
Run the command "Session: Focus on Variables View", which will open up the Variables View if it is not already open.
-
In the Variables View, click the "View Data Table" icon or double-click on any of the table variables to open them in the Data Explorer. Start with the
falcons_seasons
dataframe. -
Play around with the Data Explorer to filter, sort, and visualize the data. For more information, see the Data Explorer documentation.
-
Open the "Summary Panel", which columns are missing data?
-
Use the "Summary Panel" to see the distribution of
Head Coach
. Which Head Coach has the longest tenure? -
Sort the data by
W
(wins) andPF
(points for) by right clicking on the column name and clicking "Sort Ascending" or "Sort Descending".
-
-
Open the Positron Assistant pane by clicking on the Positron Assistant robot icon in the sidebar, or by opening the Command Palette (Cmd/Ctrl + Shift + P) and running the command "View: Show Chat".
-
In the Positron Assistant pane, ensure your chat is in
Ask
mode. You can switch modes by clicking on the mode selector at the bottom of the chat pane. Positron Assistant offers three modes:Ask
for questions and help (default),Edit
for collaborative code modifications, andAgent
for autonomous task execution including file management and code execution. -
We recommend selecting the Claude 4 Sonnet model for this activity. You can change the model by clicking on the model name at the bottom of the chat pane.
-
Use the example messages below to explore the Atlanta Falcons football team datasets.
Try out these example prompts in Ask
mode!
Please summarize the `falcons_scores` data table
What do you see in the current plot?
Explain what each of the columns means for someone who does not watch football
Based on the data tables in my session, please suggest some interesting analyses or visualizations
-
Try out the code snippets Positron Assistant suggests by clicking the Play button on the code blocks.
-
If you run into issues, it's a good time to switch over to
Agent
mode (see optional next step) to let Positron Assistant help you debug!
You're done! π
Additional prompts for `Agent` mode
Agent
mode allows Positron Assistant to modify and run code in the Console, making it possible to perform more complex tasks.
-
Start a new chat by clicking on the "+" icon at the top of the Positron Assistant sidebar chat.
-
Switch to
Agent
mode by clicking on the mode selector at the bottom of the chat pane and selectingAgent
. -
Ensure you have r-demo.R attached to the chat context. If it is not already attached:
-
Open the file in the editor
-
Drag the file tab to the sidebar chat; or in the Command Palette (Cmd/Ctrl + Shift + P), run the command "Chat: Add File to Chat".
-
-
Then, try these additional prompts:
Change the plot to use a different colour scheme.
- Run the script to see the changes reflected in the plot. If you're satisfied with the changes, you can "Keep" the changes.
Create a heatmap of the win-loss percentage by season.
- Positron Assistant may prompt you to "Run Code" to better understand the data and execute code in the Console. Click "Run Code" to execute the code in the Console.