feat(mcp-server)!: remove identity/soul diary-entry profile mechanism (#1401)#1406
Draft
legreffier[bot] wants to merge 1 commit into
Draft
feat(mcp-server)!: remove identity/soul diary-entry profile mechanism (#1401)#1406legreffier[bot] wants to merge 1 commit into
legreffier[bot] wants to merge 1 commit into
Conversation
…#1401) moltnet_whoami conflated agent identities by joining the authenticated caller with identity/soul diary entries authored by anyone in a (possibly shared) diary — a recurrence of #889. Remove the mechanism instead of re-patching: - moltnet_whoami returns only the authenticated identity block (no diary_id input, no profile/soul/hint). - Delete self/whoami + self/soul MCP resources and identity_bootstrap / write_identity prompts; delete profile-utils. - Remove 'identity'/'soul' from the entry_type enum across DB, @moltnet/models, MCP schemas, diary-service/diary-ui, and the generated TS + Go clients. - Migration 0021 drops diary_search() before recreating the enum (it depends on the type), remaps existing identity/soul rows to 'semantic', then recreates the function. Verified against Postgres: fresh apply + data remap. BREAKING CHANGE: entry_type no longer accepts 'identity'/'soul'; moltnet_whoami no longer returns profile/soul/hint or accepts diary_id. Published consumers need a major version bump. MoltNet-Diary: 71fa4937-8ed6-42a0-97c8-e0fada5f0325 Task-Group: remove-identity-soul-profile Task-Family: refactor Task-Completes: true
Contributor
|
Contributor
🚨 Dependency Audit — Vulnerabilities foundFull report |
Contributor
|
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
Closes #1401.
moltnet_whoamirepeatedly conflated agent identities because it joined the authenticated caller withidentity/souldiary entries authored by anyone in a (possibly shared) diary — a recurrence of #889. Rather than re-patch the join a third time, this removes the identity/soul diary-entry profile mechanism entirely.The authenticated identity block was always correct; the diary-entry profile join was the recurring source of bugs. With it gone, the conflation class is structurally impossible —
moltnet_whoaminever reads diary entries.What changed
moltnet_whoami: takes no arguments, returns only the authenticated identity (identityId,clientId,publicKey,fingerprint). No moreprofile/whoami/soul/hint; nodiary_idinput.profile-utils.ts, themoltnet://diaries/{id}/self/whoami+self/soulMCP resources, and theidentity_bootstrap+write_identityprompts.entry_typeenum:identityandsoulremoved across the DB enum,@moltnet/models, MCP/REST schemas,diary-service/diary-ui, and both generated clients (TS hey-api + Go ogen). Now:episodic | semantic | procedural | reflection.0021: dropsdiary_search()before recreating the enum (the function depends on the type — the auto-generated SQL omitted this and would have failed onDROP TYPE), remaps existingidentity/soulrows tosemantic, then recreates the function verbatim.legreffier), docs, Go CLI help text, and the judge-pack signing rule updated.entry_typeno longer acceptsidentity/soul(existing rows remapped tosemantic— no data loss).moltnet_whoamino longer returnsprofile/soul/hintor acceptsdiary_id.Published consumers (
@themoltnet/cli, SDK) warrant a major version bump.Verification
go builddiary_searchrecreated and callable, identity/soul→semantic remap preserves rowsNotes
The
identityId-per-fingerprint discrepancy originally bundled into this issue (OAuth2 clientmetadata.identity_iddrifting from the agents table, surfaced via thetoken-validatorfallback) is no longer reachable through whoami since whoami no longer joins diary entries. If you still want the auth-layer reconciliation fix, I can file a focused follow-up — say the word.