shareAI-lab / shareAI-lab/learn-claude-code

[Discussion] Design Concerns about Context Compression (s06) and Task System (s07) / 关于s06 与 s07 一些异见与讨论,欢迎交流

Open
#174 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

discussion
Dominant language
Python
Stars
77.2k
Forks
12.4k
Avg merge
2d 5h
Merged PRs (30d)
6

Description

关于 s06 上下文压缩 / On s06 Context Compression

micro_compact 的实现过于粗暴,对所有 tool_result 一视同仁地替换为占位符。这种粒度忽略了重要结果的保留需求,比如 subagent 返回的阶段性结论。建议引入重要性标记机制。
compact 工具缺少明确的触发提示,LLM 难以判断何时需要主动压缩。建议在系统层面提供 token 计数等元信息,让 agent 有状态感知。

The micro_compact approach is overly aggressive, treating all tool results equally. This granularity ignores the need to preserve important results, such as subagent conclusions. A priority/preservation mechanism would be more robust.
The compact tool lacks clear triggering cues, making it hard for LLMs to know when to compress. Suggest exposing metadata like token count at the system level for better situational awareness.


关于 s07 任务系统 / On s07 Task System

DAG 模式不符合 LLM 的认知特点。LLM 天然是线性思维,强行引入"与或非"逻辑判断会显著增加任务管理出错概率,且 DAG 一旦出错极难回滚。
多 agent 场景下,DAG 应该由编排系统维护,LLM 退化为执行单元。
Subagent 场景更不需要显式依赖管理,主 agent 只需等待结果即可。
这个设计更像传统工程思维,而非 agentic 范式。
建议回归扁平列表 + 隐式依赖的简单模式。
“少即是多”。

The DAG pattern doesn't align with LLM cognition. LLMs naturally think linearly; introducing AND/OR/NOT logic significantly increases error rates in task management, and DAG errors are hard to rollback.
In multi-agent scenarios, DAG should be managed by orchestration systems, with LLMs acting as execution units. Subagent flows need no explicit dependency management—just wait for results.
This design reflects traditional engineering thinking rather than an agentic paradigm. Suggest returning to flat lists with implicit dependencies for simplicity.
"Less is more".

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the s06 micro_compact and compact entry points and the s07 task-system implementation; no file or test is named in the issue. A contribution would need a settled design and explicit acceptance criteria before implementation can be considered done.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
ai
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.