@reqvire-org/ads 0.3.35 → 0.3.36
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/dist/mcp/drafts.mjs +5 -2
- package/dist/mcp/mutation-limits.mjs +2 -0
- package/dist/mcp/mutations.mjs +4 -3
- package/dist/mcp/patch.mjs +5 -3
- package/dist/mcp/server.mjs +2 -2
- package/dist/skills/ads-break-ui/references/drafts.md +6 -0
- package/dist/skills/ads-break-ui/references/guarded-editing.md +2 -2
- package/dist/skills/ads-designer/references/drafts.md +6 -0
- package/dist/skills/ads-designer/references/guarded-editing.md +2 -2
- package/dist/skills/ads-import/references/drafts.md +6 -0
- package/dist/skills/ads-import/references/guarded-editing.md +2 -2
- package/dist/skills/ads-motion/references/drafts.md +6 -0
- package/dist/skills/ads-motion/references/guarded-editing.md +2 -2
- package/dist/skills/ads-port/references/drafts.md +6 -0
- package/dist/skills/ads-port/references/guarded-editing.md +2 -2
- package/docs/CHANGELOG.md +19 -12
- package/docs/MCP.md +2 -2
- package/package.json +1 -1
package/dist/mcp/drafts.mjs
CHANGED
|
@@ -12,13 +12,15 @@ import { mergeDraftExports, isDraftExportEntry } from "./draft-exports.mjs";
|
|
|
12
12
|
import { inspectTokens } from "../tokens.mjs";
|
|
13
13
|
import { previewFileIgnored, previewWatchDirectories } from "../preview-files.mjs";
|
|
14
14
|
import { createDraftDiscovery } from "./draft-discovery.mjs";
|
|
15
|
+
import { mutationLimits } from "./mutation-limits.mjs";
|
|
15
16
|
|
|
16
17
|
export const DRAFTS_URI = "ads://project/drafts";
|
|
17
18
|
const hash = bytes => createHash("sha256").update(bytes).digest("hex");
|
|
18
19
|
const idSchema = z.string().regex(/^[a-z0-9][a-z0-9-]{0,79}$/);
|
|
19
20
|
const relative = z.string().min(1).max(500).refine(value => !path.isAbsolute(value) && !value.includes("\\") && !value.includes("\0") && !value.split("/").some(part => !part || part === "." || part === ".."), "Use a canonical project-relative path.");
|
|
20
21
|
const fileSchema = z.object({ target: relative, source: relative.nullable(), baseline: z.string().regex(/^[a-f0-9]{64}$/).nullable(), unit: z.string().max(256) }).strict();
|
|
21
|
-
const
|
|
22
|
+
const draftUnits = z.array(z.string().min(1).max(256)).min(1).max(mutationLimits.units).refine(values=>new Set(values).size===values.length,"Draft owners must be unique.");
|
|
23
|
+
const manifestSchema = z.object({ schemaVersion: z.literal(1), id: idSchema, title: z.string().min(1).max(160), units: draftUnits, dependencies: z.array(idSchema).max(8).refine(values=>new Set(values).size===values.length,"Draft dependencies must be unique.").default([]), tokenGroups:z.array(z.string().min(1).max(160)).max(32).default([]), files: z.array(fileSchema).max(mutationLimits.files) }).strict();
|
|
22
24
|
export const draftIdSchema = idSchema;
|
|
23
25
|
export const draftRevisionSchema = z.string().regex(/^[a-f0-9]{64}$/);
|
|
24
26
|
|
|
@@ -154,6 +156,7 @@ export function createDraftController(directory, { edits, startPreview, prewarm
|
|
|
154
156
|
}
|
|
155
157
|
function create({ units, title, id = randomUUID(), dependencies = [], tokenGroups: selectedGroups = [] }) {
|
|
156
158
|
if (closed) throw new Error("Draft controller is closed.");
|
|
159
|
+
units = draftUnits.parse(units);
|
|
157
160
|
idSchema.parse(id);
|
|
158
161
|
if (existsSync(manifestFile(id))) throw new Error("Draft already exists.");
|
|
159
162
|
const options = loadConfig(root), inventory = inspectUnits(options), files = new Map();
|
|
@@ -174,7 +177,7 @@ export function createDraftController(directory, { edits, startPreview, prewarm
|
|
|
174
177
|
files.set(target, { target, source, baseline: hash(content), unit });
|
|
175
178
|
}
|
|
176
179
|
}
|
|
177
|
-
const manifest = manifestSchema.parse({ schemaVersion: 1, id, title: title ?? units.join(", "), units, dependencies, tokenGroups:selectedGroups, files: [...files.values()] });
|
|
180
|
+
const manifest = manifestSchema.parse({ schemaVersion: 1, id, title: title ?? units.join(", ").slice(0,160), units, dependencies, tokenGroups:selectedGroups, files: [...files.values()] });
|
|
178
181
|
for (const dependency of dependencies) {const value=inspect(dependency,[id]);if(value.dependencyErrors.length)throw new Error(value.dependencyErrors[0].message);}
|
|
179
182
|
for (const file of manifest.files) atomic(safe(path.dirname(manifestFile(id)), file.source), bytes(safe(root, file.target)));
|
|
180
183
|
save(manifest);
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/** Shared budgets for tracked drafts and guarded publication. */
|
|
2
|
+
export const mutationLimits = Object.freeze({ units: 64, files: 256, patchBytes: 256 * 1024, patchFileBytes: 16 * 1024 * 1024, fileBytes: 16 * 1024 * 1024, readChars: 12000, snapshotFiles: 100000, snapshotBytes: 2 * 1024 * 1024 * 1024 });
|
package/dist/mcp/mutations.mjs
CHANGED
|
@@ -16,8 +16,9 @@ import { acceptance, failure as evidenceFailure } from "../evidence.mjs";
|
|
|
16
16
|
import { checkCandidate, checkCommand, projectChecks as checks } from "../validation-checks.mjs";
|
|
17
17
|
import { preparePreviewCache } from "../scenarios-compiler.mjs";
|
|
18
18
|
import { validationInputFiles } from "../validation-inputs.mjs";
|
|
19
|
+
import { mutationLimits } from "./mutation-limits.mjs";
|
|
19
20
|
|
|
20
|
-
export
|
|
21
|
+
export { mutationLimits } from "./mutation-limits.mjs";
|
|
21
22
|
const digest = bytes => `sha256:${createHash("sha256").update(bytes).digest("hex")}`;
|
|
22
23
|
const ignored = new Set([".git", ".ds", "node_modules", ".vite", "coverage", ".playwright-cli", "test-results", "output"]);
|
|
23
24
|
const textFile = file => /\.(?:[cm]?[jt]sx?|css|html|jsonc?|md|txt|svg)$/.test(file);
|
|
@@ -180,7 +181,7 @@ export function createMutationController(directory, { captures = createCaptureCo
|
|
|
180
181
|
const options = loadConfig(root);
|
|
181
182
|
if (screenshot && !dryRun || selections !== undefined && !screenshot) throw fail("mutation-capture", "Use screenshot:true only with dryRun:true and an explicit captures:[{scenario,target?,theme?,viewport?}] selection. Ordinary patches create no screenshots.");
|
|
182
183
|
if (screenshot) selections = captureSelections(selections);
|
|
183
|
-
if (patches !== undefined && (unit !== undefined || patch !== undefined || patchFile !== undefined || !Array.isArray(patches) || patches.length < 2 || patches.length > mutationLimits.units)) throw fail("mutation-batch",
|
|
184
|
+
if (patches !== undefined && (unit !== undefined || patch !== undefined || patchFile !== undefined || !Array.isArray(patches) || patches.length < 2 || patches.length > mutationLimits.units)) throw fail("mutation-batch", `A transaction requires 2–${mutationLimits.units} distinct owner patches, without a top-level unit/patch.`);
|
|
184
185
|
const groups = patches ?? [{unit,patch,patchFile}];
|
|
185
186
|
if (new Set(groups.map(group => group.unit)).size !== groups.length) throw fail("mutation-batch", "Use one patch per distinct unit in a transaction.");
|
|
186
187
|
let patchBytes = 0;
|
|
@@ -240,7 +241,7 @@ export function createMutationController(directory, { captures = createCaptureCo
|
|
|
240
241
|
originals.push({...original,mode:original.exists ? lstatSync(address(options,entry.path)).mode : undefined});
|
|
241
242
|
byPath.set(entry.path,changes.length);
|
|
242
243
|
changes.push({...change,expectedDigest:original.digest});
|
|
243
|
-
if (changes.length > mutationLimits.files) throw fail("mutation-batch",
|
|
244
|
+
if (changes.length > mutationLimits.files) throw fail("mutation-batch", `A transaction may change at most ${mutationLimits.files} distinct files.`);
|
|
244
245
|
}
|
|
245
246
|
return change;
|
|
246
247
|
});
|
package/dist/mcp/patch.mjs
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { mutationLimits } from "./mutation-limits.mjs";
|
|
2
|
+
|
|
1
3
|
function error(message, file, rule = "mutation-patch") {
|
|
2
4
|
return Object.assign(new Error(message), { diagnostic: { rule, message, ...(file ? { file } : {}) } });
|
|
3
5
|
}
|
|
@@ -10,7 +12,7 @@ function fileName(header, prefix) {
|
|
|
10
12
|
}
|
|
11
13
|
|
|
12
14
|
/** Text hunks are exact; Git binary blocks are applied by Git in the candidate. */
|
|
13
|
-
export function parseUnifiedPatch(patch, maxFiles =
|
|
15
|
+
export function parseUnifiedPatch(patch, maxFiles = mutationLimits.files) {
|
|
14
16
|
const lines = patch.split("\n");
|
|
15
17
|
if (lines.at(-1) === "") lines.pop();
|
|
16
18
|
const files = [], paths = new Set();
|
|
@@ -32,7 +34,7 @@ export function parseUnifiedPatch(patch, maxFiles = 32) {
|
|
|
32
34
|
if (lines[index] === "GIT binary patch") {
|
|
33
35
|
if (!gitPath || !binaryIndex) throw error("Binary patches need a Git file header and full blob hashes. Generate with git diff --binary.");
|
|
34
36
|
const file = gitPath;
|
|
35
|
-
if (paths.has(file) || files.length >= maxFiles) throw error(
|
|
37
|
+
if (paths.has(file) || files.length >= maxFiles) throw error(`Provide 1–${maxFiles} distinct file patches.`, file, "mutation-batch");
|
|
36
38
|
paths.add(file);
|
|
37
39
|
while (index < lines.length && !lines[index].startsWith("diff --git ")) index++;
|
|
38
40
|
const block = lines.slice(start, index).join("\n") + "\n";
|
|
@@ -44,7 +46,7 @@ export function parseUnifiedPatch(patch, maxFiles = 32) {
|
|
|
44
46
|
const file = after ?? before;
|
|
45
47
|
if (gitPath && gitPath !== file) throw error("Git metadata and file headers must identify the same path.", file);
|
|
46
48
|
if (!file || before && after && before !== after) throw error("Use separate delete and create entries to rename a file.", file);
|
|
47
|
-
if (paths.has(file) || files.length >= maxFiles) throw error(
|
|
49
|
+
if (paths.has(file) || files.length >= maxFiles) throw error(`Provide 1–${maxFiles} distinct file patches.`, file, "mutation-batch");
|
|
48
50
|
paths.add(file);
|
|
49
51
|
const entry = { path: file, operation: before === null ? "create" : after === null ? "delete" : "update", hunks: [] };
|
|
50
52
|
while (lines[index]?.startsWith("@@")) {
|
package/dist/mcp/server.mjs
CHANGED
|
@@ -366,7 +366,7 @@ export function createAdsMcp(directory, { era = "legacy", skillDirectory, pollIn
|
|
|
366
366
|
return json({...value,isolatedShowcaseUrl:value.showcaseUrl,showcaseUrl:comparisonUrl??value.showcaseUrl,comparisonUrl});
|
|
367
367
|
} },
|
|
368
368
|
...(mutations ? [
|
|
369
|
-
{ name:"ads_create_draft", description:"Create a Git-committable proposal under ads-drafts/ for 1–
|
|
369
|
+
{ name:"ads_create_draft", description:"Create a Git-committable proposal under ads-drafts/ for 1–64 coupled ADS owners, copying only their source/companions into non-importable .ads files. New owners are allowed. Optional dependencies name separate unaccepted drafts used by pattern/composition previews. Creation does not change accepted source. Edit the returned files normally; use ads_update_draft to register additions/deletions.", schema:z.object({units:z.array(z.string().min(1).max(256)).min(1).max(mutationLimits.units),title:z.string().min(1).max(160).optional(),id:draftIdSchema.optional(),dependencies:z.array(draftIdSchema).max(8).default([]),tokenGroups:z.array(z.string().min(1).max(160)).max(32).default([])}).strict(),_meta:{ui:{visibility:["model"]}},annotations:{...annotations,readOnlyHint:false,idempotentHint:false},call:async args=>{const result=drafts.create(args);if(observeChanges)await refresh();return json(result);} },
|
|
370
370
|
{ name:"ads_update_draft", description:"Update marked draft source or register new/deleted canonical target paths. Pass the current revision from ads_drafts. Source is UTF-8 unless encoding:base64; content:null proposes deletion. Optional dependencies replaces the draft dependency list. Normal local file edits need no iteration tool. Accepted source remains unchanged; ownership and all required checks run at acceptance.",schema:z.object({id:draftIdSchema,revision:draftRevisionSchema,dependencies:z.array(draftIdSchema).max(8).optional(),changes:z.array(z.object({unit:z.string().max(256),path:z.string().min(1).max(500),content:z.string().max(256*1024).nullable(),encoding:z.enum(["utf8","base64"]).optional()}).strict()).max(32).default([])}).strict(),_meta:{ui:{visibility:["model"]}},annotations:{...annotations,readOnlyHint:false,idempotentHint:false},call:async args=>{const result=drafts.update(args);if(observeChanges)await refresh();return json(result);} },
|
|
371
371
|
{ name:"ads_drop_draft",description:"Delete an exact tracked draft and its generated preview. This is Drop, not a separate refusal workflow. Accepted source is unchanged. Dependents report a missing dependency until corrected.",schema:z.object({id:draftIdSchema,revision:draftRevisionSchema}).strict(),_meta:{ui:{visibility:["model"]}},annotations:{...annotations,readOnlyHint:false,destructiveHint:true,idempotentHint:false},call:async args=>{const result=await drafts.drop(args);if(observeChanges)await refresh();return json(result);} },
|
|
372
372
|
{ name:"ads_accept",title:"Accept a reviewed draft",description:"Auto-mode acceptance: validate and apply the exact rendered/reviewed draft revision in one operation. Accept dependency drafts first; dependent drafts automatically switch to their final @ds implementations. Mandatory architecture, registered Oxlint/project and affected behavior checks run once on the candidate. Draft/source changes invalidate acceptance. On failure retain the draft and inspect ads_results; on success apply normal source, remove the draft and publish an event. No additional human approval or manual Apply step.",schema:z.object({id:draftIdSchema,revision:draftRevisionSchema}).strict(),_meta:{ui:{visibility:["model"]}},annotations:{...annotations,readOnlyHint:false,destructiveHint:true,idempotentHint:false},call:async(args,signal,progress)=>{
|
|
@@ -477,7 +477,7 @@ export function createAdsMcp(directory, { era = "legacy", skillDirectory, pollIn
|
|
|
477
477
|
schema: z.object({ unit: z.string().min(1).max(256), dryRun: z.boolean(), patch: z.string().min(1).max(mutationLimits.patchBytes).optional(), patchFile: z.string().min(1).max(500).optional(), ...screenshotFields }).strict().refine(args => (args.patch !== undefined) !== (args.patchFile !== undefined), "Provide exactly one of patch or patchFile."),
|
|
478
478
|
annotations: { readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false }, _meta: { ui: { visibility: ["model"] } },
|
|
479
479
|
call: applyEdits,
|
|
480
|
-
}, {name:"ads_apply_transaction",description:"Apply genuinely coupled ADS changes as 2–
|
|
480
|
+
}, {name:"ads_apply_transaction",description:"Apply genuinely coupled ADS changes as 2–64 distinct owner Git patches. Each patch must obey its unit and narrow companion rules. Patches run in order; later patches use the earlier candidate's shared-entry content. Core guards, registered Oxlint/project checks and affected behavior checks validate the complete final candidate before any live source is written. Maximum 256 distinct files/16 MiB combined. Dry runs, failures and cancellation publish nothing; publication rolls back on write failure. Optional screenshot:true with dryRun:true and explicit captures selects current/candidate images. Prefer ads_apply_patch for independent edits. Reply is a bounded summary; page diagnostics, outcomes and captures with ads_results using the returned resultId.",schema:z.object({patches:z.array(ownerPatch).min(2).max(mutationLimits.units),dryRun:z.boolean(),...screenshotFields}).strict(),annotations:{readOnlyHint:false,destructiveHint:true,idempotentHint:false,openWorldHint:false},_meta:{ui:{visibility:["model"]}},call:applyEdits}] : []),
|
|
481
481
|
...options.config.mcp.apps.map((app) => ({ name: `ads_show_${app.id.replaceAll("-", "_")}`, title: app.title, description: `${app.description ?? app.title}. Renders the project's built ${app.kind} examples through MCP Apps; text fallback provides the showcase URL.`, schema: empty, _meta: { ui: { resourceUri: appUri(app.id) } }, call: async (_args, signal) => {
|
|
482
482
|
// Validate readiness without embedding executable HTML in model results.
|
|
483
483
|
const build = await previewBuild(app, signal);
|
|
@@ -24,6 +24,12 @@ For example, `Button.tsx.ads` maps to the normal `Button.tsx` target. The final
|
|
|
24
24
|
`.ads` extension keeps proposed code out of default TypeScript/lint discovery,
|
|
25
25
|
without editing project tsconfig files. The manifest remains
|
|
26
26
|
`proposal.ads.draft.json`. These are ordinary tracked project files: commit them and review them in a PR.
|
|
27
|
+
|
|
28
|
+
A draft may group up to 64 owners and 256 tracked files. For related changes,
|
|
29
|
+
use one multi-owner draft: its previews share a compiler workspace and acceptance
|
|
30
|
+
validates the combined candidate once, then applies all changes together. The
|
|
31
|
+
existing source and patch byte budgets still apply.
|
|
32
|
+
|
|
27
33
|
Git is not required to create or recover a draft. Restarting ADS or cloning the
|
|
28
34
|
project discovers the same source. Generated compiler workspaces and execution
|
|
29
35
|
events remain under ignored `.ds/`; an interrupted check is never a pass.
|
|
@@ -104,8 +104,8 @@ of duplicating them across units. Do not create an asset group or bypass a guard
|
|
|
104
104
|
to add these documents. Code/configuration and hidden/generated paths remain
|
|
105
105
|
outside documentation ownership.
|
|
106
106
|
|
|
107
|
-
For genuinely coupled changes, `ads_apply_transaction` accepts 2–
|
|
108
|
-
patches (
|
|
107
|
+
For genuinely coupled changes, `ads_apply_transaction` accepts 2–64 distinct owner
|
|
108
|
+
patches (256 distinct files and 16 MiB combined). Each patch keeps its ownership and
|
|
109
109
|
companion restrictions. Patches apply in order; later shared-entry hunks match the
|
|
110
110
|
earlier candidate. All guards, registered checks and affected behavior checks run
|
|
111
111
|
on the final candidate before live source is written. Dry-run first. Rejection,
|
|
@@ -24,6 +24,12 @@ For example, `Button.tsx.ads` maps to the normal `Button.tsx` target. The final
|
|
|
24
24
|
`.ads` extension keeps proposed code out of default TypeScript/lint discovery,
|
|
25
25
|
without editing project tsconfig files. The manifest remains
|
|
26
26
|
`proposal.ads.draft.json`. These are ordinary tracked project files: commit them and review them in a PR.
|
|
27
|
+
|
|
28
|
+
A draft may group up to 64 owners and 256 tracked files. For related changes,
|
|
29
|
+
use one multi-owner draft: its previews share a compiler workspace and acceptance
|
|
30
|
+
validates the combined candidate once, then applies all changes together. The
|
|
31
|
+
existing source and patch byte budgets still apply.
|
|
32
|
+
|
|
27
33
|
Git is not required to create or recover a draft. Restarting ADS or cloning the
|
|
28
34
|
project discovers the same source. Generated compiler workspaces and execution
|
|
29
35
|
events remain under ignored `.ds/`; an interrupted check is never a pass.
|
|
@@ -104,8 +104,8 @@ of duplicating them across units. Do not create an asset group or bypass a guard
|
|
|
104
104
|
to add these documents. Code/configuration and hidden/generated paths remain
|
|
105
105
|
outside documentation ownership.
|
|
106
106
|
|
|
107
|
-
For genuinely coupled changes, `ads_apply_transaction` accepts 2–
|
|
108
|
-
patches (
|
|
107
|
+
For genuinely coupled changes, `ads_apply_transaction` accepts 2–64 distinct owner
|
|
108
|
+
patches (256 distinct files and 16 MiB combined). Each patch keeps its ownership and
|
|
109
109
|
companion restrictions. Patches apply in order; later shared-entry hunks match the
|
|
110
110
|
earlier candidate. All guards, registered checks and affected behavior checks run
|
|
111
111
|
on the final candidate before live source is written. Dry-run first. Rejection,
|
|
@@ -24,6 +24,12 @@ For example, `Button.tsx.ads` maps to the normal `Button.tsx` target. The final
|
|
|
24
24
|
`.ads` extension keeps proposed code out of default TypeScript/lint discovery,
|
|
25
25
|
without editing project tsconfig files. The manifest remains
|
|
26
26
|
`proposal.ads.draft.json`. These are ordinary tracked project files: commit them and review them in a PR.
|
|
27
|
+
|
|
28
|
+
A draft may group up to 64 owners and 256 tracked files. For related changes,
|
|
29
|
+
use one multi-owner draft: its previews share a compiler workspace and acceptance
|
|
30
|
+
validates the combined candidate once, then applies all changes together. The
|
|
31
|
+
existing source and patch byte budgets still apply.
|
|
32
|
+
|
|
27
33
|
Git is not required to create or recover a draft. Restarting ADS or cloning the
|
|
28
34
|
project discovers the same source. Generated compiler workspaces and execution
|
|
29
35
|
events remain under ignored `.ds/`; an interrupted check is never a pass.
|
|
@@ -104,8 +104,8 @@ of duplicating them across units. Do not create an asset group or bypass a guard
|
|
|
104
104
|
to add these documents. Code/configuration and hidden/generated paths remain
|
|
105
105
|
outside documentation ownership.
|
|
106
106
|
|
|
107
|
-
For genuinely coupled changes, `ads_apply_transaction` accepts 2–
|
|
108
|
-
patches (
|
|
107
|
+
For genuinely coupled changes, `ads_apply_transaction` accepts 2–64 distinct owner
|
|
108
|
+
patches (256 distinct files and 16 MiB combined). Each patch keeps its ownership and
|
|
109
109
|
companion restrictions. Patches apply in order; later shared-entry hunks match the
|
|
110
110
|
earlier candidate. All guards, registered checks and affected behavior checks run
|
|
111
111
|
on the final candidate before live source is written. Dry-run first. Rejection,
|
|
@@ -24,6 +24,12 @@ For example, `Button.tsx.ads` maps to the normal `Button.tsx` target. The final
|
|
|
24
24
|
`.ads` extension keeps proposed code out of default TypeScript/lint discovery,
|
|
25
25
|
without editing project tsconfig files. The manifest remains
|
|
26
26
|
`proposal.ads.draft.json`. These are ordinary tracked project files: commit them and review them in a PR.
|
|
27
|
+
|
|
28
|
+
A draft may group up to 64 owners and 256 tracked files. For related changes,
|
|
29
|
+
use one multi-owner draft: its previews share a compiler workspace and acceptance
|
|
30
|
+
validates the combined candidate once, then applies all changes together. The
|
|
31
|
+
existing source and patch byte budgets still apply.
|
|
32
|
+
|
|
27
33
|
Git is not required to create or recover a draft. Restarting ADS or cloning the
|
|
28
34
|
project discovers the same source. Generated compiler workspaces and execution
|
|
29
35
|
events remain under ignored `.ds/`; an interrupted check is never a pass.
|
|
@@ -104,8 +104,8 @@ of duplicating them across units. Do not create an asset group or bypass a guard
|
|
|
104
104
|
to add these documents. Code/configuration and hidden/generated paths remain
|
|
105
105
|
outside documentation ownership.
|
|
106
106
|
|
|
107
|
-
For genuinely coupled changes, `ads_apply_transaction` accepts 2–
|
|
108
|
-
patches (
|
|
107
|
+
For genuinely coupled changes, `ads_apply_transaction` accepts 2–64 distinct owner
|
|
108
|
+
patches (256 distinct files and 16 MiB combined). Each patch keeps its ownership and
|
|
109
109
|
companion restrictions. Patches apply in order; later shared-entry hunks match the
|
|
110
110
|
earlier candidate. All guards, registered checks and affected behavior checks run
|
|
111
111
|
on the final candidate before live source is written. Dry-run first. Rejection,
|
|
@@ -24,6 +24,12 @@ For example, `Button.tsx.ads` maps to the normal `Button.tsx` target. The final
|
|
|
24
24
|
`.ads` extension keeps proposed code out of default TypeScript/lint discovery,
|
|
25
25
|
without editing project tsconfig files. The manifest remains
|
|
26
26
|
`proposal.ads.draft.json`. These are ordinary tracked project files: commit them and review them in a PR.
|
|
27
|
+
|
|
28
|
+
A draft may group up to 64 owners and 256 tracked files. For related changes,
|
|
29
|
+
use one multi-owner draft: its previews share a compiler workspace and acceptance
|
|
30
|
+
validates the combined candidate once, then applies all changes together. The
|
|
31
|
+
existing source and patch byte budgets still apply.
|
|
32
|
+
|
|
27
33
|
Git is not required to create or recover a draft. Restarting ADS or cloning the
|
|
28
34
|
project discovers the same source. Generated compiler workspaces and execution
|
|
29
35
|
events remain under ignored `.ds/`; an interrupted check is never a pass.
|
|
@@ -104,8 +104,8 @@ of duplicating them across units. Do not create an asset group or bypass a guard
|
|
|
104
104
|
to add these documents. Code/configuration and hidden/generated paths remain
|
|
105
105
|
outside documentation ownership.
|
|
106
106
|
|
|
107
|
-
For genuinely coupled changes, `ads_apply_transaction` accepts 2–
|
|
108
|
-
patches (
|
|
107
|
+
For genuinely coupled changes, `ads_apply_transaction` accepts 2–64 distinct owner
|
|
108
|
+
patches (256 distinct files and 16 MiB combined). Each patch keeps its ownership and
|
|
109
109
|
companion restrictions. Patches apply in order; later shared-entry hunks match the
|
|
110
110
|
earlier candidate. All guards, registered checks and affected behavior checks run
|
|
111
111
|
on the final candidate before live source is written. Dry-run first. Rejection,
|
package/docs/CHANGELOG.md
CHANGED
|
@@ -1,34 +1,41 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## 0.3.
|
|
3
|
+
## 0.3.36
|
|
4
4
|
|
|
5
5
|
<!-- ads-local-tests:start -->
|
|
6
|
-
Local verification: **
|
|
7
|
-
Tested commit: `
|
|
8
|
-
Completed 2026-10-
|
|
6
|
+
Local verification: **550/550 passed** with `ADS_TEST_BUN=1 npm test`.
|
|
7
|
+
Tested commit: `bd323b5bca2899bfe0693cbe18d847e7117363ff`; Node v24.13.0, Bun 1.3.13.
|
|
8
|
+
Completed 2026-10-23T08:15:20.531Z (755 seconds).
|
|
9
9
|
|
|
10
10
|
<!-- ads-local-test-proof
|
|
11
11
|
{
|
|
12
12
|
"schema": 1,
|
|
13
|
-
"version": "0.3.
|
|
14
|
-
"commit": "
|
|
15
|
-
"sourceSha256": "
|
|
13
|
+
"version": "0.3.36",
|
|
14
|
+
"commit": "bd323b5bca2899bfe0693cbe18d847e7117363ff",
|
|
15
|
+
"sourceSha256": "071702f9a64c119b33cd06b348cb995ccfe6c97de7f8d624a05d75b57f15eec7",
|
|
16
16
|
"command": "ADS_TEST_BUN=1 npm test",
|
|
17
17
|
"result": "pass",
|
|
18
|
-
"tests":
|
|
19
|
-
"pass":
|
|
18
|
+
"tests": 550,
|
|
19
|
+
"pass": 550,
|
|
20
20
|
"fail": 0,
|
|
21
21
|
"cancelled": 0,
|
|
22
22
|
"skipped": 0,
|
|
23
23
|
"node": "v24.13.0",
|
|
24
24
|
"bun": "1.3.13",
|
|
25
|
-
"completedAt": "2026-10-
|
|
26
|
-
"durationMs":
|
|
27
|
-
"logSha256": "
|
|
25
|
+
"completedAt": "2026-10-23T08:15:20.531Z",
|
|
26
|
+
"durationMs": 754603,
|
|
27
|
+
"logSha256": "9c04003e1d68049541f855f2d3909f8f1569737f2b978fb828889a2f5ff13da8"
|
|
28
28
|
}
|
|
29
29
|
-->
|
|
30
30
|
<!-- ads-local-tests:end -->
|
|
31
31
|
|
|
32
|
+
- Allow up to 64 owners in one tracked draft or guarded transaction, with up to
|
|
33
|
+
256 changed files. Related changes share the draft compiler and one final
|
|
34
|
+
acceptance validation; source/patch byte budgets and publication checks remain
|
|
35
|
+
enforced. Share these limits across draft manifests, MCP schemas and patch parsing.
|
|
36
|
+
|
|
37
|
+
## 0.3.35
|
|
38
|
+
|
|
32
39
|
- Bound acceptance memory by parking accepted/draft compilers while retaining
|
|
33
40
|
published views, running candidate architecture checks in a short-lived
|
|
34
41
|
process, and retiring idle semantic workers and temporary program caches.
|
package/docs/MCP.md
CHANGED
|
@@ -31,7 +31,7 @@ exercised conditions alongside normal application integration checks.
|
|
|
31
31
|
### Auto-mode tracked drafts
|
|
32
32
|
|
|
33
33
|
Use the [draft workflow](../skills/ads-designer/references/drafts.md) for iterative
|
|
34
|
-
design. With `--mutations`, `ads_create_draft` creates a tracked proposal for 1–
|
|
34
|
+
design. With `--mutations`, `ads_create_draft` creates a tracked proposal for 1–64
|
|
35
35
|
owners; ordinary file edits or `ads_update_draft` continue it. `ads_show_draft`
|
|
36
36
|
reuses an isolated compiler workspace and returns both an MCP App preview and
|
|
37
37
|
browser URLs without running acceptance checks. `ads_drafts` lists only pending
|
|
@@ -638,7 +638,7 @@ For a coupled rename or upgrade, call `ads_apply_transaction`:
|
|
|
638
638
|
}
|
|
639
639
|
```
|
|
640
640
|
|
|
641
|
-
It accepts 2–
|
|
641
|
+
It accepts 2–64 distinct owners, at most 256 distinct files and 16 MiB of combined
|
|
642
642
|
Git diff text. Each patch obeys its own ownership/companion rules. Patches apply
|
|
643
643
|
in order inside one candidate; shared-entry hunks in a later patch must match
|
|
644
644
|
the earlier candidate's content. Core checks, registered Oxlint, project commands
|