framework_eng/skills/framework-meta/rlm-workflow/SKILL.md
MUST use WHEN you are writing reusable knowledge into RLM (pattern / architectural decision / stable domain fact) OR reading it before a non-trivial task/solution in the domain. Provides the breakdown of native-push vs RLM-pull, tools for writing and reading RLM, H-MEM levels, and hygiene.
npx skillsauth add steelmorgan/1c-agent-based-dev-framework rlm-workflowInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
RLM is a pull storage for universal reusable knowledge: patterns, architectural decisions, domain facts for 1С/БСП, module findings. It is retrieved by topic through semantic search (embeddings fine-tuned for 1С) and does NOT stay in the context. The triggers for "when to write / when to read" are in the
rlm-workflowrule; here is how to do it.
| Knowledge | Layer | Tool |
|---|---|---|
| Always-on core (security, invariants, standing preferences) | native push | MEMORY.md + memory/*.md |
| Universal reusable knowledge (patterns, solutions, domain facts) | RLM pull | this skill |
| Transient task state (PENDING, next step, WIP) | agent-context | task_dir/.context/*.md |
Precondition (MUST): rlm_start_session() before any writes — otherwise silent failure (you only learn about it through rlm_get_hierarchy_stats).
| What to write | Call |
|---|---|
| Universal pattern / anti-pattern | rlm_add_hierarchical_fact(content, level=1, domain="retrospective") |
| Detail of a specific module/file | rlm_add_hierarchical_fact(content, level=2, domain="<domain>", module="<path>", code_ref="<file:line>") |
| Temporary note / hypothesis | rlm_add_hierarchical_fact(content, level=3, ttl_days=7) — auto-consolidation |
| Decision with alternatives | rlm_record_causal_decision(decision, reasons, consequences, constraints, alternatives) |
Finalizing the write — rlm_sync_state().
H-MEM levels:
| level | Name | When |
|---|---|---|
| 0 | L0_PROJECT | Loaded always. Critical global knowledge, project pitfalls. Write rarely (bloats every start) |
| 1 | L1_DOMAIN | By context. Stable patterns, session decisions |
| 2 | L2_MODULE | On request. Implementation details, findings at the module level |
| 3 | L3_CODE | Temporary. Auto-collapses into L2/L1 via rlm_consolidate_facts |
At the boundary of work (entering a non-trivial task / before an architectural decision / when a recurring problem appears) — one call, not a tool sweep:
| Goal | Call |
|---|---|
| Topic context (recommended, one-call) | rlm_enterprise_context(query="<domain/symptom>", max_tokens=3000) — auto-routing of L0 + relevant L1/L2 + causal chains |
| Only relevant facts within budget | rlm_route_context(query, max_tokens=2000) — L0 always + L1/L2 by similarity |
| Targeted hybrid search | rlm_search_facts(query, semantic_weight, keyword_weight, recency_weight, top_k) |
Weights in rlm_search_facts: semantic query → raise semantic_weight; search by exact term/identifier → raise keyword_weight; "what was changed recently" → recency_weight.
rlm_get_stale_facts() → if needed rlm_delete_fact().rlm_consolidate_facts(min_facts=5) (L3→L2→L1 + dedup).rlm_discover_project(project_root, task_hint) once (seeds the L0 structure).| Anti-pattern | Consequence |
|---|---|
| Writing without rlm_start_session | Silent failure |
| Writing everything into L0 "just in case" | L0 is loaded always → every start becomes more expensive |
| Keeping universal knowledge in the native always-on core | Bloats context on every turn — this belongs in RLM (pull) |
| Putting transient (PENDING, WIP) into RLM | Pollutes the knowledge store; transient → agent-context |
| Reading RLM on every turn | Pull degrades into push; read at the boundary of work |
depends_on:
testing
MUST use BEFORE making a judgment about the cause of a conflict, a test failure, or an artifact dispute. Defines the end-to-end verification method L1→L6 and the classification of the first broken link.
development
MUST use AFTER a work cycle with ≥2 iterations (wrote → error → fixed → success). Provides the retrospective procedure and the format for recording practice/anti-patterns in references/learned-patterns.md or {project}/.context/learned-patterns.md.
testing
MUST use WHEN the task is classified as simple (< 20 lines, 1 file, no new metadata objects, no architectural decisions). Provides a short cycle of 3 steps with a guard on the self path and mandatory verify.
development
MUST use WHEN the orchestrator creates a task branch, commits a phase, merges a task, or rolls back changes. Provides branch strategy, phase commit format, squash-merge, and a ban on file deletion.