instar 0.28.124 → 0.28.125
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/server.d.ts.map +1 -1
- package/dist/commands/server.js +15 -0
- package/dist/commands/server.js.map +1 -1
- package/dist/core/ContextHierarchy.d.ts +1 -0
- package/dist/core/ContextHierarchy.d.ts.map +1 -1
- package/dist/core/ContextHierarchy.js +49 -0
- package/dist/core/ContextHierarchy.js.map +1 -1
- package/dist/core/PostUpdateMigrator.d.ts +1 -0
- package/dist/core/PostUpdateMigrator.d.ts.map +1 -1
- package/dist/core/PostUpdateMigrator.js +61 -0
- package/dist/core/PostUpdateMigrator.js.map +1 -1
- package/package.json +1 -1
- package/src/data/builtin-manifest.json +17 -17
- package/src/templates/playbook/conversational-catalog-manifest.json +43 -0
- package/upgrades/0.28.125.md +36 -0
- package/upgrades/side-effects/feat-conversational-action-v02.md +68 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 1,
|
|
3
|
+
"name": "instar-conversational-catalog",
|
|
4
|
+
"description": "Conversational-action catalog pointer for Playbook (Instar v1.0 built-in)",
|
|
5
|
+
"items": [
|
|
6
|
+
{
|
|
7
|
+
"id": "/instar/conversational-catalog",
|
|
8
|
+
"category": "infrastructure",
|
|
9
|
+
"memory_type": "procedural",
|
|
10
|
+
"path": ".instar/context/conversational-actions.md",
|
|
11
|
+
"tags": {
|
|
12
|
+
"domains": ["conversational-action", "intent-interpretation", "capability"],
|
|
13
|
+
"qualifiers": ["on-demand", "structural", "bloat-aware"]
|
|
14
|
+
},
|
|
15
|
+
"freshness": "2026-05-19T00:00:00Z",
|
|
16
|
+
"tokens_est": 800,
|
|
17
|
+
"usefulness": { "helpful": 0, "misleading": 0 },
|
|
18
|
+
"load_triggers": [
|
|
19
|
+
"interpreting-user-intent",
|
|
20
|
+
"matching-to-skill",
|
|
21
|
+
"translating-conversation-to-action",
|
|
22
|
+
"user-said-switch-to-X",
|
|
23
|
+
"user-said-lets-do-Y"
|
|
24
|
+
],
|
|
25
|
+
"dependencies": [],
|
|
26
|
+
"provenance": [
|
|
27
|
+
{
|
|
28
|
+
"source_session": "GENESIS",
|
|
29
|
+
"created_at": "2026-05-19",
|
|
30
|
+
"provenance_type": "instar-builtin",
|
|
31
|
+
"spec": "specs/instar-concepts/conversational-action.md (v0.2)",
|
|
32
|
+
"context_segment": ".instar/context/conversational-actions.md",
|
|
33
|
+
"probe_name": "conversational-catalog",
|
|
34
|
+
"rationale": "On-demand load of the invocable action catalog. Per Instar Design Principle P1 (Structure>Willpower) and the AGENT.md bloat lesson (L1), the catalog is NEVER inlined into AGENT.md. Playbook scoring decides when this pointer is relevant; SelfKnowledgeTree probe materializes the live catalog when fetched."
|
|
35
|
+
}
|
|
36
|
+
],
|
|
37
|
+
"retirement_policy": "auto",
|
|
38
|
+
"access_scope": "global",
|
|
39
|
+
"inheritance_eligible": true,
|
|
40
|
+
"status": "active"
|
|
41
|
+
}
|
|
42
|
+
]
|
|
43
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# Upgrade Guide — v1.0.13
|
|
2
|
+
|
|
3
|
+
<!-- bump: patch -->
|
|
4
|
+
|
|
5
|
+
## What Changed
|
|
6
|
+
|
|
7
|
+
Wires the v0.1 conversational-action catalog primitives (`discoverActions`, `renderCatalogBlock` from PR #256) through Instar's three pre-built bloat defenses — ContextHierarchy Tier 2 segment, SelfKnowledgeTree probe, and Playbook context item. The v0.1 deliberately shipped the catalog as pure data with no inlining into AGENT.md, because Instar already has structural defenses against AGENT.md bloat. This release wires the consumers.
|
|
8
|
+
|
|
9
|
+
The catalog content lives in the `conversational-catalog` SelfKnowledgeTree probe — generated fresh on each probe call, never cached. The new ContextHierarchy Tier 2 segment `.instar/context/conversational-actions.md` is the dispatch instruction (when the agent is in an intent-interpretation moment, this segment tells it to fetch the catalog via the probe). The new `conversational-catalog.json` Playbook manifest item is the third on-demand loader — Playbook's scoring engine surfaces the pointer when intent-interpretation triggers fire. All three paths are on-demand by design. The catalog is never inlined into the always-loaded identity prompt.
|
|
10
|
+
|
|
11
|
+
A semantic correctness test asserts that the Tier 1 loadTier output does not contain the conversational-actions segment content. If a future PR accidentally re-introduces AGENT.md inlining, the test fails.
|
|
12
|
+
|
|
13
|
+
## Evidence
|
|
14
|
+
|
|
15
|
+
Reproduction prior to this release: a user says "let's switch to local model" in conversation. The agent has no on-demand path to discover the available conversational actions — `.instar/skills/` exists on disk but the agent has no instruction to consult it for intent interpretation, no probe registered at server boot, and no Playbook item surfaced by the scoring engine. The agent falls back to asking the user for a slash command, breaking the conversation-default promise.
|
|
16
|
+
|
|
17
|
+
Observed after this release: same setup, three on-demand load paths come alive. The dispatch table for the new Tier 2 segment fires on the `interpreting-user-intent` trigger; the segment instructs the agent to invoke the `conversational-catalog` probe. The probe calls `discoverActions` + `renderCatalogBlock` and returns the live catalog. The agent matches the user's intent against the catalog and routes to the local-model skill. The slash-command surface is never shown.
|
|
18
|
+
|
|
19
|
+
Unit-test verification: three new ContextHierarchy tests (segment content presence, dispatch table registration, Tier 1 loadTier exclusion) and three new PostUpdateMigrator tests (manifest install when missing, idempotency on second run, refresh on content drift). The existing 19 ContextHierarchy tests continue to pass.
|
|
20
|
+
|
|
21
|
+
## What to Tell Your User
|
|
22
|
+
|
|
23
|
+
- "When you say something like 'let's switch to local' or 'send Dawn a message', I now have three independent on-demand paths to discover the right action without you having to know a slash-command name. The catalog is generated live on each lookup, never inlined into my always-loaded identity prompt, and the bloat-aware design is asserted-against in the test suite so a future regression can't sneak it back in."
|
|
24
|
+
|
|
25
|
+
## Summary of New Capabilities
|
|
26
|
+
|
|
27
|
+
| Capability | How to Use |
|
|
28
|
+
|-----------|-----------|
|
|
29
|
+
| Conversational-actions ContextHierarchy segment | Automatic. The Tier 2 segment loads on `interpreting-user-intent`, `matching-to-skill`, or `translating-conversation-to-action` triggers. |
|
|
30
|
+
| `conversational-catalog` SelfKnowledgeTree probe | Automatic. Registered at server boot when `selfKnowledgeTree` is enabled. The probe walks `.instar/skills/` and returns the live catalog on each call. |
|
|
31
|
+
| Playbook conversational-catalog manifest | Automatic install via PostUpdateMigrator; mount with `instar playbook mount` (explicit consent per Playbook design). |
|
|
32
|
+
|
|
33
|
+
## Deferred (Tracked Follow-ups)
|
|
34
|
+
|
|
35
|
+
- HTTP endpoint `/capabilities/conversational-catalog` is referenced in the segment as a third fallback after the probe; not implemented in this PR. The probe is the canonical access path; the HTTP endpoint is a future convenience.
|
|
36
|
+
- Future v0.3 may add new triggers to the manifest template; PostUpdateMigrator's content-sniff guard will refresh the manifest on update without operator action.
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# Side-effects review — Conversational-action v0.2 (three on-demand loaders)
|
|
2
|
+
|
|
3
|
+
Per L6 (Side-effects review gate). Seven dimensions.
|
|
4
|
+
|
|
5
|
+
## 1. Over-block / under-block
|
|
6
|
+
|
|
7
|
+
**Before this change.** UNDER-blocked: the v0.1 (PR #256) shipped catalog primitives but deliberately omitted any wiring. The catalog existed as pure data; agents had no on-demand load path. The promise "user says intent → agent recognizes via catalog" was a future promise, not an observed behavior.
|
|
8
|
+
|
|
9
|
+
**After this change.** No over-block risk. All three loaders are on-demand by design. The semantic correctness test asserts the conversational-actions content is NOT in Tier 0 or Tier 1 loads, so the AGENT.md bloat anti-pattern can't sneak back in via accidental regression.
|
|
10
|
+
|
|
11
|
+
The Playbook integration is opt-in via `instar playbook mount` — operator explicit consent per Playbook design. Operators who don't mount the Playbook manifest still get the other two loaders (segment + probe).
|
|
12
|
+
|
|
13
|
+
## 2. Level-of-abstraction fit
|
|
14
|
+
|
|
15
|
+
Each loader lives in its natural home:
|
|
16
|
+
- ContextHierarchy Tier 2 segment → `src/core/ContextHierarchy.ts` DEFAULT_SEGMENTS array
|
|
17
|
+
- SelfKnowledgeTree probe → `src/commands/server.ts` boot path (alongside the existing feature-discovery probe)
|
|
18
|
+
- Playbook manifest → `src/templates/playbook/` (template) + PostUpdateMigrator step (installer)
|
|
19
|
+
|
|
20
|
+
The probe registration deliberately uses dynamic import (`await import(...)`) so the catalog primitives aren't pulled into the boot graph until the probe is invoked. Lazy load = no startup cost for agents that never trigger the catalog.
|
|
21
|
+
|
|
22
|
+
The PostUpdateMigrator step uses content-sniff idempotency (skip if existing file matches template byte-for-byte). On every update, the template is re-checked; if it has drifted (e.g., a future v0.3 adds new triggers to the manifest), the file is refreshed.
|
|
23
|
+
|
|
24
|
+
## 3. Signal vs Authority compliance
|
|
25
|
+
|
|
26
|
+
The ContextHierarchy Tier 2 segment is the SIGNAL — it tells the agent "you're in an intent-interpretation moment, here's how to fetch the catalog." The SelfKnowledgeTree probe is the AUTHORITY — when invoked, it returns the live catalog. The Playbook item is a complementary RELEVANCE signal — Playbook's scoring engine decides when to surface the pointer based on usefulness history.
|
|
27
|
+
|
|
28
|
+
Three independent signal/authority paths give the agent multiple on-ramps. No single load path is mandatory; each fills a different role.
|
|
29
|
+
|
|
30
|
+
## 4. Interactions with adjacent systems
|
|
31
|
+
|
|
32
|
+
**ContextHierarchy initializer.** The new segment uses the existing template-generator pattern. `generateSegmentTemplate('conversational-actions')` returns a fresh template string; the initializer writes it on first init AND on every update (via the parity-renderings backfill from PR #262, which re-renders all canonical sources).
|
|
33
|
+
|
|
34
|
+
**SelfKnowledgeTree.** The probe is registered alongside the existing `feature-discovery` probe at server boot. Both probes are conditional on `selfKnowledgeTree` being non-null (matches the existing pattern). No new lifecycle complications.
|
|
35
|
+
|
|
36
|
+
**Playbook system.** The manifest template lives in `src/templates/playbook/` and is shipped to `.instar/playbook/builtin-manifests/` on update. The actual mount registration is operator-initiated via `instar playbook mount`. No automatic mount — this preserves Playbook's "explicit consent for context items" invariant.
|
|
37
|
+
|
|
38
|
+
**PostUpdateMigrator backfill (PR #262, now on main).** The parity-renderings backfill re-renders the ContextHierarchy segment on every update, so the conversational-actions segment file stays fresh. The new migrateConversationalCatalogPlaybookManifest step is a sibling — also idempotent, also runs on every update.
|
|
39
|
+
|
|
40
|
+
**AGENT.md.** Unchanged. The whole point of this PR is to NOT add the catalog to AGENT.md. Asserted structurally by the semantic correctness test.
|
|
41
|
+
|
|
42
|
+
## 5. Rollback cost
|
|
43
|
+
|
|
44
|
+
Low. Five files changed (one new template, one new test file, three sibling additions to existing files: ContextHierarchy, server.ts probe registration, PostUpdateMigrator step). Revert is `git revert`. Deployed agents would keep the Playbook manifest file (orphan, harmless — Playbook ignores unmounted manifests); the segment file would remain (still readable but the dispatch table would no longer fire for intent-interpretation triggers). The probe would be unregistered on next server restart.
|
|
45
|
+
|
|
46
|
+
## 6. Backwards compatibility / drift surface
|
|
47
|
+
|
|
48
|
+
Backwards-compatible:
|
|
49
|
+
- v0.1 catalog primitives unchanged.
|
|
50
|
+
- Existing ContextHierarchy segments unchanged.
|
|
51
|
+
- Existing SelfKnowledgeTree probes unchanged.
|
|
52
|
+
- Playbook manifest is additive (only writes to builtin-manifests/; never modifies existing mounts).
|
|
53
|
+
|
|
54
|
+
**Drift surface.** The conversational-actions segment file content is regenerated by ContextHierarchy.initialize() — operators who customize the file would lose customizations on update. This is consistent with all other Tier 0-2 segment files (initialize-only-when-missing protection has been removed in favor of always-overwrite via PR #262's parity-renderings backfill for canonical sources). Operators who want custom intent-dispatch instructions should add a separate custom segment file outside the DEFAULT_SEGMENTS path.
|
|
55
|
+
|
|
56
|
+
**Playbook manifest format.** The shipped template uses Playbook's documented manifest schema. If Playbook v2 changes the schema, this template would need updating. Documented as a known coupling.
|
|
57
|
+
|
|
58
|
+
## 7. Authorization / Trust posture
|
|
59
|
+
|
|
60
|
+
No new authority claims. The probe is read-only (walks `.instar/skills/`, returns a string). The PostUpdateMigrator step writes to `.instar/playbook/builtin-manifests/` (a write surface PostUpdateMigrator already has authority over). The Playbook mount registration is operator-initiated — `instar playbook mount` is a CLI command requiring explicit user invocation.
|
|
61
|
+
|
|
62
|
+
Trust-floor implications: the conversational-catalog probe is at the same Tier-1 LLM-supervised execution surface as the other knowledge-tree probes. Output is capped at the probe's default `maxOutputChars` (2000 chars). Catalog blocks exceeding this would be truncated; v0.1's renderCatalogBlock produces compact output well within the cap for typical skill counts.
|
|
63
|
+
|
|
64
|
+
## Outcome
|
|
65
|
+
|
|
66
|
+
Ship.
|
|
67
|
+
|
|
68
|
+
The three on-demand loaders are wired structurally. The AGENT.md bloat anti-pattern is asserted-against in the semantic correctness test. The catalog content lives in the probe (dynamic, live) — the segment and Playbook item are pointers, never the content itself. Final v1.0 task closed; the conversational-action layer is structurally complete.
|