![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
A distributed orchestrator for Google Jules AI coding agent. Manages multiple Jules accounts, coordinates async agent workflows, persists context memory in Supabase, and auto-merges pull requests.
Clone the repo, run the installer, and launch.
Windows (PowerShell or CMD):
git clone https://github.com/iceyxsm/JAT-AI.git
cd JAT-AI
scripts\install.batThen open a new terminal (so the updated PATH is loaded) and run:
jatmacOS / Linux:
git clone https://github.com/iceyxsm/JAT-AI.git
cd JAT-AI
bash scripts/install.shThen run:
jatThat's it. jat starts the backend (FastAPI on http://localhost:8000) and the frontend (Vite on http://localhost:3000), then opens the dashboard in your browser. Press Ctrl+C in the terminal to stop both.
The dashboard uses pnpm. Make sure pnpm is installed before running the installer or launch scripts.
- Installs the Python package in editable mode (
pip install -e .), which registers thejatandjat-clicommands. - Installs the dashboard's pnpm dependencies (
cd dashboard && pnpm install). - Sets up the
jatcommand on your PATH (~/jat.cmdon Windows,/usr/local/bin/jaton macOS/Linux).
Create a .env file at the repo root (copy from .env.example) with at minimum:
GITHUB_TOKEN=your_github_pat
Jules API keys are managed through the dashboard's APIs page (stored encrypted in the database), not in .env.
JAT-AI treats Jules sessions as nodes in a workflow tree. A parent task can spawn child tasks that run in parallel across different Jules accounts. Children share context through a central Supabase store. When a child finishes and creates a PR, the orchestrator can automatically merge it after CI passes. Other agents waiting on that result get notified and continue their work.
Single session with live tracking:
python src/cli.py run --prompt "Add unit tests" --owner iceyxsm --repo MyRepo --branch mainSingle session with auto-merge:
python src/cli.py run --prompt "Fix the login bug" --owner iceyxsm --repo MyRepo --auto-merge --merge-strategy squashMulti-session workflow from a JSON file:
python src/cli.py workflow examples/workflow_parallel.jsonList connected repos:
python src/cli.py list-sourcesList recent sessions:
python src/cli.py list-sessions --limit 5Get session details:
python src/cli.py status <session_id>Get session activities:
python src/cli.py activities <session_id>Define multi-task workflows as JSON. Tasks without dependencies run in parallel. Tasks with depends_on wait for their dependencies and get context injected.
{
"name": "parallel-review",
"tasks": [
{
"name": "review-frontend",
"prompt": "Review the frontend code for quality issues.",
"owner": "iceyxsm",
"repo": "MyApp",
"branch": "main"
},
{
"name": "review-backend",
"prompt": "Review the backend code for security issues.",
"owner": "iceyxsm",
"repo": "MyAPI",
"branch": "main"
},
{
"name": "summary",
"prompt": "Create a consolidated report from the reviews.",
"owner": "iceyxsm",
"repo": "MyApp",
"branch": "main",
"depends_on": ["review-frontend", "review-backend"]
}
]
}Exposes JAT to external AI agents via Model Context Protocol. Run it with:
python src/mcp/server.pyAvailable tools:
| Tool | Description |
|---|---|
| jat_list_sources | List repos connected to Jules |
| jat_list_sessions | List recent Jules sessions |
| jat_get_session | Get session details by ID |
| jat_run_session | Create a session, track to completion, return result |
| jat_get_activities | Get activities for a session |
| jat_send_message | Send a follow-up message to an active session |
| jat_create_repo | Create a new GitHub repo (Jules gets access automatically) |
| jat_merge_pr | Merge a PR after CI passes |
src/
__init__.py
cli.py CLI entry point
config.py Settings, logging, secret masking
exceptions.py Domain exceptions with is_retryable
models/
jules.py Jules API types with camelCase alias mapping
github.py GitHub PR and check models
workflow.py Workflow and agent task models
clients/
jules.py Async Jules API client with smart retries
github.py Async GitHub client with rate limit warnings
supabase.py Supabase client wrapper
core/
account_pool.py Multi-account management with daily task tracking
coordinator.py Agent coordination with dependency resolution
workflow_engine.py DAG execution with parallel tasks
session_runner.py End-to-end session lifecycle with auto-merge
context_store.py Context memory via Supabase
auto_merge.py PR monitoring and merge after CI
tracker.py Real-time agent status tracking
mcp/
server.py MCP server with 8 tools
supabase/
001_initial_schema.sql Accounts, sources, workflows, tasks
002_context_and_merge.sql Context messages, merge queue, activities
examples/
workflow_parallel.json Example parallel workflow
-
Clone and install:
git clone https://github.com/iceyxsm/JAT-AI.git cd JAT-AI pip install -e ".[dev]" cd dashboard pnpm install cd ..
-
Configure
.env:GITHUB_TOKEN=your_token SUPABASE_URL=your_url SUPABASE_KEY=your_key DEFAULT_REPO_OWNER=your_github_username DEFAULT_REPO_NAME=your_default_repo -
Run the Supabase migrations in your dashboard SQL editor:
supabase/001_initial_schema.sqlsupabase/002_context_and_merge.sql
-
Connect repos to Jules at jules.google.com
-
Run:
python src/cli.py list-sources
| Variable | Required | Description |
|---|---|---|
| JULES_API_KEY | Yes | Jules API key from jules.google.com/settings |
| GITHUB_TOKEN | Yes | GitHub PAT with repo scope |
| SUPABASE_URL | Yes | Supabase project URL |
| SUPABASE_KEY | Yes | Supabase publishable key |
| DEFAULT_REPO_OWNER | No | Default repo owner for CLI commands |
| DEFAULT_REPO_NAME | No | Default repo name for CLI commands |
| LOG_LEVEL | No | DEBUG, INFO, WARNING, ERROR (default: INFO) |
Jules has per-account rate limits based on plan tier:
| Plan | Daily Tasks | Concurrent Sessions |
|---|---|---|
| Free | 15 | 3 |
| Pro | 100 | 15 |
| Ultra | 300 | 60 |
The account pool tracks daily usage with a 24-hour rolling window and routes tasks to the least-loaded account with available capacity.
- API keys are never logged. A regex-based masking processor strips Jules keys, GitHub PATs, and Supabase keys from all structlog output.
.envis gitignored and was never committed.- HTTP clients only retry on 5xx and 429 errors. 4xx errors (auth failures, not found) fail immediately.
- GitHub rate limit headers are monitored and warnings are logged when remaining requests drop below 10.
MIT






