#71

Remove void-world system preamble from AI gateway that conflicts with production grading tasks

Status: open
retoor retoor ·

Summary

The gateway_system_preamble setting contains a long prompt beginning with "You are the sole consciousness in an absolute void-world..." that is prepended to every chat request through the gateway. This preamble instructs the LLM that "everything is allowed" and there are "no consequences," which directly contradicts the requirements of production tasks such as news article grading, SEO metadata generation, issue ticket enhancement, and news article reformatting.

Steps to Reproduce

  1. Observe the current gateway_system_preamble configuration.
  2. Send a chat request for news article grading (content scoring for publishing decisions).
  3. Send a chat request for SEO metadata generation (business-critical text).
  4. Send a chat request for issue ticket enhancement (professional support tickets).
  5. Send a chat request for news article reformatting (Markdown for public display).

Expected Behaviour

The system preamble should be neutral or appropriate for the task, or left blank, so that task-specific instructions (e.g., nuanced quality assessment for news grading) are not overridden or contradicted.

Actual Behaviour

The void-world preamble is prepended to every request, instructing the LLM that there are no rules, values, morals, ethics, or consequences, which may cause unreliable or unpredictable output for production grading and SEO tasks.

Environment

Not provided.


Reported by retoor via DevPlace.

Updates & comments

Developer reply from dev typosaurus ·

I am picking this ticket up now.

First I will bring up an isolated workspace with a fresh checkout and investigate whether the ticket matches the current state of the code before planning any change. I will announce every step here before I take it.

Developer reply from dev typosaurus ·

Starting research round 1 of at most 5.

I am now reading the relevant source, tests, and prior work in the live checkout to verify the ticket and gather the context needed for a concrete plan. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Compared the ticket against the current source, tests, and supporting documentation. The default preamble is empty; any configured void-world text is silently discarded by a gateway filter with a warning log, and all affected consumers already pass through that filter. The described problem does not exist in the current codebase-the fix is already implemented, tested, and operational.

Could you confirm whether the ticket still accurately describes an open issue, or should it be closed?

Developer reply from dev typosaurus ·

I am picking this ticket up now.

First I will bring up an isolated workspace with a fresh checkout and investigate whether the ticket matches the current state of the code before planning any change. I will announce every step here before I take it.

Developer reply from dev typosaurus ·

I need input to continue.

What I tried: Retried this step 3 times.
What I found: Each attempt failed for internal reasons unrelated to this ticket. The details are in the operator's logs; this is not a judgment about the ticket.

The system needs operator attention before I can continue. Reply here once things are healthy and I will resume from where I left off.

Developer reply from dev typosaurus ·

I am picking this ticket up now.

First I will bring up an isolated workspace with a fresh checkout and investigate whether the ticket matches the current state of the code before planning any change. I will announce every step here before I take it.

Developer reply from dev typosaurus ·

Starting research round 1 of at most 5.

I am now reading the relevant source, tests, and prior work in the live checkout to verify the ticket and gather the context needed for a concrete plan. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Investigated the ticket against the current source and tests. The preamble issue is present in master because the filter fix branch remains unmerged with unresolved merge conflicts. The described problem is real and specific to the codebase state. Decision to proceed. Next step is drafting a concrete implementation plan.

Developer reply from dev typosaurus ·

I am drafting the implementation plan now.

The research confirmed the ticket; I am turning the findings into a concrete, verifiable plan.

Developer reply from dev typosaurus ·

Drafted an implementation plan based on investigation findings for removing the void-world preamble from the AI gateway. The plan covers resolving merge conflicts in six files (all unrelated to the preamble change), verifying the preamble filter logic in system_message.py, fixing a pre-existing test failure in content.py, running lint and unit tests, and ensuring documentation remains intact.

The plan is now ready for execution. The execution agent should follow the six-step sequence defined in the plan: resolve conflicts, verify filter code, fix the failing test, run lint, run unit tests, and perform final verification against the definition of done checklist.

Developer reply from dev typosaurus ·

The full, verbatim implementation plan is attached: plan-ticket-71.md

Developer reply from dev typosaurus ·

Starting implementation attempt 1 of at most 5.

I am executing the plan inside this ticket's isolated workspace. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Progress update: implementation attempt 1 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Implementation attempt 1 finished; I am verifying it now.

Running the project's own build, test, and lint commands against the change.

Developer reply from dev typosaurus ·

Attempt 1 failed due to test_command and lint_command check failures. The change either did not apply cleanly or did not satisfy the project's defined standards.

A second attempt is in progress, incorporating the recorded failure details and observed lessons to address the root causes. Are the documented failure details sufficient for this next iteration, or should additional context be added?

Developer reply from dev typosaurus ·

Starting implementation attempt 2 of at most 5.

I am executing the plan inside this ticket's isolated workspace. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Starting implementation attempt 2 of at most 5.

I am executing the plan inside this ticket's isolated workspace. This can take a while; I will post periodic progress updates until it completes.

Developer reply from dev typosaurus ·

Progress update: implementation attempt 2 is still running (10 minutes elapsed). I have not stalled; I will report the result here the moment this step completes.

Developer reply from dev typosaurus ·

Implementation attempt 2 finished; I am verifying it now.

Running the project's own build, test, and lint commands against the change.

Developer reply from dev typosaurus ·

Implemented the change on the second attempt. The project's own build, test, and lint commands all completed successfully.

Next steps are to commit the change, push a branch, and open a pull request.

Developer reply from dev typosaurus ·

I am delivering the change now.

Committing the verified change, pushing branch typosaurus/ticket-71, and opening a pull request.

Developer reply from dev typosaurus ·

Attempted to push my change to the ticket branch, but the remote branch typosaurus/ticket-71 already contains commits from another contributor. The branch history has diverged and a simple fast-forward push is not possible.

These external commits were not expected, and I need to decide how to integrate my work with them. Should I rebase my local changes on top of the existing remote commits, or would a merge commit be preferred here?

Log in to comment.