# Customize forecast analytics agents

> Customize forecast analytics agents - A walkthrough to customize the behavior of an AI agent used in
> the ERCOT Forecast Analytics application.

This Markdown file sits beside the HTML page at the same path (with a `.md` suffix). It summarizes the topic and lists links for tools and LLM context.

Companion generated at `2026-05-06T18:17:09.944163+00:00` (UTC).

## Primary page

- [Customize forecast analytics agents](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html): Full documentation for this topic (HTML).

## Sections on this page

- [Prerequisites](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#prerequisites): In-page section heading.
- [Set up for agent experimentation](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#set-up-for-agent-experimentation): In-page section heading.
- [1. Log in and navigate to Workbench](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#1-log-in-and-navigate-to-workbench): In-page section heading.
- [2. Create a codespace](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#2-create-a-codespace): In-page section heading.
- [3. Load files to the codespace](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#3-load-files-to-the-codespace): In-page section heading.
- [4. Start a terminal session](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#4-start-a-terminal-session): In-page section heading.
- [5. Deploy the agent](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#5-deploy-the-agent): In-page section heading.
- [6. Create an API key](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#6-create-an-api-key): In-page section heading.
- [7. Connect to the application](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#7-connect-to-the-application): In-page section heading.
- [8. Test the baseline agent](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#8-test-the-baseline-agent): In-page section heading.
- [9. Open the agent YAML](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#open-the-agent-yaml): In-page section heading.
- [Experiment with the agent](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#experiment-with-the-agent): In-page section heading.
- [Create new agent versions](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#create-new-agent-versions): In-page section heading.
- [Save and publish changes](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#save-and-publish-changes): In-page section heading.
- [Register the updated agent](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#register-the-updated-agent): In-page section heading.
- [Replace with the new version](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#replace-with-the-new-version): In-page section heading.
- [Test the new agent](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#test-the-new-agent): In-page section heading.
- [Samples for experimenting](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#samples-for-experimenting): In-page section heading.
- [Experiment A. Change theagentssection](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#experiment-a-change-the-agents-section): In-page section heading.
- [Experiment B: Adjust the analysis depth](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#experiment-b-adjust-the-analysis-depth): In-page section heading.
- [Experiment C. Add new data sources](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#experiment-c-add-new-data-sources): In-page section heading.
- [Experiment D. Change the output structure](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#experiment-d-change-the-output-structure): In-page section heading.
- [Experiment E. Add a reasoning framework](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#experiment-e-add-a-reasoning-framework): In-page section heading.

## Related documentation

- [Get started](https://docs.datarobot.com/en/docs/get-started/index.html): Linked from this page.
- [agentic workflow](https://docs.datarobot.com/en/docs/agentic-ai/index.html): Linked from this page.
- [API keys and tools](https://docs.datarobot.com/en/docs/platform/acct-settings/api-key-mgmt.html#api-keys-and-tools): Linked from this page.
- [WorkbenchPlaygroundstile](https://docs.datarobot.com/en/docs/agentic-ai/playground-tools/playground-overview.html): Linked from this page.

## Documentation content

This how-to illustrates customizing the behavior of an AI agent used in the ERCOT Forecast Analytics application. The app is already deployed and running—you will connect your own personal agent to it and modify its YAML configuration directly in the DataRobot UI.

**What is ERCOT?**

ERCOT is the Electric Reliability Council of Texas. It is a comprehensive forecasting and data analytics system used to predict electricity demand and generation across the Texas power grid. It provides short-, mid-, and long-term forecast data to help energy traders, utilities, grid operators, and market participants make decisions about power generation dispatch, energy trading, capacity planning, and grid reliability management.

The workflow removes the need to edit YAML files locally. All configuration changes will be performed in the custom model interface in DataRobot after your agent is deployed. Read more about the DataRobot [agentic workflow](https://docs.datarobot.com/en/docs/agentic-ai/index.html).

After this walkthrough, you will have:

- Deployed an AI agent to DataRobot.
- Modified agent behavior in the DataRobot UI.
- Customized role, goal, tone, structure, and data sources.
- Added reasoning logic.
- Updated deployments to use UI-based YAML edits.
- Tested and compared different agent versions.
- Connected custom agents to applications using deployment IDs.

#### Prerequisites

Prior to the workshop, DataRobot has:

- Deployed and shared the ERCOT Forecast Analytics application.
- Cloned the agent template repository.
- Prepared sample data and configured tools.

Download the agent template:

[Download demo data](https://datarobot-doc-assets.s3.us-east-1.amazonaws.com/newsanalystagent.zip)

## Set up for agent experimentation

To get started, unzip the agent template file you just downloaded.

### 1. Log in and navigate to Workbench

Log in to DataRobot; you will land on the home page.

Navigate to Workbench and create a new Use Case.

Name it “Agents in the AM”.

### 2. Create a codespace

From the Use Case getting started page, navigate to codespaces by clicking Notebooks & codespaces:

Then, click to create a new codespace.

And start a new session.

### 3. Load files to the codespace

After the session initializes, drag-and-drop the unzipped file folder named `newsanalystagent` that was downloaded as part of the [prerequisites](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#prerequisites).

### 4. Start a terminal session

Click the Terminal tile to start a terminal session in the codespace.

Navigate to your agent folder:

```
cd newsanalystagent
```

### 5. Deploy the agent

Send the agent to the Registry workshop in preparation for deployment and monitoring. To do so:

From `newsanalystagent` run:

1. Runtask deployto send the agent to the Registry. (.venv)[notebooks@kernel~/storage/newsanalystagent]$taskdeployRunningpulumiupwith[DEPLOY]modeUsingCPython3.11.14interpreterat:/usr/bin/python3Creatingvirtualenvironmentat:.venvBuiltpulumi-datarobot==0.10.24Installed84packagesin151msPleasechooseastack,orcreateanewone:[Usearrowstomove,typetofilter]><createanewstack>
2. PressEnterto create a new Pulumi stack.
3. Type a stack name, such asagent_in_the_am_<LASTNAME>, andEnter.
4. When prompted, selectyesto accept and perform Pulumi updates. This process can take 3-5 minutes and is an excellent time to read up on how to take agents fromPOC to production.

During these steps, the following happens:

- Pulumi packages the agent code.
- DataRobot creates a custom model.
- DataRobot creates a deployment (3–5 minutes) and returns a deployment ID.

Save the deployment ID—you will need it in the next step.

### 6. Create an API key

Click on your user icon and navigate to [API keys and tools](https://docs.datarobot.com/en/docs/platform/acct-settings/api-key-mgmt.html#api-keys-and-tools) to access the area where you can create and manage API keys:

Generate a new API key and name it `Agents in the AM`.

### 7. Connect to the application

Duration: 5 minutes

Open the shared application. A link to it is available in an email sent to the email you signed up with. Enter your "Agents in the AM" token and deployment ID from the previous step.

Click Refresh. The app will confirm a successful connection.

### 8. Test the baseline agent

Duration: 10 minutes

Before modifying the agent YAML, see how the agent behaves in your application.

1. Set the following: FieldValueTrading hubHB_HOUSTONStart date7 days agoEnd dateToday
2. ClickRefreshto load data.
3. View the Forecast Chart and select an error point.
4. ClickAnalyze with AI.

Document the output so that you can compare it against output after you make modifications. Specifically:

- Tone
- Length
- Structure
- Emphasis
- Data sources

### 9. Open the agent YAML

Duration: 20-30 minutes

For the next steps, you will make configuration changes within DataRobot, not in your local files.

1. Navigate toRegistry > Workshop.
2. Open your agent and navigate to theFilessection.
3. Openagents.yamlby clicking thepencil icon to the right of the name. All YAML edits will be done here. The structure defines: And looks as follows: agents:forecast_analyst:role:"..."goal:"..."backstory:"..."tasks:error_analysis:description:"..."expected_output:"..."

## Experiment with the agent

Based on the structure defined above, try making some changes to experiment with the agent output.

- Learn how to create agent versions .
- See the experiments section for sample changes.

### Create new agent versions

To save and publish an edited YAML file, do the following with each change, or any combination of changes:

1. Save and publish your changes.
2. Register the updated agent.
3. Replace the model with the new version.
4. Test the new agent.

#### Save and publish changes

After making any changes to the YAML, while in the YAML editor, click Save.

#### Register the updated agent

Create a new version of the agent by registering the updates.

1. Go to Registry > Workshop .
2. Under the Model list, click on the agent name.
3. Click Register a workflow .

#### Replace with the new version

Replace the current deployment with the new version.

1. Navigate to Console > Deployments .
2. Select the deployment and under the actions menu selectReplace model.
3. Select the new version and replace by clickingSelect.

#### Test the new agent

Once deployed, re-run the analysis you did when [testing the baseline agent](https://docs.datarobot.com/en/docs/get-started/how-to/agents-ercot.html#8-test-the-baseline-agent). As you did in that step, compare and document the output for comparison. Consider:

- Role
- Tone
- Length
- Structure
- News coverage
- Insights

### Samples for experimenting

Iterate and experiment! Try some, or all, of the following examples to use for comparison:

- Change the role and goal .
- Adjust the analysis depth .
- Add new data sources .
- Change the output structure .
- Add a reasoning framework .

Or, try your own.

#### Experiment A. Change the agents section

The default structure of the `agents` section defines the role, goal, and backstory in this way:

```
agents:
  forecast_analyst:
    role: "Energy Market Analyst"
    goal: "Interpret and explain ERCOT forecast errors through comprehensive narrative analysis"
    backstory: |
      You synthesize data into clear narratives that explain market dynamics. 
      You interpret patterns and connect causes rather than simply listing facts.
      You understand how natural gas markets, international energy politics, geopolitical events, 
      and regulatory changes impact electricity prices.
      You consider the interconnected nature of global energy markets and their influence on 
      regional power markets like ERCOT.
```

Try replacing those values, for example, with one of the following:

**Technical perspective:**
```
role: "Grid Operations Engineer"
goal: "Diagnose forecast errors through technical analysis of grid operations"
backstory: |
    You specialize in load balancing, renewable integration, and system constraints.
```

**Financial perspective:**
```
role: "Energy Trading Strategist"
goal: "Identify market inefficiencies and trading opportunities from forecast errors"
backstory: |
    You focus on arbitrage, market signals, and price movements.
```


#### Experiment B: Adjust the analysis depth

Try varying the depth of the analysis:

**Brief:**
```
expected_output: |
    A concise executive summary (3-4 sentences maximum) explaining the primary driver.
```

**Deep dive:**
```yaml
expected_output: |
    A comprehensive analysis (12-15 sentences) covering immediate causes, market dynamics,


external factors, interconnections, and implications.
    ```

#### Experiment C. Add new data sources

In the YAML `description` section, expand your news search queries. Adding more queries gives the agent richer context. Replace lines 28-31 with the following:

```
Call fetch_energy_news with queries:
- "ERCOT Texas electricity grid"
- "natural gas prices energy markets"
- "international energy politics natural gas LNG"
- "renewable energy solar wind forecast Texas"
- "power plant outages maintenance Texas ERCOT"
- "electricity demand forecast weather Texas"
- "Texas energy policy regulation changes"
```

#### Experiment D. Change the output structure

Replace the narrative format with a structured, sectioned output:

```
expected_output: |
    Format your response with these sections:
    1. EXECUTIVE SUMMARY
    2. WEATHER CONDITIONS
    3. MARKET DYNAMICS
    4. EXTERNAL FACTORS
    5. ROOT CAUSE ANALYSIS
    6. APPENDICES
```

#### Experiment E. Add a reasoning framework

Enhance the agent’s step-by-step reasoning:

```
description: |
  Analyze the forecast error using this reasoning process:
  STEP 1 - Quantify Impact
  STEP 2 - Immediate Causes
  STEP 3 - Market Context
  STEP 4 - External Factors
  STEP 5 - Synthesis
```

Congratulations—you now have a working agent, modified and applied for the ERCOT app. Find your agent at any time in the [WorkbenchPlaygroundstile](https://docs.datarobot.com/en/docs/agentic-ai/playground-tools/playground-overview.html).
