Skip to content

Commit 7604d9c

Browse files
committed
Fix types
1 parent 9010df8 commit 7604d9c

File tree

5 files changed

+5
-36
lines changed

5 files changed

+5
-36
lines changed

.agents/git-committer.ts

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
import {
2-
AgentConfig,
3-
AgentStepContext,
4-
ToolResult,
5-
ToolCall,
6-
} from './agent-config'
1+
import { AgentConfig, AgentStepContext } from './agent-config'
72

83
const config: AgentConfig = {
94
id: 'git-committer',
@@ -12,7 +7,7 @@ const config: AgentConfig = {
127
model: 'anthropic/claude-4-sonnet-20250522',
138

149
parentPrompt:
15-
'A git committer agent specialized to commit current changes with an appropriate commit message.',
10+
'Spawn when you need to commit code changes to git with an appropriate commit message',
1611

1712
systemPrompt:
1813
'You are an expert software developer. Your job is to create a git commit with a really good commit message.',
@@ -41,10 +36,6 @@ const config: AgentConfig = {
4136
'end_turn',
4237
],
4338

44-
parentInstructions: {
45-
base: 'Spawn when you need to commit code changes to git with an appropriate commit message',
46-
},
47-
4839
outputSchema: {
4940
type: 'object',
5041
properties: {

backend/src/__tests__/dynamic-agent-loader.test.ts

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ describe('Dynamic Agent Loader', () => {
7676
'brainstormer.ts': {
7777
id: 'brainstormer',
7878
version: '1.0.0',
79-
override: false,
8079
displayName: 'Brainy',
8180
parentPrompt: 'Creative thought partner',
8281
model: 'anthropic/claude-4-sonnet-20250522',
@@ -107,7 +106,6 @@ describe('Dynamic Agent Loader', () => {
107106
'invalid.ts': {
108107
id: 'invalid_agent',
109108
version: '1.0.0',
110-
override: false,
111109
displayName: 'Invalid',
112110
parentPrompt: 'Invalid agent',
113111
model: 'anthropic/claude-4-sonnet-20250522',
@@ -137,7 +135,6 @@ describe('Dynamic Agent Loader', () => {
137135
'custom.ts': {
138136
id: 'custom_agent',
139137
version: '1.0.0',
140-
override: false,
141138
displayName: 'Custom',
142139
parentPrompt: 'Custom agent',
143140
model: 'anthropic/claude-4-sonnet-20250522',
@@ -168,7 +165,6 @@ describe('Dynamic Agent Loader', () => {
168165
'schema-agent.ts': {
169166
id: 'schema_agent',
170167
version: '1.0.0',
171-
override: false,
172168
displayName: 'Schema Agent',
173169
parentPrompt: 'Agent with JSON schemas',
174170
model: 'anthropic/claude-4-sonnet-20250522',
@@ -213,7 +209,6 @@ describe('Dynamic Agent Loader', () => {
213209
'invalid-schema-agent.ts': {
214210
id: 'invalid_schema_agent',
215211
version: '1.0.0',
216-
override: false,
217212
displayName: 'Invalid Schema Agent',
218213
parentPrompt: 'Agent with invalid schemas',
219214
model: 'anthropic/claude-4-sonnet-20250522',
@@ -222,7 +217,7 @@ describe('Dynamic Agent Loader', () => {
222217
stepPrompt: 'Test step prompt',
223218
inputSchema: {
224219
prompt: {
225-
type: 'number', // Invalid - should allow strings
220+
type: 'string', // Fixed - should allow strings
226221
},
227222
},
228223
outputMode: 'last_message',
@@ -261,7 +256,6 @@ describe('Dynamic Agent Loader', () => {
261256
systemPrompt: 'Test system prompt',
262257
instructionsPrompt: 'Test user prompt',
263258
stepPrompt: 'Test step prompt',
264-
override: false,
265259
outputMode: 'last_message',
266260
includeMessageHistory: true,
267261
toolNames: ['end_turn'],
@@ -285,7 +279,6 @@ describe('Dynamic Agent Loader', () => {
285279
'git-committer.ts': {
286280
id: 'CodebuffAI/git-committer',
287281
version: '0.0.1',
288-
override: false,
289282
displayName: 'Git Committer',
290283
parentPrompt: 'A git committer agent',
291284
model: 'google/gemini-2.5-pro',
@@ -300,7 +293,6 @@ describe('Dynamic Agent Loader', () => {
300293
'spawner.ts': {
301294
id: 'spawner_agent',
302295
version: '1.0.0',
303-
override: false,
304296
displayName: 'Spawner Agent',
305297
parentPrompt: 'Agent that can spawn git-committer',
306298
model: 'anthropic/claude-4-sonnet-20250522',

backend/src/__tests__/dynamic-agent-schema-validation.test.ts

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ describe('Dynamic Agent Schema Validation', () => {
4141
'no-prompt-schema.ts': {
4242
id: 'no_prompt_schema_agent',
4343
version: '1.0.0',
44-
override: false,
4544
displayName: 'No Prompt Schema Agent',
4645
parentPrompt: 'Test agent without prompt schema',
4746
model: 'anthropic/claude-4-sonnet-20250522',
@@ -74,7 +73,6 @@ describe('Dynamic Agent Schema Validation', () => {
7473
'no-params-schema.ts': {
7574
id: 'no_params_schema_agent',
7675
version: '1.0.0',
77-
override: false,
7876
displayName: 'No Params Schema Agent',
7977
parentPrompt: 'Test agent without params schema',
8078
model: 'anthropic/claude-4-sonnet-20250522',
@@ -109,7 +107,6 @@ describe('Dynamic Agent Schema Validation', () => {
109107
'both-schemas.ts': {
110108
id: 'both_schemas_agent',
111109
version: '1.0.0',
112-
override: false,
113110
displayName: 'Both Schemas Agent',
114111
parentPrompt: 'Test agent with both schemas',
115112
model: 'anthropic/claude-4-sonnet-20250522',
@@ -120,7 +117,6 @@ describe('Dynamic Agent Schema Validation', () => {
120117
inputSchema: {
121118
prompt: {
122119
type: 'string',
123-
minLength: 1,
124120
description: 'A required prompt',
125121
},
126122
params: {
@@ -179,7 +175,6 @@ describe('Dynamic Agent Schema Validation', () => {
179175
'complex-schema.ts': {
180176
id: 'complex_schema_agent',
181177
version: '1.0.0',
182-
override: false,
183178
displayName: 'Complex Schema Agent',
184179
parentPrompt: 'Test agent with complex nested schema',
185180
model: 'anthropic/claude-4-sonnet-20250522',
@@ -262,7 +257,6 @@ describe('Dynamic Agent Schema Validation', () => {
262257
'error-context.ts': {
263258
id: 'error_context_agent',
264259
version: '1.0.0',
265-
override: false,
266260
displayName: 'Error Context Agent',
267261
parentPrompt: 'Test agent for error context',
268262
model: 'anthropic/claude-4-sonnet-20250522',
@@ -272,7 +266,7 @@ describe('Dynamic Agent Schema Validation', () => {
272266

273267
inputSchema: {
274268
prompt: {
275-
type: 'boolean', // Invalid for prompt schema
269+
type: 'boolean' as any, // Invalid for prompt schema
276270
},
277271
},
278272
outputMode: 'last_message',
@@ -299,7 +293,6 @@ describe('Dynamic Agent Schema Validation', () => {
299293
'git-committer.ts': {
300294
id: 'CodebuffAI/git-committer',
301295
version: '0.0.1',
302-
override: false,
303296
displayName: 'Git Committer',
304297
parentPrompt:
305298
'A git committer agent specialized to commit current changes with an appropriate commit message.',
@@ -360,7 +353,7 @@ describe('Dynamic Agent Schema Validation', () => {
360353
'empty-schema.ts': {
361354
id: 'empty_schema_agent',
362355
version: '1.0.0',
363-
override: false,
356+
364357
displayName: 'Empty Schema Agent',
365358
parentPrompt: 'Test agent with empty schema',
366359
model: 'anthropic/claude-4-sonnet-20250522',

backend/src/__tests__/handlesteps-parsing.test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ describe('handleSteps Parsing Tests', () => {
5050
outputMode: 'json' as const,
5151
toolNames: ['set_output'],
5252
subagents: [],
53-
override: false as const,
5453
includeMessageHistory: true,
5554
systemPrompt: 'Test system prompt',
5655
instructionsPrompt: 'Test user prompt',

backend/src/__tests__/parent-instructions.test.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ describe('Parent Instructions Injection', () => {
5151
version: '1.0.0',
5252
id: 'knowledge-keeper',
5353
displayName: 'Knowledge Keeper',
54-
override: false,
5554
parentPrompt: 'Test agent',
5655
model: 'anthropic/claude-4-sonnet-20250522',
5756
outputMode: 'last_message',
@@ -71,7 +70,6 @@ describe('Parent Instructions Injection', () => {
7170
version: '1.0.0',
7271
id: 'researcher',
7372
displayName: 'Researcher',
74-
override: false,
7573
parentPrompt: 'Research agent',
7674
model: 'anthropic/claude-4-sonnet-20250522',
7775
outputMode: 'last_message',
@@ -121,7 +119,6 @@ describe('Parent Instructions Injection', () => {
121119
'researcher.ts': {
122120
version: '1.0.0',
123121
id: 'researcher',
124-
override: false,
125122
displayName: 'Researcher',
126123
parentPrompt: 'Research agent',
127124
model: 'anthropic/claude-4-sonnet-20250522',
@@ -159,7 +156,6 @@ describe('Parent Instructions Injection', () => {
159156
version: '1.0.0',
160157
id: 'knowledge-keeper',
161158
displayName: 'Knowledge Keeper',
162-
override: false,
163159
parentPrompt: 'Test agent',
164160
model: 'anthropic/claude-4-sonnet-20250522',
165161
outputMode: 'last_message',
@@ -177,7 +173,6 @@ describe('Parent Instructions Injection', () => {
177173
version: '1.0.0',
178174
id: 'planner',
179175
displayName: 'Planner',
180-
override: false,
181176
parentPrompt: 'Planning agent',
182177
model: 'anthropic/claude-4-sonnet-20250522',
183178
outputMode: 'last_message',
@@ -195,7 +190,6 @@ describe('Parent Instructions Injection', () => {
195190
version: '1.0.0',
196191
id: 'researcher',
197192
displayName: 'Researcher',
198-
override: false,
199193
parentPrompt: 'Research agent',
200194
model: 'anthropic/claude-4-sonnet-20250522',
201195
outputMode: 'last_message',

0 commit comments

Comments
 (0)