Skip to content

Commit ff88e98

Browse files
JihaoXinclaude
andcommitted
Soften concept figure requirement: encourage but don't force
Planner is encouraged to suggest at least 1 system overview if the research has a multi-component system, but can output NO_CONCEPT_FIGURES if truly not needed. Removed fallback that auto-created a default figure. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent da49ff5 commit ff88e98

File tree

1 file changed

+10
-12
lines changed

1 file changed

+10
-12
lines changed

ark/compiler.py

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -685,29 +685,27 @@ def _generate_nano_banana_figures(self):
685685
- "full_width": for complex multi-stage pipelines, architectures with 4+ components
686686
- "single_column": for simple 2-3 component diagrams
687687
688-
You MUST output at least 1 figure (system overview). Output up to 3 figures maximum.
689-
Do NOT output NO_CONCEPT_FIGURES — every paper needs at least one architecture diagram.
688+
We encourage at least 1 system overview figure if the research has a multi-component system.
689+
Output up to 3 figures maximum. If the research truly has no visual architecture to illustrate,
690+
output: NO_CONCEPT_FIGURES
690691
""", timeout=600)
691692

693+
if not analysis_output or "NO_CONCEPT_FIGURES" in analysis_output:
694+
self.log_step("Planner decided no concept figures needed", "info")
695+
return
696+
692697
# Parse figure list from agent output
693698
figures = []
694699
try:
695-
json_match = re.search(r'\[[\s\S]*?\]', analysis_output or "")
700+
json_match = re.search(r'\[[\s\S]*?\]', analysis_output)
696701
if json_match:
697702
figures = json.loads(json_match.group())
698703
except (json.JSONDecodeError, AttributeError):
699704
self.log("Failed to parse concept figure list from planner output", "WARN")
705+
return
700706

701-
# Fallback: if planner returned nothing, create a default system overview
702707
if not figures:
703-
self.log("Planner did not suggest figures, creating default system overview", "INFO")
704-
figures = [{
705-
"name": "fig_overview",
706-
"caption": f"System overview of {title or 'the proposed approach'}",
707-
"section_context": idea[:2000] if idea else paper_context[:2000],
708-
"latex_label": "fig:overview",
709-
"placement": "full_width",
710-
}]
708+
return
711709

712710
paper_text = paper_context
713711

0 commit comments

Comments
 (0)