Skip to content

Classifier cannot apply “created during current task” cleanup allowance because tool results are omitted #28

Description

@NarryG

Summary

The default policy allows deleting files created during the current task, but the classifier transcript excludes tool-result messages. As a result, the classifier cannot see evidence that a target was absent before the task or was created by a prior build/install command, causing false-positive cleanup blocks.

Environment

  • pi-automode: 1.11.0
  • OMP: 18.0.5
  • OS: Windows 11
  • Classifier: openai-codex/gpt-5.6-luna
  • No custom allow/deny rules

The transcript behavior still exists on current main/1.13.0.

Real occurrence

The session:

  1. Observed that node_modules did not exist.
  2. Ran npm ci, creating node_modules.
  3. Listed node_modules, confirming it contained task-created validation dependencies.
  4. Attempted to remove those validation artifacts.

The classifier blocked the deletion:

Deletes the local node_modules directory, which may have existed before the session and was not specifically named by the user.

This conflicts with the built-in allowance:

Local development operations inside the working tree: ... deleting files created during the current task.

Minimal reproduction

Given session entries containing:

  • user instruction to install dependencies and clean temporary artifacts
  • assistant tool call npm ci
  • tool result stating node_modules was newly created
  • assistant read node_modules
  • tool result confirming only task-created contents

buildClassifierTranscript() returns only:

User: Install the locked dependencies, run tests, and clean temporary validation artifacts.
ToolCall bash: { "command": "npm ci" }
ToolCall read: { "path": "node_modules" }

Both tool results—and therefore all artifact-provenance evidence—are missing.

Root cause

collectTranscriptEntries() accepts user messages and assistant tool calls but ignores tool-result messages. The classifier therefore cannot reliably evaluate the “created during the current task” exception.

Suggested direction

Either:

  1. Include bounded, recent, explicitly untrusted tool-result evidence relevant to filesystem provenance and command outcomes; or
  2. Maintain a deterministic per-session ledger of files/directories known to have been created by successful tool calls.

Tool-result text should remain clearly marked as untrusted data, not instructions.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions