From 086b99cc3045ae7471841e3f675c975bb72ba4cf Mon Sep 17 00:00:00 2001 From: Tejas Kashinath Date: Fri, 20 Feb 2026 11:10:14 -0500 Subject: [PATCH 1/2] fix: correct path references and env var names in agent README templates All 6 agent framework README templates referenced nonexistent paths (src/main.py, src/model/load.py, .agentcore) from an older layout. Updated to match the actual generated project structure (main.py, model/load.py, agentcore/). Also replaced hardcoded env var names (AGENTCORE_IDENTITY_OPENAI etc.) with dynamic Handlebars template using identityProviders.[0].envVarName, gated by hasIdentity so Bedrock projects omit the API key row. Added src/assets/**/*.md to .prettierignore since asset markdown files are Handlebars templates that prettier cannot parse correctly. --- .prettierignore | 1 + .../assets.snapshot.test.ts.snap | 116 ++++++++---------- src/assets/python/autogen/base/README.md | 20 ++- src/assets/python/crewai/base/README.md | 20 ++- src/assets/python/googleadk/base/README.md | 18 +-- .../python/langchain_langgraph/base/README.md | 20 ++- src/assets/python/openaiagents/base/README.md | 18 +-- src/assets/python/strands/base/README.md | 20 ++- 8 files changed, 109 insertions(+), 124 deletions(-) diff --git a/.prettierignore b/.prettierignore index 1b763b1b..b0252969 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1 +1,2 @@ CHANGELOG.md +src/assets/**/*.md diff --git a/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap b/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap index ad79babe..f49f4f47 100644 --- a/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap +++ b/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap @@ -792,25 +792,23 @@ exports[`Assets Directory Snapshots > Python framework assets > python/python/au # Layout -There is one directory with generated application code, \`src/\` . At the root, there is a \`.gitignore\` file, a -\`.agentcore\` folder which represents the configurations and state associated with this project. Other \`agentcore\` +The generated application code lives at the agent root directory. At the root, there is a \`.gitignore\` file, an +\`agentcore/\` folder which represents the configurations and state associated with this project. Other \`agentcore\` commands like \`deploy\`, \`dev\`, and \`invoke\` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in \`src/main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this +The main entrypoint to your app is defined in \`main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this file defines a Starlette ASGI app with the AutoGen framework running within. -\`src/model/load.py\` instantiates your chosen model provider. +\`model/load.py\` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| \`AGENTCORE_IDENTITY_OPENAI\` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_ANTHROPIC\` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_GEMINI\` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | # Developing locally @@ -1148,25 +1146,23 @@ exports[`Assets Directory Snapshots > Python framework assets > python/python/cr # Layout -There is one directory with generated application code, \`src/\` . At the root, there is a \`.gitignore\` file, a -\`.agentcore\` folder which represents the configurations and state associated with this project. Other \`agentcore\` +The generated application code lives at the agent root directory. At the root, there is a \`.gitignore\` file, an +\`agentcore/\` folder which represents the configurations and state associated with this project. Other \`agentcore\` commands like \`deploy\`, \`dev\`, and \`invoke\` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in \`src/main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this +The main entrypoint to your app is defined in \`main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this file defines a Starlette ASGI app with the CrewAI framework running within. -\`src/model/load.py\` instantiates your chosen model provider. +\`model/load.py\` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| \`AGENTCORE_IDENTITY_OPENAI\` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_ANTHROPIC\` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_GEMINI\` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | # Developing locally @@ -1474,23 +1470,23 @@ exports[`Assets Directory Snapshots > Python framework assets > python/python/go # Layout -There is one directory with generated application code, \`src/\` . At the root, there is a \`.gitignore\` file, a -\`.agentcore\` folder which represents the configurations and state associated with this project. Other \`agentcore\` +The generated application code lives at the agent root directory. At the root, there is a \`.gitignore\` file, an +\`agentcore/\` folder which represents the configurations and state associated with this project. Other \`agentcore\` commands like \`deploy\`, \`dev\`, and \`invoke\` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in \`src/main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this +The main entrypoint to your app is defined in \`main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this file defines a Starlette ASGI app with the Google ADK framework running within. -\`src/model/load.py\` instantiates your chosen model provider (Gemini). +\`model/load.py\` instantiates your chosen model provider (Gemini). ## Environment Variables -| Variable | Required | Description | -| --------------------------- | -------- | ---------------------------------------------------------------- | -| \`AGENTCORE_IDENTITY_GEMINI\` | Yes | Gemini API key (local) or Identity provider name (deployed) | -| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | # Developing locally @@ -1755,25 +1751,23 @@ exports[`Assets Directory Snapshots > Python framework assets > python/python/la # Layout -There is one directory with generated application code, \`src/\` . At the root, there is a \`.gitignore\` file, a -\`.agentcore\` folder which represents the configurations and state associated with this project. Other \`agentcore\` +The generated application code lives at the agent root directory. At the root, there is a \`.gitignore\` file, an +\`agentcore/\` folder which represents the configurations and state associated with this project. Other \`agentcore\` commands like \`deploy\`, \`dev\`, and \`invoke\` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in \`src/main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this +The main entrypoint to your app is defined in \`main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this file defines a Starlette ASGI app with the LangChain/LangGraph framework running within. -\`src/model/load.py\` instantiates your chosen model provider. +\`model/load.py\` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| \`AGENTCORE_IDENTITY_OPENAI\` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_ANTHROPIC\` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_GEMINI\` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | # Developing locally @@ -2105,23 +2099,23 @@ exports[`Assets Directory Snapshots > Python framework assets > python/python/op # Layout -There is one directory with generated application code, \`src/\` . At the root, there is a \`.gitignore\` file, a -\`.agentcore\` folder which represents the configurations and state associated with this project. Other \`agentcore\` +The generated application code lives at the agent root directory. At the root, there is a \`.gitignore\` file, an +\`agentcore/\` folder which represents the configurations and state associated with this project. Other \`agentcore\` commands like \`deploy\`, \`dev\`, and \`invoke\` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in \`src/main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this +The main entrypoint to your app is defined in \`main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this file defines a Starlette ASGI app with the OpenAI Agents SDK framework running within. -\`src/model/load.py\` instantiates your chosen model provider (OpenAI). +\`model/load.py\` instantiates your chosen model provider (OpenAI). ## Environment Variables -| Variable | Required | Description | -| --------------------------- | -------- | ---------------------------------------------------------------- | -| \`AGENTCORE_IDENTITY_OPENAI\` | Yes | OpenAI API key (local) or Identity provider name (deployed) | -| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | # Developing locally @@ -2352,25 +2346,23 @@ exports[`Assets Directory Snapshots > Python framework assets > python/python/st # Layout -There is one directory with generated application code, \`src/\` . At the root, there is a \`.gitignore\` file, a -\`.agentcore\` folder which represents the configurations and state associated with this project. Other \`agentcore\` +The generated application code lives at the agent root directory. At the root, there is a \`.gitignore\` file, an +\`agentcore/\` folder which represents the configurations and state associated with this project. Other \`agentcore\` commands like \`deploy\`, \`dev\`, and \`invoke\` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in \`src/main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this +The main entrypoint to your app is defined in \`main.py\`. Using the AgentCore SDK \`@app.entrypoint\` decorator, this file defines a Starlette ASGI app with the chosen Agent framework SDK running within. -\`src/model/load.py\` instantiates your chosen model provider. +\`model/load.py\` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| \`AGENTCORE_IDENTITY_OPENAI\` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_ANTHROPIC\` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| \`AGENTCORE_IDENTITY_GEMINI\` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/autogen/base/README.md b/src/assets/python/autogen/base/README.md index 11ab9b5b..576274bf 100644 --- a/src/assets/python/autogen/base/README.md +++ b/src/assets/python/autogen/base/README.md @@ -2,25 +2,23 @@ This is a project generated by the agentcore create CLI tool! # Layout -There is one directory with generated application code, `src/` . At the root, there is a `.gitignore` file, a -`.agentcore` folder which represents the configurations and state associated with this project. Other `agentcore` +The generated application code lives at the agent root directory. At the root, there is a `.gitignore` file, an +`agentcore/` folder which represents the configurations and state associated with this project. Other `agentcore` commands like `deploy`, `dev`, and `invoke` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in `src/main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this +The main entrypoint to your app is defined in `main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this file defines a Starlette ASGI app with the AutoGen framework running within. -`src/model/load.py` instantiates your chosen model provider. +`model/load.py` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| `AGENTCORE_IDENTITY_OPENAI` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_ANTHROPIC` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_GEMINI` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/crewai/base/README.md b/src/assets/python/crewai/base/README.md index ca948cc5..12bf26eb 100644 --- a/src/assets/python/crewai/base/README.md +++ b/src/assets/python/crewai/base/README.md @@ -2,25 +2,23 @@ This is a project generated by the agentcore create CLI tool! # Layout -There is one directory with generated application code, `src/` . At the root, there is a `.gitignore` file, a -`.agentcore` folder which represents the configurations and state associated with this project. Other `agentcore` +The generated application code lives at the agent root directory. At the root, there is a `.gitignore` file, an +`agentcore/` folder which represents the configurations and state associated with this project. Other `agentcore` commands like `deploy`, `dev`, and `invoke` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in `src/main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this +The main entrypoint to your app is defined in `main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this file defines a Starlette ASGI app with the CrewAI framework running within. -`src/model/load.py` instantiates your chosen model provider. +`model/load.py` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| `AGENTCORE_IDENTITY_OPENAI` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_ANTHROPIC` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_GEMINI` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/googleadk/base/README.md b/src/assets/python/googleadk/base/README.md index fac9c478..89de0b46 100644 --- a/src/assets/python/googleadk/base/README.md +++ b/src/assets/python/googleadk/base/README.md @@ -2,23 +2,23 @@ This is a project generated by the agentcore create CLI tool! # Layout -There is one directory with generated application code, `src/` . At the root, there is a `.gitignore` file, a -`.agentcore` folder which represents the configurations and state associated with this project. Other `agentcore` +The generated application code lives at the agent root directory. At the root, there is a `.gitignore` file, an +`agentcore/` folder which represents the configurations and state associated with this project. Other `agentcore` commands like `deploy`, `dev`, and `invoke` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in `src/main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this +The main entrypoint to your app is defined in `main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this file defines a Starlette ASGI app with the Google ADK framework running within. -`src/model/load.py` instantiates your chosen model provider (Gemini). +`model/load.py` instantiates your chosen model provider (Gemini). ## Environment Variables -| Variable | Required | Description | -| --------------------------- | -------- | ---------------------------------------------------------------- | -| `AGENTCORE_IDENTITY_GEMINI` | Yes | Gemini API key (local) or Identity provider name (deployed) | -| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/langchain_langgraph/base/README.md b/src/assets/python/langchain_langgraph/base/README.md index 2d275ac1..a99fcd58 100644 --- a/src/assets/python/langchain_langgraph/base/README.md +++ b/src/assets/python/langchain_langgraph/base/README.md @@ -2,25 +2,23 @@ This is a project generated by the agentcore create CLI tool! # Layout -There is one directory with generated application code, `src/` . At the root, there is a `.gitignore` file, a -`.agentcore` folder which represents the configurations and state associated with this project. Other `agentcore` +The generated application code lives at the agent root directory. At the root, there is a `.gitignore` file, an +`agentcore/` folder which represents the configurations and state associated with this project. Other `agentcore` commands like `deploy`, `dev`, and `invoke` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in `src/main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this +The main entrypoint to your app is defined in `main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this file defines a Starlette ASGI app with the LangChain/LangGraph framework running within. -`src/model/load.py` instantiates your chosen model provider. +`model/load.py` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| `AGENTCORE_IDENTITY_OPENAI` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_ANTHROPIC` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_GEMINI` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/openaiagents/base/README.md b/src/assets/python/openaiagents/base/README.md index 8ee78644..12bb64b9 100644 --- a/src/assets/python/openaiagents/base/README.md +++ b/src/assets/python/openaiagents/base/README.md @@ -2,23 +2,23 @@ This is a project generated by the agentcore create CLI tool! # Layout -There is one directory with generated application code, `src/` . At the root, there is a `.gitignore` file, a -`.agentcore` folder which represents the configurations and state associated with this project. Other `agentcore` +The generated application code lives at the agent root directory. At the root, there is a `.gitignore` file, an +`agentcore/` folder which represents the configurations and state associated with this project. Other `agentcore` commands like `deploy`, `dev`, and `invoke` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in `src/main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this +The main entrypoint to your app is defined in `main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this file defines a Starlette ASGI app with the OpenAI Agents SDK framework running within. -`src/model/load.py` instantiates your chosen model provider (OpenAI). +`model/load.py` instantiates your chosen model provider (OpenAI). ## Environment Variables -| Variable | Required | Description | -| --------------------------- | -------- | ---------------------------------------------------------------- | -| `AGENTCORE_IDENTITY_OPENAI` | Yes | OpenAI API key (local) or Identity provider name (deployed) | -| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/strands/base/README.md b/src/assets/python/strands/base/README.md index 1c8ab4bd..540dd314 100644 --- a/src/assets/python/strands/base/README.md +++ b/src/assets/python/strands/base/README.md @@ -2,25 +2,23 @@ This is a project generated by the agentcore create basic CLI tool! # Layout -There is one directory with generated application code, `src/` . At the root, there is a `.gitignore` file, a -`.agentcore` folder which represents the configurations and state associated with this project. Other `agentcore` +The generated application code lives at the agent root directory. At the root, there is a `.gitignore` file, an +`agentcore/` folder which represents the configurations and state associated with this project. Other `agentcore` commands like `deploy`, `dev`, and `invoke` rely on the configuration stored here. -## src/ +## Agent Root -The main entrypoint to your app is defined in `src/main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this +The main entrypoint to your app is defined in `main.py`. Using the AgentCore SDK `@app.entrypoint` decorator, this file defines a Starlette ASGI app with the chosen Agent framework SDK running within. -`src/model/load.py` instantiates your chosen model provider. +`model/load.py` instantiates your chosen model provider. ## Environment Variables -| Variable | Required | Description | -| ------------------------------ | --------------- | ---------------------------------------------------------------- | -| `AGENTCORE_IDENTITY_OPENAI` | Yes (OpenAI) | OpenAI API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_ANTHROPIC` | Yes (Anthropic) | Anthropic API key (local) or Identity provider name (deployed) | -| `AGENTCORE_IDENTITY_GEMINI` | Yes (Gemini) | Gemini API key (local) or Identity provider name (deployed) | -| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +| Variable | Required | Description | +| --- | --- | --- | +{{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | # Developing locally From 443b2d8834c10db1ffb8ff224a3c7df44ff552d0 Mon Sep 17 00:00:00 2001 From: Tejas Kashinath Date: Fri, 20 Feb 2026 11:13:28 -0500 Subject: [PATCH 2/2] fix: correct env file reference from agentcore/.env to .env.local The actual env file used is agentcore/.env.local (constant ENV_FILE in src/lib/constants.ts), not agentcore/.env. --- .../__snapshots__/assets.snapshot.test.ts.snap | 12 ++++++------ src/assets/python/autogen/base/README.md | 2 +- src/assets/python/crewai/base/README.md | 2 +- src/assets/python/googleadk/base/README.md | 2 +- src/assets/python/langchain_langgraph/base/README.md | 2 +- src/assets/python/openaiagents/base/README.md | 2 +- src/assets/python/strands/base/README.md | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap b/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap index f49f4f47..7d85fb3a 100644 --- a/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap +++ b/src/assets/__tests__/__snapshots__/assets.snapshot.test.ts.snap @@ -808,7 +808,7 @@ file defines a Starlette ASGI app with the AutoGen framework running within. | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`.env.local\` instead of AgentCore Identity | # Developing locally @@ -1162,7 +1162,7 @@ file defines a Starlette ASGI app with the CrewAI framework running within. | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`.env.local\` instead of AgentCore Identity | # Developing locally @@ -1486,7 +1486,7 @@ file defines a Starlette ASGI app with the Google ADK framework running within. | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`.env.local\` instead of AgentCore Identity | # Developing locally @@ -1767,7 +1767,7 @@ file defines a Starlette ASGI app with the LangChain/LangGraph framework running | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`.env.local\` instead of AgentCore Identity | # Developing locally @@ -2115,7 +2115,7 @@ file defines a Starlette ASGI app with the OpenAI Agents SDK framework running w | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`.env.local\` instead of AgentCore Identity | # Developing locally @@ -2362,7 +2362,7 @@ file defines a Starlette ASGI app with the chosen Agent framework SDK running wi | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| \`{{identityProviders.[0].envVarName}}\` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`agentcore/.env\` instead of AgentCore Identity | +{{/if}}| \`LOCAL_DEV\` | No | Set to \`1\` to use \`.env.local\` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/autogen/base/README.md b/src/assets/python/autogen/base/README.md index 576274bf..c52d5118 100644 --- a/src/assets/python/autogen/base/README.md +++ b/src/assets/python/autogen/base/README.md @@ -18,7 +18,7 @@ file defines a Starlette ASGI app with the AutoGen framework running within. | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `.env.local` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/crewai/base/README.md b/src/assets/python/crewai/base/README.md index 12bf26eb..3c159da2 100644 --- a/src/assets/python/crewai/base/README.md +++ b/src/assets/python/crewai/base/README.md @@ -18,7 +18,7 @@ file defines a Starlette ASGI app with the CrewAI framework running within. | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `.env.local` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/googleadk/base/README.md b/src/assets/python/googleadk/base/README.md index 89de0b46..b40564aa 100644 --- a/src/assets/python/googleadk/base/README.md +++ b/src/assets/python/googleadk/base/README.md @@ -18,7 +18,7 @@ file defines a Starlette ASGI app with the Google ADK framework running within. | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `.env.local` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/langchain_langgraph/base/README.md b/src/assets/python/langchain_langgraph/base/README.md index a99fcd58..68d74c13 100644 --- a/src/assets/python/langchain_langgraph/base/README.md +++ b/src/assets/python/langchain_langgraph/base/README.md @@ -18,7 +18,7 @@ file defines a Starlette ASGI app with the LangChain/LangGraph framework running | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `.env.local` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/openaiagents/base/README.md b/src/assets/python/openaiagents/base/README.md index 12bb64b9..a60b131e 100644 --- a/src/assets/python/openaiagents/base/README.md +++ b/src/assets/python/openaiagents/base/README.md @@ -18,7 +18,7 @@ file defines a Starlette ASGI app with the OpenAI Agents SDK framework running w | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `.env.local` instead of AgentCore Identity | # Developing locally diff --git a/src/assets/python/strands/base/README.md b/src/assets/python/strands/base/README.md index 540dd314..1c180436 100644 --- a/src/assets/python/strands/base/README.md +++ b/src/assets/python/strands/base/README.md @@ -18,7 +18,7 @@ file defines a Starlette ASGI app with the chosen Agent framework SDK running wi | Variable | Required | Description | | --- | --- | --- | {{#if hasIdentity}}| `{{identityProviders.[0].envVarName}}` | Yes | {{modelProvider}} API key (local) or Identity provider name (deployed) | -{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `agentcore/.env` instead of AgentCore Identity | +{{/if}}| `LOCAL_DEV` | No | Set to `1` to use `.env.local` instead of AgentCore Identity | # Developing locally