@steipete/oracle 0.8.6 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (181) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +130 -45
  3. package/dist/bin/oracle-cli.js +613 -379
  4. package/dist/bin/oracle-mcp.js +2 -2
  5. package/dist/bin/oracle.js +165 -279
  6. package/dist/scripts/agent-send.js +31 -31
  7. package/dist/scripts/check.js +6 -6
  8. package/dist/scripts/debug/extract-chatgpt-response.js +10 -10
  9. package/dist/scripts/docs-list.js +30 -30
  10. package/dist/scripts/git-policy.js +25 -23
  11. package/dist/scripts/run-cli.js +8 -8
  12. package/dist/scripts/runner.js +203 -195
  13. package/dist/scripts/test-browser.js +21 -18
  14. package/dist/scripts/test-remote-chrome.js +20 -20
  15. package/dist/src/bridge/connection.js +18 -18
  16. package/dist/src/bridge/userConfigFile.js +7 -7
  17. package/dist/src/browser/actions/assistantResponse.js +149 -101
  18. package/dist/src/browser/actions/attachmentDataTransfer.js +49 -47
  19. package/dist/src/browser/actions/attachments.js +246 -150
  20. package/dist/src/browser/actions/domEvents.js +2 -2
  21. package/dist/src/browser/actions/modelSelection.js +314 -104
  22. package/dist/src/browser/actions/navigation.js +161 -136
  23. package/dist/src/browser/actions/promptComposer.js +100 -64
  24. package/dist/src/browser/actions/remoteFileTransfer.js +10 -10
  25. package/dist/src/browser/actions/thinkingTime.js +207 -110
  26. package/dist/src/browser/chromeLifecycle.js +62 -60
  27. package/dist/src/browser/config.js +34 -15
  28. package/dist/src/browser/constants.js +17 -12
  29. package/dist/src/browser/cookies.js +19 -19
  30. package/dist/src/browser/detect.js +62 -62
  31. package/dist/src/browser/domDebug.js +1 -1
  32. package/dist/src/browser/index.js +452 -303
  33. package/dist/src/browser/modelStrategy.js +1 -1
  34. package/dist/src/browser/pageActions.js +5 -5
  35. package/dist/src/browser/policies.js +16 -13
  36. package/dist/src/browser/profileState.js +44 -39
  37. package/dist/src/browser/prompt.js +72 -42
  38. package/dist/src/browser/promptSummary.js +5 -5
  39. package/dist/src/browser/providerDomFlow.js +17 -0
  40. package/dist/src/browser/providers/chatgptDomProvider.js +49 -0
  41. package/dist/src/browser/providers/geminiDeepThinkDomProvider.js +254 -0
  42. package/dist/src/browser/providers/index.js +2 -0
  43. package/dist/src/browser/reattach.js +67 -34
  44. package/dist/src/browser/reattachHelpers.js +31 -26
  45. package/dist/src/browser/sessionRunner.js +37 -25
  46. package/dist/src/browser/utils.js +9 -9
  47. package/dist/src/browserMode.js +1 -1
  48. package/dist/src/cli/bridge/claudeConfig.js +16 -16
  49. package/dist/src/cli/bridge/client.js +28 -20
  50. package/dist/src/cli/bridge/codexConfig.js +16 -16
  51. package/dist/src/cli/bridge/doctor.js +47 -39
  52. package/dist/src/cli/bridge/host.js +58 -56
  53. package/dist/src/cli/browserConfig.js +65 -45
  54. package/dist/src/cli/browserDefaults.js +27 -26
  55. package/dist/src/cli/bundleWarnings.js +1 -1
  56. package/dist/src/cli/clipboard.js +11 -2
  57. package/dist/src/cli/detach.js +7 -4
  58. package/dist/src/cli/dryRun.js +29 -25
  59. package/dist/src/cli/duplicatePromptGuard.js +3 -3
  60. package/dist/src/cli/engine.js +9 -9
  61. package/dist/src/cli/errorUtils.js +1 -1
  62. package/dist/src/cli/fileSize.js +11 -0
  63. package/dist/src/cli/format.js +2 -2
  64. package/dist/src/cli/help.js +28 -28
  65. package/dist/src/cli/hiddenAliases.js +3 -3
  66. package/dist/src/cli/markdownBundle.js +12 -8
  67. package/dist/src/cli/markdownRenderer.js +15 -15
  68. package/dist/src/cli/notifier.js +77 -67
  69. package/dist/src/cli/options.js +145 -87
  70. package/dist/src/cli/oscUtils.js +1 -1
  71. package/dist/src/cli/promptRequirement.js +2 -2
  72. package/dist/src/cli/renderOutput.js +1 -1
  73. package/dist/src/cli/rootAlias.js +1 -1
  74. package/dist/src/cli/runOptions.js +37 -25
  75. package/dist/src/cli/sessionCommand.js +31 -21
  76. package/dist/src/cli/sessionDisplay.js +182 -79
  77. package/dist/src/cli/sessionLineage.js +60 -0
  78. package/dist/src/cli/sessionRunner.js +118 -90
  79. package/dist/src/cli/sessionTable.js +28 -24
  80. package/dist/src/cli/stdin.js +22 -0
  81. package/dist/src/cli/tagline.js +121 -124
  82. package/dist/src/cli/tui/index.js +140 -127
  83. package/dist/src/cli/writeOutputPath.js +5 -5
  84. package/dist/src/config.js +7 -7
  85. package/dist/src/gemini-web/browserSessionManager.js +80 -0
  86. package/dist/src/gemini-web/client.js +81 -64
  87. package/dist/src/gemini-web/executionMode.js +16 -0
  88. package/dist/src/gemini-web/executor.js +327 -169
  89. package/dist/src/gemini-web/index.js +1 -1
  90. package/dist/src/mcp/server.js +16 -12
  91. package/dist/src/mcp/tools/consult.js +81 -64
  92. package/dist/src/mcp/tools/sessionResources.js +12 -12
  93. package/dist/src/mcp/tools/sessions.js +26 -17
  94. package/dist/src/mcp/types.js +5 -5
  95. package/dist/src/mcp/utils.js +15 -7
  96. package/dist/src/oracle/background.js +15 -15
  97. package/dist/src/oracle/claude.js +53 -25
  98. package/dist/src/oracle/client.js +84 -46
  99. package/dist/src/oracle/config.js +124 -58
  100. package/dist/src/oracle/errors.js +38 -38
  101. package/dist/src/oracle/files.js +69 -45
  102. package/dist/src/oracle/finishLine.js +10 -8
  103. package/dist/src/oracle/format.js +3 -3
  104. package/dist/src/oracle/gemini.js +37 -30
  105. package/dist/src/oracle/logging.js +7 -7
  106. package/dist/src/oracle/markdown.js +28 -28
  107. package/dist/src/oracle/modelResolver.js +16 -16
  108. package/dist/src/oracle/multiModelRunner.js +12 -12
  109. package/dist/src/oracle/oscProgress.js +8 -8
  110. package/dist/src/oracle/promptAssembly.js +6 -3
  111. package/dist/src/oracle/request.js +23 -15
  112. package/dist/src/oracle/run.js +172 -140
  113. package/dist/src/oracle/runUtils.js +8 -5
  114. package/dist/src/oracle/tokenEstimate.js +6 -6
  115. package/dist/src/oracle/tokenStats.js +5 -5
  116. package/dist/src/oracle/tokenStringifier.js +5 -5
  117. package/dist/src/oracle.js +12 -12
  118. package/dist/src/oracleHome.js +3 -3
  119. package/dist/src/remote/client.js +25 -25
  120. package/dist/src/remote/health.js +20 -20
  121. package/dist/src/remote/remoteServiceConfig.js +9 -9
  122. package/dist/src/remote/server.js +129 -118
  123. package/dist/src/sessionManager.js +81 -75
  124. package/dist/src/sessionStore.js +3 -3
  125. package/dist/src/version.js +10 -10
  126. package/dist/vendor/oracle-notifier/OracleNotifier.app/Contents/CodeResources +0 -0
  127. package/dist/vendor/oracle-notifier/OracleNotifier.app/Contents/MacOS/OracleNotifier +0 -0
  128. package/dist/vendor/oracle-notifier/README.md +2 -0
  129. package/package.json +69 -65
  130. package/vendor/oracle-notifier/OracleNotifier.app/Contents/CodeResources +0 -0
  131. package/vendor/oracle-notifier/OracleNotifier.app/Contents/MacOS/OracleNotifier +0 -0
  132. package/vendor/oracle-notifier/README.md +2 -0
  133. package/dist/markdansi/types/index.js +0 -4
  134. package/dist/oracle/bin/oracle-cli.js +0 -472
  135. package/dist/oracle/src/browser/actions/assistantResponse.js +0 -471
  136. package/dist/oracle/src/browser/actions/attachments.js +0 -82
  137. package/dist/oracle/src/browser/actions/modelSelection.js +0 -190
  138. package/dist/oracle/src/browser/actions/navigation.js +0 -75
  139. package/dist/oracle/src/browser/actions/promptComposer.js +0 -167
  140. package/dist/oracle/src/browser/chromeLifecycle.js +0 -104
  141. package/dist/oracle/src/browser/config.js +0 -33
  142. package/dist/oracle/src/browser/constants.js +0 -40
  143. package/dist/oracle/src/browser/cookies.js +0 -210
  144. package/dist/oracle/src/browser/domDebug.js +0 -36
  145. package/dist/oracle/src/browser/index.js +0 -331
  146. package/dist/oracle/src/browser/pageActions.js +0 -5
  147. package/dist/oracle/src/browser/prompt.js +0 -88
  148. package/dist/oracle/src/browser/promptSummary.js +0 -20
  149. package/dist/oracle/src/browser/sessionRunner.js +0 -80
  150. package/dist/oracle/src/browser/utils.js +0 -62
  151. package/dist/oracle/src/browserMode.js +0 -1
  152. package/dist/oracle/src/cli/browserConfig.js +0 -44
  153. package/dist/oracle/src/cli/dryRun.js +0 -59
  154. package/dist/oracle/src/cli/engine.js +0 -17
  155. package/dist/oracle/src/cli/errorUtils.js +0 -9
  156. package/dist/oracle/src/cli/help.js +0 -70
  157. package/dist/oracle/src/cli/markdownRenderer.js +0 -15
  158. package/dist/oracle/src/cli/options.js +0 -103
  159. package/dist/oracle/src/cli/promptRequirement.js +0 -14
  160. package/dist/oracle/src/cli/rootAlias.js +0 -30
  161. package/dist/oracle/src/cli/sessionCommand.js +0 -77
  162. package/dist/oracle/src/cli/sessionDisplay.js +0 -270
  163. package/dist/oracle/src/cli/sessionRunner.js +0 -94
  164. package/dist/oracle/src/heartbeat.js +0 -43
  165. package/dist/oracle/src/oracle/client.js +0 -48
  166. package/dist/oracle/src/oracle/config.js +0 -29
  167. package/dist/oracle/src/oracle/errors.js +0 -101
  168. package/dist/oracle/src/oracle/files.js +0 -220
  169. package/dist/oracle/src/oracle/format.js +0 -33
  170. package/dist/oracle/src/oracle/fsAdapter.js +0 -7
  171. package/dist/oracle/src/oracle/oscProgress.js +0 -60
  172. package/dist/oracle/src/oracle/request.js +0 -48
  173. package/dist/oracle/src/oracle/run.js +0 -444
  174. package/dist/oracle/src/oracle/tokenStats.js +0 -39
  175. package/dist/oracle/src/oracle/types.js +0 -1
  176. package/dist/oracle/src/oracle.js +0 -9
  177. package/dist/oracle/src/sessionManager.js +0 -205
  178. package/dist/oracle/src/version.js +0 -39
  179. package/dist/scripts/chrome/browser-tools.js +0 -295
  180. package/dist/src/browser/profileSync.js +0 -141
  181. /package/dist/{oracle/src/browser/types.js → src/gemini-web/executionClients.js} +0 -0
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- \g<1>2026 Peter Steinberger
3
+ Copyright (c) 2026 Peter Steinberger
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -11,7 +11,40 @@
11
11
  <a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-green?style=for-the-badge" alt="MIT License"></a>
12
12
  </p>
13
13
 
14
- Oracle bundles your prompt and files so another AI can answer with real context. It speaks GPT-5.1 Pro (default alias to GPT-5.2 Pro on the API), GPT-5.1 Codex (API-only), GPT-5.1, GPT-5.2, Gemini 3 Pro, Claude Sonnet 4.5, Claude Opus 4.1, and more—and it can ask one or multiple models in a single run. Browser automation is available; use `--browser-model-strategy current` to keep the active ChatGPT model (or `ignore` to skip the picker). API remains the most reliable path, and `--copy` is an easy manual fallback.
14
+ Oracle bundles your prompt and files so another AI can answer with real context. It speaks GPT-5.5 Pro (default), GPT-5.5, GPT-5.4 Pro, GPT-5.4, GPT-5.1 Pro, GPT-5.1 Codex (API-only), GPT-5.1, GPT-5.2, Gemini 3.1 Pro (API-only), Gemini 3 Pro, Claude Sonnet 4.6, Claude Opus 4.1, and more—and it can ask one or multiple models in a single run. Browser automation is available; use `--browser-model-strategy current` to keep the active ChatGPT model (or `ignore` to skip the picker). API remains the most reliable path, and `--copy` is an easy manual fallback.
15
+
16
+ ## Setting up (macOS Browser Mode)
17
+
18
+ Browser mode lets you use GPT-5.5 Pro without any API keys — it automates your Chrome browser directly.
19
+
20
+ ### First-time login
21
+
22
+ Run this once to create an automation profile and log into ChatGPT. The browser will stay open so you can complete the login:
23
+
24
+ ```bash
25
+ oracle --engine browser --browser-manual-login \
26
+ --browser-keep-browser --browser-input-timeout 120000 \
27
+ -p "HI"
28
+ ```
29
+
30
+ ### Subsequent runs
31
+
32
+ Once logged in, the automation profile is saved. Use this for all future runs:
33
+
34
+ ```bash
35
+ oracle --engine browser --browser-manual-login \
36
+ --browser-auto-reattach-delay 5s \
37
+ --browser-auto-reattach-interval 3s \
38
+ --browser-auto-reattach-timeout 60s \
39
+ -p "your prompt"
40
+ ```
41
+
42
+ > **Why these flags?**
43
+ >
44
+ > - `--browser-manual-login` — Skips macOS Keychain cookie access (avoids repeated permission popups)
45
+ > - `--browser-auto-reattach-*` — Reconnects when ChatGPT redirects mid-page-load (fixes "Inspected target navigated or closed" error)
46
+ > - `--browser-keep-browser` — Keeps browser open for first-time login (not needed after)
47
+ > - `--browser-input-timeout 120000` — Gives you 2 minutes to log in on first run
15
48
 
16
49
  ## Quick start
17
50
 
@@ -30,6 +63,12 @@ npx -y @steipete/oracle -p "Write a concise architecture note for the storage ad
30
63
  # Multi-model API run
31
64
  npx -y @steipete/oracle -p "Cross-check the data layer assumptions" --models gpt-5.1-pro,gemini-3-pro --file "src/**/*.ts"
32
65
 
66
+ # Follow up from an existing OpenAI/Azure session id
67
+ npx -y @steipete/oracle --engine api --model gpt-5.2-pro --followup release-readiness-audit --followup-model gpt-5.2-pro -p "Re-evaluate with this new context" --file "src/**/*.ts"
68
+
69
+ # Follow up directly from an OpenAI Responses API id
70
+ npx -y @steipete/oracle --engine api --model gpt-5.2-pro --followup resp_abc1234567890 -p "Continue from this response" --file docs/notes.md
71
+
33
72
  # Preview without spending tokens
34
73
  npx -y @steipete/oracle --dry-run summary -p "Check release notes" --file docs/release-notes.md
35
74
 
@@ -53,7 +92,8 @@ Engine auto-picks API when `OPENAI_API_KEY` is set, otherwise browser; browser i
53
92
  ## Integration
54
93
 
55
94
  **CLI**
56
- - API mode expects API keys in your environment: `OPENAI_API_KEY` (GPT-5.x), `GEMINI_API_KEY` (Gemini 3 Pro), `ANTHROPIC_API_KEY` (Claude Sonnet 4.5 / Opus 4.1).
95
+
96
+ - API mode expects API keys in your environment: `OPENAI_API_KEY` (GPT-5.x), `GEMINI_API_KEY` (Gemini 3.1 Pro / Gemini 3 Pro), `ANTHROPIC_API_KEY` (Claude Sonnet 4.6 / Opus 4.1).
57
97
  - Gemini browser mode uses Chrome cookies instead of an API key—just be logged into `gemini.google.com` in Chrome (no Python/venv required).
58
98
  - If your Gemini account can’t access “Pro”, Oracle auto-falls back to a supported model for web runs (and logs the fallback in verbose mode).
59
99
  - Prefer API mode or `--copy` + manual paste; browser automation is experimental.
@@ -67,19 +107,23 @@ Engine auto-picks API when `OPENAI_API_KEY` is set, otherwise browser; browser i
67
107
  - Tip: set `browser.chatgptUrl` in config (or `--chatgpt-url`) to a dedicated ChatGPT project folder so browser runs don’t clutter your main history.
68
108
 
69
109
  **Codex skill**
110
+
70
111
  - Copy the bundled skill from this repo to your Codex skills folder:
71
112
  - `mkdir -p ~/.codex/skills`
72
113
  - `cp -R skills/oracle ~/.codex/skills/oracle`
73
114
  - Then reference it in your `AGENTS.md`/`CLAUDE.md` so Codex loads it.
74
115
 
75
116
  **MCP**
117
+
76
118
  - Run the stdio server via `oracle-mcp`.
77
119
  - Configure clients via [steipete/mcporter](https://github.com/steipete/mcporter) or `.mcp.json`; see [docs/mcp.md](docs/mcp.md) for connection examples.
120
+
78
121
  ```bash
79
122
  npx -y @steipete/oracle oracle-mcp
80
123
  ```
124
+
81
125
  - Cursor setup (MCP): drop a `.cursor/mcp.json` like below, then pick “oracle” in Cursor’s MCP sources. See https://cursor.com/docs/context/mcp for UI steps.
82
- [![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en-US/install-mcp?name=oracle&config=eyJjb21tYW5kIjoibnB4IC15IEBzdGVpcGV0ZS9vcmFjbGUgb3JhY2xlLW1jcCJ9)
126
+ [![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en-US/install-mcp?name=oracle&config=eyJjb21tYW5kIjoibnB4IC15IEBzdGVpcGV0ZS9vcmFjbGUgb3JhY2xlLW1jcCJ9)
83
127
 
84
128
  ```json
85
129
  {
@@ -96,16 +140,49 @@ npx -y @steipete/oracle oracle-mcp
96
140
  - Multi-model API runs with aggregated cost/usage, including OpenRouter IDs alongside first-party models.
97
141
  - Render/copy bundles for manual paste into ChatGPT when automation is blocked.
98
142
  - GPT‑5 Pro API runs detach by default; reattach via `oracle session <id>` / `oracle status` or block with `--wait`.
143
+ - OpenAI/Azure follow-up API runs can continue from `--followup <sessionId|responseId>`; for multi-model parents, add `--followup-model <model>`.
99
144
  - Azure endpoints supported via `--azure-endpoint/--azure-deployment/--azure-api-version` or `AZURE_OPENAI_*` envs.
100
145
  - File safety: globs/excludes, size guards, `--files-report`.
101
146
  - Sessions you can replay (`oracle status`, `oracle session <id> --render`).
102
147
  - Session logs and bundles live in `~/.oracle/sessions` (override with `ORACLE_HOME_DIR`).
103
148
 
149
+ ## Follow-up and lineage
150
+
151
+ Use `--followup` to continue an existing OpenAI/Azure Responses API run with additional context/files:
152
+
153
+ ```bash
154
+ oracle \
155
+ --engine api \
156
+ --model gpt-5.2-pro \
157
+ --followup <existing-session-id-or-resp_id> \
158
+ --followup-model gpt-5.2-pro \
159
+ --slug "my-followup-run" \
160
+ --wait \
161
+ -p "Follow-up: re-evaluate the previous recommendation with the attached files." \
162
+ --file "server/src/strategy/plan.ts" \
163
+ --file "server/src/strategy/executor.ts"
164
+ ```
165
+
166
+ When the parent session used `--models`, `--followup-model` picks which model's response id to chain from.
167
+ Custom `--base-url` providers plus Gemini/Claude API runs are excluded here because they do not preserve `previous_response_id` in Oracle.
168
+
169
+ `oracle status` shows parent/child lineage in tree form:
170
+
171
+ ```text
172
+ Recent Sessions
173
+ Status Model Mode Timestamp Chars Cost Slug
174
+ completed gpt-5.2-pro api 03/01/2026 09:00 AM 1800 $2.110 architecture-review-parent
175
+ completed gpt-5.2-pro api 03/01/2026 09:14 AM 2200 $2.980 ├─ architecture-review-followup
176
+ running gpt-5.2-pro api 03/01/2026 09:22 AM 1400 - │ └─ architecture-review-implementation-pass
177
+ pending gpt-5.2-pro api 03/01/2026 09:25 AM 900 - └─ architecture-review-risk-check
178
+ ```
179
+
104
180
  ## Browser auto-reattach (long Pro runs)
105
181
 
106
182
  When browser runs time out (common with long GPT‑5.x Pro responses), Oracle can keep polling the existing ChatGPT tab and capture the final answer without manual `oracle session <id>` commands.
107
183
 
108
184
  Enable auto-reattach by setting a non-zero interval:
185
+
109
186
  - `--browser-auto-reattach-delay` — wait before the first retry (e.g. `30s`)
110
187
  - `--browser-auto-reattach-interval` — how often to retry (e.g. `2m`)
111
188
  - `--browser-auto-reattach-timeout` — per-attempt budget (default `2m`)
@@ -121,66 +198,71 @@ oracle --engine browser \
121
198
 
122
199
  ## Flags you’ll actually use
123
200
 
124
- | Flag | Purpose |
125
- | --- | --- |
126
- | `-p, --prompt <text>` | Required prompt. |
127
- | `-f, --file <paths...>` | Attach files/dirs (globs + `!` excludes). |
128
- | `-e, --engine <api\|browser>` | Choose API or browser (browser is experimental). |
129
- | `-m, --model <name>` | Built-ins (`gpt-5.1-pro` default, `gpt-5-pro`, `gpt-5.1`, `gpt-5.1-codex`, `gpt-5.2`, `gpt-5.2-instant`, `gpt-5.2-pro`, `gemini-3-pro`, `claude-4.5-sonnet`, `claude-4.1-opus`) plus any OpenRouter id (e.g., `minimax/minimax-m2`, `openai/gpt-4o-mini`). |
130
- | `--models <list>` | Comma-separated API models (mix built-ins and OpenRouter ids) for multi-model runs. |
131
- | `--base-url <url>` | Point API runs at LiteLLM/Azure/OpenRouter/etc. |
132
- | `--chatgpt-url <url>` | Target a ChatGPT workspace/folder (browser). |
133
- | `--browser-model-strategy <select\|current\|ignore>` | Control ChatGPT model selection in browser mode (current keeps the active model; ignore skips the picker). |
134
- | `--browser-manual-login` | Skip cookie copy; reuse a persistent automation profile and wait for manual ChatGPT login. |
135
- | `--browser-thinking-time <light\|standard\|extended\|heavy>` | Set ChatGPT thinking-time intensity (browser; Thinking/Pro models only). |
136
- | `--browser-port <port>` | Pin the Chrome DevTools port (WSL/Windows firewall helper). |
137
- | `--browser-inline-cookies[(-file)] <payload|path>` | Supply cookies without Chrome/Keychain (browser). |
138
- | `--browser-timeout`, `--browser-input-timeout` | Control overall/browser input timeouts (supports h/m/s/ms). |
139
- | `--browser-recheck-delay`, `--browser-recheck-timeout` | Delayed recheck for long Pro runs: wait then retry capture after timeout (supports h/m/s/ms). |
140
- | `--browser-reuse-wait` | Wait for a shared Chrome profile before launching (parallel browser runs). |
141
- | `--browser-profile-lock-timeout` | Wait for the shared manual-login profile lock before sending (serializes parallel runs). |
142
- | `--render`, `--copy` | Print and/or copy the assembled markdown bundle. |
143
- | `--wait` | Block for background API runs (e.g., GPT‑5.1 Pro) instead of detaching. |
144
- | `--timeout <seconds\|auto>` | Overall API deadline (auto = 60m for pro, 120s otherwise). |
145
- | `--background`, `--no-background` | Force Responses API background mode (create + retrieve) for API runs. |
146
- | `--http-timeout <ms\|s\|m\|h>` | HTTP client timeout (default 20m). |
147
- | `--zombie-timeout <ms\|s\|m\|h>` | Override stale-session cutoff used by `oracle status`. |
148
- | `--zombie-last-activity` | Use last log activity to detect stale sessions. |
149
- | `--write-output <path>` | Save only the final answer (multi-model adds `.<model>`). |
150
- | `--files-report` | Print per-file token usage. |
151
- | `--dry-run [summary\|json\|full]` | Preview without sending. |
152
- | `--remote-host`, `--remote-token` | Use a remote `oracle serve` host (browser). |
153
- | `--remote-chrome <host:port>` | Attach to an existing remote Chrome session (browser). |
154
- | `--youtube <url>` | YouTube video URL to analyze (Gemini browser mode). |
155
- | `--generate-image <file>` | Generate image and save to file (Gemini browser mode). |
156
- | `--edit-image <file>` | Edit existing image with `--output` (Gemini browser mode). |
157
- | `--azure-endpoint`, `--azure-deployment`, `--azure-api-version` | Target Azure OpenAI endpoints (picks Azure client automatically). |
201
+ | Flag | Purpose |
202
+ | --------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
203
+ | `-p, --prompt <text>` | Required prompt. |
204
+ | `-f, --file <paths...>` | Attach files/dirs (globs + `!` excludes). |
205
+ | `-e, --engine <api\|browser>` | Choose API or browser (browser is experimental). |
206
+ | `-m, --model <name>` | Built-ins (`gpt-5.5-pro` default, `gpt-5.5`, `gpt-5.4-pro`, `gpt-5.4`, `gpt-5.1-pro`, `gpt-5-pro`, `gpt-5.1`, `gpt-5.1-codex`, `gpt-5.2`, `gpt-5.2-instant`, `gpt-5.2-pro`, `gemini-3.1-pro` API-only, `gemini-3-pro`, `claude-4.6-sonnet`, `claude-4.1-opus`) plus any OpenRouter id (e.g., `minimax/minimax-m2`, `openai/gpt-4o-mini`). |
207
+ | `--models <list>` | Comma-separated API models (mix built-ins and OpenRouter ids) for multi-model runs. |
208
+ | `--followup <sessionId\|responseId>` | Continue an OpenAI/Azure Responses API run from a stored oracle session or `resp_...` response id. |
209
+ | `--followup-model <model>` | For multi-model OpenAI/Azure parent sessions, choose which model response to continue from. |
210
+ | `--base-url <url>` | Point API runs at LiteLLM/Azure/OpenRouter/etc. |
211
+ | `--chatgpt-url <url>` | Target a ChatGPT workspace/folder (browser). |
212
+ | `--browser-model-strategy <select\|current\|ignore>` | Control ChatGPT model selection in browser mode (current keeps the active model; ignore skips the picker). |
213
+ | `--browser-manual-login` | Skip cookie copy; reuse a persistent automation profile and wait for manual ChatGPT login. |
214
+ | `--browser-thinking-time <light\|standard\|extended\|heavy>` | Set ChatGPT thinking-time intensity (browser; Thinking/Pro models only). |
215
+ | `--browser-port <port>` | Pin the Chrome DevTools port (WSL/Windows firewall helper). |
216
+ | `--browser-inline-cookies[(-file)] <payload \| path>` | Supply cookies without Chrome/Keychain (browser). |
217
+ | `--browser-timeout`, `--browser-input-timeout` | Control overall/browser input timeouts (supports h/m/s/ms). |
218
+ | `--browser-recheck-delay`, `--browser-recheck-timeout` | Delayed recheck for long Pro runs: wait then retry capture after timeout (supports h/m/s/ms). |
219
+ | `--browser-reuse-wait` | Wait for a shared Chrome profile before launching (parallel browser runs). |
220
+ | `--browser-profile-lock-timeout` | Wait for the shared manual-login profile lock before sending (serializes parallel runs). |
221
+ | `--render`, `--copy` | Print and/or copy the assembled markdown bundle. |
222
+ | `--wait` | Block for background API runs (e.g., GPT‑5.1 Pro) instead of detaching. |
223
+ | `--timeout <seconds\|auto>` | Overall API deadline (auto = 60m for pro, 120s otherwise). |
224
+ | `--background`, `--no-background` | Force Responses API background mode (create + retrieve) for API runs. |
225
+ | `--http-timeout <ms\|s\|m\|h>` | HTTP client timeout (default 20m). |
226
+ | `--zombie-timeout <ms\|s\|m\|h>` | Override stale-session cutoff used by `oracle status`. |
227
+ | `--zombie-last-activity` | Use last log activity to detect stale sessions. |
228
+ | `--write-output <path>` | Save only the final answer (multi-model adds `.<model>`). |
229
+ | `--files-report` | Print per-file token usage. |
230
+ | `--dry-run [summary\|json\|full]` | Preview without sending. |
231
+ | `--remote-host`, `--remote-token` | Use a remote `oracle serve` host (browser). |
232
+ | `--remote-chrome <host:port>` | Attach to an existing remote Chrome session (browser). |
233
+ | `--youtube <url>` | YouTube video URL to analyze (Gemini browser mode). |
234
+ | `--generate-image <file>` | Generate image and save to file (Gemini browser mode). |
235
+ | `--edit-image <file>` | Edit existing image with `--output` (Gemini browser mode). |
236
+ | `--azure-endpoint`, `--azure-deployment`, `--azure-api-version` | Target Azure OpenAI endpoints (picks Azure client automatically). |
158
237
 
159
238
  ## Configuration
160
239
 
161
240
  Put defaults in `~/.oracle/config.json` (JSON5). Example:
241
+
162
242
  ```json5
163
243
  {
164
- model: "gpt-5.1-pro",
244
+ model: "gpt-5.5-pro",
165
245
  engine: "api",
166
246
  filesReport: true,
167
247
  browser: {
168
- chatgptUrl: "https://chatgpt.com/g/g-p-691edc9fec088191b553a35093da1ea8-oracle/project"
169
- }
248
+ chatgptUrl: "https://chatgpt.com/g/g-p-691edc9fec088191b553a35093da1ea8-oracle/project",
249
+ },
170
250
  }
171
251
  ```
252
+
172
253
  Use `browser.chatgptUrl` (or the legacy alias `browser.url`) to target a specific ChatGPT workspace/folder for browser automation.
173
254
  See [docs/configuration.md](docs/configuration.md) for precedence and full schema.
174
255
 
175
256
  Advanced flags
176
257
 
177
- | Area | Flags |
178
- | --- | --- |
179
- | Browser | `--browser-manual-login`, `--browser-thinking-time`, `--browser-timeout`, `--browser-input-timeout`, `--browser-recheck-delay`, `--browser-recheck-timeout`, `--browser-reuse-wait`, `--browser-profile-lock-timeout`, `--browser-auto-reattach-delay`, `--browser-auto-reattach-interval`, `--browser-auto-reattach-timeout`, `--browser-cookie-wait`, `--browser-inline-cookies[(-file)]`, `--browser-attachments`, `--browser-inline-files`, `--browser-bundle-files`, `--browser-keep-browser`, `--browser-headless`, `--browser-hide-window`, `--browser-no-cookie-sync`, `--browser-allow-cookie-errors`, `--browser-chrome-path`, `--browser-cookie-path`, `--chatgpt-url` |
180
- | Run control | `--background`, `--no-background`, `--http-timeout`, `--zombie-timeout`, `--zombie-last-activity` |
181
- | Azure/OpenAI | `--azure-endpoint`, `--azure-deployment`, `--azure-api-version`, `--base-url` |
258
+ | Area | Flags |
259
+ | ------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
260
+ | Browser | `--browser-manual-login`, `--browser-thinking-time`, `--browser-timeout`, `--browser-input-timeout`, `--browser-recheck-delay`, `--browser-recheck-timeout`, `--browser-reuse-wait`, `--browser-profile-lock-timeout`, `--browser-auto-reattach-delay`, `--browser-auto-reattach-interval`, `--browser-auto-reattach-timeout`, `--browser-cookie-wait`, `--browser-inline-cookies[(-file)]`, `--browser-attachments`, `--browser-inline-files`, `--browser-bundle-files`, `--browser-keep-browser`, `--browser-headless`, `--browser-hide-window`, `--browser-no-cookie-sync`, `--browser-allow-cookie-errors`, `--browser-chrome-path`, `--browser-cookie-path`, `--chatgpt-url` |
261
+ | Run control | `--background`, `--no-background`, `--http-timeout`, `--zombie-timeout`, `--zombie-last-activity` |
262
+ | Azure/OpenAI | `--azure-endpoint`, `--azure-deployment`, `--azure-api-version`, `--base-url` |
182
263
 
183
264
  Remote browser example
265
+
184
266
  ```bash
185
267
  # Host (signed-in Chrome): launch serve
186
268
  oracle serve --host 0.0.0.0:9473 --token secret123
@@ -193,12 +275,14 @@ oracle --engine browser --browser-inline-cookies-file ~/.oracle/cookies.json -p
193
275
  ```
194
276
 
195
277
  Session management
278
+
196
279
  ```bash
197
280
  # Prune stored sessions (default path ~/.oracle/sessions; override ORACLE_HOME_DIR)
198
281
  oracle status --clear --hours 168
199
282
  ```
200
283
 
201
284
  ## More docs
285
+
202
286
  - Bridge (Windows host → Linux client): [docs/bridge.md](docs/bridge.md)
203
287
  - Browser mode & forks: [docs/browser-mode.md](docs/browser-mode.md) (includes `oracle serve` remote service), [docs/chromium-forks.md](docs/chromium-forks.md), [docs/linux.md](docs/linux.md)
204
288
  - MCP: [docs/mcp.md](docs/mcp.md)
@@ -210,6 +294,7 @@ If you’re looking for an even more powerful context-management tool, check out
210
294
  Name inspired by: https://ampcode.com/news/oracle
211
295
 
212
296
  ## More free stuff from steipete
297
+
213
298
  - ✂️ [Trimmy](https://trimmy.app) — “Paste once, run once.” Flatten multi-line shell snippets so they paste and run.
214
299
  - 🟦🟩 [CodexBar](https://codexbar.app) — Keep Codex token windows visible in your macOS menu bar.
215
300
  - 🧳 [MCPorter](https://mcporter.dev) — TypeScript toolkit + CLI for Model Context Protocol servers.