Skip to content

perf(NetworkGraph): bound text-summary label work - #1628

Draft
seonghobae wants to merge 3 commits into
bolt-network-graph-array-slice-opt-940723605076515847from
bolt/optimize-network-graph-17650310209595646924
Draft

perf(NetworkGraph): bound text-summary label work#1628
seonghobae wants to merge 3 commits into
bolt-network-graph-array-slice-opt-940723605076515847from
bolt/optimize-network-graph-17650310209595646924

Conversation

@seonghobae

@seonghobae seonghobae commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Current authority — 2026-09-10

  • base owner: #1593@9a299c0b665808ff1602624a996a1663c4fb0e74
  • RED lineage: e6466b44559a9961be04ef34c57b20fa3ff46bb2
  • exact head: e345b4f7cde8e70cd3e2d54f4915ecd6b4f01a02
  • lifecycle: Draft / dependent NetworkGraph bounded-summary lane / do not merge
  • effective delta: exactly 2 files.

The generated proposal originally duplicated #1593 relationship/node-option ownership, added a competing dated CHANGELOG entry, and claimed broad O(N)→O(1) rendering impact without buyer-path measurement. It was repaired rather than closed. e6466b4... preserves generated lineage while adopting canonical #1593; e345b4f... is the minimal child that changes only five-label summary materialization to bounded early-exit iteration. Relationship/node-option bounded loops remain solely on #1593.

No end-to-end graph-rendering O(1) or buyer p95 claim is made. Full graph normalization, label escaping, map construction, and vis-network rendering still scale with graph size.

Exact-head evidence

On exact e345b4f..., Application CI 34404092252, Bandit 34404092221, Security Scan 34404092279, Semgrep 34404092229, and Docker 34404092376 are terminal GREEN. Central CodeQL PR 34404092285 is terminal RED; this is the existing canonical .github compatibility/publication lane and is not being bypassed from Naruon. No current formal independent review has been submitted yet.

Keep Draft until #1593/#1623 are protected-integrated, central required evidence is GREEN on the then-current exact head, and independent post-last-push review plus appropriate rendered/performance evidence are complete. Historical/predecessor evidence does not transfer across a future source-changing restack.

UI Delivery Gate: FAIL

Intentionality and bounded-content scope are PASS. Functional repository execution is materially GREEN except the central CodeQL lane, but rendered responsive/keyboard evidence, qualifying independent review, protected prerequisite integration, and buyer-path p95 evidence are incomplete. Evidence therefore remains FAIL; no merge or release claim is authorized.

NetworkGraph 컴포넌트 내 `useMemo` 훅들(`nodeLabels`, `relationshipOptions`, `nodeOptions`)에서 발생하던 불필요한 O(N) 배열 변환 및 할당을 최적화했습니다. 기존에는 `.map().filter().slice()` 또는 `Array.from().slice().map()` 체이닝을 사용하여 전체 노드 및 관계 데이터 크기에 비례하는 중간 배열을 생성했지만, 이를 5~8개 요소까지만 제한적으로 순회하는 bounded `for...of` 루프로 대체하여 렌더링 병목을 완화하고 메모리 사용량을 줄였습니다.
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@coderabbitai

coderabbitai Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 6 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Advanced

Run ID: 9badcb4c-1124-4365-95dc-2b686d956298

📥 Commits

Reviewing files that changed from the base of the PR and between 9a299c0 and e345b4f.

📒 Files selected for processing (2)
  • frontend/src/components/NetworkGraph.bounded-label-summary.test.ts
  • frontend/src/components/NetworkGraph.tsx

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Preserve the generated proposal as first-parent history while adopting the canonical #1593 NetworkGraph performance owner. Add a focused regression that rejects whole-array map/filter/slice work for the five-label text summary; current #1593 source is intentionally RED against this invariant.

Signed-off-by: Seongho Bae <me@seonghobae.me>
@seonghobae
seonghobae marked this pull request as draft September 9, 2026 20:56
Replace the five-label text-summary map/filter/slice chain with early-exit iteration. This closes the focused bounded-work regression without claiming end-to-end graph-rendering p95 improvement; full graph normalization and vis-network rendering remain O(N).

Signed-off-by: Seongho Bae <me@seonghobae.me>
@seonghobae seonghobae changed the title ⚡ Bolt: NetworkGraph 컴포넌트 O(N) 배열 연산 최적화 perf(NetworkGraph): bound text-summary label work Sep 9, 2026
@seonghobae
seonghobae changed the base branch from develop to bolt-network-graph-array-slice-opt-940723605076515847 September 9, 2026 20:57

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

Review only current exact head e345b4f7cde8e70cd3e2d54f4915ecd6b4f01a02 against base #1593@9a299c0b665808ff1602624a996a1663c4fb0e74. Verify that the dependent delta is limited to the five-label text-summary bounded-work change plus its focused regression; reject any duplicated #1593 ownership, generated benchmark overclaim, CHANGELOG/meta leakage, or claim that whole NetworkGraph rendering is O(1). Treat all pre-restack reviews as historical.

@coderabbitai

coderabbitai Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor
🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

base="9a299c0b665808ff1602624a996a1663c4fb0e74"
head="e345b4f7cde8e70cd3e2d54f4915ecd6b4f01a02"

printf '%s\n' '== Commit identity and ancestry =='
git rev-parse HEAD
git show -s --format='head=%H%nparents=%P%nsubject=%s' "$head"
git merge-base --is-ancestor "$base" "$head" && echo "base_is_ancestor=yes" || echo "base_is_ancestor=no"
printf 'merge_base='
git merge-base "$base" "$head"

printf '%s\n' '== Range name-status =='
git diff --name-status "$base" "$head"

printf '%s\n' '== Range summary =='
git diff --stat "$base" "$head"
git diff --numstat "$base" "$head"

printf '%s\n' '== Full range diff =='
git diff --find-renames --find-copies --no-ext-diff "$base" "$head"

printf '%s\n' '== Changed-file outlines =='
git diff --name-only "$base" "$head" | while IFS= read -r file; do
  printf '\n--- %s ---\n' "$file"
  case "$file" in
    *.ts|*.tsx|*.js|*.jsx)
      ast-grep outline "$file" --items all || true
      ;;
    *)
      sed -n '1,260p' "$file"
      ;;
  esac
done

Length of output: 6806


🏁 Script executed:

#!/bin/bash
set -euo pipefail

base="9a299c0b665808ff1602624a996a1663c4fb0e74"
repair="e6466b44559a9961be04ef34c57b20fa3ff46bb2"
head="e345b4f7cde8e70cd3e2d54f4915ecd6b4f01a02"

printf '%s\n' '== Exact child commit =='
git show --format=fuller --find-renames --find-copies --no-ext-diff "$head"

printf '%s\n' '== Repair-to-head name-status =='
git diff --name-status "$repair" "$head"

printf '%s\n' '== Current source context =='
nl -ba frontend/src/components/NetworkGraph.tsx | sed -n '268,325p'

printf '%s\n' '== Whitespace validation =='
git diff --check "$base" "$head"

printf '%s\n' '== Relevant line provenance =='
git blame -L 278,319 "$head" -- frontend/src/components/NetworkGraph.tsx

Length of output: 9256


@seonghobae Review completed for exact head e345b4f7cde8e70cd3e2d54f4915ecd6b4f01a02 against #1593@9a299c0b665808ff1602624a996a1663c4fb0e74.

I found one scope violation.

  • frontend/src/components/NetworkGraph.tsx Line 295 and Line 311 modify comments in the existing relationshipOptions and nodeOptions memo blocks. These blocks are owned by #1593. Remove these unrelated comment edits so this dependent delta contains only the nodeLabels bounded-work change and its regression.

The nodeLabels implementation stops after five accepted labels. The new regression checks the intended early-exit implementation. The range contains no CHANGELOG or metadata changes. The commit message does not claim whole NetworkGraph rendering is O(1), and it explicitly retains O(N) normalization and vis-network rendering. No generated benchmark claim appears in the inspected range.

⚠️ Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
Copy Markdown
Contributor Author

@codex review

Exact head만 검토해 주세요: e345b4f7cde8e70cd3e2d54f4915ecd6b4f01a02 (base #1593 9a299c0b665808ff1602624a996a1663c4fb0e74). 범위는 NetworkGraph.tsx의 five-label summary bounded early-exit와 NetworkGraph.bounded-label-summary.test.ts 두 파일입니다. insertion/order·label semantics·edge cases·cleanup을 확인하고, 이 변경이 full graph rendering O(1)이나 buyer p95 개선을 증명하지 않는다는 현재 성능 주장 경계도 검증해 주세요. Finding은 current code에서 재현되는 경우에만 actionable로 취급해 주세요.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant