@foundocs/foundocs-setup 0.3.25 → 0.3.27

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/README.md CHANGED
@@ -17,7 +17,7 @@ Input JSON follows `SetupInstallInput` version 1: `client` (`claude` or `codex`)
17
17
 
18
18
  Configuration is local to the exact `--root`: `foundocs.json`, a marked `AGENTS.md` block, and either `.codex/config.toml` or `.mcp.json`. Claude additionally receives a marked `CLAUDE.md` reference to `AGENTS.md`. The package also installs its English Foundocs skill at `.agents/skills/foundocs/` for Codex or `.claude/skills/foundocs/` for Claude, including the Dreaming protocol reference. The managed instruction block points to the selected client’s discoverable skill. Existing instructions and foreign MCP entries are preserved. Skill files are updated only when unchanged from the installer’s recorded version. Byte-identical packaged files in a new clone are adopted locally; other foreign or user-edited skills stop preflight, and rollback preserves later user edits. Run `update-skills` to add the bundled skills to an older installation without a new connection code. Manual document archival/restoration uses the server-discovered `set_content_status` tool on explicit request; the bundled Foundocs skill documents versioned writes, archived lookup and the separate Dreaming approval path. Existing installations receive this guidance through `update-skills`; ordinary capture does not authorize archival. The bridge discovers tools dynamically, so server tool additions do not require a runtime upgrade. Dreaming itself requires the connected server to expose `dream_memory` and `get_dream`; installation does not enable unavailable server capabilities. Conflicting project IDs, malformed files, symlinks, or a different same-name `foundocs` server stop installation before exchanging the code. Resolve a conflict explicitly; this installer does not overwrite it.
19
19
 
20
- Keys, backups and installation journals live in `~/.local/share/foundocs/setup`, outside the project. `FOUNDOCS_SETUP_HOME` may select another absolute private directory outside the target project, including isolated test fixtures. Keep using that same value for doctor/rollback. Credentials are isolated by workspace, project, and canonical project root. Both clients use the exact-version npm package’s `mcp` command through `npx` on PATH; their project settings contain no user-specific path. Older copied helpers remain in private storage for compatibility and rollback, but portable MCP does not depend on them. Its stdio adapter forwards MCP tool discovery and calls to the same Remote HTTP endpoint with the saved Bearer key. This adapter preserves remote schemas, annotations, structured results and errors, and requires an explicit valid project ID on every call. A changed valid project ID is forwarded unchanged; the remote server enforces workspace access. It adds no remote service. macOS/Linux use user-only directories/files (0700/0600). Windows uses PowerShell to apply and verify a protected current-user-only ACL; unsupported ACL filesystems stop before code exchange.
20
+ Keys, backups and installation journals live in `~/.local/share/foundocs/setup`, outside the project. `FOUNDOCS_SETUP_HOME` may select another absolute private directory outside the target project, including isolated test fixtures. Keep using that same value for doctor/rollback. Credentials are isolated by workspace, project, and canonical project root. Both clients use the exact-version npm package’s `mcp` command through `npx` on PATH; their project settings contain no user-specific path. Older copied helpers remain in private storage for compatibility and rollback, but portable MCP does not depend on them. Its stdio adapter forwards MCP tool discovery and calls to the same Remote HTTP endpoint with the saved Bearer key. This adapter preserves remote structured results and errors, augments supported measurement schemas/annotations with local task metadata, and requires an explicit valid project ID on every call. A changed valid project ID is forwarded unchanged; the remote server enforces workspace access. It adds no remote service. macOS/Linux use user-only directories/files (0700/0600). Windows uses PowerShell to apply and verify a protected current-user-only ACL; unsupported ACL filesystems stop before code exchange.
21
21
 
22
22
  The helper prefers the saved installation credential. To explicitly use a process-provided `FOUNDOCS_API_KEY`, also provide matching `FOUNDOCS_PROJECT_ID` and `FOUNDOCS_WORKSPACE_ID`. An unrelated shell key never silently overrides the saved workspace key. The legacy HTTP helper’s stdout contains authentication headers solely for the host MCP client; do not invoke it through tools that log stdout. The shared portable runtime writes only MCP messages to stdout.
23
23
 
@@ -125,7 +125,7 @@ The skills explain stable IDs, previous-path aliases, relative-link bases, move
125
125
 
126
126
  ## Session discovery
127
127
 
128
- The Foundocs skill reached through the managed bootstrap guides the agent to resolve the configured project and read `get_project_context({ project_id, view: "index" })` once on the first use of each project in a session. The compact index combines frequently retrieved, recently beneficial and recently updated documents and knowledge. It is a discovery shortcut: if an entry is absent or insufficient, the agent continues with metadata, path and body searches across active content. Index exposure does not add retrieval records.
128
+ The Foundocs skill reached through the managed bootstrap guides the agent to resolve the configured project and use `lookup_evidence` first for a concrete question when available. This returns up to three original passages with source links and versions. For an overview or on an older host, read `get_project_context({ project_id, view: "index" })` once. The compact index combines frequently retrieved, recently beneficial and recently updated documents and knowledge. It is a discovery shortcut: if an entry is absent or insufficient, the agent continues with metadata, path and body searches across active content. Index exposure does not add retrieval records.
129
129
 
130
130
  Older servers without index mode remain usable through the existing context call and search tools. Index retrieval remains agent guidance; the separate SessionStart hook updates managed runtime pins and skills. The same instructions ship in new installations and `update-skills`.
131
131
 
@@ -292,3 +292,9 @@ CODEX_HOME, with workspace-write and on-request approvals. It never alters the
292
292
  real user configuration. Claude uses project/local settings and a scoped tool
293
293
  allowlist, with no permission bypass. `eval/episode-api-check.mjs` separately
294
294
  checks scripted API scenarios; those are not reported as host model evidence.
295
+
296
+ ### Automatic effect measurement
297
+
298
+ After explicit consent, `measure configure --root /absolute/project` accepts stdin JSON with `enabled: true`, `consentVersion: 1`, `shareProjectDataWithWorkingModel: true`, `additionalModelUsage: true`, a relative `allowlist`, and `excludePaths`. New installations may include this object as `effectMeasurement`; existing installations do not need a new key. Use `measure status` with `{}` to diagnose readiness. Disable with `{"enabled":false}`. These commands never weaken host security or enable project policy.
299
+
300
+ On a server advertising measurement diagnostics, the local MCP runtime augments information read schemas with `effectTask` and evaluation with `effectTaskId`/`effectTaskComplete`. The first read supplies the pre-exposure brief and trusted current host identity; subsequent reads reuse the task ID. The installer prepares and attaches tracking before exposure, accumulates every retrieval, and runs once after the final successful evaluation. Ordinary reads continue on skip/failure. Reconnect recovery flushes normalized reports only, never repeats inference. Insights shows bounded status/reason metadata without prompts or source paths. Hosts that cannot run the installed process/network/model retain ordinary MCP and report the restriction.