@attest-ai/core 0.4.1 → 0.5.0
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/cjs/index.cjs +2484 -0
- package/dist/cjs/index.cjs.map +1 -0
- package/dist/cjs/index.d.cts +1085 -0
- package/dist/cjs/proto/index.cjs +208 -0
- package/dist/cjs/proto/index.cjs.map +1 -0
- package/dist/cjs/proto/index.d.cts +228 -0
- package/dist/client.d.ts +7 -3
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +48 -9
- package/dist/client.js.map +1 -1
- package/dist/config.d.ts +21 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +31 -0
- package/dist/config.js.map +1 -0
- package/dist/delegate.d.ts.map +1 -1
- package/dist/delegate.js +1 -7
- package/dist/delegate.js.map +1 -1
- package/dist/esm/cli.d.ts +9 -0
- package/dist/esm/cli.js +154 -0
- package/dist/esm/cli.js.map +1 -0
- package/dist/esm/index.d.ts +1085 -0
- package/dist/esm/index.js +2385 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/proto/index.d.ts +228 -0
- package/dist/esm/proto/index.js +152 -0
- package/dist/esm/proto/index.js.map +1 -0
- package/dist/expect.d.ts +8 -2
- package/dist/expect.d.ts.map +1 -1
- package/dist/expect.js +12 -1
- package/dist/expect.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/proto/errors.d.ts +5 -0
- package/dist/proto/errors.d.ts.map +1 -1
- package/dist/proto/errors.js +11 -0
- package/dist/proto/errors.js.map +1 -1
- package/dist/simulation.d.ts +8 -0
- package/dist/simulation.d.ts.map +1 -0
- package/dist/simulation.js +21 -0
- package/dist/simulation.js.map +1 -0
- package/dist/trace.d.ts +1 -0
- package/dist/trace.d.ts.map +1 -1
- package/dist/trace.js +3 -0
- package/dist/trace.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +34 -8
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,IAAI,eAAe,GAAG,KAAK,CAAC;AAE5B;;;;;;GAMG;AACH,MAAM,UAAU,MAAM,CAAC,OAAiC;IACtD,IAAI,OAAO,CAAC,UAAU,KAAK,SAAS,EAAE,CAAC;QACrC,eAAe,GAAG,OAAO,CAAC,UAAU,CAAC;IACvC,CAAC;AACH,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,gBAAgB;IAC9B,OAAO,CACL,eAAe;QACf,OAAO,CAAC,GAAG,CAAC,mBAAmB,CAAC,KAAK,GAAG;QACxC,OAAO,CAAC,GAAG,CAAC,mBAAmB,CAAC,KAAK,MAAM;QAC3C,OAAO,CAAC,GAAG,CAAC,mBAAmB,CAAC,KAAK,KAAK,CAC3C,CAAC;AACJ,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,WAAW;IACzB,eAAe,GAAG,KAAK,CAAC;AAC1B,CAAC"}
|
package/dist/delegate.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"delegate.d.ts","sourceRoot":"","sources":["../src/delegate.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAG1C,wBAAsB,QAAQ,CAC5B,OAAO,EAAE,MAAM,EACf,EAAE,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,GAChD,OAAO,CAAC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"delegate.d.ts","sourceRoot":"","sources":["../src/delegate.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAG1C,wBAAsB,QAAQ,CAC5B,OAAO,EAAE,MAAM,EACf,EAAE,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,GAChD,OAAO,CAAC,IAAI,CAAC,CAyBf"}
|
package/dist/delegate.js
CHANGED
|
@@ -8,13 +8,7 @@ export async function delegate(agentId, fn) {
|
|
|
8
8
|
"No active TraceBuilder found.");
|
|
9
9
|
}
|
|
10
10
|
const child = new TraceBuilder(agentId);
|
|
11
|
-
|
|
12
|
-
// The child needs the parent's trace_id. We set it after building.
|
|
13
|
-
// TraceBuilder exposes setParentTraceId, but we need to read parent's id.
|
|
14
|
-
// Build a temporary trace to get the id, or use the builder directly.
|
|
15
|
-
// TraceBuilder stores _traceId privately. We need to read it.
|
|
16
|
-
// Build approach: create a minimal parent trace to get the id.
|
|
17
|
-
// Alternative: add a getter. For now, use the build-peek pattern.
|
|
11
|
+
child.setParentTraceId(parent.getTraceId());
|
|
18
12
|
await activeBuilder.run(child, async () => {
|
|
19
13
|
await fn(child);
|
|
20
14
|
});
|
package/dist/delegate.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"delegate.js","sourceRoot":"","sources":["../src/delegate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAE7C,MAAM,CAAC,KAAK,UAAU,QAAQ,CAC5B,OAAe,EACf,EAAiD;IAEjD,MAAM,MAAM,GAAG,aAAa,CAAC,QAAQ,EAAE,CAAC;IACxC,IAAI,MAAM,KAAK,SAAS,EAAE,CAAC;QACzB,MAAM,IAAI,KAAK,CACb,yDAAyD;YACzD,+BAA+B,CAChC,CAAC;IACJ,CAAC;IAED,MAAM,KAAK,GAAG,IAAI,YAAY,CAAC,OAAO,CAAC,CAAC;IACxC
|
|
1
|
+
{"version":3,"file":"delegate.js","sourceRoot":"","sources":["../src/delegate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAE7C,MAAM,CAAC,KAAK,UAAU,QAAQ,CAC5B,OAAe,EACf,EAAiD;IAEjD,MAAM,MAAM,GAAG,aAAa,CAAC,QAAQ,EAAE,CAAC;IACxC,IAAI,MAAM,KAAK,SAAS,EAAE,CAAC;QACzB,MAAM,IAAI,KAAK,CACb,yDAAyD;YACzD,+BAA+B,CAChC,CAAC;IACJ,CAAC;IAED,MAAM,KAAK,GAAG,IAAI,YAAY,CAAC,OAAO,CAAC,CAAC;IACxC,KAAK,CAAC,gBAAgB,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC,CAAC;IAE5C,MAAM,aAAa,CAAC,GAAG,CAAC,KAAK,EAAE,KAAK,IAAI,EAAE;QACxC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC;IAClB,CAAC,CAAC,CAAC;IAEH,MAAM,UAAU,GAAG,KAAK,CAAC,KAAK,EAAE,CAAC;IAEjC,MAAM,CAAC,OAAO,CAAC;QACb,IAAI,EAAE,eAAe;QACrB,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,SAAS;QACf,MAAM,EAAE,UAAU,CAAC,MAAM;QACzB,SAAS,EAAE,UAAU;KACtB,CAAC,CAAC;AACL,CAAC"}
|
package/dist/esm/cli.js
ADDED
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
// src/cli.ts
|
|
4
|
+
import * as fs from "fs";
|
|
5
|
+
import * as path from "path";
|
|
6
|
+
import * as os from "os";
|
|
7
|
+
|
|
8
|
+
// src/version.ts
|
|
9
|
+
var VERSION = "0.5.0";
|
|
10
|
+
|
|
11
|
+
// src/cli.ts
|
|
12
|
+
function cacheDir() {
|
|
13
|
+
const envOverride = process.env["ATTEST_CACHE_DIR"];
|
|
14
|
+
if (envOverride) return envOverride;
|
|
15
|
+
return path.join(os.homedir(), ".attest", "cache");
|
|
16
|
+
}
|
|
17
|
+
function cacheDbPath() {
|
|
18
|
+
return path.join(cacheDir(), "attest.db");
|
|
19
|
+
}
|
|
20
|
+
function cmdCacheStats() {
|
|
21
|
+
const dbPath = cacheDbPath();
|
|
22
|
+
const exists = fs.existsSync(dbPath);
|
|
23
|
+
let fileSize = 0;
|
|
24
|
+
if (exists) {
|
|
25
|
+
fileSize = fs.statSync(dbPath).size;
|
|
26
|
+
}
|
|
27
|
+
const stats = { exists, file_size: fileSize, path: dbPath };
|
|
28
|
+
process.stdout.write(JSON.stringify(stats) + "\n");
|
|
29
|
+
}
|
|
30
|
+
function cmdCacheClear() {
|
|
31
|
+
const dbPath = cacheDbPath();
|
|
32
|
+
if (fs.existsSync(dbPath)) {
|
|
33
|
+
fs.unlinkSync(dbPath);
|
|
34
|
+
process.stdout.write(`Cleared cache: ${dbPath}
|
|
35
|
+
`);
|
|
36
|
+
} else {
|
|
37
|
+
process.stdout.write(`No cache to clear: ${dbPath}
|
|
38
|
+
`);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
var CONFTEST_TEMPLATE = `import { describe, it, expect } from "vitest";
|
|
42
|
+
import { attestExpect, TraceBuilder } from "@attest-ai/core";
|
|
43
|
+
|
|
44
|
+
describe("my agent", () => {
|
|
45
|
+
it("returns expected output", async () => {
|
|
46
|
+
const trace = new TraceBuilder("my-agent")
|
|
47
|
+
.setInput({ user_message: "hello" })
|
|
48
|
+
.setOutput({ message: "world" })
|
|
49
|
+
.build();
|
|
50
|
+
|
|
51
|
+
attestExpect(trace).outputContains("world");
|
|
52
|
+
});
|
|
53
|
+
});
|
|
54
|
+
`;
|
|
55
|
+
function cmdInit(targetDir) {
|
|
56
|
+
const testsDir = path.join(targetDir, "tests");
|
|
57
|
+
fs.mkdirSync(testsDir, { recursive: true });
|
|
58
|
+
process.stdout.write(`Directory: ${testsDir}
|
|
59
|
+
`);
|
|
60
|
+
const sampleTestPath = path.join(testsDir, "test_my_agent.test.ts");
|
|
61
|
+
if (fs.existsSync(sampleTestPath)) {
|
|
62
|
+
process.stderr.write(`Skipped (exists): ${sampleTestPath}
|
|
63
|
+
`);
|
|
64
|
+
} else {
|
|
65
|
+
fs.writeFileSync(sampleTestPath, CONFTEST_TEMPLATE);
|
|
66
|
+
process.stdout.write(`Created: ${sampleTestPath}
|
|
67
|
+
`);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
function cmdValidate(targetDir) {
|
|
71
|
+
const testsDir = path.join(targetDir, "tests");
|
|
72
|
+
let testFiles = [];
|
|
73
|
+
if (fs.existsSync(testsDir)) {
|
|
74
|
+
testFiles = fs.readdirSync(testsDir).filter((f) => f.endsWith(".test.ts") || f.endsWith(".test.js"));
|
|
75
|
+
}
|
|
76
|
+
if (testFiles.length === 0) {
|
|
77
|
+
process.stderr.write(
|
|
78
|
+
`Warning: no test files (*.test.ts / *.test.js) found in ${testsDir}.
|
|
79
|
+
`
|
|
80
|
+
);
|
|
81
|
+
} else {
|
|
82
|
+
process.stdout.write(`Found ${testFiles.length} test file(s) in ${testsDir}
|
|
83
|
+
`);
|
|
84
|
+
}
|
|
85
|
+
const STALE_DAYS = 30;
|
|
86
|
+
const now = Date.now();
|
|
87
|
+
const goldenFiles = findGoldenFiles(targetDir);
|
|
88
|
+
for (const golden of goldenFiles) {
|
|
89
|
+
const mtime = fs.statSync(golden).mtimeMs;
|
|
90
|
+
const ageDays = Math.floor((now - mtime) / (1e3 * 60 * 60 * 24));
|
|
91
|
+
if (ageDays > STALE_DAYS) {
|
|
92
|
+
process.stderr.write(
|
|
93
|
+
`Warning: golden trace ${golden} is ${ageDays} days old (>${STALE_DAYS} days). Consider regenerating.
|
|
94
|
+
`
|
|
95
|
+
);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
function findGoldenFiles(dir) {
|
|
100
|
+
const results = [];
|
|
101
|
+
if (!fs.existsSync(dir)) return results;
|
|
102
|
+
const entries = fs.readdirSync(dir, { withFileTypes: true });
|
|
103
|
+
for (const entry of entries) {
|
|
104
|
+
const fullPath = path.join(dir, entry.name);
|
|
105
|
+
if (entry.isDirectory() && entry.name !== "node_modules") {
|
|
106
|
+
results.push(...findGoldenFiles(fullPath));
|
|
107
|
+
} else if (entry.isFile() && entry.name.endsWith(".golden")) {
|
|
108
|
+
results.push(fullPath);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
return results;
|
|
112
|
+
}
|
|
113
|
+
function main(argv = process.argv.slice(2)) {
|
|
114
|
+
const args = argv;
|
|
115
|
+
if (args[0] === "--version") {
|
|
116
|
+
process.stdout.write(`attest ${VERSION}
|
|
117
|
+
`);
|
|
118
|
+
process.exit(0);
|
|
119
|
+
}
|
|
120
|
+
if (args[0] === "cache" && args.length >= 2) {
|
|
121
|
+
if (args[1] === "stats") {
|
|
122
|
+
cmdCacheStats();
|
|
123
|
+
process.exit(0);
|
|
124
|
+
} else if (args[1] === "clear") {
|
|
125
|
+
cmdCacheClear();
|
|
126
|
+
process.exit(0);
|
|
127
|
+
} else {
|
|
128
|
+
process.stderr.write(`Unknown cache subcommand: ${args[1]}
|
|
129
|
+
`);
|
|
130
|
+
process.stderr.write("Available: cache stats, cache clear\n");
|
|
131
|
+
process.exit(1);
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
if (args[0] === "init") {
|
|
135
|
+
cmdInit(process.cwd());
|
|
136
|
+
process.exit(0);
|
|
137
|
+
}
|
|
138
|
+
if (args[0] === "validate") {
|
|
139
|
+
cmdValidate(process.cwd());
|
|
140
|
+
process.exit(0);
|
|
141
|
+
}
|
|
142
|
+
process.stderr.write(
|
|
143
|
+
"Usage: attest <command>\n\nCommands:\n --version Print version\n init Scaffold a test project\n validate Validate test suite\n cache stats Show cache statistics\n cache clear Clear cache database\n"
|
|
144
|
+
);
|
|
145
|
+
process.exit(args.length === 0 ? 0 : 1);
|
|
146
|
+
}
|
|
147
|
+
var isDirectExecution = typeof import.meta.url === "string" && import.meta.url.startsWith("file:") && process.argv[1] !== void 0 && import.meta.url.endsWith(path.basename(process.argv[1]));
|
|
148
|
+
if (isDirectExecution) {
|
|
149
|
+
main();
|
|
150
|
+
}
|
|
151
|
+
export {
|
|
152
|
+
main
|
|
153
|
+
};
|
|
154
|
+
//# sourceMappingURL=cli.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/cli.ts","../../src/version.ts"],"sourcesContent":["#!/usr/bin/env node\n/**\n * CLI entry point for Attest: npx attest or attest (after global install).\n *\n * Ported from Python sdks/python/src/attest/__main__.py\n */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\nimport * as os from \"node:os\";\nimport { VERSION } from \"./version.js\";\n\nfunction cacheDir(): string {\n const envOverride = process.env[\"ATTEST_CACHE_DIR\"];\n if (envOverride) return envOverride;\n return path.join(os.homedir(), \".attest\", \"cache\");\n}\n\nfunction cacheDbPath(): string {\n return path.join(cacheDir(), \"attest.db\");\n}\n\nfunction cmdCacheStats(): void {\n const dbPath = cacheDbPath();\n const exists = fs.existsSync(dbPath);\n let fileSize = 0;\n if (exists) {\n fileSize = fs.statSync(dbPath).size;\n }\n const stats = { exists, file_size: fileSize, path: dbPath };\n process.stdout.write(JSON.stringify(stats) + \"\\n\");\n}\n\nfunction cmdCacheClear(): void {\n const dbPath = cacheDbPath();\n if (fs.existsSync(dbPath)) {\n fs.unlinkSync(dbPath);\n process.stdout.write(`Cleared cache: ${dbPath}\\n`);\n } else {\n process.stdout.write(`No cache to clear: ${dbPath}\\n`);\n }\n}\n\nconst CONFTEST_TEMPLATE = `import { describe, it, expect } from \"vitest\";\nimport { attestExpect, TraceBuilder } from \"@attest-ai/core\";\n\ndescribe(\"my agent\", () => {\n it(\"returns expected output\", async () => {\n const trace = new TraceBuilder(\"my-agent\")\n .setInput({ user_message: \"hello\" })\n .setOutput({ message: \"world\" })\n .build();\n\n attestExpect(trace).outputContains(\"world\");\n });\n});\n`;\n\nfunction cmdInit(targetDir: string): void {\n const testsDir = path.join(targetDir, \"tests\");\n fs.mkdirSync(testsDir, { recursive: true });\n process.stdout.write(`Directory: ${testsDir}\\n`);\n\n const sampleTestPath = path.join(testsDir, \"test_my_agent.test.ts\");\n if (fs.existsSync(sampleTestPath)) {\n process.stderr.write(`Skipped (exists): ${sampleTestPath}\\n`);\n } else {\n fs.writeFileSync(sampleTestPath, CONFTEST_TEMPLATE);\n process.stdout.write(`Created: ${sampleTestPath}\\n`);\n }\n}\n\nfunction cmdValidate(targetDir: string): void {\n const testsDir = path.join(targetDir, \"tests\");\n\n let testFiles: string[] = [];\n if (fs.existsSync(testsDir)) {\n testFiles = fs\n .readdirSync(testsDir)\n .filter((f) => f.endsWith(\".test.ts\") || f.endsWith(\".test.js\"));\n }\n\n if (testFiles.length === 0) {\n process.stderr.write(\n `Warning: no test files (*.test.ts / *.test.js) found in ${testsDir}.\\n`,\n );\n } else {\n process.stdout.write(`Found ${testFiles.length} test file(s) in ${testsDir}\\n`);\n }\n\n // Check for stale golden traces\n const STALE_DAYS = 30;\n const now = Date.now();\n const goldenFiles = findGoldenFiles(targetDir);\n for (const golden of goldenFiles) {\n const mtime = fs.statSync(golden).mtimeMs;\n const ageDays = Math.floor((now - mtime) / (1000 * 60 * 60 * 24));\n if (ageDays > STALE_DAYS) {\n process.stderr.write(\n `Warning: golden trace ${golden} is ${ageDays} days old (>${STALE_DAYS} days). Consider regenerating.\\n`,\n );\n }\n }\n}\n\nfunction findGoldenFiles(dir: string): string[] {\n const results: string[] = [];\n if (!fs.existsSync(dir)) return results;\n\n const entries = fs.readdirSync(dir, { withFileTypes: true });\n for (const entry of entries) {\n const fullPath = path.join(dir, entry.name);\n if (entry.isDirectory() && entry.name !== \"node_modules\") {\n results.push(...findGoldenFiles(fullPath));\n } else if (entry.isFile() && entry.name.endsWith(\".golden\")) {\n results.push(fullPath);\n }\n }\n return results;\n}\n\nexport function main(argv: string[] = process.argv.slice(2)): void {\n const args = argv;\n\n if (args[0] === \"--version\") {\n process.stdout.write(`attest ${VERSION}\\n`);\n process.exit(0);\n }\n\n if (args[0] === \"cache\" && args.length >= 2) {\n if (args[1] === \"stats\") {\n cmdCacheStats();\n process.exit(0);\n } else if (args[1] === \"clear\") {\n cmdCacheClear();\n process.exit(0);\n } else {\n process.stderr.write(`Unknown cache subcommand: ${args[1]}\\n`);\n process.stderr.write(\"Available: cache stats, cache clear\\n\");\n process.exit(1);\n }\n }\n\n if (args[0] === \"init\") {\n cmdInit(process.cwd());\n process.exit(0);\n }\n\n if (args[0] === \"validate\") {\n cmdValidate(process.cwd());\n process.exit(0);\n }\n\n process.stderr.write(\n \"Usage: attest <command>\\n\\n\" +\n \"Commands:\\n\" +\n \" --version Print version\\n\" +\n \" init Scaffold a test project\\n\" +\n \" validate Validate test suite\\n\" +\n \" cache stats Show cache statistics\\n\" +\n \" cache clear Clear cache database\\n\",\n );\n process.exit(args.length === 0 ? 0 : 1);\n}\n\n// Run when executed directly\nconst isDirectExecution =\n typeof import.meta.url === \"string\" &&\n import.meta.url.startsWith(\"file:\") &&\n process.argv[1] !== undefined &&\n import.meta.url.endsWith(path.basename(process.argv[1]));\n\nif (isDirectExecution) {\n main();\n}\n","export const VERSION = \"0.5.0\";\nexport const ENGINE_VERSION = \"0.5.0\";\n"],"mappings":";;;AAOA,YAAY,QAAQ;AACpB,YAAY,UAAU;AACtB,YAAY,QAAQ;;;ACTb,IAAM,UAAU;;;ADYvB,SAAS,WAAmB;AAC1B,QAAM,cAAc,QAAQ,IAAI,kBAAkB;AAClD,MAAI,YAAa,QAAO;AACxB,SAAY,UAAQ,WAAQ,GAAG,WAAW,OAAO;AACnD;AAEA,SAAS,cAAsB;AAC7B,SAAY,UAAK,SAAS,GAAG,WAAW;AAC1C;AAEA,SAAS,gBAAsB;AAC7B,QAAM,SAAS,YAAY;AAC3B,QAAM,SAAY,cAAW,MAAM;AACnC,MAAI,WAAW;AACf,MAA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