File tree Expand file tree Collapse file tree
openviking/storage/queuefs Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1179,15 +1179,22 @@ async def _generate_overview(
11791179 file_summaries_lines .append (f"[{ idx } ] { item ['name' ]} : { item ['summary' ]} " )
11801180 file_summaries_str = "\n " .join (file_summaries_lines ) if file_summaries_lines else "None"
11811181
1182- output_language = resolve_output_language (file_summaries_str , config = config )
1183-
11841182 # Build subdirectory summary string
11851183 children_abstracts_str = (
11861184 "\n " .join (f"- { item ['name' ]} /: { item ['abstract' ]} " for item in children_abstracts )
11871185 if children_abstracts
11881186 else "None"
11891187 )
11901188
1189+ language_source_parts = []
1190+ if file_summaries :
1191+ language_source_parts .append (file_summaries_str )
1192+ if children_abstracts :
1193+ language_source_parts .append (children_abstracts_str )
1194+ if not language_source_parts :
1195+ language_source_parts .append (dir_uri .split ("/" )[- 1 ])
1196+ output_language = resolve_output_language ("\n " .join (language_source_parts ), config = config )
1197+
11911198 # Budget guard: check if prompt would be oversized
11921199 estimated_size = len (file_summaries_str ) + len (children_abstracts_str )
11931200 over_budget = estimated_size > semantic .max_overview_prompt_chars
You can’t perform that action at this time.
0 commit comments