Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 41 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,41 @@ debug with a built-in UI.

## Quickstart

Requirements: Node.js 18+ and `OPENROUTER_API_KEY` (set `OPENROUTER_BASE_URL` if
you proxy OpenRouter-style APIs).
Requirements: Node.js 18+ and either

- `OPENROUTER_API_KEY` (set `OPENROUTER_BASE_URL` if you proxy OpenRouter-style
APIs), or
- a Google AI account with
[Gemini Code Assist access](https://developers.google.com/gemini-code-assist/docs/overview)
(Google AI Pro/Ultra includes this).

Run the CLI directly with npx (no install):

```
# Example using OpenRouter
export OPENROUTER_API_KEY=...
npx @bolt-foundry/gambit init

# Example using Google OAuth
# (Uses the built-in public client automatically; set your own if needed.)
npx @bolt-foundry/gambit auth google
npx @bolt-foundry/gambit init
```

Downloads example files (hello decks plus the `examples/` gallery) and sets
environment variables.

### Local install (dev)

When running the local CLI from this repo, use the install script so the import
map resolves workspace paths:

```
./scripts/install_local.sh
```

This installs a `gambit` binary into `~/.deno/bin`.

Run an example in the terminal (`repl`):

```
Expand Down Expand Up @@ -74,6 +96,23 @@ Run with npx (no install):
npx @bolt-foundry/gambit <command>
```

### Google OAuth login (Gemini Code Assist)

If you want to use your Google AI Pro/Gemini Code Assist subscription instead of
an API key:

```
export GEMINI_PROJECT_ID="your-project-id" # where your Code Assist access lives

npx @bolt-foundry/gambit auth google
```

We ship a public OAuth client baked into the CLI; set your own values above if
you need a different Google Cloud project. The login flow opens a browser,
stores tokens in `~/.config/gambit/auth.json`, and reuses them on future runs.

Then run decks with `model = "google/<model>"`.

Run a deck once:

```
Expand Down
7 changes: 6 additions & 1 deletion deno.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,15 @@
},
"compilerOptions": {
"jsx": "react-jsx",
"jsxImportSource": "react"
"jsxImportSource": "react",
"lib": ["dom", "dom.iterable", "es2022", "deno.ns"]
},
"imports": {
"@deno/dnt": "jsr:@deno/dnt@^0.42.3", // dev
"@std/front-matter": "jsr:@std/front-matter@^1.0.9",
"@std/fs": "jsr:@std/fs@^1.0.20",
"@std/http": "jsr:@std/http@^1.0.8",
"@std/http/server": "jsr:@std/http@^1.0.8/server",
"@std/jsonc": "jsr:@std/jsonc@^1.0.2", // dev
"@std/path": "jsr:@std/path@^1.0.6",
"@std/cli": "jsr:@std/cli@^1.0.7",
Expand All @@ -74,6 +77,8 @@
"zod": "npm:zod@^3.23.8",
"zod-to-json-schema": "npm:zod-to-json-schema@^3.23.0",
"@openai/openai": "npm:openai@^4.78.1",
"@google/generative-ai": "npm:@google/generative-ai@^0.24.1",
"puppeteer-core": "npm:puppeteer-core@^24.35.0",
"react": "npm:react@^19.2.0",
"react-dom": "npm:react-dom@^19.2.0"
},
Expand Down
Loading