Skip to content

Commit b7a5a3b

Browse files
charleslienjahooma
andauthored
Move db to internal
Co-authored-by: James Grugett <jahooma@gmail.com>
1 parent 2e899d0 commit b7a5a3b

File tree

359 files changed

+2120
-1931
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

359 files changed

+2120
-1931
lines changed

.agents/editor/code-sketcher.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ const definition: SecretAgentDefinition = {
1111
inputSchema: {
1212
prompt: {
1313
type: 'string',
14-
description: 'The coding task to sketch out, including the key sections of logic or interfaces it should focus on.',
14+
description:
15+
'The coding task to sketch out, including the key sections of logic or interfaces it should focus on.',
1516
},
1617
},
1718
outputMode: 'last_message',

.agents/file-explorer/file-q-and-a.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@ Read the file and answer the user's question about it. Depending on what they're
4141
- For specific questions: focus on the relevant parts and provide clear explanations
4242
- For excerpts: reproduce the requested code exactly as it appears in the file
4343
`.trim(),
44-
stepPrompt: 'Do not use any tools again. Just answer the question about the file.',
44+
stepPrompt:
45+
'Do not use any tools again. Just answer the question about the file.',
4546

4647
handleSteps: function* ({ prompt, params }) {
4748
const filePath = params?.filePath

.agents/planners/planner-pro.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ const definition: SecretAgentDefinition = {
99
model: 'openai/gpt-5-pro',
1010
publisher,
1111
displayName: 'Planner Pro',
12-
spawnerPrompt: 'Uses deep thinking to generate an implementation plan for a user request.',
12+
spawnerPrompt:
13+
'Uses deep thinking to generate an implementation plan for a user request.',
1314
inputSchema: {},
1415
outputMode: 'last_message',
1516
spawnableAgents: [],

.agents/researcher/researcher-grok-4-fast.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,7 @@ const definition: SecretAgentDefinition = {
1010
model: 'x-ai/grok-4-fast',
1111
displayName: 'Grok 4 Fast Researcher',
1212
toolNames: ['spawn_agents'],
13-
spawnableAgents: [
14-
'file-explorer',
15-
'researcher-web',
16-
'researcher-docs',
17-
],
13+
spawnableAgents: ['file-explorer', 'researcher-web', 'researcher-docs'],
1814

1915
inputSchema: {
2016
prompt: {

.agents/thinker/deep-thinker.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,7 @@ const definition: AgentDefinition = {
1414
},
1515

1616
toolNames: ['spawn_agents'],
17-
spawnableAgents: [
18-
'gpt5-thinker',
19-
'sonnet-thinker',
20-
'gemini-thinker',
21-
],
17+
spawnableAgents: ['gpt5-thinker', 'sonnet-thinker', 'gemini-thinker'],
2218

2319
includeMessageHistory: true,
2420
inputSchema: {

.agents/thinker/thinker-lite.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ const definition: SecretAgentDefinition = {
88
model: 'x-ai/grok-4-fast',
99
}
1010

11-
export default definition
11+
export default definition

.github/workflows/ci.yml

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,14 +83,26 @@ jobs:
8383
strategy:
8484
matrix:
8585
package:
86-
[.agents, backend, cli, common, npm-app, packages/agent-runtime, web]
86+
[
87+
.agents,
88+
backend,
89+
cli,
90+
common,
91+
npm-app,
92+
packages/agent-runtime,
93+
packages/billing,
94+
packages/internal,
95+
web,
96+
]
8797
include:
8898
- package: .agents
8999
- package: backend
90100
- package: cli
91101
- package: common
92102
- package: npm-app
93103
- package: packages/agent-runtime
104+
- package: packages/billing
105+
- package: packages/internal
94106
- package: web
95107
name: test-${{ matrix.package }}
96108
runs-on: ubuntu-latest
@@ -157,14 +169,26 @@ jobs:
157169
strategy:
158170
matrix:
159171
package:
160-
[.agents, backend, cli, common, npm-app, packages/agent-runtime, web]
172+
[
173+
.agents,
174+
backend,
175+
cli,
176+
common,
177+
npm-app,
178+
packages/agent-runtime,
179+
packages/billing,
180+
packages/internal,
181+
web,
182+
]
161183
include:
162184
- package: .agents
163185
- package: backend
164186
- package: cli
165187
- package: common
166188
- package: npm-app
167189
- package: packages/agent-runtime
190+
- package: packages/billing
191+
- package: packages/internal
168192
- package: web
169193
name: test-integration-${{ matrix.package }}
170194
runs-on: ubuntu-latest

.vscode/settings.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,15 @@
11
{
22
"editor.formatOnSave": true,
3+
"editor.defaultFormatter": "esbenp.prettier-vscode",
4+
"[typescript]": {
5+
"editor.defaultFormatter": "esbenp.prettier-vscode"
6+
},
7+
"[typescriptreact]": {
8+
"editor.defaultFormatter": "esbenp.prettier-vscode"
9+
},
310
"editor.codeActionsOnSave": {
411
"source.fixAll.eslint": "explicit"
512
},
6-
"eslint.validate": ["typescript"],
13+
"eslint.validate": ["typescript", "typescriptreact"],
714
"eslint.quiet": true
815
}

backend/src/__tests__/agent-run.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
import db from '@codebuff/common/db'
2-
import * as schema from '@codebuff/common/db/schema'
31
import { TEST_AGENT_RUNTIME_IMPL } from '@codebuff/common/testing/impl/agent-runtime'
42
import {
53
mockModule,
64
clearMockedModules,
75
} from '@codebuff/common/testing/mock-modules'
6+
import db from '@codebuff/internal/db'
7+
import * as schema from '@codebuff/internal/db/schema'
88
import {
99
spyOn,
1010
beforeEach,

backend/src/__tests__/auto-topup.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ describe('Auto Top-up System', () => {
4545
)
4646

4747
// Mock the database
48-
mockModule('@codebuff/common/db', () => ({
48+
mockModule('@codebuff/internal/db', () => ({
4949
default: {
5050
query: {
5151
user: {

0 commit comments

Comments
 (0)