From 10fc753ae99f0af4d53e0711f64276961c6973d6 Mon Sep 17 00:00:00 2001 From: BenCodez <17074231+BenCodez@users.noreply.github.com> Date: Mon, 9 Nov 2026 21:13:21 -0600 Subject: [PATCH 1/2] Prepare MEX project memory migration --- .agents/skills/mex-inbox/.mex-managed.json | 11 --- .agents/skills/mex-inbox/SKILL.md | 44 ---------- .agents/skills/mex-inbox/agents/openai.yaml | 4 - .../mex-inbox/references/cli-workflows.md | 86 ------------------ .agents/skills/mex-relay/.mex-managed.json | 11 --- .agents/skills/mex-relay/SKILL.md | 39 -------- .agents/skills/mex-relay/agents/openai.yaml | 4 - .../mex-relay/references/cli-workflows.md | 88 ------------------- .mex/.gitignore | 3 - .mex/AGENTS.md | 17 ---- .mex/ROUTER.md | 22 ----- .mex/SETUP.md | 3 - .mex/SYNC.md | 3 - .mex/config.json | 10 --- .mex/context/architecture.md | 18 ---- .mex/context/conventions.md | 16 ---- .mex/context/decisions.md | 18 ---- .mex/context/network.md | 18 ---- .mex/context/protocol.md | 18 ---- .mex/context/setup.md | 16 ---- .mex/context/stack.md | 10 --- .mex/events/operations.jsonl | 10 --- .mex/patterns/INDEX.md | 6 -- .mex/patterns/README.md | 3 - .mex/patterns/protocol-change.md | 16 ---- .mex/patterns/proxy-connection-change.md | 16 ---- AGENTS.md | 6 +- 27 files changed, 3 insertions(+), 513 deletions(-) delete mode 100644 .agents/skills/mex-inbox/.mex-managed.json delete mode 100644 .agents/skills/mex-inbox/SKILL.md delete mode 100644 .agents/skills/mex-inbox/agents/openai.yaml delete mode 100644 .agents/skills/mex-inbox/references/cli-workflows.md delete mode 100644 .agents/skills/mex-relay/.mex-managed.json delete mode 100644 .agents/skills/mex-relay/SKILL.md delete mode 100644 .agents/skills/mex-relay/agents/openai.yaml delete mode 100644 .agents/skills/mex-relay/references/cli-workflows.md delete mode 100644 .mex/.gitignore delete mode 100644 .mex/AGENTS.md delete mode 100644 .mex/ROUTER.md delete mode 100644 .mex/SETUP.md delete mode 100644 .mex/SYNC.md delete mode 100644 .mex/config.json delete mode 100644 .mex/context/architecture.md delete mode 100644 .mex/context/conventions.md delete mode 100644 .mex/context/decisions.md delete mode 100644 .mex/context/network.md delete mode 100644 .mex/context/protocol.md delete mode 100644 .mex/context/setup.md delete mode 100644 .mex/context/stack.md delete mode 100644 .mex/events/operations.jsonl delete mode 100644 .mex/patterns/INDEX.md delete mode 100644 .mex/patterns/README.md delete mode 100644 .mex/patterns/protocol-change.md delete mode 100644 .mex/patterns/proxy-connection-change.md diff --git a/.agents/skills/mex-inbox/.mex-managed.json b/.agents/skills/mex-inbox/.mex-managed.json deleted file mode 100644 index 64a7433..0000000 --- a/.agents/skills/mex-inbox/.mex-managed.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "schemaVersion": 1, - "owner": "mex-agent", - "skill": "mex-inbox", - "packageVersion": "0.8.2", - "files": { - "SKILL.md": "39cf595ac48203bf49ea2e273ea1c1c25e7ebbf4616c68596cd8e1c08eaf2738", - "agents/openai.yaml": "12a2827fe257c303d926122e4bb590910abd660e6451550a1db68a48037b4402", - "references/cli-workflows.md": "6c91905cc69d8ea47080630ee1551bf1a61ec33605fff01463d4a2ad71f497c6" - } -} diff --git a/.agents/skills/mex-inbox/SKILL.md b/.agents/skills/mex-inbox/SKILL.md deleted file mode 100644 index 7ddb707..0000000 --- a/.agents/skills/mex-inbox/SKILL.md +++ /dev/null @@ -1,44 +0,0 @@ ---- -name: mex-inbox -description: Draft and review contributions to existing MEX project knowledge. Use when the user asks to capture a discussion or decision in project knowledge, propose an addition or correction for team review, or explicitly invokes /mex-inbox or $mex-inbox. Also supports existing Spec proposals. Do not activate for brainstorming alone, routine GROW upkeep, email inboxes, session logs, or handoffs. ---- - -# MEX Inbox - -Turn an explicit request to retain project knowledge into a focused contribution for review. Inbox proposals are review artifacts; accepted knowledge belongs in the existing Wiki Markdown. Ordinary GROW upkeep can continue directly. - -## Keep the scope honest - -- Create one `knowledge.create` or `knowledge.update` change per draft, for an existing kind: `architecture`, `component`, `convention`, `decision`, `pattern`, or `guide`. -- Existing Spec workflows also support `spec.create` and `spec.update` for `spec`, `requirement`, `constraint`, and `acceptance_criterion`. Choose these only for actual Spec-family intent. -- Capture durable conclusions, their rationale, and useful evidence. Do not dump the conversation or present unresolved ideas as agreed facts. -- Do not route session logs, Relays, or routine GROW edits through Inbox merely because they contain context. - -## Prepare a draft - -1. Distill what future agents or teammates need to know from the user's request and discussion. -2. Search existing knowledge first. Prefer correcting or extending the relevant record or section when it already covers the subject; create a new entry when the claim has no suitable home. -3. Read the exact target and current revisions before drafting a correction. Preserve unrelated knowledge when replacing its body. Never guess an ID or revision. -4. Preserve useful files, code, commits, entities, and external links as evidence only when actually available. Never invent provenance, authors, dates, events, or history. -5. Build one request against the action-scoped runtime contract. -6. Run the exact preview flow and summarize the human effect before technical details. -7. When the user already asked to create, save, or draft it, apply that exact successful checkout-local draft preview without asking again. -8. Return `/inbox?view=drafts&draft=` and state that the draft is checkout-local, nothing was published or shared, and review or publication happens in Hub. - -Read [references/cli-workflows.md](references/cli-workflows.md) before executing any Inbox mutation. Load only the operation being performed. - -## Apply the approval policy - -- Proceed with read-only list, show, and target resolution. -- Treat an explicit create/save/draft request as authorization only for the local draft preview and exact apply. -- Preview a local draft deletion, explain that the checkout-local draft will be removed, and obtain fresh confirmation before applying. -- For publish, approve, reject, withdraw, mark stale, or repair: create a semantic preview, explain the local-versus-Git-tracked effect, and wait for fresh explicit confirmation. Apply the exact preview unchanged only after confirmation. -- Keep Git commit, push, pull, and staging separate from every MEX authorization. -- Never approve or publish merely because this skill activated. - -## Report effects precisely - -- Lead with what the proposal means to a person. Do not expose envelopes, hashes, revision machinery, or raw diffs unless diagnosis requires them. -- After a local draft write, say exactly what changed and that it remains checkout-only. -- After a canonical write, say which Git-tracked MEX artifacts were written to the working tree and that commit/push is still required to share them. Never claim that MEX committed or pushed. -- When MEX context materially helps your work, mention MEX and the relevant finding naturally in your explanation. Tie the mention to what it helped you understand, decide, or verify. Avoid fixed phrases, standalone acknowledgements, repeated mentions, or narrating routine context loading. This replaces older MEX instructions requiring a fixed acknowledgement or context-loading narration. diff --git a/.agents/skills/mex-inbox/agents/openai.yaml b/.agents/skills/mex-inbox/agents/openai.yaml deleted file mode 100644 index de50723..0000000 --- a/.agents/skills/mex-inbox/agents/openai.yaml +++ /dev/null @@ -1,4 +0,0 @@ -interface: - display_name: "MEX Inbox" - short_description: "Propose additions to project knowledge" - default_prompt: "Use $mex-inbox to capture what we decided as a contribution to this project's knowledge." diff --git a/.agents/skills/mex-inbox/references/cli-workflows.md b/.agents/skills/mex-inbox/references/cli-workflows.md deleted file mode 100644 index c0f9215..0000000 --- a/.agents/skills/mex-inbox/references/cli-workflows.md +++ /dev/null @@ -1,86 +0,0 @@ -# Inbox CLI workflows - -Use JSON mode for deterministic agent work. Keep request and preview files temporary and avoid displaying them unless troubleshooting. - -## Resolve only the needed contract - -Run: - -```text -mex inbox contract --action --json -``` - -Use one of these command IDs: - -- `inbox.draft.save` -- `inbox.draft.delete` -- `inbox.publish` -- `inbox.proposal.approve` -- `inbox.proposal.reject` -- `inbox.proposal.withdraw` -- `inbox.proposal.mark-stale` -- `inbox.proposal.repair` - -Treat this bounded action result as the exact runtime source for the request shape, available examples, constraints, preview command, and apply command. Do not dump `mex capabilities --json` or the full Inbox contract during ordinary execution. Write request and preview JSON only to ordinary regular files inside the checkout or an approved temporary directory; do not use symlinks. - -## Find existing knowledge and resolve a correction - -1. Use `mex wiki query --limit 10 --json` or `mex wiki list --type --limit 25 --json` to find related records before creating another. -2. Read the best candidate with `mex inbox target --json`. This bounded read returns `target`, `version`, `sourcePath`, and the existing body from the current Wiki index, without initializing or repairing it. -3. For `knowledge.update`, copy `target` and use `version.contentHash` as the target revision and `version.semanticRevision` as the semantic revision. Select a section entity when only that section should change. The patch body replaces the target's body; preserve its relevant existing content. A target can fit the read response but exceed the 16 KiB update-body limit; choose a smaller section or a title/summary-only patch when appropriate, never truncate existing knowledge to fit. -4. If no suitable record exists, use `knowledge.create` with the appropriate existing kind. MEX chooses a path in `context/` or `patterns/`; do not invent an Inbox knowledge category or supply an arbitrary destination path. -5. If several targets remain plausible after reading them, ask which one the user intends. If a read reports a stale or unavailable index, address its explicit maintenance requirement before relying on it; never fabricate revisions or silently refresh an index as part of a read. - -For create-time topics, find them with Wiki reads, then resolve each with `mex inbox target --json` for current revisions. Topics can be dependencies but are not Inbox correction targets. Omit topics when none are needed; normal knowledge creates have no relation editor. - -## Resolve a legacy Spec update - -1. Use `mex spec list --json` to identify candidates. -2. Use `mex spec show --json` for the exact candidate. -3. Match the requested durable claim to one exact entity and kind. -4. Copy `version.contentHash` as the entity revision and `version.semanticRevision` as the semantic revision exactly as the selected contract requires. For nested requirements, constraints, or acceptance criteria, take both from the enclosing `mex spec show` projection. -5. Stop and ask for target clarification when multiple candidates remain plausible. - -Do not invent target IDs, relation endpoints, topic IDs, or revisions. For a create request with relations or topics, resolve every referenced entity and its current revisions first. - -## Save a checkout-local draft - -1. Resolve `inbox.draft.save`. -2. Create a unique operation ID and a request containing one `knowledge.create` or `knowledge.update` draft (or a Spec change for actual Spec-family intent). -3. For a new draft, provide no unrelated expectations. For an existing draft update, read it with `mex inbox draft show --json` and use its exact current local revision. -4. Preview with `mex inbox draft save --json` and capture the complete successful JSON wrapper unchanged. Require `ok: true`, `mode: "preview"`, and `data.preview.valid: true`. -5. Summarize the proposed local effect. If the user asked to create/save/draft, apply with `mex inbox draft save --apply --json` without another confirmation. -6. Read the returned draft ID and respond with `/inbox?view=drafts&draft=`. - -The apply writes only checkout-local draft state. It does not create a canonical proposal, Activity record, commit, push, or notification. Apply before the preview expires; if anything changes or the preview becomes stale, preview again instead of reconstructing it. - -## Delete a local draft - -1. Read the exact draft and current local revision. -2. Resolve and preview `inbox.draft.delete`. -3. Explain that the checkout-local draft will be deleted and wait for fresh confirmation. -4. Apply the captured preview unchanged with `mex inbox draft delete --apply --json`. - -## Publish a draft - -1. Read the exact draft and resolve `inbox.publish`. -2. Build the request with the exact local draft revision and preview using `mex inbox publish --json`. -3. Explain that applying writes a canonical proposal and Activity artifact into the working tree while leaving Git commit/push separate. -4. Wait for fresh explicit confirmation. -5. Apply the exact preview with `mex inbox publish --apply --json`. -6. Return `/inbox?view=review&proposal=`. - -Publishing removes the exact local draft after creating the pending proposal. It does not approve the proposal or change accepted knowledge. The proposal is Markdown in the working tree; teammates receive it through Git. - -## Review canonical proposals - -Use `mex inbox proposal list --json` and `mex inbox proposal show --json` for read-only review. For approve, reject, withdraw, mark-stale, or repair: - -1. Resolve the matching command ID. -2. Use the proposal's exact current artifact revision and any action-specific rationale or replacement draft. -3. Preview with the corresponding `mex inbox proposal --json` command. -4. Explain the semantic outcome and which canonical Git-tracked MEX records would change. -5. Wait for fresh explicit confirmation. -6. Apply the exact preview with the same command plus `--apply --json`. - -Approval writes the proposed knowledge change, proposal decision, Wiki ledger, and Activity records to the working tree. The proposal remains review history. Reject and withdraw make a terminal proposal decision without changing knowledge. Mark stale changes a pending proposal to stale only when MEX proves dependency drift. Repair replaces stale intent, clears prior review, and returns the proposal to pending without changing knowledge. These canonical transitions write Activity records; none commits, pushes, pulls, stages, or notifies teammates. diff --git a/.agents/skills/mex-relay/.mex-managed.json b/.agents/skills/mex-relay/.mex-managed.json deleted file mode 100644 index 20ae02b..0000000 --- a/.agents/skills/mex-relay/.mex-managed.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "schemaVersion": 1, - "owner": "mex-agent", - "skill": "mex-relay", - "packageVersion": "0.8.2", - "files": { - "SKILL.md": "186d1d19c4b513f4b98ee27bf0259744d1ef79ffc758676484596cfe498aa502", - "agents/openai.yaml": "9c2e9c2e34d60ec0f4d07089b07d9e49a6c8210c2a3e277593c15a2635f03076", - "references/cli-workflows.md": "56b6e74129cdc6ddb5121480b03e01fd2f1f65b7b8c0b7899552a4a217d48cf5" - } -} diff --git a/.agents/skills/mex-relay/SKILL.md b/.agents/skills/mex-relay/SKILL.md deleted file mode 100644 index 1593561..0000000 --- a/.agents/skills/mex-relay/SKILL.md +++ /dev/null @@ -1,39 +0,0 @@ ---- -name: mex-relay -description: Prepare and manage durable MEX team handoffs. Use when the user asks to hand work to a person or team, prepare an end-of-session handoff, save what the next engineer needs, create a MEX Relay, take or close a Relay, or explicitly invokes /mex-relay or $mex-relay. Treat Relay as a memory and context baton, not chat, notifications, task assignment, issue tracking, or a Jira replacement; do not activate for ordinary status messages that are not durable handoffs. ---- - -# MEX Relay - -Prepare durable team handoffs that another engineer can continue from. Never represent a Relay as a sent message or notification. - -## Prepare a Relay draft - -1. Infer the useful session state: a concise summary, current position, completed work, in-progress work, blockers, unresolved questions, next actions, and relevant decisions, files, code, commits, or external links. -2. For “whoever picks this up,” choose open-to-team. It includes future active project Members; no Member lookup is needed to save this local draft. If the user names people, retain named-recipient intent and resolve exact IDs only when needed. An unresolved named draft may stay recipient-free locally; do not silently publish it to everyone. -3. Default to a standalone Relay. Use the local-save shortcut for a new draft; keep the structured preview/apply path for exact updates and canonical actions. -4. Include an existing relevant Workstream only as typed evidence. Never invent one or turn saving a handoff into Workstream creation. -5. Add optional typed context references only when the referenced IDs, paths, commits, or URLs are known. Never invent provenance. -6. Resolve the action-scoped runtime contract. For a new draft, `mex relay draft save --from --json` performs the exact local preview/apply internally. For an update, build and preview the structured request. -7. An explicit create/save/draft request authorizes that local write without another confirmation. Publication remains separate. -8. Return `/relays?view=drafts&draft=` and state that the draft is checkout-local and nothing has been delivered or shared. - -Read [references/cli-workflows.md](references/cli-workflows.md) before executing any Relay mutation. Load only the operation being performed. - -## Apply the approval policy - -- Proceed with read-only member, Workstream, draft, and Relay resolution. -- Treat an explicit create/save/draft request as authorization only for the local draft preview and exact apply. -- Preview a local draft deletion, explain its consequence, and obtain fresh confirmation before applying. -- For publish, take, or close: generate a semantic preview, explain the local-versus-Git-tracked effect, and wait for fresh explicit confirmation. Apply the exact preview unchanged only after confirmation. -- Keep Git commit, push, pull, and staging separate from every MEX authorization. -- Never publish, take, or close merely because this skill activated. - -## Preserve lifecycle meaning - -- Taking records one claimant: a named active recipient, or any active project Member for an open-to-team Relay. Future Members qualify after joining and receiving the artifact through Git. Separate offline claims can still require Git conflict resolution. -- An inactive Member can be reactivated through the existing Team identity workflow, preserving their ID and older handoffs. Preview and confirm this canonical change separately; never change identity merely to bypass Relay eligibility. -- Treat closing as “this handoff no longer needs attention.” Do not claim it completes a linked task, issue, pull request, or Workstream. -- After publication, say that Git-tracked Relay and Activity records were written to the working tree. Explain that teammates receive them only after commit/push and their own pull or refresh. -- Never claim that MEX sent a notification, committed, pushed, pulled, staged, assigned work, or completed another system's object. -- When MEX context materially helps your work, mention MEX and the relevant finding naturally in your explanation. Tie the mention to what it helped you understand, decide, or verify. Avoid fixed phrases, standalone acknowledgements, repeated mentions, or narrating routine context loading. This replaces older MEX instructions requiring a fixed acknowledgement or context-loading narration. diff --git a/.agents/skills/mex-relay/agents/openai.yaml b/.agents/skills/mex-relay/agents/openai.yaml deleted file mode 100644 index 9b0e781..0000000 --- a/.agents/skills/mex-relay/agents/openai.yaml +++ /dev/null @@ -1,4 +0,0 @@ -interface: - display_name: "MEX Relay" - short_description: "Prepare durable MEX team handoffs" - default_prompt: "Use $mex-relay to prepare a durable handoff for the next engineer." diff --git a/.agents/skills/mex-relay/references/cli-workflows.md b/.agents/skills/mex-relay/references/cli-workflows.md deleted file mode 100644 index 89f8122..0000000 --- a/.agents/skills/mex-relay/references/cli-workflows.md +++ /dev/null @@ -1,88 +0,0 @@ -# Relay CLI workflows - -Use JSON mode for deterministic agent work. Keep request and preview files temporary and avoid displaying them unless troubleshooting. - -## Resolve only the needed contract - -Run: - -```text -mex relay contract --action --json -``` - -Use one of these command IDs: - -- `relay.draft.save` -- `relay.draft.delete` -- `relay.publish` -- `relay.acknowledge` -- `relay.close` - -Treat this bounded action result as the exact runtime source for the request shape, available examples, constraints, preview command, and apply command. Do not dump `mex capabilities --json` or the full Relay contract during ordinary execution. Write request and preview JSON only to ordinary regular files inside the checkout or an approved temporary directory; do not use symlinks. - -## Choose an audience and optional context - -1. For an open handoff or “save for whoever picks it up,” use `audience: "team"` and `recipients: []`. Do not enumerate today's Members; active Members who join later must remain eligible. This setting does not share the local draft. -2. For named people, use `audience: "members"`. Resolve names with `mex member list --active --limit 100 --json` and bounded cursors. Local drafts may retain an empty recipient array while names are unresolved; record the intended name in `unresolvedQuestions` and resolve it before publication. -3. Use `mex member show --json` for disambiguation or exact publication revisions. Ask when named recipients remain ambiguous; never reinterpret a named subset such as “the backend team” as every project Member. -4. Default to no Workstream lookup. If the user named a Workstream or the handoff clearly belongs to an existing one, run `mex workstream list --json` and `mex workstream show --json` to resolve it exactly. -5. In Relay v3, preserve a relevant Workstream as typed entity evidence when the selected contract supports it; do not author the legacy top-level Workstream field. - -Never fabricate recipient IDs, entity IDs, revisions, commits, code fingerprints, paths, URLs, or provenance. - -## Save a checkout-local draft - -1. Resolve `relay.draft.save`. -2. Write one temporary JSON object containing the draft content. Include a concise summary, the intended audience, and only useful non-empty context sections. Prefer accurate omissions over invented completeness. -3. For a new draft, run `mex relay draft save --from --operation-id --json`. This validates the content, obtains a signed local preview, and applies that exact preview internally. It never publishes and needs no Member resolution. Do not combine `--from` with a request file or `--apply`. -4. Require `ok: true`, `mode: "apply"`, and `data.applied: true`; read the draft ID from `data.localChanges` and return `/relays?view=drafts&draft=`. The shortcut retains the original preview under `.mex/local/relay-previews/` before applying and removes it after success. An interrupted save can resume with the same operation ID and unchanged content, or the exact `problem.recovery` command. Do not replace the receipt or create another operation to work around an interrupted/conflicting result; if recovery is refused, report it and inspect the existing draft state. - -For example, a new open handoff may contain: - -```json -{ - "audience": "team", - "recipients": [], - "summary": "Continue the parser correction.", - "completed": ["Reproduced the failure with the nested-import fixture."], - "nextActions": ["Check whether the same failure affects exported aliases."] -} -``` - -For an existing draft update, read it with `mex relay draft show --json`, preserve its content, and use its exact local revision in the structured request. Preview with `mex relay draft save --json`; require `ok: true`, `mode: "preview"`, and `data.preview.valid: true`. Apply the complete captured envelope unchanged with `mex relay draft save --apply --json`. An explicit save/update request needs no additional confirmation for this checkout-local write. - -The apply writes only checkout-local draft state in `.mex/local/team.db`. It does not create a canonical Relay or Activity record, deliver a handoff, commit, push, or notify anyone. Apply before the preview expires; if anything changes or the preview becomes stale, preview again instead of reconstructing it. - -## Delete a local draft - -1. Read the exact draft and current local revision. -2. Resolve and preview `relay.draft.delete`. -3. Explain that the checkout-local draft will be deleted and wait for fresh confirmation. -4. Apply the captured preview unchanged with `mex relay draft delete --apply --json`. - -## Publish a Relay - -1. Read the exact draft. For an open-to-team audience, no recipient Member list is needed. For named recipients, require at least one and read each current active Member; an empty named draft must be completed before publication. -2. Resolve `relay.publish`. Team publication expects only the exact local draft revision; named publication also expects every recipient Member revision. Preview with `mex relay publish --json`. The service verifies the current active sender in both cases. -3. Explain that applying replaces the private local draft with canonical Git-tracked Relay and Activity records in the working tree, records the service-observed branch/HEAD/dirty repository state without copying dirty source contents, and does not deliver through a notification service or share before Git commit/push and teammate pull/refresh. -4. Wait for fresh explicit confirmation. -5. Apply the exact preview with `mex relay publish --apply --json`. -6. Return `/relays?view=sent&state=open&relay=`. - -## Take a Relay - -1. Resolve the exact published Relay with `mex relay show --json`. A team audience allows the current active project Member; a named audience requires the current Member to be listed. An omitted audience on an older Relay means named recipients. -2. Resolve `relay.acknowledge` and preview with `mex relay acknowledge --json`. -3. Explain that applying records the current Member as claimant and writes canonical Relay/Activity state in the working tree. A synchronized claim prevents another take; separate offline claims still require Git conflict resolution. There is no unclaim or reassignment action, and it does not assign or start a task elsewhere. -4. Wait for fresh explicit confirmation, then apply the exact preview with `mex relay acknowledge --apply --json`. -5. Return `/relays?view=mine&state=open&relay=`. - -## Close a Relay - -1. Resolve the exact acknowledged Relay and its current revision. -2. Resolve `relay.close` and preview with `mex relay close --json`. -3. Explain that applying irreversibly marks only the handoff as no longer needing attention and writes canonical Relay/Activity state in the working tree. -4. Wait for fresh explicit confirmation, then apply the exact preview with `mex relay close --apply --json`. -5. Return `/relays?view=all&state=closed&relay=`. - -Closing does not complete a linked task, issue, pull request, or Workstream. No lifecycle command stages, commits, pushes, pulls, or sends a notification. diff --git a/.mex/.gitignore b/.mex/.gitignore deleted file mode 100644 index a2ec937..0000000 --- a/.mex/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -graph.db* -wiki.db* -local/ diff --git a/.mex/AGENTS.md b/.mex/AGENTS.md deleted file mode 100644 index 30bb2b3..0000000 --- a/.mex/AGENTS.md +++ /dev/null @@ -1,17 +0,0 @@ ---- -name: agents -description: VotifierPlus MEX authority and protocol context guide. -last_updated: 2026-09-20 ---- - -# VotifierPlus memory - -Root `AGENTS.md` defines authority and use. This Wiki records protocol/security compatibility constraints; it is not a substitute for current Java/tests. MEX 0.8.2 does not structurally index Java. See `ROUTER.md` for topic routes. - - -## MEX context policy -- When MEX context materially helps your work, mention MEX and the relevant finding naturally in your explanation. Tie the mention to what it helped you understand, decide, or verify. Avoid fixed phrases, standalone acknowledgements, repeated mentions, or narrating routine context loading. This replaces older MEX instructions requiring a fixed acknowledgement or context-loading narration. -- Do not claim an author, date, or historical event unless the retrieved data actually provides it. -- After a MEX write, say exactly what changed and its sharing boundary: a local draft is checkout-only and nothing is shared; a canonical artifact is written to the working tree and requires commit/push to share. -- Skill activation is not approval for canonical actions. - diff --git a/.mex/ROUTER.md b/.mex/ROUTER.md deleted file mode 100644 index 16d54dc..0000000 --- a/.mex/ROUTER.md +++ /dev/null @@ -1,22 +0,0 @@ ---- -name: router -description: VotifierPlus protocol and security memory routes. -edges: - - target: patterns/protocol-change.md - condition: when parsing or negotiating vote formats - - target: patterns/proxy-connection-change.md - condition: when changing network or source-IP handling -last_updated: 2026-09-20 ---- - -# VotifierPlus memory routes - -| Task | Read | -| --- | --- | -| Packet versions or downgrade behavior | `context/protocol.md`, `patterns/protocol-change.md` | -| Network, proxy headers, throttling | `context/network.md`, `patterns/proxy-connection-change.md` | -| Event/platform boundaries | `context/architecture.md` | -| Security rationale and legacy concerns | `context/decisions.md` | -| Build and MEX limits | `context/stack.md`, `context/setup.md` | - -Retrieve only relevant memory, then verify Java source, tests, and configuration defaults. diff --git a/.mex/SETUP.md b/.mex/SETUP.md deleted file mode 100644 index 1c3dee5..0000000 --- a/.mex/SETUP.md +++ /dev/null @@ -1,3 +0,0 @@ -# VotifierPlus MEX setup - -Codex uses the official MEX Inbox and Relay skills. Java source is not structurally indexed by MEX 0.8.2. Use Wiki context, then inspect Java source and tests. diff --git a/.mex/SYNC.md b/.mex/SYNC.md deleted file mode 100644 index 419e6d8..0000000 --- a/.mex/SYNC.md +++ /dev/null @@ -1,3 +0,0 @@ -# Keep VotifierPlus memory current - -Follow root `AGENTS.md` authority rules. Verify protocol and security claims against current parser/tests/configuration. Correct stale entries through reviewed MEX edits or Inbox and rebuild the Wiki index. diff --git a/.mex/config.json b/.mex/config.json deleted file mode 100644 index c46a8c4..0000000 --- a/.mex/config.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "setupMode": "code-repo", - "aiTools": [ - "codex" - ], - "scaffold_id": "4653ca9c-2291-458c-8476-ae08bec4291f", - "scaffold_name": "VotifierPlus", - "origin": null, - "upstream": null -} diff --git a/.mex/context/architecture.md b/.mex/context/architecture.md deleted file mode 100644 index d988e97..0000000 --- a/.mex/context/architecture.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: architecture -description: Vote receiver and platform event boundary. -triggers: [architecture, vote, event, proxy] -last_updated: 2026-09-20 -mex: - id: mx_01M307A5P51CDX3XQVFMYGA7BA - type: architecture - status: promoted - revision: 1 - title: architecture ---- - -# Vote delivery boundary - -The network receiver parses an accepted socket into a vote request, and platform adapters expose Votifier events for Bukkit, BungeeCord, or Velocity consumers. VotingPlugin consumes the Votifier API event but owns downstream totals/rewards; this repository does not prove vote reward durability. Source: `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteReceiver.java`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/model/VotifierEvent.java`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/bungee/`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/velocity/`. - -Forwarding is a separate outbound path configured per target server. Keep receive authentication and forwarding credentials distinct. Source: `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteForwarder.java`, `VotifierPlus/src/main/resources/config.yml`. diff --git a/.mex/context/conventions.md b/.mex/context/conventions.md deleted file mode 100644 index 42f7d93..0000000 --- a/.mex/context/conventions.md +++ /dev/null @@ -1,16 +0,0 @@ ---- -name: conventions -description: Formal source and test ownership. -triggers: [convention, testing] -last_updated: 2026-09-20 -mex: - id: mx_01M307A5Q3M393KGEQMG5HGEK3 - type: convention - status: promoted - revision: 1 - title: conventions ---- - -# Rule ownership - -Use root `AGENTS.md`, current source/tests, and deployment configuration for current behavior. MEX retains protocol rationale and traps, not generic Java/Maven or review instructions. diff --git a/.mex/context/decisions.md b/.mex/context/decisions.md deleted file mode 100644 index 1363243..0000000 --- a/.mex/context/decisions.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: decisions -description: Current, legacy, and security categories. -triggers: [decision, security, downgrade, legacy] -last_updated: 2026-09-20 -mex: - id: mx_01M307CFHKV470P8EA8CZ8QVQN - type: decision - status: promoted - revision: 1 - title: Security and compatibility categories ---- - -# Security and compatibility categories - -Current required behavior: reject malformed or unauthenticated V2 votes and honor `DisableV1` when set. Legacy compatibility behavior: defaults currently leave V1 enabled, and the receiver warns when TokenSupport is on without DisableV1. That compatibility default is not a recommendation for token-only deployments. Known security concern: enabling tokens alone still permits V1 acceptance, so a site requiring token-authenticated votes must disable V1 only after confirming every configured sender supports V2. Source: `VotifierPlus/src/main/resources/config.yml`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteReceiver.java`, `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteProtocolSecurityTest.java`. - -Future desired behavior is not specified by this checkout. Do not silently reinterpret the compatibility default as a promised migration plan. diff --git a/.mex/context/network.md b/.mex/context/network.md deleted file mode 100644 index dfd080e..0000000 --- a/.mex/context/network.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: network -description: Connection budget and proxy header trust boundary. -triggers: [network, PROXY, throttle, thread, tunnel] -last_updated: 2026-09-20 -mex: - id: mx_01M307CW4VKS6V9B37VZQDZN8F - type: component - status: promoted - revision: 1 - title: Connection and proxy header boundary ---- - -# Connection boundary - -The receiver uses bounded connection and forwarding executors and timeouts. Throttling is available but disabled in default configuration. The connection handler processes optional PROXY/CONNECT headers before vote parsing. Only textual PROXY v1 currently supplies a reported client IP for throttling; PROXY v2 is discarded and CONNECT does not supply one. There is no trusted-proxy allowlist for PROXY v1 in this path, so a directly connected client can spoof that metadata and affect attribution/throttle keys. It does not bypass V2 HMAC authentication. Source: `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteReceiver.java`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteConnectionHandler.java`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/ProxyHeaderProcessor.java`, `VotifierPlus/src/main/resources/config.yml`. - -Tunnel egress IP settings and per-client bans have different purposes: the documented throttle policy warns not to put ordinary backend/proxy IPs in the tunnel list, and per-client bans require a known real client IP. Check both parser tests and throttle tests when changing this boundary. Source: `VotifierPlus/src/main/resources/config.yml`, `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteReceiverThrottleTest.java`. diff --git a/.mex/context/protocol.md b/.mex/context/protocol.md deleted file mode 100644 index 577011e..0000000 --- a/.mex/context/protocol.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: protocol -description: Current V1/V2 parsing and token compatibility. -triggers: [protocol, token, RSA, V1, V2] -last_updated: 2026-09-20 -mex: - id: mx_01M307CW4VM5CZ0SZXZBWYWHK7 - type: component - status: promoted - revision: 1 - title: Vote protocol versions ---- - -# Protocol versions - -Current behavior: V2 votes use a token/HMAC-SHA256 signature; the parser accepts framed and unframed V2 forms and checks the challenge. V2 parsing is not gated by `TokenSupport`; that setting affects handshake selection and the compatibility warning. `DisableV1` rejects legacy V1 packets and forces a V2 handshake. Token support alone does not disable V1. Source: `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteParser.java`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteConnectionHandler.java`, `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteProtocolSecurityTest.java`, `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteReceiverTest.java`. - -Legacy compatibility: V1 uses a fixed 256-byte RSA packet. A V1 block may begin with bytes that look like a V2 frame; the parser has a bounded collision/grace path rather than treating the prefix alone as definitive. `DisableV1` rejects V1 votes, so enable it only after confirming every configured sender supports V2. Source: `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteParser.java`, `VotifierPlus/src/main/java/com/vexsoftware/votifier/net/VoteConnectionHandler.java`, `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteReceiverTest.java`, `VotifierPlus/src/main/resources/config.yml`. diff --git a/.mex/context/setup.md b/.mex/context/setup.md deleted file mode 100644 index 2a4d7c7..0000000 --- a/.mex/context/setup.md +++ /dev/null @@ -1,16 +0,0 @@ ---- -name: setup -description: MEX use for VotifierPlus. -triggers: [setup, MEX, graph] -last_updated: 2026-09-20 -mex: - id: mx_01M307A5QDKVASN6NXQ8HE4RYW - type: guide - status: promoted - revision: 1 - title: setup ---- - -# MEX use - -Use Wiki for protocol/security context and current Java source/tests for implementation truth. After memory changes run `mex wiki rebuild-index` and `mex check`. CLI use needs no Hub. diff --git a/.mex/context/stack.md b/.mex/context/stack.md deleted file mode 100644 index 5a3bd80..0000000 --- a/.mex/context/stack.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -name: stack -description: Current platform and build boundary. -triggers: [Java, Maven, Bukkit, Velocity, BungeeCord] -last_updated: 2026-09-20 ---- - -# Platform boundary - -The single nested Maven project targets Java 21 and produces a plugin artifact with Bukkit, BungeeCord, and Velocity entry points. CI uses `mvn -B -f VotifierPlus/pom.xml package`. Inspect current POM and plugin descriptors for exact platform/version support. MEX 0.8.2 has no Java Code Graph here. Source: `VotifierPlus/pom.xml`, `.github/workflows/maven.yml`. diff --git a/.mex/events/operations.jsonl b/.mex/events/operations.jsonl deleted file mode 100644 index 145008b..0000000 --- a/.mex/events/operations.jsonl +++ /dev/null @@ -1,10 +0,0 @@ -{"v":1,"phase":"intent","opId":"mig_04bdfe68d2f7f9f793ced12eadc3a4027c0b5a64","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5P51CDX3XQVFMYGA7BA"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["context/architecture.md"],"payloadHash":"60e9cb3b8cf14fc598ca64e965b4e9a2e20ef743ac37abc02e2c86cc48103ff5","revisions":[{"entityId":"mx_01M307A5P51CDX3XQVFMYGA7BA","before":0,"after":1}]} -{"v":1,"phase":"complete","opId":"mig_04bdfe68d2f7f9f793ced12eadc3a4027c0b5a64","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5P51CDX3XQVFMYGA7BA"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["context/architecture.md"],"payloadHash":"60e9cb3b8cf14fc598ca64e965b4e9a2e20ef743ac37abc02e2c86cc48103ff5","revisions":[{"entityId":"mx_01M307A5P51CDX3XQVFMYGA7BA","before":0,"after":1}]} -{"v":1,"phase":"intent","opId":"mig_bba7e40030721976170be1e0e46673406f16555f","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5Q3M393KGEQMG5HGEK3"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["context/conventions.md"],"payloadHash":"dea0802d2c6208b2f103f615a1a322ba63f9a35dbddbe82d49988f8ed41f86ae","revisions":[{"entityId":"mx_01M307A5Q3M393KGEQMG5HGEK3","before":0,"after":1}]} -{"v":1,"phase":"complete","opId":"mig_bba7e40030721976170be1e0e46673406f16555f","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5Q3M393KGEQMG5HGEK3"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["context/conventions.md"],"payloadHash":"dea0802d2c6208b2f103f615a1a322ba63f9a35dbddbe82d49988f8ed41f86ae","revisions":[{"entityId":"mx_01M307A5Q3M393KGEQMG5HGEK3","before":0,"after":1}]} -{"v":1,"phase":"intent","opId":"mig_8dba03310a5302a413a7df38e88f6c2de16bc1e0","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5QDKVASN6NXQ8HE4RYW"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["context/setup.md"],"payloadHash":"cf355dba2ffc569444242ee5b2fce6dd91e95d47beb012e590e6b8893c2314a4","revisions":[{"entityId":"mx_01M307A5QDKVASN6NXQ8HE4RYW","before":0,"after":1}]} -{"v":1,"phase":"complete","opId":"mig_8dba03310a5302a413a7df38e88f6c2de16bc1e0","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5QDKVASN6NXQ8HE4RYW"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["context/setup.md"],"payloadHash":"cf355dba2ffc569444242ee5b2fce6dd91e95d47beb012e590e6b8893c2314a4","revisions":[{"entityId":"mx_01M307A5QDKVASN6NXQ8HE4RYW","before":0,"after":1}]} -{"v":1,"phase":"intent","opId":"mig_8cb606ce9a66b98026fdd27e6a07c26fd55b0907","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5QQDBA5HQKJCQ24BVRX"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["patterns/protocol-change.md"],"payloadHash":"a28fc2d1dca29a6414dcaa2eeb896536554996bd23e1a4faf6f42c3190e29a13","revisions":[{"entityId":"mx_01M307A5QQDBA5HQKJCQ24BVRX","before":0,"after":1}]} -{"v":1,"phase":"complete","opId":"mig_8cb606ce9a66b98026fdd27e6a07c26fd55b0907","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5QQDBA5HQKJCQ24BVRX"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["patterns/protocol-change.md"],"payloadHash":"a28fc2d1dca29a6414dcaa2eeb896536554996bd23e1a4faf6f42c3190e29a13","revisions":[{"entityId":"mx_01M307A5QQDBA5HQKJCQ24BVRX","before":0,"after":1}]} -{"v":1,"phase":"intent","opId":"mig_026584c05568eab3f76c419ba94a761f972bd0a1","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5R34GQ529RP0RK12MQH"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["patterns/proxy-connection-change.md"],"payloadHash":"3560c98efcc49337d91d5eb4f1777e4d9465fec5bf07b19ec3ab2ab25e0080f0","revisions":[{"entityId":"mx_01M307A5R34GQ529RP0RK12MQH","before":0,"after":1}]} -{"v":1,"phase":"complete","opId":"mig_026584c05568eab3f76c419ba94a761f972bd0a1","type":"create-entry","entityIds":[],"createdIds":["mx_01M307A5R34GQ529RP0RK12MQH"],"actor":{"kind":"system","id":"mex-migration"},"timestamp":"2026-01-01T00:00:00.000Z","files":["patterns/proxy-connection-change.md"],"payloadHash":"3560c98efcc49337d91d5eb4f1777e4d9465fec5bf07b19ec3ab2ab25e0080f0","revisions":[{"entityId":"mx_01M307A5R34GQ529RP0RK12MQH","before":0,"after":1}]} diff --git a/.mex/patterns/INDEX.md b/.mex/patterns/INDEX.md deleted file mode 100644 index b71b5ed..0000000 --- a/.mex/patterns/INDEX.md +++ /dev/null @@ -1,6 +0,0 @@ -# VotifierPlus patterns - -| Pattern | When useful | -| --- | --- | -| [protocol-change.md](protocol-change.md) | Changing V1/V2 parsing or handshake | -| [proxy-connection-change.md](proxy-connection-change.md) | Changing PROXY/CONNECT headers or throttling | diff --git a/.mex/patterns/README.md b/.mex/patterns/README.md deleted file mode 100644 index 534f03e..0000000 --- a/.mex/patterns/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# VotifierPlus patterns - -Task-specific protocol and network traps only. Verify against current source/tests. Do not turn legacy acceptance into an unqualified security recommendation. diff --git a/.mex/patterns/protocol-change.md b/.mex/patterns/protocol-change.md deleted file mode 100644 index 79c126d..0000000 --- a/.mex/patterns/protocol-change.md +++ /dev/null @@ -1,16 +0,0 @@ ---- -name: protocol-change -description: Preserve explicit V1 compatibility and V2 authentication boundaries. -triggers: [protocol, V1, V2, token] -last_updated: 2026-09-20 -mex: - id: mx_01M307A5QQDBA5HQKJCQ24BVRX - type: pattern - status: promoted - revision: 1 - title: protocol-change ---- - -# Protocol change - -Trace handshake, prefix detection, framed/unframed parsing, V1 collision handling, signature verification, and event dispatch. Test TokenSupport and DisableV1 independently; V2 can be parsed when TokenSupport is false, while token support alone leaves V1 allowed under current defaults. Parsing/collision tests are in `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteReceiverTest.java`; mode rejection tests are in `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteProtocolSecurityTest.java`. diff --git a/.mex/patterns/proxy-connection-change.md b/.mex/patterns/proxy-connection-change.md deleted file mode 100644 index 28eb012..0000000 --- a/.mex/patterns/proxy-connection-change.md +++ /dev/null @@ -1,16 +0,0 @@ ---- -name: proxy-connection-change -description: Keep proxy header, timeout, and throttle semantics distinct. -triggers: [PROXY, CONNECT, tunnel, throttle] -last_updated: 2026-09-20 -mex: - id: mx_01M307A5R34GQ529RP0RK12MQH - type: pattern - status: promoted - revision: 1 - title: proxy-connection-change ---- - -# Proxy connection change - -Trace socket peer, optional reported source IP, header bounds, parser deadline, and throttle key together. Reported source IP is not a vote credential. Check malformed/truncated headers and tunnel-mode behavior against `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/ProxyHeaderProcessorSecurityTest.java` and `VotifierPlus/src/test/java/com/bencodez/votifierplus/tests/VoteReceiverThrottleTest.java`. diff --git a/AGENTS.md b/AGENTS.md index e3ecc43..c8d517f 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -81,14 +81,14 @@ For substantive changes, obtain a fresh source-read-only review. Add a bounded s ## MEX project memory -For substantive protocol, security-compatibility, or architecture tasks, read relevant MEX context and then verify against current Java/tests and formal docs. Use code/tests first, this guide and formal docs second, reviewed MEX third, and historical Relays last; correct stale claims. Skip MEX for trivial edits. MEX 0.8.2 does not index Java here. Treat legacy packet acceptance as compatibility, not a security recommendation. Use `$mex-inbox` for durable findings and `$mex-relay` for substantial unfinished handoffs. +For substantive protocol, security-compatibility, or architecture tasks, read relevant MEX context and then verify against current Java/tests and formal docs. Use code/tests first, this guide and formal docs second, reviewed MEX third, and historical Relays last; correct stale claims. Skip MEX for trivial edits. MEX 0.8.2 does not index Java here. Treat legacy packet acceptance as compatibility, not a security recommendation. Use the verified private MEX skills for durable findings and substantial unfinished handoffs. ## MEX agent skills -- At the start of every session, read `.mex/AGENTS.md` and `.mex/ROUTER.md` before project work; follow `ROUTER.md` to load only the relevant context. +- At the start of every session, use the configured project knowledge reader to verify the private MEX projection, then read its `.mex/AGENTS.md` and `.mex/ROUTER.md` and follow the router for relevant context. Run knowledge queries in that projection; read checkout-local drafts and preferences in the writable workspace when applicable. Report an unavailable reader rather than substituting another project's memory. - Read `mex logging --json` at session start and before optional logging. Its checkout-local advisory mode is `significant` (quiet default: material decisions, risks, blockers, or durable discoveries), `checkpoints` (batch useful notes at task/session boundaries), or `manual` (no unsolicited notes). Skip routine tool calls, edits, repeated status, and empty summaries. Honor explicit user log requests in every mode; never suppress mandatory workflow Activity or recovery audit records. Report a policy read failure instead of guessing or changing the preference. - When earlier work may inform the task, retrieve bounded relevant notes with `mex timeline --query "subject phrase" --file src/example.ts --limit 10 --json`, using the known subject or exact recorded file path, or both. Treat matches as historical evidence, not accepted current knowledge; verify conclusions before reuse or explicit promotion with their source retained. -- Use `$mex-inbox` for explicit contributions to project knowledge and `$mex-relay` for durable team handoffs. Invoke them automatically when intent clearly matches; ordinary GROW upkeep remains available without Inbox. +- Read `.agents/skills/mex-inbox/SKILL.md` and `.agents/skills/mex-relay/SKILL.md` from this project's entry in the verified private knowledge archive. Perform MEX writes only through a supported writable project workspace and its publication workflow, never in the read-only projection; report an unavailable workspace. - When MEX context materially helps your work, mention MEX and the relevant finding naturally in your explanation. Tie the mention to what it helped you understand, decide, or verify. Avoid fixed phrases, standalone acknowledgements, repeated mentions, or narrating routine context loading. This replaces older MEX instructions requiring a fixed acknowledgement or context-loading narration. - Do not claim an author, date, or historical event unless the retrieved data actually provides it. - After a MEX write, say exactly what changed and its sharing boundary: a local draft is checkout-only and nothing is shared; a canonical artifact is written to the working tree and requires commit/push to share. From 7e276174336d2d0ba8a95db96ea4e4d6ece99376 Mon Sep 17 00:00:00 2001 From: BenCodez <17074231+BenCodez@users.noreply.github.com> Date: Sun, 15 Nov 2026 14:09:05 -0600 Subject: [PATCH 2/2] docs: explain project knowledge reader setup --- AGENTS.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/AGENTS.md b/AGENTS.md index c8d517f..fc66263 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -86,6 +86,16 @@ For substantive protocol, security-compatibility, or architecture tasks, read re ## MEX agent skills - At the start of every session, use the configured project knowledge reader to verify the private MEX projection, then read its `.mex/AGENTS.md` and `.mex/ROUTER.md` and follow the router for relevant context. Run knowledge queries in that projection; read checkout-local drafts and preferences in the writable workspace when applicable. Report an unavailable reader rather than substituting another project's memory. +- If the project reader is not configured, ask the maintainer for the approved platform helper, project-specific admission bound to your exact clean checkout and its independently supplied admission SHA-256, immutable archive revision, isolated projection, and separate hash-verified skill snapshot, using your own authorized access. Do not copy credentials or derive an approval pin from an arbitrary download. If the bundle or access is unavailable, report it and stop memory-dependent work until it is available; do not substitute another project's memory. +- For a separately approved source-removal admission, replace the placeholders below with the maintainer-provided values and run the existing bounded query helper. It verifies the admission before and after the query and returns only admitted `.mex` paths. Open the returned files under the approved projection, and read its `.mex/AGENTS.md` and `.mex/ROUTER.md`. Read Inbox and Relay from the separate verified skill snapshot bound to the same source and archive revision; do not place the skill instruction root in the read-only projection. If verification or lookup fails, stop and request corrected access or configuration. + + ```sh + python3 /path/to/approved-platform/scripts/query_knowledge_reader.py \ + --manifest /private/admission.json --manifest-sha256 INDEPENDENTLY_PROVIDED_PIN \ + --project CURRENT_FRESH_CHECKOUT --reader APPROVED_PROJECTION \ + --removal-mode --limit 10 protocol + ``` + - Read `mex logging --json` at session start and before optional logging. Its checkout-local advisory mode is `significant` (quiet default: material decisions, risks, blockers, or durable discoveries), `checkpoints` (batch useful notes at task/session boundaries), or `manual` (no unsolicited notes). Skip routine tool calls, edits, repeated status, and empty summaries. Honor explicit user log requests in every mode; never suppress mandatory workflow Activity or recovery audit records. Report a policy read failure instead of guessing or changing the preference. - When earlier work may inform the task, retrieve bounded relevant notes with `mex timeline --query "subject phrase" --file src/example.ts --limit 10 --json`, using the known subject or exact recorded file path, or both. Treat matches as historical evidence, not accepted current knowledge; verify conclusions before reuse or explicit promotion with their source retained. - Read `.agents/skills/mex-inbox/SKILL.md` and `.agents/skills/mex-relay/SKILL.md` from this project's entry in the verified private knowledge archive. Perform MEX writes only through a supported writable project workspace and its publication workflow, never in the read-only projection; report an unavailable workspace.