perf(flutter): add opt-in retained AOT summary and string pages
Add explicit MCP Dart AOT summary delivery and exact retained string-pool pages while preserving complete defaults, CLI behavior, ABI selection, original Evidence identity, partial coverage and lower bounds. Real LocalSend SDK replies shrink 92.05% with approximately unchanged SDK time. Two actual Codex pairs preserve all selected facts and reduce total input 48.75% / 42.38%, uncached input 33.63% / 42.52%, and task time 23.95% / 30.30%; all client errors/repeated calls remain counted. Preserve old portable Evidence and the real CLI complete result after rebasing onto SAZ/qlog main. Curated results keep measured and integration runtime pins separate; raw artifacts stay outside Git. Refs #2016. Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
parent
bb154d1067
commit
23de4f77c7
@@ -726,6 +726,54 @@ const workflows = {
|
||||
},
|
||||
"sharex.dll": inspectManagedTarget,
|
||||
"sharex.helpers.dll": inspectManagedTarget,
|
||||
"localsend-arm64.apk": async () => {
|
||||
const input = {
|
||||
path: values.path,
|
||||
...(values.delivery === "summary" ? { detail: "summary" } : {}),
|
||||
};
|
||||
const definition = catalogDefinitions.get("inspect_dart_aot");
|
||||
if (
|
||||
definition === undefined ||
|
||||
!new Ajv2020({ strict: false, validateFormats: false }).validate(
|
||||
definition.inputSchema,
|
||||
input,
|
||||
)
|
||||
)
|
||||
throw new Error(
|
||||
"Selected Dart AOT delivery is not advertised by this runtime",
|
||||
);
|
||||
const inspected = await call("inspect_dart_aot", input);
|
||||
const result = normalized(inspected);
|
||||
if (
|
||||
values.delivery === "summary" &&
|
||||
(result.kind !== "summary" ||
|
||||
result.parent_operation !== "inspect_dart_aot")
|
||||
)
|
||||
throw new Error("Runtime returned no retained Dart AOT summary");
|
||||
const report = values.delivery === "summary" ? result.summary : result;
|
||||
const { package_uris, dart_uris, class_like_tokens, ...pool } =
|
||||
report.string_pool;
|
||||
return {
|
||||
artifact_sha256: targetSha(inspected),
|
||||
target: report.target,
|
||||
abi: report.abi,
|
||||
libapp: report.libapp,
|
||||
string_pool:
|
||||
values.delivery === "summary"
|
||||
? pool
|
||||
: {
|
||||
...pool,
|
||||
returned_counts: {
|
||||
package_uris: package_uris.length,
|
||||
dart_uris: dart_uris.length,
|
||||
class_like_tokens: class_like_tokens.length,
|
||||
},
|
||||
},
|
||||
coverage: report.coverage,
|
||||
limitations: inspected.limitations,
|
||||
evidence_ids: [inspected.evidence_id],
|
||||
};
|
||||
},
|
||||
"openwrt.bin": async () => {
|
||||
const info = await call("inspect_firmware_regions", { path: values.path });
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user