Skip to content

feat: project genie integration#77

Draft
Igor Holt (igor-holt) wants to merge 4 commits into
mainfrom
feat/project-genie-integration-4533367094448095881
Draft

feat: project genie integration#77
Igor Holt (igor-holt) wants to merge 4 commits into
mainfrom
feat/project-genie-integration-4533367094448095881

Conversation

@igor-holt
Copy link
Copy Markdown
Member

Integrates the dynamically generated interactive 3D capabilities from Google's Project Genie into the continuous Yennefer loop.


PR created automatically by Jules for task 4533367094448095881 started by Igor Holt (@igor-holt)

Integrates the dynamically generated interactive 3D capabilities from
Google's Project Genie into the continuous Yennefer loop by updating
`scripts/genesis.cjs`. Mutates the `generateEvolutionComponent` to include
logic to force Genie-like continuous mutations. Update the path resolution
for mutations to be written directly to the `mutations/` directory rather
than `generated/`. Add sandbox/CI fallback for journal logging path.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
@google-labs-jules
Copy link
Copy Markdown

👋 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.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented May 2, 2026

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
yennefer ed27d61 Commit Preview URL May 02 2026, 08:13 AM

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces "GenieWorld" simulations, including dynamic landscapes and makerspace environments, and adds a fallback mechanism for the journal path to support CI environments. Feedback was provided to make the mutation selection logic more robust, optimize vertex manipulation performance in the landscape simulation, and ensure that additional meshes in the makerspace simulation correctly inherit parent transformations.

Comment thread scripts/genesis.cjs
Comment on lines +66 to +68
const idx = isGenieSim
? Math.floor(Math.random() * 2) + (mutations.length - 2)
: Math.floor(Date.now() / 1000) % mutations.length;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The logic for selecting Genie mutations is brittle as it relies on the assumption that they are always the last two elements of the mutations array. If the array is reordered or new mutations are appended, this logic will break or select incorrect prompts.

    const genieIndices = mutations.map((m, i) => m.content.includes("landscape") || m.content.includes("makerspace") ? i : -1).filter(i => i !== -1);
    const idx = isGenieSim && genieIndices.length > 0
        ? genieIndices[Math.floor(Math.random() * genieIndices.length)]
        : Math.floor(Date.now() / 1000) % mutations.length;

Comment thread scripts/genesis.cjs
Comment on lines +191 to +198
const positions = meshRef.current.geometry.attributes.position;
for (let i = 0; i < positions.count; i++) {
const x = positions.getX(i);
const y = positions.getY(i);
const z = Math.sin(x * 2 + state.clock.elapsedTime) * 0.5 + Math.cos(y * 2 + state.clock.elapsedTime) * 0.5;
positions.setZ(i, z * Math.min(1, balance * 2));
}
positions.needsUpdate = true;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Modifying geometry attributes by calling getX, getY, and setZ in a loop inside useFrame is inefficient for performance, especially as the number of segments increases. Accessing the underlying Float32Array directly is significantly faster.

      const attr = meshRef.current.geometry.attributes.position;
      const pos = attr.array;
      for (let i = 0; i < pos.length; i += 3) {
        const x = pos[i];
        const y = pos[i + 1];
        pos[i + 2] = (Math.sin(x * 2 + state.clock.elapsedTime) + Math.cos(y * 2 + state.clock.elapsedTime)) * 0.5 * Math.min(1, balance * 2);
      }
      attr.needsUpdate = true;

Comment thread scripts/genesis.cjs
Comment on lines +301 to +305
<mesh ref={meshRef}>
${geometry}
${material}
</mesh>
${additionalMeshes}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

In the makerspace simulation, the additionalMeshes (the red box and blue sphere) are currently siblings of the main mesh. Since the customLogic only applies rotation to meshRef.current, the workbench top will rotate while the objects on it remain static in mid-air. Moving them inside the main mesh component will ensure they inherit the parent's transformation.

      <mesh ref={meshRef}>
        ${geometry}
        ${material}
        ${additionalMeshes}
      </mesh>

Igor Holt (igor-holt) and others added 3 commits May 2, 2026 07:37
* Fix the CI failure by passing the `--legacy-peer-deps` flag to the npm install
* Prevent Cloudflare Workers Builds CI check failures by removing the placement mode.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
* Renames `workers/index.js` to `workers/index.mjs` to match the entry point ESM requirement.
* Modifies `wrangler.toml` to configure `workers/index.mjs` and compatibility date.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
* Update `wrangler.toml` to build from `yennefer-observatory` rather than `frontend` which was throwing errors.
* Sets static assets directory to `yennefer-observatory/dist`.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
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