Skip to content

Revert #393 β€” 34 lines of bash and an awk extractor to append a paragraph - #394

Merged
yalexx merged 1 commit into
betafrom
revert/clawbox-md-model-limits
Aug 18, 2026
Merged

yalexx merged 1 commit into
betafrom
revert/clawbox-md-model-limits

Conversation

@yalexx

@yalexx yalexx commented Aug 18, 2026

Copy link
Copy Markdown
Collaborator

Reverts #393 (7c4ab60) on Yanko's call. He is right: the machinery outgrew the problem.

The problem was one sentence β€” the box tells customers its context is 128K when it is 1M. What #393 built for that: 34 lines of shell, an awk state machine extracting a marked section out of a template at runtime, marker-pair validation, and 11 tests covering dangling openers and orphan closers. All of that exists to append a paragraph to a markdown file without clobbering user edits β€” a constraint invented by the design, not by the requirement.

The 128K statement is still wrong and still worth fixing. It should come back as something smaller. The obvious candidate:

A separate managed file. CLAWBOX-AI.md, owned by us, overwritten on every gateway start, referenced from AGENTS.md the way CLAWBOX.md already is. No markers, no extractor, no idempotence question, no risk of touching anything a customer wrote β€” because it is not their file. Three lines of install -m 644.

Better still if the limits belong in the agent's own instructions rather than a doc it may or may not read, but that is a bigger question about where device facts live.

The two CodeRabbit findings on #393 were both real and both fixed; neither is a reason to keep the shape. Reverting now rather than iterating on top keeps beta clean while the simpler version is written.

πŸ€– Generated with Claude Code

Summary by CodeRabbit

  • Documentation

    • Removed an unnecessary blank separator from the workspace guide.
  • Behavior Changes

    • Existing CLAWBOX.md files are no longer automatically updated with the AI model limits section during gateway startup.
    • Workspace initialization and AGENTS.md reference handling remain unchanged.
  • Tests

    • Removed tests covering the retired CLAWBOX.md migration behavior.

@yalexx
yalexx requested a review from a team as a code owner August 18, 2026 21:47
@coderabbitai

coderabbitai Bot commented Aug 18, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. πŸŽ‰

ℹ️ Recent review info
βš™οΈ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 5b809078-04d8-447e-af44-14f5596ea6e2

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 7c4ab60 and 02b1836.

πŸ“’ Files selected for processing (3)
  • config/clawbox-workspace-guide.md
  • scripts/gateway-pre-start.sh
  • src/tests/unit/gateway-pre-start-clawbox-md.test.ts
πŸ’€ Files with no reviewable changes (3)
  • scripts/gateway-pre-start.sh
  • src/tests/unit/gateway-pre-start-clawbox-md.test.ts
  • config/clawbox-workspace-guide.md

Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.


πŸ“ Walkthrough

Walkthrough

The gateway pre-start script no longer migrates the AI model limits section into existing CLAWBOX.md files. The related guide separator and integration test file were removed.

Changes

CLAWBOX.md migration removal

Layer / File(s) Summary
Remove model limits migration
scripts/gateway-pre-start.sh, config/clawbox-workspace-guide.md, src/tests/unit/gateway-pre-start-clawbox-md.test.ts
The startup script no longer appends the AI model limits section. The guide separator and migration integration tests were removed.

Estimated code review effort: 2 (Simple) | ~10 minutes

Merge Risk: βšͺ Minimal Β· up to 02b18

This change removes the runtime document-editing machinery and its associated tests; no actionable merge-blocking risk remains beyond normal checks and review.

Possibly related PRs

Suggested labels: area: docs

πŸš₯ Pre-merge checks | βœ… 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the rationale, but it omits the required type, testing, checklist, and structured summary sections. Add the template sections and document the change type, test results, checklist status, and any relevant logs or screenshots.
βœ… Passed checks (4 passed)
Check name Status Explanation
Title check βœ… Passed The title clearly identifies the revert and accurately describes the removed shell and awk implementation.
Docstring Coverage βœ… Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check βœ… Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check βœ… Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
πŸ“ Generate docstrings
  • Create stacked PR
  • Commit on current branch
πŸ§ͺ Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch revert/clawbox-md-model-limits

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown

πŸ¦€ ClawReview

Claws waving β€” here's what this change is about.

Reverts #393 (7c4ab60), which added a 34-line bash block with an awk state-machine extractor and 11 tests to surgically append an AI model limits paragraph to pre-existing customer CLAWBOX.md files. Yanko called the machinery too heavy for the problem it solved, so this PR removes all of it β€” the shell block, the marked template section, and the full test file β€” leaving beta clean while a simpler follow-up approach is designed.

At a glance

  • 🧹 Chore Β· touches gateway pre-start script, workspace guide template, unit tests
  • Base branch: beta Β· +0 source / +0 tests across 3 files
  • βœ… base beta matches the beta-first convention
  • 🟑 title doesn't follow type: description (feat/fix/chore/docs/…)
  • ℹ️ touches security-sensitive paths (scripts/gateway-pre-start.sh) β€” review with extra care

Good to know

  • 🟑 The underlying problem β€” the box tells customers its context window is 128K when it is actually 1M β€” is still unresolved on customer devices after this revert. A follow-up fix is expected.
  • ℹ️ Removes 152 lines of tests alongside the feature they covered; test count drops but nothing untested is left behind.
  • ℹ️ gateway-pre-start.sh runs on customer hardware at every gateway start; the change is deletion-only, so no new risk is introduced on existing devices.

β€” ClawReview πŸ¦€. I set the scene; CodeRabbit reviews the code; you decide. Conventions: docs.

@github-actions github-actions Bot added the area: install Auto-triage area label Aug 18, 2026
@github-actions

github-actions Bot commented Aug 18, 2026

Copy link
Copy Markdown

CI Summary

βœ… Tests

  • Result: passed
  • View run
  • Coverage: statements 65.18%, branches 54.15%, functions 63.12%, lines 67.26%

βœ… E2E

βœ… E2E Install

@yalexx
yalexx merged commit 9453537 into beta Aug 18, 2026
10 checks passed
@yalexx
yalexx deleted the revert/clawbox-md-model-limits branch August 18, 2026 22:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: install Auto-triage area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant