StreetRace is an agentic AI coding partner designed to help engineers leverage AI capabilities directly from the command line to create software.
Project description
StreetRace is an open-source platform for engineering-native AI agents that integrate with your tools, automate your workflows, and evolve with your development process.
StreetRace is a new kind of teammate: one that runs linters, generates modules, monitors builds, or triages bugs the way you taught it.
We believe the future of development is peer-to-peer: engineer + agent. And we’re building the rails.
If you want to help define that future - contribute code, build agents, or shape the platform - GitHub’s open. Jump in, clone it, and make agents your own.
StreetRace🚗💨
Unlike generic agent frameworks or black-box AI engineers, StreetRace is:
🔧 Built for Developers, by Developers
StreetRace integrates directly with your tools like the CLI and code editor (Dockerized environments will follow). Agents can operate in the same terminal and shell as their human counterparts, enabling seamless, trusted collaboration.
🤝 Engineering Peer, Not Replacement
Where Devin and other agents aim to replace engineers, StreetRace empowers engineers. Your agent isn't a shadow coder, it’s a co-worker you can inspect, guide, and evolve.
🧩 Opinionated, Yet Extensible
Unlike CrewAI’s generic orchestration layer, StreetRace comes powered by ADK, provides built-in A2A publishing, and integrates with any MCP tools. It comes with battle-tested patterns and tools for building high-performing agents. Developers can publish reusable agents to automate routine tasks like onboarding codebases, responding to CI failures, or generating service templates.
🛠 Open, Flexible, and Secure
Model-agnostic and open-source, StreetRace supports everything from local Ollama models to cloud APIs. Agents run in the local environment, with controlled APIs (A2A endpoints), giving teams full control, observability, and security.
Getting Started
Development Environment
For the best development experience, use the VS Code Dev Container which includes:
- Enhanced terminal with persistent bash history and autocompletion
- Command shortcuts like
gs(git status),pi(poetry install),check(make check)
To get started:
- Install the Dev Containers extension
- Open the project in VS Code
- Click "Reopen in Container" when prompted
- Type
helpin the terminal to see all available commands and aliases
Installation and usage
Install from PyPI
Using pipx (follow pipx installation instructions here.)
$ pipx install streetrace
Or using pip to install as project dependency:
$ pip install streetrace
Install from source
The code is managed by poetry. If it's not already installed, follow the poetry
install guide.
$ git clone git@github.com:krmrn42/street-race.git
$ cd street-race
$ poetry install
$ poetry run streetrace --model=$YOUR_FAVORITE_MODEL
Where $YOUR_FAVORITE_MODEL is the
LiteLLM provider route (provider/model).
Environment Setup
Follow relevant LiteLLM guides to set up environment for a specific model. For example,
for commercial providers, set your regular API key in the environment
(ANTHROPIC_API_KEY, GEMINI_API_KEY, OPENAI_API_KEY, etc), or OLLAMA_API_URL for
local Ollama models.
Usage
streetrace is a CLI, and it can be installed as your dev dependency. It runs in the
current directory, keeping all file reading and modifications in the current directory.
You can optionally supply a --path argument to provide a different working directory
path.
$ streetrace --model=$YOUR_FAVORITE_MODEL
You: Type your prompt
Try in your environment
Currently, StreetRace includes one coding agent with a model of your choise. This agent is a capable software engineering agent that can work with your technology stack.
You can add more context to your prompts in two ways:
- Use @-mentions, autocomplete will suggest local files that you can add to the prompt.
- Add project context and instructions in the
.streetracefolder in your project's directory:SYSTEM.mdis used as your system instruction.- Any other files under
.streetraceare added as initial conversation messages.
Command Line Arguments
Help Information
You can view all available command-line arguments and their descriptions:
$ streetrace --help
# or
$ streetrace -h
This displays the complete usage information, including all available options and their descriptions.
Version Information
You can check the installed version of StreetRace:
$ streetrace --version
StreetRace🚗💨 0.1.13
Session Management
StreetRace supports persistence of conversations through sessions. You can specify:
--app-name- Application name for the session (defaults to the current working directory name)--user-id- User ID for the session (defaults to your GitHub username, Git username, or OS username)--session-id- Session ID to use or create (defaults to current timestamp)--list-sessions- List all available sessions for the current app and user
Examples:
# List all sessions for the current app and user
$ streetrace --list-sessions
# Create or continue a specific session
$ streetrace --session-id my-project-refactoring
# Work with a specific app name and user
$ streetrace --app-name my-project --user-id john.doe --session-id feature-x
If no session arguments are provided, StreetRace will:
- Use the current working directory name as the app name
- Use your detected user identity as the user ID
- Create a new session with a timestamp-based ID
This allows you to maintain separate conversation contexts for different projects or tasks.
If you want to work with the same agent/context across multiple runs, use the same session ID.
Working with Files in Another Directory
The --path argument allows you to specify a different working directory for all file
operations:
$ streetrace --path /path/to/your/project
This path will be used as the working directory (work_dir) for all tools that interact with the file system, including:
list_directoryread_filewrite_filefind_in_files- as a cwd in cli commands.
This feature makes it easier to work with files in another location without changing your current directory.
Interactive Mode
When run without --prompt, StreetRace enters interactive mode.
Autocompletion
- Type
@followed by characters to autocomplete file or directory paths relative to the working directory. - Type
/at the beginning of the line to autocomplete available internal commands.
Internal Commands
These commands can be typed directly into the prompt (with autocompletion support):
/help: Display a list of all available commands with their descriptions./exit: Exit the interactive session./quit: Quit the interactive session./history: Display the conversation history./compact: Summarize conversation history to reduce token count./reset: Reset the current session, clearing the conversation history.
For detailed information about the /compact command, see
docs/commands/compact.md.
Non-interactive Mode
You can use the --prompt argument to run StreetRace in non-interactive mode:
$ streetrace --prompt "List all Python files in the current directory"
This will execute the prompt once and exit, which is useful for scripting or one-off commands.
CLI Command Safety
StreetRace includes an experimental safety mechanism for CLI command execution. Each command requested by the AI is analyzed and categorized into one of three safety levels:
- Safe: Commands from a pre-configured safe list with only relative paths
- Ambiguous: Commands not in the safe list but without obvious risks
- Risky: Commands with absolute paths, directory traversal attempts, or potentially dangerous operations
Risky commands are blocked by default to prevent unintended filesystem operations or system changes. This adds a layer of protection when working with AI-suggested commands.
The safety checker uses bashlex to parse and analyze commands and arguments, checking
for:
- Command presence in a predefined safe list
- Use of absolute vs. relative paths
- Directory traversal attempts (using
..to move outside the working directory)
This helps ensure that StreetRace operates within the intended working directory and with known-safe commands.
Agent System
StreetRace includes a modular agent system that allows for specialized agents to be discovered and used.
Agent Discovery
The list_agents tool allows the assistant to discover available agents in the system.
Agents are searched for in the following locations:
./agents/(relative to the current working directory)../../agents/(relative to the src/streetrace/app.py)
Creating Custom Agents
StreetRace supports two ways to create custom agents:
Option 1: Using the StreetRaceAgent Interface (Recommended)
-
Create a directory for your agent in the
./agents/folder (e.g.,./agents/my_agent/) -
Create an
agent.pyfile with a class that inherits fromStreetRaceAgentand implements:get_agent_card()- Returns metadata about the agent (name, description, capabilities)get_required_tools()- Returns a list of tools the agent needscreate_agent()- Creates the actual agent instance with the provided model and tools
-
Add a
README.mdfile with documentation for your agent
Example agent class:
from streetrace.agents.street_race_agent import StreetRaceAgent
from streetrace.agents.street_race_agent_card import StreetRaceAgentCard
class MyAgent(StreetRaceAgent):
def get_agent_card(self) -> StreetRaceAgentCard:
return StreetRaceAgentCard(
name="My Agent",
description="A specialized agent that does something useful",
capabilities=["capability1", "capability2"],
)
async def get_required_tools(self) -> list[str]:
return [
"streetrace:fs_tool::read_file",
"streetrace:fs_tool::write_file",
]
async def create_agent(self, model_factory, tools) -> BaseAgent:
model = model_factory.get_default_model()
return Agent(
name="My Agent",
model=model,
description="My specialized agent",
instruction="You are a specialized agent that does X, Y, and Z...",
tools=tools,
)
Option 2: Legacy Approach (Basic Functions)
-
Create a directory for your agent in the
./agents/folder (e.g.,./agents/my_agent/) -
Create an
agent.pyfile with these required functions:get_agent_metadata()- Returns a dictionary withnameanddescriptionkeysrun_agent(input_text: str)- Implements the agent's functionality
-
Add a
README.mdfile with documentation for your agent
Running Agents
The run_agent tool allows the primary assistant to execute specialized agents:
run_agent(
agent_name="Hello World",
input_text="What files are in this directory?",
model_name="default" # Optional, defaults to the default model
)
This enables a hierarchical agent system where the primary StreetRace assistant can delegate tasks to specialized agents.
Tool Configuration
Tools available to agents are defined in the ./tools/tools.yaml configuration file.
This file specifies:
- Tool name and description
- Source type (e.g., 'local' for Python modules or 'mcp' for external services)
- Module and function name for local tools
- Whether the tool requires agent capabilities
The configuration makes it easy to add, modify, or disable tools without changing code.
Tool Discovery
The list_tools tool provides information about available tools that can be provided to
agents. This helps the assistant understand what capabilities are available in the
system.
The tool returns a list of available tools with:
- Tool name
- Description
- Whether the tool requires agent capabilities
GitHub Workflow: Startup Profiling on PR
On every pull request, the project runs scripts/profile_startup.py on both the PR branch and the main branch and compares their startup performance. The results are posted as a comment on the PR for fast visibility and regression detection.
How it works:
- On each PR, the CI workflow:
- Checks out the PR branch, installs dependencies, and runs
profile_startup.py --json --save=profile_pr.json. - Checks out the main branch at HEAD, installs dependencies, and runs the profiler to
profile_main.json. - Uses
scripts/compare_profiles.pyto generate a Markdown summary showing deltas for startup performance key metrics. - Posts the difference as a persistent, auto-updating PR comment.
- Checks out the PR branch, installs dependencies, and runs
This ensures that startup regressions are caught early and remediation advice is visible to contributors and reviewers.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file streetrace-0.1.21.tar.gz.
File metadata
- Download URL: streetrace-0.1.21.tar.gz
- Upload date:
- Size: 109.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.2.0 CPython/3.12.11 Linux/6.11.0-1018-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
666d28728a787c881e6f096baee1afe1576cdeda5716b96b92395ea8181fc345
|
|
| MD5 |
854d205ba428a6cb9d7761064ebeb8b1
|
|
| BLAKE2b-256 |
930f2f1b248f49e0d3e2c797a0c1352acbc29f3b10626ce78ac3ee9a2113c3f8
|
File details
Details for the file streetrace-0.1.21-py3-none-any.whl.
File metadata
- Download URL: streetrace-0.1.21-py3-none-any.whl
- Upload date:
- Size: 149.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.2.0 CPython/3.12.11 Linux/6.11.0-1018-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
806565aaef32899e09a899058967ded3a33cde631838270092c65bed724c5147
|
|
| MD5 |
0d64cf474acb8e7fc3815e54c4d4ff4b
|
|
| BLAKE2b-256 |
c47a445a39fdbb8209beff508d2c48b23bb72876163f9e3d2417ec39e7cee34d
|