Skip to content

Commit a7bb93e

Browse files
committed
Add smaller file tree for lite mode
1 parent da9b5bb commit a7bb93e

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

.agents/types/secret-agent-definition.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ const placeholderNames = [
2525
'AGENT_NAME',
2626
'AGENTS_PROMPT',
2727
'CONFIG_SCHEMA',
28+
'FILE_TREE_PROMPT_SMALL',
2829
'FILE_TREE_PROMPT',
2930
'GIT_CHANGES_PROMPT',
3031
'INITIAL_AGENT_PROMPT',

backend/src/templates/strings.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,11 @@ export async function formatPrompt(
5353
? agentTemplate.displayName || 'Unknown Agent'
5454
: 'Buffy',
5555
[PLACEHOLDER.CONFIG_SCHEMA]: schemaToJsonStr(CodebuffConfigSchema),
56+
[PLACEHOLDER.FILE_TREE_PROMPT_SMALL]: getProjectFileTreePrompt(
57+
fileContext,
58+
2_500,
59+
'agent',
60+
),
5661
[PLACEHOLDER.FILE_TREE_PROMPT]: getProjectFileTreePrompt(
5762
fileContext,
5863
20_000,

backend/src/templates/types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ const placeholderNames = [
1515
'AGENT_NAME',
1616
'AGENTS_PROMPT',
1717
'CONFIG_SCHEMA',
18+
'FILE_TREE_PROMPT_SMALL',
1819
'FILE_TREE_PROMPT',
1920
'GIT_CHANGES_PROMPT',
2021
'INITIAL_AGENT_PROMPT',

0 commit comments

Comments
 (0)