From 379e8a5d22da3ddd5d18a8b256af9545802ffb6e Mon Sep 17 00:00:00 2001 From: Sarmad Tawfeek <125739417+SamCT86@users.noreply.github.com> Date: Thu, 1 Oct 2026 19:50:32 +0200 Subject: [PATCH 1/2] docs: align dependency resolution with current contract model --- skills/open-prose/deps.md | 36 ++++++++----------- .../open-prose/skill-meta/skill-meta.test.ts | 8 +++++ 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/skills/open-prose/deps.md b/skills/open-prose/deps.md index de2a17ab..43d08129 100644 --- a/skills/open-prose/deps.md +++ b/skills/open-prose/deps.md @@ -1,20 +1,20 @@ --- role: dependency-resolution summary: | - How OpenProse resolves git-native dependencies from `use` statements, - service references, and pattern references. Defines the resolution + How OpenProse resolves git-native dependencies from `use` statements + and `pattern:` references. Defines the resolution algorithm, the `prose install` command, the lockfile format, and the `/deps/` directory structure. see-also: - prose.md: VM execution semantics (loads resolved deps at runtime) - - forme.md: Wiring semantics (resolves services and systems from /deps/) + - forme.md: Compile-time wiring semantics (`### Requires` → `### Maintains`) - SKILL.md: Command routing for `prose install` --- # Dependency Resolution -OpenProse uses a git-native dependency model. `use` statements, dependency-like -service names, and `pattern:` references can point at any explicit git host. +OpenProse uses a git-native dependency model. `use` statements and `pattern:` +references can point at any explicit git host. Dependencies are cloned into `/deps/`, pinned in `/prose.lock`, and resolved from disk at runtime. @@ -99,13 +99,13 @@ let result = call research topic: "quantum computing" ``` -In `### Services`, use the full path — aliases are for execution blocks only. +Aliases name imported functions inside pinned ProseScript choreography. --- ## Resolution Algorithm (Runtime) -When the VM or Forme encounters a `use` path at runtime: +When the VM encounters a `use` path at runtime: 1. Expand `std/` and `co/` shorthands to `github.com/openprose/prose/packages/{std|co}/` if applicable @@ -127,7 +127,6 @@ Scans the project for dependency references and clones missing dependencies. 1. **Scan** all `*.prose.md` files under `/src/` for: - `use "host/owner/repo/path"` statements - - service names in `### Services` that start with `std/`, `co/`, or `host/owner/repo/` - `pattern:` references that start with `std/`, `co/`, or `host/owner/repo/` 2. **Expand** `std/` and `co/` shorthands to `github.com/openprose/prose/packages/{std|co}/` 3. **Parse** each expanded dependency path to extract `{host, owner, repo}` triples (the first segment is the host if it contains a dot) @@ -281,17 +280,10 @@ If `/prose.lock` exists but `/deps/` is missing ## Interaction with Forme -When Forme resolves a service listed in `### Services`, it checks `/deps/` as part of its resolution order (see `forme.md`, Step 2): +Forme does not scan a service registry or implement a second dependency-resolution order. Cross-node composition is declared by mounted responsibility contracts: Forme matches each `### Requires` facet-need to the producer `### Maintains` facet that satisfies it. Pinned intra-node choreography uses `use` plus `call`; those dependency paths follow the disk-only resolver documented here. -1. Same directory as the system file: `./researcher.prose.md` -2. A subdirectory matching the name: `./researcher/index.prose.md` -3. **`/deps/` directory:** first - `/deps/{host}/{owner}/{repo}/{path}.prose.md`, then - `/deps/{host}/{owner}/{repo}/{path}/index.prose.md` -4. Bare `owner/repo` identifiers: reserved for the OpenProse registry (future home at `p.prose.md`); inert today - -A service or system reference like `std/evals/inspector` in `### Services` resolves to `/deps/github.com/openprose/prose/packages/std/evals/inspector.prose.md` after `std/` shorthand expansion. -A directory-root system reference like `co/systems/company-repo-checker` resolves to `/deps/github.com/openprose/prose/packages/co/systems/company-repo-checker/index.prose.md`. +A `use "std/evals/inspector"` dependency resolves to `/deps/github.com/openprose/prose/packages/std/evals/inspector.prose.md` after `std/` shorthand expansion. +A directory-root dependency like `co/systems/company-repo-checker` resolves to `/deps/github.com/openprose/prose/packages/co/systems/company-repo-checker/index.prose.md`. --- @@ -301,8 +293,8 @@ When the VM encounters a `use` statement during execution: 1. Expand shorthand (`std/` → `github.com/openprose/prose/packages/std/`; `co/` → `github.com/openprose/prose/packages/co/`) 2. Parse `{host}/{owner}/{repo}` and remaining path -3. Read the service or system from `/deps/{host}/{owner}/{repo}/{path}.prose.md`, or from `/deps/{host}/{owner}/{repo}/{path}/index.prose.md` when the dependency is a directory-root system -4. Parse the imported service or system contract (`### Requires` / `### Ensures`) +3. Read the imported function from `/deps/{host}/{owner}/{repo}/{path}.prose.md`, or from `/deps/{host}/{owner}/{repo}/{path}/index.prose.md` when the dependency uses a directory root +4. Parse its current function interface (`### Parameters` / `### Returns`) 5. Register the import (with alias if `as` was used) Runtime resolution is disk-only. If a `use` path is missing from `/deps/`, the @@ -320,8 +312,8 @@ docs, install counts, eval scores, and supported runtimes). | Use case | Resolution | |----------|------------| -| `use "github.com/owner/repo/path"` in a system | `/deps/github.com/owner/repo/`; error if missing | -| `use "std/..."` or `use "co/..."` in a system | Expands to `github.com/openprose/prose/packages/{std\|co}/...` then resolves as above | +| `use "github.com/owner/repo/path"` in ProseScript | `/deps/github.com/owner/repo/`; error if missing | +| `use "std/..."` or `use "co/..."` in ProseScript | Expands to `github.com/openprose/prose/packages/{std\|co}/...` then resolves as above | | `prose run github.com/owner/repo/path` at the CLI | Same algorithm as `use` | | `prose run github.com/owner/repo/path@{version}` | That specific pinned version in `/deps/`; error if missing | | `prose run ... --offline` | `/deps/` only; error on miss | diff --git a/tests/open-prose/skill-meta/skill-meta.test.ts b/tests/open-prose/skill-meta/skill-meta.test.ts index 55a3e4ee..c993378a 100644 --- a/tests/open-prose/skill-meta/skill-meta.test.ts +++ b/tests/open-prose/skill-meta/skill-meta.test.ts @@ -285,6 +285,14 @@ describe("deps.md + agent-onboarding.md — kept, survive the overhaul", () => { expect(f).toMatch(/std\/.*github\.com\/openprose\/prose\/packages\/std/); }); + it("deps.md does not teach retired service/system dependency syntax", () => { + const doc = read("deps.md"); + const f = flat(doc); + expect(doc).not.toContain("### Services"); + expect(doc).not.toContain("### Ensures"); + expect(f).not.toMatch(/service or system|system file|service listed/i); + }); + it("agent-onboarding.md teaches an outcome contract without pinning implementation choreography", () => { // Kept, with links; the narrative already aligns. const doc = read("agent-onboarding.md"); From 122d8fd051448b9f11f127a225a5566d76723fa4 Mon Sep 17 00:00:00 2001 From: Sarmad Tawfeek <125739417+SamCT86@users.noreply.github.com> Date: Fri, 23 Oct 2026 07:46:04 +0200 Subject: [PATCH 2/2] fix(test): remove accidental tool-output text from skill conformance test Preserve the source and scoped deps.md regression assertions in openprose/prose#184; remove only two non-TypeScript tool transcript lines. --- tests/open-prose/skill-meta/skill-meta.test.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/tests/open-prose/skill-meta/skill-meta.test.ts b/tests/open-prose/skill-meta/skill-meta.test.ts index dd24dd6f..c621b620 100644 --- a/tests/open-prose/skill-meta/skill-meta.test.ts +++ b/tests/open-prose/skill-meta/skill-meta.test.ts @@ -1,5 +1,3 @@ -[Reading 327 lines from start (total: 327 lines, 0 remaining)] - // Conformance test for the skill-meta module: the versioning + upgrade-mechanism // docs of the open-prose SKILL (SKILL.md frontmatter, changelog.md, help.md, // prosescript.md, deps.md, agent-onboarding.md). @@ -327,5 +325,3 @@ describe("README.md — the skill version of record lives in SKILL.md", () => { ); }); }); - -[executed on device: ubuntu (a09eeb6f-1167-48b6-b141-f250676c6cc5)] \ No newline at end of file