[GH-ISSUE #6049] [Issue]: Scene Analysis inherits main RP provider configuration #3354

Closed
opened 2026-10-21 06:02:16 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @SpicyMarinara on GitHub (Sep 10, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6049

Originally assigned to: @Romuromylus on GitHub.

Summary

In Game Mode, Scene Analysis appears to inherit the provider configuration from the main RP connection instead of using its own agent connection configuration. This causes agent requests to fail for providers that reject the inherited or injected provider field.

Expected behavior

Scene Analysis should use the model and provider configuration of its own connection independently of the main RP connection. A main RP connection configured for Opus 4.6 through Google Vertex should not affect an agent configured for GLM 5.3/5.3 Flash through OpenRouter, or an agent using Google Gemini without a provider restriction.

Actual behavior

With the main RP connection set to Opus 4.6 through Anthropic with Google Vertex as the only allowed provider, Scene Analysis configured for GLM 5.3/5.3 Flash through OpenRouter fails with OpenRouter API error 404: No allowed providers are available for the selected model even though the agent connection has no provider restriction. A Google Gemini agent connection also fails with Gemini API error 400: Invalid JSON payload received. Unknown name "provider": Cannot find field. Both failures occur through runGameChatComplete in game.routes.js around line 2381, before provider-specific completion logic.

Steps to reproduce

  1. Configure the main RP connection to use Opus 4.6 through Anthropic with Google Vertex as the only allowed provider.
  2. Configure the Scene Analysis agent connection to use GLM 5.3/5.3 Flash through OpenRouter with no provider restriction.
  3. Verify that both connections work independently when tested separately.
  4. Run Scene Analysis in Game Mode.
  5. Observe the OpenRouter 404 error stating that no allowed providers are available for the selected model.
  6. Alternatively, configure the Scene Analysis agent to use Google Gemini without a provider and run Scene Analysis.
  7. Observe the Gemini 400 error reporting an invalid provider field.

Environment

  • Marinara Engine version: 2.4.5+1411d71dadbc (version 2.4.5, commit 1411d71dad)
  • Install type: termux
  • OS + version: Server: Android / Termux 6.1.145-android14-11-33419968-abS928BXXS6DZH2 (arm64); Client: Android 10
  • Browser or app shell: SamsungBrowser 30.0 / Chrome 143.0.0.0 mobile WebKit app shell

Logs, screenshots, or video

Full console log attached as text.txt: https://cdn.discordapp.com/attachments/1547629519949660241/1547629856991477790/text.txt?ex=6aa41e1f&is=6aa2cc9f&hm=cdc059964b6d3a98c01c339679cea0adf343b4462f4b20359510d1f28c0383f1&. Reported errors: OpenRouter API 404 for z-ai/glm-5.3-20260816; Gemini API 400 for an unknown provider field.

Additional context

The issue does not occur with Anthropic models or APIs/models that appear to silently ignore the provider field, such as DeepSeek. The suspected cause is that the main RP connection's provider value is propagated into the Scene Analysis agent request, overriding or incorrectly populating the agent connection's provider configuration. The Discord context does not provide the Scene Analysis agent version.

Discord thread: Bug report - Scene analysis fails due to provider issue
Discord thread link: https://discord.com/channels/1417099416812392641/1547629519949660241
Requested by: Kuc0 (kuc0, Discord ID 108988150629531648)

Discord thread transcript (5 messages)
[2026-09-10T15:27:11.122Z] Fussel: Summary

In Game Mode, Scene Analysis appears to incorrectly inherit the "provider" configuration from the main RP connection when making its agent request.

Setup

Main RP connection:

- Opus 4.6
- Anthropic connection
- Allowed provider: Google Vertex only

Scene Analysis agent connection:

- GLM 5.3/5.3 Flash
- OpenRouter
- No provider restriction

Both connections work successfully when tested independently.

Issue

Scene Analysis fails with OpenRouter:

OpenRouter API error 404: No allowed providers are available for the selected model.
Providers serving z-ai/glm-5.3-20260816: reka, streamlake, novita, ...

The behavior suggests the agent request is inheriting a provider restriction from the main RP connection rather than using the agent connection's configuration.

The same issue occurs with a Google Gemini connection as the agent. In that case, the request fails with:

Gemini API error 400: Invalid JSON payload received.
Unknown name "provider": Cannot find field.

The Gemini connection does not specify a provider, suggesting that a "provider" field is being injected into the agent request regardless.

Both errors occur through "runGameChatComplete" in "game.routes.js" (around line 2381), before reaching the provider-specific completion logic.

Expected behavior

The Scene Analysis agent should use the model and provider configuration of its own connection independently of the main RP connection.

For example:

Main RP: Opus 4.6 → Google Vertex
Agent: GLM 5.3/5.3 Flash → OpenRouter

Additional observations

The issue does not occur with Anthropic models or APIs/models that appear to silently ignore the "provider" field (e.g. DeepSeek).

Suspected cause: The main RP connection's "provider" value is being propagated into the Scene Analysis agent request, overriding or incorrectly populating the agent connection's provider configuration.

More info below:
[Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547629519949660241]

[2026-09-10T15:27:11.970Z] Professor Mari [bot]: Howdy!

Thank you for submitting a new bug report/feature request, your support means a lot. A member of the team will look into it as soon as possible, and if they find it valid, they will open a GitHub Issue out of it. You can check whether it was addressed on the staging build of Marinara Engine. **Do not ping any of the developers, this will not speed up the process.**

**Please include a Support Diagnostic in the post if you haven't done it yet.** Otherwise, ignore this step. To grab it, go to the Marinara Engine tab:

`Settings -> Advanced -> Support Diagnostics -> Copy Support Diagnostics.`

If your report is about any of the **Agents**, please provide **the Agent's version** which you can grab from here:

`Agents -> Download Agents -> Installed Agents -> Selected Agent -> Installed Version`

Thank you, this will help tremendously.

This is an automated message, but if you reply to it, I will do my best to assist you using my LLM-powered brain. That said, it's best for a human to handle this case.

Cheers!
[Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547629523506438204]

[2026-09-10T15:28:31.572Z] Fussel: Full console log
[attached file: text.txt — https://cdn.discordapp.com/attachments/1547629519949660241/1547629856991477790/text.txt?ex=6aa41e1f&is=6aa2cc9f&hm=cdc059964b6d3a98c01c339679cea0adf343b4462f4b20359510d1f28c0383f1&]
[Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547629857381421197]

[2026-09-10T15:29:36.247Z] Fussel: Marinara Engine diagnostics
Version: 2.4.5
Build: 2.4.5+1411d71dadbc
Commit: 1411d71dadbc
Server OS: Android / Termux 6.1.145-android14-11-33419968-abS928BXXS6DZH2 (arm64)
Server memory: heap 131.3 / 1120 MiB; RSS 172.3 MiB
Background wake lock: acquired
Last detected freeze: none detected
Previous session: ended without shutting down - last alive 2026-09-10T14:27:46.143Z (up 32m, RSS 160.3 MiB); device rebooted before next launch: yes
Sessions ended without shutdown: 10 recorded
Client OS: Android 10
Browser / app shell: Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/30.0 Chrome/143.0.0.0 Mobile Safari/537.36
GPU: Adreno (TM) 750
Active connection: Opus 4.6
Connection provider: anthropic
LLM model: claude-opus-4-6
Mari last acted on: none recorded this session
Client runtime:
[Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547630128648036362]

[2026-09-10T15:29:39.882Z] Fussel: {"build":"2.4.5+1411d71dadbc","page":"mtvomxhr-7m66mkkt","persistence":"local","navigation":"back_forward","standalone":false,"view":[878,0,878,0],"events":[{"at":1789051628089,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[985,0,985,0]},{"at":1789051632265,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051636728,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051637398,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051668941,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051669848,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051721160,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051760851,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051903626,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051904471,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789052016006,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789052016978,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789052572443,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789052573489,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789054129935,"page":"mtvomxhr-7m66mkkt","build":"2.4.5+1411d71dadbc","kind":"page-start","view":[878,0,878,0]},{"at":1789054129939,"page":"mtvomxhr-7m66mkkt","build":"2.4.5+1411d71dadbc","kind":"page-show","view":[878,0,878,0]}]}
[Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547630143894331453]

Template check

Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @SpicyMarinara on GitHub (Sep 10, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6049 Originally assigned to: @Romuromylus on GitHub. ## Summary In Game Mode, Scene Analysis appears to inherit the provider configuration from the main RP connection instead of using its own agent connection configuration. This causes agent requests to fail for providers that reject the inherited or injected provider field. ## Expected behavior Scene Analysis should use the model and provider configuration of its own connection independently of the main RP connection. A main RP connection configured for Opus 4.6 through Google Vertex should not affect an agent configured for GLM 5.3/5.3 Flash through OpenRouter, or an agent using Google Gemini without a provider restriction. ## Actual behavior With the main RP connection set to Opus 4.6 through Anthropic with Google Vertex as the only allowed provider, Scene Analysis configured for GLM 5.3/5.3 Flash through OpenRouter fails with `OpenRouter API error 404: No allowed providers are available for the selected model` even though the agent connection has no provider restriction. A Google Gemini agent connection also fails with `Gemini API error 400: Invalid JSON payload received. Unknown name "provider": Cannot find field.` Both failures occur through `runGameChatComplete` in `game.routes.js` around line 2381, before provider-specific completion logic. ## Steps to reproduce 1. Configure the main RP connection to use Opus 4.6 through Anthropic with Google Vertex as the only allowed provider. 2. Configure the Scene Analysis agent connection to use GLM 5.3/5.3 Flash through OpenRouter with no provider restriction. 3. Verify that both connections work independently when tested separately. 4. Run Scene Analysis in Game Mode. 5. Observe the OpenRouter 404 error stating that no allowed providers are available for the selected model. 6. Alternatively, configure the Scene Analysis agent to use Google Gemini without a provider and run Scene Analysis. 7. Observe the Gemini 400 error reporting an invalid `provider` field. ## Environment - Marinara Engine version: 2.4.5+1411d71dadbc (version 2.4.5, commit 1411d71dadbc) - Install type: termux - OS + version: Server: Android / Termux 6.1.145-android14-11-33419968-abS928BXXS6DZH2 (arm64); Client: Android 10 - Browser or app shell: SamsungBrowser 30.0 / Chrome 143.0.0.0 mobile WebKit app shell ## Logs, screenshots, or video Full console log attached as `text.txt`: https://cdn.discordapp.com/attachments/1547629519949660241/1547629856991477790/text.txt?ex=6aa41e1f&is=6aa2cc9f&hm=cdc059964b6d3a98c01c339679cea0adf343b4462f4b20359510d1f28c0383f1&. Reported errors: OpenRouter API 404 for `z-ai/glm-5.3-20260816`; Gemini API 400 for an unknown `provider` field. ## Additional context The issue does not occur with Anthropic models or APIs/models that appear to silently ignore the `provider` field, such as DeepSeek. The suspected cause is that the main RP connection's provider value is propagated into the Scene Analysis agent request, overriding or incorrectly populating the agent connection's provider configuration. The Discord context does not provide the Scene Analysis agent version. Discord thread: Bug report - Scene analysis fails due to provider issue Discord thread link: https://discord.com/channels/1417099416812392641/1547629519949660241 Requested by: Kuc0 (kuc0, Discord ID 108988150629531648) <details> <summary>Discord thread transcript (5 messages)</summary> ```text [2026-09-10T15:27:11.122Z] Fussel: Summary In Game Mode, Scene Analysis appears to incorrectly inherit the "provider" configuration from the main RP connection when making its agent request. Setup Main RP connection: - Opus 4.6 - Anthropic connection - Allowed provider: Google Vertex only Scene Analysis agent connection: - GLM 5.3/5.3 Flash - OpenRouter - No provider restriction Both connections work successfully when tested independently. Issue Scene Analysis fails with OpenRouter: OpenRouter API error 404: No allowed providers are available for the selected model. Providers serving z-ai/glm-5.3-20260816: reka, streamlake, novita, ... The behavior suggests the agent request is inheriting a provider restriction from the main RP connection rather than using the agent connection's configuration. The same issue occurs with a Google Gemini connection as the agent. In that case, the request fails with: Gemini API error 400: Invalid JSON payload received. Unknown name "provider": Cannot find field. The Gemini connection does not specify a provider, suggesting that a "provider" field is being injected into the agent request regardless. Both errors occur through "runGameChatComplete" in "game.routes.js" (around line 2381), before reaching the provider-specific completion logic. Expected behavior The Scene Analysis agent should use the model and provider configuration of its own connection independently of the main RP connection. For example: Main RP: Opus 4.6 → Google Vertex Agent: GLM 5.3/5.3 Flash → OpenRouter Additional observations The issue does not occur with Anthropic models or APIs/models that appear to silently ignore the "provider" field (e.g. DeepSeek). Suspected cause: The main RP connection's "provider" value is being propagated into the Scene Analysis agent request, overriding or incorrectly populating the agent connection's provider configuration. More info below: [Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547629519949660241] [2026-09-10T15:27:11.970Z] Professor Mari [bot]: Howdy! Thank you for submitting a new bug report/feature request, your support means a lot. A member of the team will look into it as soon as possible, and if they find it valid, they will open a GitHub Issue out of it. You can check whether it was addressed on the staging build of Marinara Engine. **Do not ping any of the developers, this will not speed up the process.** **Please include a Support Diagnostic in the post if you haven't done it yet.** Otherwise, ignore this step. To grab it, go to the Marinara Engine tab: `Settings -> Advanced -> Support Diagnostics -> Copy Support Diagnostics.` If your report is about any of the **Agents**, please provide **the Agent's version** which you can grab from here: `Agents -> Download Agents -> Installed Agents -> Selected Agent -> Installed Version` Thank you, this will help tremendously. This is an automated message, but if you reply to it, I will do my best to assist you using my LLM-powered brain. That said, it's best for a human to handle this case. Cheers! [Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547629523506438204] [2026-09-10T15:28:31.572Z] Fussel: Full console log [attached file: text.txt — https://cdn.discordapp.com/attachments/1547629519949660241/1547629856991477790/text.txt?ex=6aa41e1f&is=6aa2cc9f&hm=cdc059964b6d3a98c01c339679cea0adf343b4462f4b20359510d1f28c0383f1&] [Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547629857381421197] [2026-09-10T15:29:36.247Z] Fussel: Marinara Engine diagnostics Version: 2.4.5 Build: 2.4.5+1411d71dadbc Commit: 1411d71dadbc Server OS: Android / Termux 6.1.145-android14-11-33419968-abS928BXXS6DZH2 (arm64) Server memory: heap 131.3 / 1120 MiB; RSS 172.3 MiB Background wake lock: acquired Last detected freeze: none detected Previous session: ended without shutting down - last alive 2026-09-10T14:27:46.143Z (up 32m, RSS 160.3 MiB); device rebooted before next launch: yes Sessions ended without shutdown: 10 recorded Client OS: Android 10 Browser / app shell: Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/30.0 Chrome/143.0.0.0 Mobile Safari/537.36 GPU: Adreno (TM) 750 Active connection: Opus 4.6 Connection provider: anthropic LLM model: claude-opus-4-6 Mari last acted on: none recorded this session Client runtime: [Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547630128648036362] [2026-09-10T15:29:39.882Z] Fussel: {"build":"2.4.5+1411d71dadbc","page":"mtvomxhr-7m66mkkt","persistence":"local","navigation":"back_forward","standalone":false,"view":[878,0,878,0],"events":[{"at":1789051628089,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[985,0,985,0]},{"at":1789051632265,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051636728,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051637398,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051668941,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051669848,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051721160,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051760851,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789051903626,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789051904471,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789052016006,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789052016978,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789052572443,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"visible","view":[878,0,878,0]},{"at":1789052573489,"page":"mtvmnz8q-qr72kjvp","build":"2.4.5+1411d71dadbc","kind":"hidden","view":[878,0,878,0]},{"at":1789054129935,"page":"mtvomxhr-7m66mkkt","build":"2.4.5+1411d71dadbc","kind":"page-start","view":[878,0,878,0]},{"at":1789054129939,"page":"mtvomxhr-7m66mkkt","build":"2.4.5+1411d71dadbc","kind":"page-show","view":[878,0,878,0]}]} [Discord message: https://discord.com/channels/1417099416812392641/1547629519949660241/1547630143894331453] ``` </details> ## Template check Please **uncheck (untick)** the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-10-21 06:02:16 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@Romuromylus commented on GitHub (Sep 11, 2026):

Fixed by #6059, merged into staging as fe1650e9f.

<!-- gh-comment-id:5637076426 --> @Romuromylus commented on GitHub (Sep 11, 2026): Fixed by #6059, merged into `staging` as fe1650e9f.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#3354
No description provided.