Repository navigation
Thinking record on runs, and a generated Fabric pattern catalog with a suggester - #2816
Open
glitchking1337 wants to merge 1 commit into
Open
glitchking1337 wants to merge 1 commit into
glitchking1337 wants to merge 1 commit into
Conversation
…a suggester Per-feature Thinking: line in the ISA (ISAFormat), LIFEOS/ROUTER/ThinkingCheck.ts (line, check, fit), HookBridge thinking verbs, LifeOSHooks draws the line beside the route line, Socrates thinking adapter and seed question, Algorithm 8.46.0 § Spend rule. skills/Fabric: PatternCatalog.ts generates Patterns/catalog.yaml (purpose, triggers, input, output, ported intent, hash), SuggestPattern.ts ranks the top three for a plain request, CheckPatterns runs the catalog check, ExecutePattern and UpdatePatterns read the catalog, FabricSystem docs. Tests: 42 across four files. The catalog in this commit was built against this branch's own Patterns/ with --no-model.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two additions, both records rather than gates:
1. The
Thinking:line, a run's written thinking plan. PAI v2.5's THINK phase walked six thinking tools on every request and wrote INCLUDE or EXCLUDE with a reason. LifeOS v8.0 cut that table as scaffolding, and nothing afterwards recorded which thinking skills a run ran or skipped. This brings the record back the way theLane:line did for dispatch:Thinking: <Skill>·<light|full>[, …] ; skipped <Skill>=<phrase>orThinking: none=<phrase>line per feature block, afterLane:. Additive; an ISA without it reads as before.LIFEOS/ROUTER/ThinkingCheck.ts(new, 18 tests):linedraws🧠 THINKING ▸ F1 RedTeam·light (skipped Council) · F2 none;check --sessioncompares the plan with the Skill tool calls in the session transcript and its subagent sidechains;fitasks one shadow Assay question per skipped skill (callerthinking-fit, fail-open) and says once when the engine is unavailable. Every subcommand exits 0.thinkingandthinking-fitverbs; the LifeOSHooks plugin draws the line beside the route line (also when the ISA has noLane:line).thinkingadapter (new, 5 tests): the weekly share of skips judged would-have-changed, unknown under 10 judged runs; one seed question inseeds/template.json.2. A generated Fabric pattern catalog and a suggester. Upstream pattern files carry no metadata and are overwritten on every sync, so metadata lives in a generated sidecar,
skills/Fabric/Patterns/catalog.yaml, never in asystem.md:skills/Fabric/Tools/PatternCatalog.ts(new, 10 tests):buildderives entries frompattern_explanations.mdand each pattern's IDENTITY and OUTPUT sections, with one cached model pass only for a pattern no explanation line covers;checkfails on a missing entry or a moved hash and is wired intoCheckPatterns.tsand the skill's deterministic evals;triggersregenerates the USE WHEN list on request (--write, opt-in).skills/Fabric/Tools/SuggestPattern.ts(new, 9 tests): top three patterns for a plain request, trigger and keyword ranking with a partial-name penalty and a ported-pattern edge, then one shadow Assay question over the shortlist (callerpattern-suggest, fail-open, skipped whenever a local pattern is shortlisted). An explicitly named pattern or intent makes no model call.Pattern: <name> (<reason>)before the pattern runs. UpdatePatterns rebuilds the catalog after every sync and in its re-scrub recovery. Local patterns get their own catalog underUSER/CUSTOMIZATIONS/SKILLS/Fabric/, merged at read time, never written into the shipped file.Notes for the maintainer
Patterns/withPatternCatalog.ts build --no-model; after any pattern change, run the same build orCheckPatterns.tsgoes red (by design: the signal to rebuild).thinking-fit,pattern-suggest) are not added toLifeOS/install/USER/CONFIG/assay-callers.jsonhere because this PR touches system trees only; add them to the template on port, or they run unregistered (shadow, fail-open).pattern_explanations.mddescribescreate_quizas a reading plan, so that catalog purpose follows the wrong line; its triggers still route "create a quiz".Tests
42 of 42 across
LIFEOS/ROUTER/ThinkingCheck.test.ts,LIFEOS/SOCRATES/adapters/thinking.test.ts,skills/Fabric/Tools/PatternCatalog.test.ts,skills/Fabric/Tools/SuggestPattern.test.ts, run inside a fresh clone of main with this branch applied;PatternCatalog.ts check --completeandCheckPatterns.tsexit 0 there.