Skip to content

refactor(memory): shim content tag storage through TinyCortex - #5244

Merged
senamakel merged 3 commits into
tinyhumansai:mainfrom
senamakel:memory-store-tinycortex
Jul 28, 2026
Merged

refactor(memory): shim content tag storage through TinyCortex#5244
senamakel merged 3 commits into
tinyhumansai:mainfrom
senamakel:memory-store-tinycortex

Conversation

@senamakel

Copy link
Copy Markdown
Member

Summary

  • Move generic chunk-tag rewrite ownership into TinyCortex.
  • Reduce memory_store::content::tags from 576 lines to a 134-line compatibility adapter.
  • Preserve all existing OpenHuman call sites through TinyCortex re-exports.
  • Keep the Config/entity-index-aware summary rewrite in OpenHuman.
  • Depend on fix(memory): guard chunk tag rewrites tinycortex#131 for the migrated body-integrity guard.

Problem

OpenHuman and TinyCortex both implemented chunk markdown tag rewriting. The OpenHuman copy also carried a post-port body-integrity guard, preventing the host from becoming a thin adapter without losing a safety invariant.

Solution

Port the missing invariant and regression coverage to TinyCortex, update the vendored gitlink, and replace OpenHuman’s generic implementation with public re-exports. Product-specific summary lookup and persistence glue remains host-owned.

Submission Checklist

  • Tests added or updated (happy path + at least one failure / edge case) per Testing Strategy
  • Diff coverage ≥ 80% — migrated TinyCortex lines have direct happy/failure-path tests; OpenHuman CI remains authoritative for the adapter diff.
  • N/A: no feature row was added, removed, or renamed in docs/TEST-COVERAGE-MATRIX.md.
  • N/A: no affected feature ID; this is an internal storage ownership refactor.
  • No new external network dependencies introduced.
  • N/A: no release-cut manual smoke surface changed.
  • N/A: no tracking issue was supplied; dependency PR is linked below.

Impact

No user-visible behavior change. Chunk tag rewriting now fails closed in TinyCortex if front matter is invalid or the markdown body changes. Existing OpenHuman paths and on-disk formats are preserved.

Related


AI Authored PR Metadata (required for Codex/Linear PRs)

Linear Issue

  • Key: N/A
  • URL: N/A

Commit & Branch

  • Branch: memory-store-tinycortex
  • Commit SHA: 3758607c6

Validation Run

  • N/A: no frontend files changed; root format command was attempted but frontend dependencies are not installed in this worktree.
  • N/A: no TypeScript changed.
  • Focused tests: cargo test --lib openhuman::memory_store::content --no-fail-fast — 20 passed. TinyCortex: cargo test — 1234 unit tests plus integration/doc tests passed.
  • Rust fmt/check: cargo fmt --check --manifest-path Cargo.toml; pre-push Rust check hook passed.
  • N/A: no Tauri files changed.

Validation Blocked

  • command: pnpm format:check
  • error: prettier: not found because this fresh worktree has no node_modules.
  • impact: Rust formatting passed directly; CI will run the repository-managed frontend formatting environment.

Behavior Changes

  • Intended behavior change: generic chunk-tag integrity enforcement is owned by TinyCortex.
  • User-visible effect: none.

Parity Contract

  • Legacy behavior preserved: public module paths, markdown format, source-tag seeding, atomic replacement, and summary lookup behavior.
  • Guard/fallback/dispatch parity checks: TinyCortex tests cover valid rewrites, malformed front matter, and body drift; OpenHuman content tests remain green.

Duplicate / Superseded PR Handling

  • Duplicate PR(s): none
  • Canonical PR: this PR
  • Resolution (closed/superseded/updated): N/A

@senamakel
senamakel requested a review from a team July 28, 2026 10:19
@coderabbitai

coderabbitai Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 14 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 19bc8f41-a1f6-44e1-8fb5-57236dec39c4

📥 Commits

Reviewing files that changed from the base of the PR and between 7620945 and 3758607.

📒 Files selected for processing (2)
  • src/openhuman/memory_store/content/tags.rs
  • vendor/tinycortex

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

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

senamakel has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@senamakel
senamakel merged commit 0004869 into tinyhumansai:main Jul 28, 2026
20 checks passed
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.

1 participant