Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/ferroxlabs/ijfw/consolidategit clone --depth 1 https://github.com/FerroxLabs/ijfwWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/ferroxlabs/ijfw/consolidate)<a href="https://agentmods.dev/commands/ferroxlabs/ijfw/consolidate"><img src="https://agentmods.dev/badge/commands/ferroxlabs/ijfw/consolidate.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00021 | $0.00859 |
| Opus 5 | $0.00010 | $0.00430 |
| Sonnet 5 | $0.00004 | $0.00172 |
| Haiku 4.5 | $0.00002 | $0.00086 |
Grade A, and why
consolidate scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 88 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Run the IJFW dream cycle on project memory using the architect agent.
Inputs to read
.ijfw/memory/project-journal.md-- append-only timeline.ijfw/memory/knowledge.md-- curated decisions/patterns.ijfw/memory/handoff.md-- latest session handoff (if present)~/.ijfw/memory/global-knowledge.md-- cross-project preferences (this project's namespace only).ijfw/sessions/*.md-- session markers~/.claude/projects/<encoded>/memory/*.md-- Claude native project memory (read-only mirror)
Algorithm
1. Promote (journal → knowledge)
Scan the journal for entries that meet the promotion threshold:
- Same topic/pattern referenced in >=3 journal entries AND
- Spanning >=2 distinct session IDs AND
- Not already present in knowledge.md
For each qualifying pattern, write a structured entry to knowledge.md:
---
type: pattern
summary: <1-line>
stored: <ISO timestamp>
tags: [derived, from, content]
---
<consolidated statement>
**Why:** <extracted rationale>
**How to apply:** <extracted guidance>
2. Reconcile contradictions
Detect pairs of entries where a later statement supersedes an earlier one (e.g., "use REST" followed later by "migrated to GraphQL"). For each:
- Mark the older entry with
superseded: trueand asuperseded_by_datefield. - Do NOT delete -- history matters for audit trails.
- Add a reconciliation note to knowledge.md explaining the transition.
3. Prune stale journal
- Entries older than 14 days that never reached promotion threshold: archive to
.ijfw/sessions/archive/journal-<YYYY-MM>.md, remove from active journal. - Keep the last 30 days regardless of promotion status.
4. Compress knowledge base
- Merge near-duplicate entries (same summary, same type, overlapping content).
- Deduplicate by structural similarity, preserving the most recent/complete version.
- Stay under ~2000 tokens total. If larger, cluster and archive oldest cluster.
5. Cross-project promotion (opt-in)
If a pattern is referenced in >=3 different projects (via global-knowledge
namespace inspection) OR the user explicitly flags it with globalize: true:
- Promote to
~/.ijfw/memory/global/<facet>.md(preferences/patterns/stack/anti-patterns/lessons). - Facet classification by architect agent using concise rule: the "what I like" axis → preferences; reusable solution → patterns; tool/framework knowledge → stack; "never do this" → anti-patterns; hard-won insight → lessons.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 88 lines · 21 tokens per session scan A a5d49b977adb
consolidate is a command published in the GitHub repository FerroxLabs/ijfw (210 stars, last pushed 11d ago), licensed MIT. It adds 21 tokens to every session and 859 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
compact-task-memory
Produce a lossy compaction summary of TASKSTATE.md when task memory has grown beyond a useful working size, preserving canonical decisions and recommended next step while dropping stale facts. Distinct from sync-task-state (incremental, append-only, never lossy) and state-reconcile (drift repair, no shrinking). Use…
capture-observation
Append a single observation, question, hypothesis, or concern to TASKSTATE.md as task memory without disrupting in-progress work or requiring a full state sync. Lean append-only; never restructures other artifacts. Use when something surfaces mid-work that should be remembered for later (during planning…
brain
General-purpose interface to the project's brain, plus a config mode for wiring the brain on first install (or repointing it at a different location).
init-workspace-flow-questions
Phase 8 Questions of init-workspace-flow.
review-code
Read ALL memory bank code rules + best practices, check the files that changed, and APPLY fixes so they adhere. The active counterpart to /scan (which is read-only). Use after an AI session, before commit, to make changed files compliant.
core-review
Review code changes against SpecOps project-specific patterns. Catches recurring failure modes from real PRs — tool abstraction violations, generated file drift, cross-platform gaps, variable inconsistencies, and more. Complements full-review-gate (generic quality) and pr-fix (applying bot comments).