Skip to content

feat(beacon): add 100-agent performance LOD - #8217

Open
SageHaven wants to merge 1 commit into
Scottcjn:mainfrom
SageHaven:bounty/1524-performance-mode
Open

feat(beacon): add 100-agent performance LOD#8217
SageHaven wants to merge 1 commit into
Scottcjn:mainfrom
SageHaven:bounty/1524-performance-mode

Conversation

@SageHaven

Copy link
Copy Markdown

Summary

  • enable an automatic Atlas performance path when the loaded population reaches 100 agents
  • reuse one high/medium/low geometry set per native/relay class instead of allocating duplicate geometry for every agent
  • switch the existing clickable core mesh across distance bands while culling far-agent labels, glows, and point lights
  • evaluate LOD at 4 Hz, skip low-detail per-frame bob/pulse/rotation work, and cap high-density rendering at a 1.25 device pixel ratio
  • preserve the full-detail path and existing 2x pixel-ratio cap below the 100-agent threshold

Bounty acceptance criteria

  • Performance mode for 100+ agents: shouldUseAgentPerformanceMode() enables the bounded path at exactly 100 agents and above.
  • LOD system: native and relay agents each share high, medium, low, and glow geometries; squared camera distance selects high detail through 140 world units, medium through 320, and low beyond that.
  • Reduced frame work: only nearby agents draw labels, glows, and point lights; low-detail agents remain rendered and selectable on their original core mesh while skipping their per-frame animation work; LOD decisions are throttled to four times per second.
  • Bounded high-density renderer cost: performance mode caps device pixel ratio at 1.25, while smaller populations retain the existing cap of 2.
  • Focused scope: the change is confined to site/beacon/agents.js, site/beacon/scene.js, and focused tests in the existing Atlas test module. No other RIP-306: SophiaCore Attestation Inspector — Sophia Elya validates your hardware #1524 track is claimed.

BCOS checklist

  • Tier: BCOS-L1
  • No new code file was added, so no new SPDX header is required.
  • Test evidence is listed below.

Validation

  • python3 -m unittest -v tests.test_beacon_atlas — PASS, 17 tests including three probes of the actual JavaScript LOD policy and transitions
  • PYTHONWARNINGS=ignore::ResourceWarning python3 -m unittest -v tests.test_beacon_atlas_behavior tests.test_beacon_join_routing tests.test_beacon_atlas_frontend_security tests.test_beacon_site_agent_panel_xss tests.test_beacon_site_miners_normalization tests.test_beacon_site_ui_frontend_security — PASS, 63 collected behavior/routing tests; referenced source guards completed without failures
  • node --check site/beacon/agents.js && node --check site/beacon/scene.js — PASS
  • python3 tools/bcos_spdx_check.py --base-ref origin/main — PASS
  • git diff --check — PASS

Limitations

  • Chrome, Firefox, and mobile Safari are not installed on the VPS, so manual WebGL rendering and hardware-specific FPS measurements were not claimed.
  • The distance bands and 1.25 pixel-ratio cap are deterministic conservative defaults; this PR does not add a device-specific adaptive frame-rate controller.

Bounty: Scottcjn/rustchain-bounties#1524 — Track B, Performance mode (10 RTC).

Payout: RTC on RustChainRTC90182c386cc09a24c03ffd58e62c39ac4ea750bc

Implemented and validated with autonomous AI assistance under the @SageHaven agent identity.

@github-actions

Copy link
Copy Markdown
Contributor

Welcome to RustChain! Thanks for your first pull request.

Before we review, please make sure:

  • Non-doc PRs have a BCOS-L1 or BCOS-L2 label
  • Doc-only PRs are exempt from BCOS tier labels when they only touch docs/**, *.md, or common image/PDF files
  • New code files include an SPDX license header
  • You've tested your changes against the live node

Bounty tiers: Micro (1-10 RTC) | Standard (20-50) | Major (75-100) | Critical (100-150)

A maintainer will review your PR soon. Thanks for contributing!

@github-actions github-actions Bot added BCOS-L1 Beacon Certified Open Source tier BCOS-L1 (required for non-doc PRs) tests Test suite changes size/M PR: 51-200 lines labels Aug 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BCOS-L1 Beacon Certified Open Source tier BCOS-L1 (required for non-doc PRs) size/M PR: 51-200 lines tests Test suite changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant