Commit Graph

18 Commits

Author SHA1 Message Date
Maxim 6d5d407624 fix(banking): make fresh setup work on Apple Silicon (native TEI + run-demo.sh)
The bundled tei embedder image is amd64-only; under arm64 emulation the Candle
backend is unavailable and TEI falls back to the ONNX/ORT backend, which needs
onnx/model.onnx files Qwen3-Embedding-0.6B doesn't publish (404) -> crash-loop.
A fresh clone on Apple Silicon therefore couldn't stand up the embedder, so
memory save/recall were dead. Ports the proven pattern from the Intelligence
repo's docker-compose.deps.yml + demos/splat-demo/run-demo.sh into this demo:

- docker-compose.yml: gate the bundled `tei` behind the `cpu-fallback` profile,
  so a bare `docker compose up` skips the crash-looping emulated image. amd64/CI
  opt back in with `--profile cpu-fallback`. (intelligence's tei dep is
  required:false, so it starts fine without it, using MEMORY_EMBEDDINGS_URL.)
- run-demo.sh: one-command cold start. On Apple Silicon it runs a native Metal
  TEI on :7067 (same 1.9.3 + Qwen3-Embedding-0.6B => byte-identical embeddings,
  ~20x faster) and points app-api at it; on amd64/CI it uses the docker tei via
  the profile. Mints a dev license if .env lacks one, then starts `pnpm dev`.
- README: correct the failure description (emulation->ONNX crash-loop, not OOM),
  document run-demo.sh as the recommended start, and the profile-gated manual path.

All CopilotKit-repo-only (banking's compose is standalone); no Intelligence
changes. Validated: shellcheck clean, compose valid, bare `up` skips tei and
keeps intelligence healthy, memory save/recall verified through the native TEI.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-06 16:20:03 +02:00
Maxim 40babda9d0 docs(banking): document general memory and the 2-persona cross-user demo 2026-07-03 16:14:26 +02:00
Maxim ad922750cf fix(showcase): align banking memory docs/smoke to kind procedural
The durable memory feature saves kind:"procedural" (route.ts:150) but the
README and drift-smoke script described/seeded kind:"operational", a
doc/code contradiction. Update both to procedural. The learning-tab
back-compat (operational || procedural) is intentionally left untouched.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-03 00:47:50 +02:00
Maxim 2d9275da1f fix(showcase): correct memory-learning spec path in banking docs
The README, .env.example, and memory-drift-smoke.mjs referenced a
non-existent path 'tests/e2e/memory-learning.spec.ts'. The actual spec
lives at 'e2e/memory-learning.spec.ts' (matching the test:self-learning
script in package.json). Corrected all three references.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-03 00:47:50 +02:00
github-actions[bot] 5f77e8696a style: auto-fix formatting 2026-07-02 19:37:31 +02:00
Maxim 5544011a93 docs(showcase): document Glass Engine advanced mode + satisfy set-state-in-effect lint
- README: two-gate Glass Engine section (availability + activation).
- Add justified eslint-disable for async fetch-on-mount + localStorage hydration
  (react-hooks/set-state-in-effect false positives — setState is post-await /
  intentional client-only hydration).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-02 19:37:31 +02:00
Maxim 177a68f7d4 docs(showcase): memory-based durable-learning runbook + real-LLM recall drift smoke
- README: replace dead sl-worker/knowledge/annotate Phase-C section with the
  memory runbook (docker compose one-command stack, host-TEI override for Apple
  Silicon, 715x ports, .env, cross-thread+cross-persona FOR-149 walkthrough,
  aimock E2E + drift-smoke testing notes)
- scripts/memory-drift-smoke.mjs: non-gating real-LLM tripwire that the live model
  still emits recall_memory on a fresh-thread over-limit request (save half is
  HITL-gated; covered by the manual walkthrough + aimock E2E)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-02 19:33:30 +02:00
GeneralJerel 0b65391501 docs(showcase): clarify same-thread (OSS) vs cross-thread (Intelligence) recall
Adds a "What each mode actually recalls" subsection to the demo README: in OSS
mode the taught workflow is recalled only within the same conversation (the
saved procedure is echoed back into that thread), so a brand-new chat won't know
it — that's expected. Cross-conversation persistence is what the external
Intelligence backend provides. Names the symptom explicitly so reviewers aren't
surprised when a new conversation "doesn't know" the workflow in OSS mode.
2026-06-15 12:04:44 -07:00
GeneralJerel 6a7f1187f7 test(showcase): add self-learning smoke script (record, distill, recall)
scripts/self-learning-smoke.mjs proves the banking demo's recording seam
end-to-end against a running Intelligence backend: posts four teaching
actions through the demo BFF /api/copilotkit/annotate (the platform
requires UUID clientEventIds), optionally runs one sl-worker sweep when
INTELLIGENCE_REPO is set, and asserts the distilled vendor policy reads
back through the platform /mcp knowledge tool. Wired as the
test:self-learning package script and documented in the README.

Verified live: PASS 6/6 against Intelligence @ mme/learn-from-user-activity
(records as rows 13-16, sweep editCount=0 steady-state, recall returns the
pre-cleared vendor policy).
2026-06-11 04:54:23 -07:00
GeneralJerel b907d6397d docs(showcase): update recording section — gap is closed
The 'Known gap' section predated the recording fix: the hook exists as
useLearnFromUserActionInCurrentThread and record-user-action.ts is now a
real adapter. Document the /annotate flow and the backend route
requirement (/connector/annotate) instead.
2026-06-10 19:05:23 -07:00
GeneralJerel 3b44d04746 docs(showcase): add banking demo screenshots to README
Dashboard, copilot chat panel, and the learning-mode recording vignette
(the violet glow shown while an officer demonstration is being recorded).
PNGs are LFS-tracked per the repo .gitattributes.
2026-06-10 19:04:33 -07:00
GeneralJerel 75607be9d8 fix(showcase): wire banking demo recording to useLearnFromUserActionInCurrentThread
Replace the no-op recorder shim with a real adapter over the v2 hook
(renamed from useRecordUserActionInCurrentThread in #4839/#5073): call-site
{title, description, previousData, newData, metadata} maps to the hook's
{title, description, data: {previous, next, metadata}}, with threadId
sourced from the surrounding chat config provider.

Add an optional INTELLIGENCE_USER_ID / INTELLIGENCE_USER_NAME override to
identifyUser for backends that enforce org membership of the asserted user
(e.g. a local Intelligence stack with seeded fixture users); the default
remains the derived northwind-<role> identity. Documented in the README.

Verified end-to-end against Intelligence @ mme/learn-from-user-activity
(PUT /connector/annotate): record -> cpki.sl_annotations -> sl-worker
distill -> /project knowledge file -> recall via /mcp. Recording requires a
backend that exposes /connector/annotate; the OSS default path
(InMemoryAgentRunner, no INTELLIGENCE_* env) is unchanged.
2026-06-10 19:00:45 -07:00
GeneralJerel a290ece6da feat(saas-demo): threads + teachable self-learning + Aurora UI
Continues the closed draft #5183 on top of the merged #5180. Adds: v2 Threads as a docked chat side panel + inbox; the self-learning teachable policy-exception gate (symptom-only over-limit gate, justifying-exception unlock, recipe withheld; OSS default, env-gated CopilotKitIntelligence); the Aurora design system; a reusable teach-mode cookbook (examples/showcases/teach-mode/); and a learning-track plan. 53 files, scoped to examples/showcases/{banking,teach-mode}.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 05:58:42 -07:00
Maxim 982f9e5378 docs(saas-demo): correct README REST/team/store details
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-03 13:08:30 +02:00
Maxim 1d2b5db575 docs(saas-demo): rewrite README for v2 architecture
Replace v1-era hooks/data references with the actual v2 surface:
useAgentContext / useFrontendTool / useHumanInTheLoop from
@copilotkit/react-core/v2, the Hono runtime route, the seed.json + store
data layer, and the Northwind identity. Drop mentions of removed
SQL/MSA/ServiceNow/RAG features.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-03 12:49:34 +02:00
Maxim 6e1f955b2e docs(saas-demo): remove stale SQL/MSA references from README 2026-06-02 21:29:21 +02:00
Jordan Ritter fd34bbfbf6 style: format all example files with prettier
Run prettier on ~1,865 files across examples/ to match the monorepo's
formatting standards. These files were imported as-is from standalone
repos that used different prettier configs.
2026-03-12 13:06:04 -07:00
Jordan Ritter ec3a5ff114 feat: consolidate 47 demo repos into examples/ 2026-03-12 13:06:02 -07:00