Skip to content

A local plugin for image-heavy chats in Codex, Claude Code and other agents: earlier images stop going out with every message, and the model fetches the one it needs by its ID, also after compaction.

docs(readme): 加上按来源筛选;说明为什么只管图片

chipfighter6e5b20818934
diff --git a/README.md b/README.md
index a32c427..dda6606 100644
--- a/README.md
+++ b/README.md
@@ -29,6 +29,7 @@ So I wanted to keep the long conversation going and decide, turn by turn, which
## Features
- **Every image in one list**: a *Context Assets* tab in Codex's side panel lists every image in the task, turn by turn: the ones you uploaded and the ones the model viewed or generated, with thumbnails, IDs and sizes. Click one to preview it.
+- **Filter by source**: with many images, show only some sources: your uploads, PDF pages you commented on in Codex (with the page number and the PDF's name), web page screenshots, and images the model viewed, got from a tool or generated. Filtering changes what you see, never what is sent.
- **One click to leave an image out**: unchecked images become a short placeholder from the next message on. Toggle single images or a whole turn.
- **Duplicates handled**: when an identical image is still being sent, the placeholder points to it.
- **The model knows why**: a note tells the model the images were left out by you to save context, so its earlier answers still stand and it doesn't make up details it can't see.
@@ -85,6 +86,7 @@ The command installs the plugin with Codex's own CLI and sets up the proxy. Rest
1. Open **Context Assets** in the side panel of a task. On a new chat you can open it before the first message; it switches to the task once you send.
2. Uncheck the images you don't want to send anymore. Each change is saved at once and applies from the next message.
3. When the model replies `need IMG-xxx` for an unchecked image, a bar at the top of the panel lists it. Click the ID to jump to the image and check it.
+4. With many images, click the filter button next to refresh and pick the sources to show. A turn's checkbox then covers only the images shown.
## Uninstall
@@ -110,7 +112,7 @@ Your selections and logs stay in the data folder (see [Privacy](#privacy)); dele
## Good to know
-- Only images are managed for now; other file types may come later.
+- Only images are managed, because they are the only files that reach the model as they are. Codex doesn't send PDFs or videos themselves, only text the model extracts from them or images it makes of them, and those images are listed like any other. Audio waits for a Codex model that accepts it: until then, Codex replaces audio with a short note before sending.
- Results of Codex's built-in image generation can't be unchecked.
- If you uncheck an image while a turn is still running over WebSocket, the rest of that turn still carries the original. The panel tells you; the change applies from the next message.
- Enabling, disabling and upgrading take effect after you restart Codex.
diff --git a/README_CN.md b/README_CN.md
index 4cee27b..454602b 100644
--- a/README_CN.md
+++ b/README_CN.md
@@ -29,6 +29,7 @@
## 功能
- **所有图片一个列表**:Codex 右侧的侧边面板里多出一个“上下文素材”标签页,按轮次列出任务里的每张图,包括你上传的,以及模型查看、生成的,带缩略图、编号和大小,点开可以看大图。
+- **按来源筛选**:图多的时候,只看某几类:你上传的、在 Codex 里批注 PDF 时附上的页面(标出第几页和 PDF 文件名)、网页截图,以及模型查看的、工具返回的、生成的。筛选只改变面板里显示哪些,不影响发送。
- **点一下就不再发送**:取消勾选的图,从下一条消息起换成一小段占位文字。可以单张勾选,也可以整轮勾选。
- **重复的图自动处理**:有内容相同的图还在发送时,占位文字指向那一张。
- **模型知道原因**:一段说明告诉模型,这些图是你为了节省上下文省略的。它之前看着原图给出的回答仍然算数,也不会编造看不到的细节。
@@ -85,6 +86,7 @@ curl -fsSL https://github.com/chipfighter/codex-attachment-manager/releases/late
1. 在任务的侧边面板里打开**上下文素材**。新任务也可以在发第一条消息之前打开:发出消息后,面板会自动切到这个任务。
2. 取消勾选不想再发送的图。每次改动立刻保存,从下一条消息起生效。
3. 模型回复“需要 IMG-xxx”、而那张图没有勾上时,面板顶部会列出它。点编号跳到那张图,勾上即可。
+4. 图多的时候,点刷新旁边的筛选按钮,选要看的来源。这时整轮勾选只管显示出来的图。
## 卸载
@@ -110,7 +112,7 @@ curl -fsSL https://github.com/chipfighter/codex-attachment-manager/releases/late
## 一点补充
-- 目前只管理图片,其他类型的文件以后再支持。
+- 只管理图片,因为只有图片会原样发给模型。Codex 不发送 PDF 和视频文件本身,只发送模型从中提取的文字或转成的图片,这些图片会和其他图一起列出来。音频要等 Codex 上有能直接听音频的模型:在那之前,Codex 会在发送前把音频换成一句说明。
- Codex 自带生图工具的结果不能取消。
- 取消勾选时,如果这一轮还在进行,并且走的是 WebSocket,这一轮剩下的请求仍会带着原图。面板会提示,从下一条消息起生效。
- 启用、停用和升级,都要重启 Codex 才生效。