oh-my-opencode 2.14.0 → 3.0.0-beta.10

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 (170) hide show
  1. package/README.ja.md +173 -97
  2. package/README.md +247 -109
  3. package/README.zh-cn.md +708 -502
  4. package/bin/oh-my-opencode.js +80 -0
  5. package/bin/platform.js +38 -0
  6. package/bin/platform.test.ts +148 -0
  7. package/dist/agents/metis.d.ts +19 -0
  8. package/dist/agents/momus.d.ts +6 -0
  9. package/dist/agents/momus.test.d.ts +1 -0
  10. package/dist/agents/orchestrator-sisyphus.d.ts +20 -0
  11. package/dist/agents/prometheus-prompt.d.ts +29 -0
  12. package/dist/agents/prometheus-prompt.test.d.ts +1 -0
  13. package/dist/agents/sisyphus-junior.d.ts +8 -0
  14. package/dist/agents/sisyphus-junior.test.d.ts +1 -0
  15. package/dist/agents/types.d.ts +2 -1
  16. package/dist/agents/utils.d.ts +6 -2
  17. package/dist/cli/config-manager.d.ts +9 -1
  18. package/dist/cli/doctor/checks/opencode.d.ts +5 -1
  19. package/dist/cli/index.js +5394 -5052
  20. package/dist/cli/run/events.d.ts +1 -0
  21. package/dist/cli/types.d.ts +3 -0
  22. package/dist/config/schema.d.ts +756 -163
  23. package/dist/features/background-agent/concurrency.d.ts +17 -0
  24. package/dist/features/background-agent/manager.d.ts +53 -2
  25. package/dist/features/background-agent/types.d.ts +34 -1
  26. package/dist/features/boulder-state/constants.d.ts +10 -0
  27. package/dist/features/boulder-state/index.d.ts +3 -0
  28. package/dist/features/boulder-state/storage.d.ts +28 -0
  29. package/dist/features/boulder-state/storage.test.d.ts +1 -0
  30. package/dist/features/boulder-state/types.d.ts +24 -0
  31. package/dist/features/builtin-commands/templates/init-deep.d.ts +1 -1
  32. package/dist/features/builtin-commands/templates/refactor.d.ts +1 -1
  33. package/dist/features/builtin-commands/templates/start-work.d.ts +1 -0
  34. package/dist/features/builtin-commands/types.d.ts +1 -1
  35. package/dist/features/claude-code-session-state/state.d.ts +6 -1
  36. package/dist/features/claude-code-session-state/state.test.d.ts +1 -0
  37. package/dist/features/context-injector/index.d.ts +1 -1
  38. package/dist/features/context-injector/injector.d.ts +1 -1
  39. package/dist/features/hook-message-injector/index.d.ts +2 -2
  40. package/dist/features/hook-message-injector/injector.d.ts +9 -2
  41. package/dist/features/hook-message-injector/types.d.ts +3 -2
  42. package/dist/features/opencode-skill-loader/index.d.ts +1 -0
  43. package/dist/features/opencode-skill-loader/skill-content.d.ts +20 -0
  44. package/dist/features/opencode-skill-loader/skill-content.test.d.ts +1 -0
  45. package/dist/features/skill-mcp-manager/manager.d.ts +11 -0
  46. package/dist/features/task-toast-manager/index.d.ts +2 -0
  47. package/dist/features/task-toast-manager/manager.d.ts +57 -0
  48. package/dist/features/task-toast-manager/manager.test.d.ts +1 -0
  49. package/dist/features/task-toast-manager/types.d.ts +21 -0
  50. package/dist/hooks/agent-usage-reminder/constants.d.ts +1 -1
  51. package/dist/hooks/anthropic-context-window-limit-recovery/executor.d.ts +1 -1
  52. package/dist/hooks/anthropic-context-window-limit-recovery/index.d.ts +1 -2
  53. package/dist/hooks/anthropic-context-window-limit-recovery/types.d.ts +0 -5
  54. package/dist/hooks/auto-update-checker/checker.d.ts +1 -1
  55. package/dist/hooks/auto-update-checker/checker.test.d.ts +1 -0
  56. package/dist/hooks/auto-update-checker/index.d.ts +4 -0
  57. package/dist/hooks/auto-update-checker/index.test.d.ts +1 -0
  58. package/dist/hooks/background-compaction/index.d.ts +19 -0
  59. package/dist/hooks/background-notification/index.d.ts +6 -0
  60. package/dist/hooks/claude-code-hooks/index.d.ts +2 -1
  61. package/dist/hooks/claude-code-hooks/types.d.ts +1 -0
  62. package/dist/hooks/comment-checker/cli.d.ts +0 -1
  63. package/dist/hooks/comment-checker/cli.test.d.ts +1 -0
  64. package/dist/hooks/compaction-context-injector/index.d.ts +7 -1
  65. package/dist/hooks/delegate-task-retry/index.d.ts +24 -0
  66. package/dist/hooks/delegate-task-retry/index.test.d.ts +1 -0
  67. package/dist/hooks/index.d.ts +5 -2
  68. package/dist/hooks/keyword-detector/index.d.ts +2 -1
  69. package/dist/hooks/prometheus-md-only/constants.d.ts +6 -0
  70. package/dist/hooks/prometheus-md-only/index.d.ts +12 -0
  71. package/dist/hooks/prometheus-md-only/index.test.d.ts +1 -0
  72. package/dist/hooks/ralph-loop/index.d.ts +1 -0
  73. package/dist/hooks/ralph-loop/types.d.ts +1 -0
  74. package/dist/hooks/sisyphus-orchestrator/index.d.ts +35 -0
  75. package/dist/hooks/sisyphus-orchestrator/index.test.d.ts +1 -0
  76. package/dist/hooks/start-work/index.d.ts +16 -0
  77. package/dist/hooks/start-work/index.test.d.ts +1 -0
  78. package/dist/hooks/task-resume-info/index.d.ts +11 -0
  79. package/dist/hooks/todo-continuation-enforcer.d.ts +1 -0
  80. package/dist/index.js +28035 -20876
  81. package/dist/mcp/context7.d.ts +1 -0
  82. package/dist/mcp/grep-app.d.ts +1 -0
  83. package/dist/mcp/index.d.ts +5 -2
  84. package/dist/mcp/websearch.d.ts +4 -0
  85. package/dist/plugin-config.test.d.ts +1 -0
  86. package/dist/plugin-handlers/config-handler.d.ts +2 -0
  87. package/dist/plugin-handlers/config-handler.test.d.ts +1 -0
  88. package/dist/shared/agent-tool-restrictions.d.ts +7 -0
  89. package/dist/shared/agent-variant.d.ts +5 -0
  90. package/dist/shared/agent-variant.test.d.ts +1 -0
  91. package/dist/shared/deep-merge.test.d.ts +1 -0
  92. package/dist/shared/external-plugin-detector.d.ts +18 -0
  93. package/dist/shared/external-plugin-detector.test.d.ts +1 -0
  94. package/dist/shared/first-message-variant.d.ts +11 -0
  95. package/dist/shared/first-message-variant.test.d.ts +1 -0
  96. package/dist/shared/index.d.ts +7 -0
  97. package/dist/shared/migration.d.ts +7 -0
  98. package/dist/shared/opencode-version.d.ts +6 -3
  99. package/dist/shared/permission-compat.d.ts +22 -7
  100. package/dist/shared/session-cursor.d.ts +13 -0
  101. package/dist/shared/session-cursor.test.d.ts +1 -0
  102. package/dist/shared/shell-env.d.ts +41 -0
  103. package/dist/shared/shell-env.test.d.ts +1 -0
  104. package/dist/shared/system-directive.d.ts +31 -0
  105. package/dist/shared/zip-extractor.d.ts +1 -0
  106. package/dist/tools/background-task/index.d.ts +1 -1
  107. package/dist/tools/call-omo-agent/constants.d.ts +1 -1
  108. package/dist/tools/delegate-task/constants.d.ts +12 -0
  109. package/dist/tools/delegate-task/index.d.ts +3 -0
  110. package/dist/tools/delegate-task/tools.d.ts +18 -0
  111. package/dist/tools/delegate-task/tools.test.d.ts +1 -0
  112. package/dist/tools/delegate-task/types.d.ts +9 -0
  113. package/dist/tools/glob/cli.d.ts +4 -0
  114. package/dist/tools/glob/cli.test.d.ts +1 -0
  115. package/dist/tools/glob/types.d.ts +1 -0
  116. package/dist/tools/index.d.ts +3 -0
  117. package/dist/tools/interactive-bash/constants.d.ts +1 -1
  118. package/dist/tools/look-at/tools.d.ts +7 -0
  119. package/dist/tools/look-at/tools.test.d.ts +1 -0
  120. package/dist/tools/lsp/client.d.ts +1 -3
  121. package/dist/tools/lsp/config.test.d.ts +1 -0
  122. package/dist/tools/lsp/index.d.ts +1 -1
  123. package/dist/tools/lsp/tools.d.ts +1 -6
  124. package/dist/tools/lsp/types.d.ts +0 -33
  125. package/dist/tools/lsp/utils.d.ts +1 -4
  126. package/dist/tools/skill/tools.d.ts +1 -7
  127. package/dist/tools/skill/types.d.ts +3 -0
  128. package/dist/tools/skill-mcp/types.d.ts +1 -1
  129. package/dist/tools/slashcommand/tools.d.ts +1 -7
  130. package/package.json +22 -14
  131. package/postinstall.mjs +43 -0
  132. package/dist/agents/build-prompt.d.ts +0 -31
  133. package/dist/agents/plan-prompt.d.ts +0 -61
  134. package/dist/auth/antigravity/constants.d.ts +0 -36
  135. package/dist/auth/antigravity/fetch.d.ts +0 -68
  136. package/dist/auth/antigravity/index.d.ts +0 -13
  137. package/dist/auth/antigravity/message-converter.d.ts +0 -54
  138. package/dist/auth/antigravity/oauth.d.ts +0 -85
  139. package/dist/auth/antigravity/plugin.d.ts +0 -54
  140. package/dist/auth/antigravity/project.d.ts +0 -10
  141. package/dist/auth/antigravity/request.d.ts +0 -104
  142. package/dist/auth/antigravity/response.d.ts +0 -137
  143. package/dist/auth/antigravity/thinking.d.ts +0 -234
  144. package/dist/auth/antigravity/thought-signature-store.d.ts +0 -52
  145. package/dist/auth/antigravity/token.d.ts +0 -38
  146. package/dist/auth/antigravity/tools.d.ts +0 -119
  147. package/dist/auth/antigravity/types.d.ts +0 -205
  148. package/dist/cli/ast-grep-napi.linux-x64-gnu-jfv8414z.node +0 -0
  149. package/dist/cli/ast-grep-napi.linux-x64-musl-8cj2e5cf.node +0 -0
  150. package/dist/google-auth.d.ts +0 -3
  151. package/dist/google-auth.js +0 -1865
  152. package/dist/hooks/anthropic-context-window-limit-recovery/pruning-executor.d.ts +0 -3
  153. package/dist/hooks/anthropic-context-window-limit-recovery/pruning-purge-errors.d.ts +0 -7
  154. package/dist/hooks/anthropic-context-window-limit-recovery/pruning-storage.d.ts +0 -2
  155. package/dist/hooks/anthropic-context-window-limit-recovery/pruning-supersede.d.ts +0 -6
  156. package/dist/hooks/comment-checker/constants.d.ts +0 -3
  157. package/dist/hooks/comment-checker/filters/bdd.d.ts +0 -2
  158. package/dist/hooks/comment-checker/filters/directive.d.ts +0 -2
  159. package/dist/hooks/comment-checker/filters/docstring.d.ts +0 -2
  160. package/dist/hooks/comment-checker/filters/index.d.ts +0 -7
  161. package/dist/hooks/comment-checker/filters/shebang.d.ts +0 -2
  162. package/dist/hooks/comment-checker/output/formatter.d.ts +0 -2
  163. package/dist/hooks/comment-checker/output/index.d.ts +0 -2
  164. package/dist/hooks/comment-checker/output/xml-builder.d.ts +0 -2
  165. package/dist/hooks/empty-message-sanitizer/index.d.ts +0 -12
  166. package/dist/hooks/preemptive-compaction/constants.d.ts +0 -3
  167. package/dist/hooks/preemptive-compaction/index.d.ts +0 -24
  168. package/dist/hooks/preemptive-compaction/types.d.ts +0 -17
  169. package/dist/tools/ast-grep/napi.d.ts +0 -13
  170. package/dist/tools/interactive-bash/types.d.ts +0 -3
@@ -1,205 +0,0 @@
1
- /**
2
- * Antigravity Auth Type Definitions
3
- * Matches cliproxyapi/sdk/auth/antigravity.go token format exactly
4
- */
5
- /**
6
- * Token storage format for Antigravity authentication
7
- * Matches Go metadata structure: type, access_token, refresh_token, expires_in, timestamp, email, project_id
8
- */
9
- export interface AntigravityTokens {
10
- /** Always "antigravity" for this auth type */
11
- type: "antigravity";
12
- /** OAuth access token from Google */
13
- access_token: string;
14
- /** OAuth refresh token from Google */
15
- refresh_token: string;
16
- /** Token expiration time in seconds */
17
- expires_in: number;
18
- /** Unix timestamp in milliseconds when tokens were obtained */
19
- timestamp: number;
20
- /** ISO 8601 formatted expiration datetime (optional, for display) */
21
- expired?: string;
22
- /** User's email address from Google userinfo */
23
- email?: string;
24
- /** GCP project ID from loadCodeAssist API */
25
- project_id?: string;
26
- }
27
- /**
28
- * Project context returned from loadCodeAssist API
29
- * Used to get cloudaicompanionProject for API calls
30
- */
31
- export interface AntigravityProjectContext {
32
- /** GCP project ID for Cloud AI Companion */
33
- cloudaicompanionProject?: string;
34
- /** Managed project ID for enterprise users (optional) */
35
- managedProjectId?: string;
36
- }
37
- /**
38
- * Metadata for loadCodeAssist API request
39
- */
40
- export interface AntigravityClientMetadata {
41
- /** IDE type identifier */
42
- ideType: "IDE_UNSPECIFIED" | string;
43
- /** Platform identifier */
44
- platform: "PLATFORM_UNSPECIFIED" | string;
45
- /** Plugin type - typically "GEMINI" */
46
- pluginType: "GEMINI" | string;
47
- }
48
- /**
49
- * Request body for loadCodeAssist API
50
- */
51
- export interface AntigravityLoadCodeAssistRequest {
52
- metadata: AntigravityClientMetadata;
53
- }
54
- export interface AntigravityUserTier {
55
- id?: string;
56
- isDefault?: boolean;
57
- userDefinedCloudaicompanionProject?: boolean;
58
- }
59
- export interface AntigravityLoadCodeAssistResponse {
60
- cloudaicompanionProject?: string | {
61
- id: string;
62
- };
63
- currentTier?: {
64
- id?: string;
65
- };
66
- allowedTiers?: AntigravityUserTier[];
67
- }
68
- export interface AntigravityOnboardUserPayload {
69
- done?: boolean;
70
- response?: {
71
- cloudaicompanionProject?: {
72
- id?: string;
73
- };
74
- };
75
- }
76
- /**
77
- * Request body format for Antigravity API calls
78
- * Wraps the actual request with project and model context
79
- */
80
- export interface AntigravityRequestBody {
81
- /** GCP project ID */
82
- project: string;
83
- /** Model identifier (e.g., "gemini-3-pro-preview") */
84
- model: string;
85
- /** User agent identifier */
86
- userAgent: string;
87
- /** Unique request ID */
88
- requestId: string;
89
- /** The actual request payload */
90
- request: Record<string, unknown>;
91
- }
92
- /**
93
- * Response format from Antigravity API
94
- * Follows OpenAI-compatible structure with Gemini extensions
95
- */
96
- export interface AntigravityResponse {
97
- /** Response ID */
98
- id?: string;
99
- /** Object type (e.g., "chat.completion") */
100
- object?: string;
101
- /** Creation timestamp */
102
- created?: number;
103
- /** Model used for response */
104
- model?: string;
105
- /** Response choices */
106
- choices?: AntigravityResponseChoice[];
107
- /** Token usage statistics */
108
- usage?: AntigravityUsage;
109
- /** Error information if request failed */
110
- error?: AntigravityError;
111
- }
112
- /**
113
- * Single response choice in Antigravity response
114
- */
115
- export interface AntigravityResponseChoice {
116
- /** Choice index */
117
- index: number;
118
- /** Message content */
119
- message?: {
120
- role: "assistant";
121
- content?: string;
122
- tool_calls?: AntigravityToolCall[];
123
- };
124
- /** Delta for streaming responses */
125
- delta?: {
126
- role?: "assistant";
127
- content?: string;
128
- tool_calls?: AntigravityToolCall[];
129
- };
130
- /** Finish reason */
131
- finish_reason?: "stop" | "tool_calls" | "length" | "content_filter" | null;
132
- }
133
- /**
134
- * Tool call in Antigravity response
135
- */
136
- export interface AntigravityToolCall {
137
- id: string;
138
- type: "function";
139
- function: {
140
- name: string;
141
- arguments: string;
142
- };
143
- }
144
- /**
145
- * Token usage statistics
146
- */
147
- export interface AntigravityUsage {
148
- prompt_tokens: number;
149
- completion_tokens: number;
150
- total_tokens: number;
151
- }
152
- /**
153
- * Error response from Antigravity API
154
- */
155
- export interface AntigravityError {
156
- message: string;
157
- type?: string;
158
- code?: string | number;
159
- }
160
- /**
161
- * Token exchange result from Google OAuth
162
- * Matches antigravityTokenResponse in Go
163
- */
164
- export interface AntigravityTokenExchangeResult {
165
- access_token: string;
166
- refresh_token: string;
167
- expires_in: number;
168
- token_type: string;
169
- }
170
- /**
171
- * User info from Google userinfo API
172
- */
173
- export interface AntigravityUserInfo {
174
- email: string;
175
- name?: string;
176
- picture?: string;
177
- }
178
- /**
179
- * Parsed refresh token parts
180
- * Format: refreshToken|projectId|managedProjectId
181
- */
182
- export interface AntigravityRefreshParts {
183
- refreshToken: string;
184
- projectId?: string;
185
- managedProjectId?: string;
186
- }
187
- /**
188
- * OAuth error payload from Google
189
- * Google returns errors in multiple formats, this handles all of them
190
- */
191
- export interface OAuthErrorPayload {
192
- error?: string | {
193
- status?: string;
194
- code?: string;
195
- message?: string;
196
- };
197
- error_description?: string;
198
- }
199
- /**
200
- * Parsed OAuth error with normalized fields
201
- */
202
- export interface ParsedOAuthError {
203
- code?: string;
204
- description?: string;
205
- }
@@ -1,3 +0,0 @@
1
- import type { Plugin } from "@opencode-ai/plugin";
2
- declare const GoogleAntigravityAuthPlugin: Plugin;
3
- export default GoogleAntigravityAuthPlugin;