Skip to content

feat: rebrand tinyclaw to tinyagi#191

Merged
jlia0 merged 7 commits intomainfrom
jlia0/rebrand-tinyagi
Mar 18, 2026
Merged

feat: rebrand tinyclaw to tinyagi#191
jlia0 merged 7 commits intomainfrom
jlia0/rebrand-tinyagi

Conversation

@jlia0
Copy link
Copy Markdown
Collaborator

@jlia0 jlia0 commented Mar 11, 2026

Summary

Complete rebrand from TinyClaw to TinyAGI across the entire codebase. Renames all package names, environment variables, CLI commands, configuration directories, and documentation to reflect the new project name.

Changes

  • Package names: @tinyclaw/* → @tinyagi/* (all workspace packages)
  • Environment variables: TINYCLAW_* → TINYAGI_* (TINYAGI_HOME, etc.)
  • CLI entry point: tinyclaw → tinyagi command
  • Configuration directory: .tinyclaw/ → .tinyagi/
  • Database filename: tinyclaw.db → tinyagi.db
  • Skill directory: tinyclaw-admin → tinyagi-admin
  • Documentation: Updated all examples, URLs, and references (README, docs/, etc.)
  • Migration script: Added scripts/migrate.sh to safely transition existing installations

Testing

  • TypeScript builds cleanly with no errors
  • Zero remaining "tinyclaw" references in codebase (verified with case-insensitive grep)
  • package-lock.json regenerated with new package names
  • Migration script handles existing ~/.tinyclaw → ~/.tinyagi transition + database rename

Checklist

  • PR title follows conventional commit format
  • TypeScript compiles without errors
  • All references updated (content + filenames)
  • Migration script created for existing users
  • Documentation updated

Rename all references from tinyclaw/TinyClaw/TINYCLAW to
tinyagi/TinyAGI/TINYAGI across the entire codebase:

- Package names: @tinyclaw/* → @tinyagi/*
- Config directory: .tinyclaw/ → .tinyagi/
- Environment variables: TINYCLAW_* → TINYAGI_*
- CLI entry point: tinyclaw → tinyagi
- Database file: tinyclaw.db → tinyagi.db
- Skill directory: tinyclaw-admin → tinyagi-admin

Adds scripts/migrate.sh for existing installations to safely
rename ~/.tinyclaw → ~/.tinyagi, migrate the database, and
clean up old CLI symlinks.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@jlia0 jlia0 requested a review from mczabca-boop March 11, 2026 19:50
@greptile-apps
Copy link
Copy Markdown

greptile-apps bot commented Mar 11, 2026

Greptile Summary

This PR performs a complete rebrand of the project from TinyClaw to TinyAGI across 83 files. It renames all package names (@tinyclaw/*@tinyagi/*), environment variables (TINYCLAW_*TINYAGI_*), CLI commands (tinyclawtinyagi), configuration/data directories (~/.tinyclaw~/.tinyagi), the database filename (tinyclaw.dbtinyagi.db), the tmux session name, and all documentation, URLs, and user-facing strings. A new scripts/migrate.sh is introduced to help existing users transition their installation.

Key observations:

  • The rename is thorough and mechanically consistent across shell scripts, TypeScript source, CI/CD workflows, and documentation.
  • The new bin/tinyagi wrapper, tinyagi.sh entry point, and scripts/install.sh are all internally coherent.
  • The release workflow correctly produces tinyagi-bundle.tar.gz and the remote installer fetches it via --strip-components=1, so bundle extraction is compatible with the renamed inner directory.
  • One logic bug was found in scripts/migrate.sh (Step 2, database rename): the elif branch that warns users when both tinyclaw.db and tinyagi.db coexist is dead code and will never be reached. The preceding elif [ -f "$DATA_DIR/$NEW_DB" ] catches that case first, silently printing "skipping" instead of the intended warning.

Confidence Score: 4/5

  • This PR is safe to merge with one minor fix needed in the migration script.
  • The rebrand is mechanically consistent and well-executed across all 83 files. The only issue is a dead-code logic bug in the new migrate.sh that causes a silent "skip" instead of a warning when both the old and new database files coexist simultaneously — a rare edge case during migration that won't affect normal usage or new installs.
  • scripts/migrate.sh — the elif ordering in Step 2 makes the "both databases exist" warning unreachable.

Important Files Changed

Filename Overview
scripts/migrate.sh New migration script to transition existing installations; contains a logic bug where the "both databases exist" warning (Step 2) is dead code due to incorrect elif ordering.
bin/tinyagi New CLI wrapper replacing bin/tinyclaw; correctly sets TINYAGI_HOME and resolves symlinks to find the repo root before executing tinyagi.sh.
packages/core/src/config.ts TINYCLAW_HOME constant and env var renamed to TINYAGI_HOME; default data directory and workspace path updated to ~/.tinyagi and ~/tinyagi-workspace respectively.
tinyagi.sh Main entry point shell script cleanly renamed from tinyclaw.sh; TMUX session name, HOME variable, and all command-line help text updated to tinyagi branding.
scripts/install.sh CLI installer updated to create tinyagi symlink instead of tinyclaw; all user-facing messages and PATH logic updated correctly.
scripts/remote-install.sh Remote installer updated to fetch tinyagi-bundle.tar.gz from TinyAGI/tinyagi repo; bundle extraction uses --strip-components=1 so the renamed tinyagi/ prefix is handled correctly.
.github/workflows/release.yml Release workflow updated to produce tinyagi-bundle.tar.gz and upload it as the tinyagi-bundle artifact; bundle directory renamed from tinyclaw/ to tinyagi/ inside the tarball.
packages/cli/src/update.ts Update command updated to reference tinyagi-bundle.tar.gz download URL, tinyagi tmux session name, and ~/.tinyagi backup path; all references consistent.
lib/daemon.sh Daemon lifecycle script updated with tinyagi branding in all log messages, tmux session window name, and TINYAGI_HOME variable references for WhatsApp QR/ready files.
packages/main/src/index.ts Entry point updated to import from @tinyagi/* packages and use tinyagi-workspace as the default workspace path.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[migrate.sh] --> B{~/.tinyclaw exists?}
    B -- Yes, ~/.tinyagi absent --> C[mv ~/.tinyclaw → ~/.tinyagi]
    B -- Both exist --> D[⚠ Warn: manual reconcile needed]
    B -- ~/.tinyagi exists --> E[✓ Skip dir rename]
    B -- Neither exist --> F[Nothing to migrate]

    C --> G{tinyclaw.db in ~/.tinyagi?}
    E --> G
    G -- "OLD_DB exists, NEW_DB absent" --> H[mv tinyclaw.db → tinyagi.db\nalso rename -wal / -shm]
    G -- "NEW_DB exists ✓" --> I["✓ Skip DB rename\n⚠ BUG: also catches 'both exist' case\n   — warning never shown"]
    G -- "Neither exist" --> J[No DB to rename]

    H --> K{Old CLI symlinks?}
    I --> K
    J --> K
    K -- "/usr/local/bin/tinyclaw exists" --> L[rm old symlink]
    K -- "~/.local/bin/tinyclaw exists" --> L
    K --> M{TINYCLAW_* env vars?}
    M -- Yes --> N[⚠ Warn: update to TINYAGI_ prefix]
    M -- No --> O[✓ Migration complete]
    N --> O
Loading

Last reviewed commit: a485378

Comment thread scripts/migrate.sh
Comment on lines +57 to +65
# Also rename WAL/SHM files if they exist (SQLite)
[ -f "$DATA_DIR/${OLD_DB}-wal" ] && mv "$DATA_DIR/${OLD_DB}-wal" "$DATA_DIR/${NEW_DB}-wal"
[ -f "$DATA_DIR/${OLD_DB}-shm" ] && mv "$DATA_DIR/${OLD_DB}-shm" "$DATA_DIR/${NEW_DB}-shm"
changes=$((changes + 1))
elif [ -f "$DATA_DIR/$NEW_DB" ]; then
echo -e "${GREEN}✓${NC} $NEW_DB already exists — skipping database rename."
elif [ -f "$DATA_DIR/$OLD_DB" ] && [ -f "$DATA_DIR/$NEW_DB" ]; then
echo -e "${YELLOW}Warning: Both $OLD_DB and $NEW_DB exist in $DATA_DIR${NC}"
echo " Please reconcile manually."
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unreachable "both files exist" warning (dead code)

The third elif condition on line 64 can never be reached. The logic is:

  1. if (line 57): OLD_DB exists AND NEW_DB doesn't → rename
  2. elif (line 62): NEW_DB exists → skip (this catches both NEW_DB-only and both files existing, since NEW_DB exists in both cases)
  3. elif (line 64): OLD_DB exists AND NEW_DB exists → ⚠ warning — DEAD CODE: to reach here, the second elif must have been false (i.e., NEW_DB doesn't exist), but this condition requires NEW_DB to exist — a contradiction.

When both tinyclaw.db and tinyagi.db are present, users will silently see "skipping database rename" instead of the intended warning to reconcile manually.

Fix by swapping the order of the second and third conditions:

Suggested change
# Also rename WAL/SHM files if they exist (SQLite)
[ -f "$DATA_DIR/${OLD_DB}-wal" ] && mv "$DATA_DIR/${OLD_DB}-wal" "$DATA_DIR/${NEW_DB}-wal"
[ -f "$DATA_DIR/${OLD_DB}-shm" ] && mv "$DATA_DIR/${OLD_DB}-shm" "$DATA_DIR/${NEW_DB}-shm"
changes=$((changes + 1))
elif [ -f "$DATA_DIR/$NEW_DB" ]; then
echo -e "${GREEN}${NC} $NEW_DB already exists — skipping database rename."
elif [ -f "$DATA_DIR/$OLD_DB" ] && [ -f "$DATA_DIR/$NEW_DB" ]; then
echo -e "${YELLOW}Warning: Both $OLD_DB and $NEW_DB exist in $DATA_DIR${NC}"
echo " Please reconcile manually."
elif [ -f "$DATA_DIR/$OLD_DB" ] && [ -f "$DATA_DIR/$NEW_DB" ]; then
echo -e "${YELLOW}Warning: Both $OLD_DB and $NEW_DB exist in $DATA_DIR${NC}"
echo " Please reconcile manually."
elif [ -f "$DATA_DIR/$NEW_DB" ]; then
echo -e "${GREEN}${NC} $NEW_DB already exists — skipping database rename."

Copy link
Copy Markdown
Collaborator

@mczabca-boop mczabca-boop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review

I reviewed this PR assuming the GitHub repo rename from TinyAGI/tinyclaw to TinyAGI/tinyagi will be handled separately.

Findings

  1. Blocking: migration path for existing users is incomplete

    This PR changes the runtime home directory from ~/.tinyclaw to ~/.tinyagi and also renames the queue DB from tinyclaw.db to tinyagi.db, but the migration script is not wired into any install/start/update path.

    Relevant files:

    The repo does include a migration script, but nothing appears to invoke it from:

    • install flow
    • remote install flow
    • update flow
    • startup flow

    As written, an existing user upgrading from ~/.tinyclaw will likely boot into a fresh ~/.tinyagi state and lose access to their previous:

    • settings.json
    • pairing.json
    • queue database
    • other persisted runtime state

    I think this needs to be fixed before merge, either by:

    • automatically running scripts/migrate.sh from install/update/startup, or
    • adding explicit backward-compat fallback reads from .tinyclaw when .tinyagi does not exist.

Notes

  • Other than the migration gap, the internal rename looks mostly consistent.
  • I did not complete a full build verification in the review worktree because dependencies were not installed there (tsc: not found).

jlia0 and others added 2 commits March 12, 2026 22:52
Adds a bin/tinyclaw shim that prints a deprecation notice and
forwards all arguments to tinyagi. Install script now symlinks
both commands.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Take rebranded names (tinyagi) with main's version bump (0.0.11)
and .js file rename.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Take main's new features (dev script, runSkills, symlinked skills,
setup page, projects, agent-messages, memory) and apply tinyagi
rebrand to all new code.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel bot commented Mar 13, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
tinyoffice Ready Ready Preview, Comment Mar 13, 2026 11:20pm

Request Review

Take main's fix removing unused updateAgentTeammates import,
apply tinyagi rename.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Take main's TinyOffice branding updates (title, icon).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Take main's major restructuring (packages/tinyagi CLI, schedule
system, services, chatroom updates, new release workflow) and
apply tinyagi rebrand to all new code. Remove deleted scripts
(remote-install.sh, uninstall.sh).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@jlia0 jlia0 merged commit 4482ce0 into main Mar 18, 2026
@jlia0 jlia0 deleted the jlia0/rebrand-tinyagi branch March 18, 2026 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants