@hraness/wordcell 0.21.2 → 0.22.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/README.md +196 -66
- package/dist/{authority-4sp9d552.js → authority-1pgftmwq.js} +55 -10
- package/dist/benchmark.js +3 -3
- package/dist/capture.js +6 -5
- package/dist/cli.js +61 -3800
- package/dist/clip/acquire.js +3 -2
- package/dist/clip/cli.js +6 -5
- package/dist/clip/doctor.js +4 -3
- package/dist/clip/jobs.js +3 -3
- package/dist/clip/refresh.js +1 -1
- package/dist/evaluation-builder.js +18 -17
- package/dist/evaluation-kb.js +14 -13
- package/dist/graph-authority.js +3 -3
- package/dist/graph-percolation.js +5 -5
- package/dist/index-0dqfnrz9.js +1985 -0
- package/dist/{index-0k2x4nn9.js → index-1tm7bgx7.js} +16 -4
- package/dist/{index-vdw5yjfa.js → index-2hf27mws.js} +108 -18
- package/dist/index-3agn8scn.js +306 -0
- package/dist/index-4ag64rc1.js +4299 -0
- package/dist/index-4knsp9qj.js +34 -0
- package/dist/index-66pshdtx.js +341 -0
- package/dist/index-9rf81m0p.js +368 -0
- package/dist/{index-59ssmqqm.js → index-a6kbv718.js} +1 -1
- package/dist/{index-51bap0mq.js → index-avbce90h.js} +9 -9
- package/dist/{index-180zbkkt.js → index-de2w8crk.js} +14 -13
- package/dist/{index-pbr6rv47.js → index-e6p9e926.js} +6 -6
- package/dist/{index-bcfn9xah.js → index-famy7fhs.js} +5 -5
- package/dist/{index-by0pbant.js → index-fc4dr114.js} +5 -2
- package/dist/{index-x6m57nfc.js → index-g5vsqmdy.js} +28 -57
- package/dist/{index-115b07ap.js → index-hcw140eb.js} +5 -5
- package/dist/index-j70m75wd.js +217 -0
- package/dist/{index-3ehtt59c.js → index-qwgsmtsz.js} +1 -1
- package/dist/{index-bgfzwt4h.js → index-t2bs9xdr.js} +4 -4
- package/dist/index.js +285 -93
- package/dist/portfolio.js +14 -13
- package/dist/publish-model.js +36 -0
- package/dist/publish-reader/reader.css +1042 -0
- package/dist/publish-reader/reader.js +1534 -0
- package/dist/publish-reader/theme.js +92 -0
- package/dist/publish-search.js +52 -0
- package/dist/publish.js +36 -0
- package/dist/rerank-typesafe.js +13 -0
- package/dist/rerank.js +14 -0
- package/dist/sdk.js +14 -11
- package/dist/search.js +2 -2
- package/dist/semantic.js +4 -4
- package/dist/support-mywv1em0.js +140 -0
- package/dist/workflows/decision-context.js +13 -12
- package/dist/workflows/index.js +13 -12
- package/package.json +68 -7
- package/skills/wordcell/AGENTS.md +1 -0
- package/skills/wordcell/SKILL.md +21 -1
- package/skills/wordcell/agents/openai.yaml +1 -1
- package/skills/wordcell/references/publish.md +93 -0
- package/skills/wordcell/references/query.md +22 -0
- package/src/cli-program.ts +353 -9
- package/src/cli.ts +12 -1
- package/src/clip/acquire.ts +2 -0
- package/src/clip/doctor.ts +2 -0
- package/src/clip/media.ts +2 -0
- package/src/index.ts +4 -0
- package/src/oh/authority.ts +14 -5
- package/src/oh/canonical-rust.ts +127 -0
- package/src/oh/projection-rust.ts +63 -0
- package/src/oh-adoption.ts +7 -1
- package/src/publish-graph.ts +0 -0
- package/src/publish-index.ts +195 -0
- package/src/publish-markdown.ts +617 -0
- package/src/publish-model.ts +599 -0
- package/src/publish-nav.ts +204 -0
- package/src/publish-pages.ts +382 -0
- package/src/publish-reader/reader.css +1042 -0
- package/src/publish-reader/reader.ts +1017 -0
- package/src/publish-reader/theme.ts +97 -0
- package/src/publish-search.ts +418 -0
- package/src/publish-select.ts +419 -0
- package/src/publish-theme.ts +106 -0
- package/src/publish.ts +904 -0
- package/src/rerank-credentials.ts +56 -0
- package/src/rerank-typesafe.ts +472 -0
- package/src/rerank.ts +389 -0
- package/src/sdk.ts +157 -6
- package/src/serve.ts +180 -0
- package/src/support-profile.ts +7 -0
- package/src/support.ts +73 -0
- package/src/vault.ts +23 -9
- package/dist/{index-why54q5p.js → index-gm9t95d9.js} +3 -3
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
(() => {
|
|
2
|
+
// src/publish-theme.ts
|
|
3
|
+
var WORDCELL_APPEARANCE_STORAGE_KEY = "hraness-design-palette-v1";
|
|
4
|
+
var wordcellPalettes = [
|
|
5
|
+
"wordcell",
|
|
6
|
+
"catppuccin",
|
|
7
|
+
"gruvbox",
|
|
8
|
+
"rose-pine",
|
|
9
|
+
"tokyo-night"
|
|
10
|
+
];
|
|
11
|
+
var wordcellAppearanceModes = ["system", "light", "dark"];
|
|
12
|
+
var DEFAULT_WORDCELL_APPEARANCE = {
|
|
13
|
+
palette: "wordcell",
|
|
14
|
+
mode: "system"
|
|
15
|
+
};
|
|
16
|
+
function isWordcellPalette(value) {
|
|
17
|
+
return typeof value === "string" && wordcellPalettes.includes(value);
|
|
18
|
+
}
|
|
19
|
+
function isWordcellAppearanceMode(value) {
|
|
20
|
+
return typeof value === "string" && wordcellAppearanceModes.includes(value);
|
|
21
|
+
}
|
|
22
|
+
function parseAppearancePreference(value) {
|
|
23
|
+
if (typeof value !== "object" || value === null)
|
|
24
|
+
return;
|
|
25
|
+
const palette = value.palette;
|
|
26
|
+
const mode = value.mode;
|
|
27
|
+
if (!isWordcellPalette(palette) || !isWordcellAppearanceMode(mode))
|
|
28
|
+
return;
|
|
29
|
+
return { palette, mode };
|
|
30
|
+
}
|
|
31
|
+
function serializeAppearancePreference(preference) {
|
|
32
|
+
return JSON.stringify({ palette: preference.palette, mode: preference.mode });
|
|
33
|
+
}
|
|
34
|
+
function resolveAppearanceMode(mode, systemPrefersDark) {
|
|
35
|
+
if (mode === "system")
|
|
36
|
+
return systemPrefersDark ? "dark" : "light";
|
|
37
|
+
return mode;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// src/publish-reader/theme.ts
|
|
41
|
+
var host = globalThis;
|
|
42
|
+
var root = host.document?.documentElement;
|
|
43
|
+
var media = host.matchMedia?.("(prefers-color-scheme: dark)");
|
|
44
|
+
function readPreference() {
|
|
45
|
+
try {
|
|
46
|
+
const raw = host.localStorage?.getItem(WORDCELL_APPEARANCE_STORAGE_KEY);
|
|
47
|
+
if (raw === null || raw === undefined)
|
|
48
|
+
return DEFAULT_WORDCELL_APPEARANCE;
|
|
49
|
+
return parseAppearancePreference(JSON.parse(raw)) ?? DEFAULT_WORDCELL_APPEARANCE;
|
|
50
|
+
} catch {
|
|
51
|
+
return DEFAULT_WORDCELL_APPEARANCE;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
var preference = readPreference();
|
|
55
|
+
var listeners = new Set;
|
|
56
|
+
function resolved() {
|
|
57
|
+
return resolveAppearanceMode(preference.mode, media?.matches === true);
|
|
58
|
+
}
|
|
59
|
+
function apply() {
|
|
60
|
+
const theme = resolved();
|
|
61
|
+
root?.setAttribute("data-palette", preference.palette);
|
|
62
|
+
root?.setAttribute("data-theme", theme);
|
|
63
|
+
for (const listener of listeners)
|
|
64
|
+
listener(preference, theme);
|
|
65
|
+
}
|
|
66
|
+
host.addEventListener?.("storage", (event) => {
|
|
67
|
+
if (event.key !== WORDCELL_APPEARANCE_STORAGE_KEY)
|
|
68
|
+
return;
|
|
69
|
+
preference = readPreference();
|
|
70
|
+
apply();
|
|
71
|
+
});
|
|
72
|
+
media?.addEventListener("change", () => {
|
|
73
|
+
if (preference.mode === "system")
|
|
74
|
+
apply();
|
|
75
|
+
});
|
|
76
|
+
host.wordcellAppearance = {
|
|
77
|
+
get: () => preference,
|
|
78
|
+
resolvedTheme: resolved,
|
|
79
|
+
set(next) {
|
|
80
|
+
preference = parseAppearancePreference(next) ?? DEFAULT_WORDCELL_APPEARANCE;
|
|
81
|
+
try {
|
|
82
|
+
host.localStorage?.setItem(WORDCELL_APPEARANCE_STORAGE_KEY, serializeAppearancePreference(preference));
|
|
83
|
+
} catch {}
|
|
84
|
+
apply();
|
|
85
|
+
},
|
|
86
|
+
subscribe(listener) {
|
|
87
|
+
listeners.add(listener);
|
|
88
|
+
return () => listeners.delete(listener);
|
|
89
|
+
}
|
|
90
|
+
};
|
|
91
|
+
apply();
|
|
92
|
+
})();
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import {
|
|
3
|
+
MAX_PUBLISH_MARK_RANGES,
|
|
4
|
+
MAX_PUBLISH_PREFIX_EXPANSIONS,
|
|
5
|
+
MAX_PUBLISH_QUERY_BYTES,
|
|
6
|
+
MAX_PUBLISH_QUERY_FILTERS,
|
|
7
|
+
MAX_PUBLISH_QUERY_TERMS,
|
|
8
|
+
PUBLISH_FIELD_ALIAS,
|
|
9
|
+
PUBLISH_FIELD_CONTENT,
|
|
10
|
+
PUBLISH_FIELD_METADATA,
|
|
11
|
+
PUBLISH_FIELD_PATH,
|
|
12
|
+
PUBLISH_FIELD_TAG,
|
|
13
|
+
PUBLISH_FIELD_TITLE,
|
|
14
|
+
PUBLISH_SEARCH_WEIGHTS_V1,
|
|
15
|
+
comparePublishScores,
|
|
16
|
+
publishDocMatchesFilters,
|
|
17
|
+
publishMarkRanges,
|
|
18
|
+
publishNormalize,
|
|
19
|
+
publishPrefixTerms,
|
|
20
|
+
publishQuery,
|
|
21
|
+
publishQueryParts,
|
|
22
|
+
publishShardName,
|
|
23
|
+
publishSnippet,
|
|
24
|
+
publishUtf8Bytes,
|
|
25
|
+
scorePublishDocument
|
|
26
|
+
} from "./index-3agn8scn.js";
|
|
27
|
+
import"./index-z1w83f81.js";
|
|
28
|
+
export {
|
|
29
|
+
scorePublishDocument,
|
|
30
|
+
publishUtf8Bytes,
|
|
31
|
+
publishSnippet,
|
|
32
|
+
publishShardName,
|
|
33
|
+
publishQueryParts,
|
|
34
|
+
publishQuery,
|
|
35
|
+
publishPrefixTerms,
|
|
36
|
+
publishNormalize,
|
|
37
|
+
publishMarkRanges,
|
|
38
|
+
publishDocMatchesFilters,
|
|
39
|
+
comparePublishScores,
|
|
40
|
+
PUBLISH_SEARCH_WEIGHTS_V1,
|
|
41
|
+
PUBLISH_FIELD_TITLE,
|
|
42
|
+
PUBLISH_FIELD_TAG,
|
|
43
|
+
PUBLISH_FIELD_PATH,
|
|
44
|
+
PUBLISH_FIELD_METADATA,
|
|
45
|
+
PUBLISH_FIELD_CONTENT,
|
|
46
|
+
PUBLISH_FIELD_ALIAS,
|
|
47
|
+
MAX_PUBLISH_QUERY_TERMS,
|
|
48
|
+
MAX_PUBLISH_QUERY_FILTERS,
|
|
49
|
+
MAX_PUBLISH_QUERY_BYTES,
|
|
50
|
+
MAX_PUBLISH_PREFIX_EXPANSIONS,
|
|
51
|
+
MAX_PUBLISH_MARK_RANGES
|
|
52
|
+
};
|
package/dist/publish.js
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import {
|
|
3
|
+
DEFAULT_PUBLISH_LIST_LIMIT,
|
|
4
|
+
MAX_PUBLISH_LIST_BYTES,
|
|
5
|
+
MAX_PUBLISH_LIST_LIMIT,
|
|
6
|
+
MAX_PUBLISH_PATH_COMPONENT_BYTES,
|
|
7
|
+
MAX_SITE_BYTES,
|
|
8
|
+
WORDCELL_PUBLISH_GENERATOR,
|
|
9
|
+
projectVault,
|
|
10
|
+
publishVault,
|
|
11
|
+
renderPublishReportText,
|
|
12
|
+
serializeSiteFile
|
|
13
|
+
} from "./index-0dqfnrz9.js";
|
|
14
|
+
import"./index-1tm7bgx7.js";
|
|
15
|
+
import"./index-d13v9ckt.js";
|
|
16
|
+
import"./index-48pz4jpc.js";
|
|
17
|
+
import"./index-06c9ctr6.js";
|
|
18
|
+
import"./index-4knsp9qj.js";
|
|
19
|
+
import"./index-66pshdtx.js";
|
|
20
|
+
import"./index-3agn8scn.js";
|
|
21
|
+
import"./index-5vwpzb5a.js";
|
|
22
|
+
import"./index-x3fthpsc.js";
|
|
23
|
+
import"./index-ekpwvbra.js";
|
|
24
|
+
import"./index-z1w83f81.js";
|
|
25
|
+
export {
|
|
26
|
+
serializeSiteFile,
|
|
27
|
+
renderPublishReportText,
|
|
28
|
+
publishVault,
|
|
29
|
+
projectVault,
|
|
30
|
+
WORDCELL_PUBLISH_GENERATOR,
|
|
31
|
+
MAX_SITE_BYTES,
|
|
32
|
+
MAX_PUBLISH_PATH_COMPONENT_BYTES,
|
|
33
|
+
MAX_PUBLISH_LIST_LIMIT,
|
|
34
|
+
MAX_PUBLISH_LIST_BYTES,
|
|
35
|
+
DEFAULT_PUBLISH_LIST_LIMIT
|
|
36
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import {
|
|
3
|
+
DEFAULT_SYSTEMONE_ENDPOINT,
|
|
4
|
+
DEFAULT_SYSTEMONE_MODEL,
|
|
5
|
+
createTypeSafeReranker
|
|
6
|
+
} from "./index-9rf81m0p.js";
|
|
7
|
+
import"./index-j70m75wd.js";
|
|
8
|
+
import"./index-z1w83f81.js";
|
|
9
|
+
export {
|
|
10
|
+
createTypeSafeReranker,
|
|
11
|
+
DEFAULT_SYSTEMONE_MODEL,
|
|
12
|
+
DEFAULT_SYSTEMONE_ENDPOINT
|
|
13
|
+
};
|
package/dist/rerank.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import {
|
|
3
|
+
MAX_RERANK_CANDIDATES,
|
|
4
|
+
MAX_RERANK_SNIPPET_BYTES,
|
|
5
|
+
MAX_RERANK_STATE_BYTES,
|
|
6
|
+
applyRerank
|
|
7
|
+
} from "./index-j70m75wd.js";
|
|
8
|
+
import"./index-z1w83f81.js";
|
|
9
|
+
export {
|
|
10
|
+
applyRerank,
|
|
11
|
+
MAX_RERANK_STATE_BYTES,
|
|
12
|
+
MAX_RERANK_SNIPPET_BYTES,
|
|
13
|
+
MAX_RERANK_CANDIDATES
|
|
14
|
+
};
|
package/dist/sdk.js
CHANGED
|
@@ -9,28 +9,31 @@ import {
|
|
|
9
9
|
openKnowledgeBase,
|
|
10
10
|
packSearchContext,
|
|
11
11
|
packUntrustedSearchContext,
|
|
12
|
+
searchEvidenceRank,
|
|
12
13
|
validateKnowledgeBaseSearchHistory
|
|
13
|
-
} from "./index-
|
|
14
|
-
import"./index-4j3tt0c3.js";
|
|
14
|
+
} from "./index-2hf27mws.js";
|
|
15
15
|
import"./index-adx6khj5.js";
|
|
16
|
-
import"./index-
|
|
17
|
-
import"./index-
|
|
18
|
-
import"./index-
|
|
19
|
-
import"./index-
|
|
20
|
-
import"./index-0k2x4nn9.js";
|
|
16
|
+
import"./index-hcw140eb.js";
|
|
17
|
+
import"./index-4j3tt0c3.js";
|
|
18
|
+
import"./index-j70m75wd.js";
|
|
19
|
+
import"./index-t2bs9xdr.js";
|
|
21
20
|
import"./index-nd6nynv2.js";
|
|
21
|
+
import"./index-famy7fhs.js";
|
|
22
|
+
import"./index-11621h23.js";
|
|
22
23
|
import"./index-1gwbassd.js";
|
|
23
|
-
import"./index-
|
|
24
|
-
import"./index-
|
|
24
|
+
import"./index-gm9t95d9.js";
|
|
25
|
+
import"./index-1xxnjn0d.js";
|
|
26
|
+
import"./index-1tm7bgx7.js";
|
|
27
|
+
import"./index-d13v9ckt.js";
|
|
25
28
|
import"./index-48pz4jpc.js";
|
|
26
29
|
import"./index-06c9ctr6.js";
|
|
27
|
-
import"./index-d13v9ckt.js";
|
|
28
30
|
import"./index-5vwpzb5a.js";
|
|
31
|
+
import"./index-3rm7cz6h.js";
|
|
29
32
|
import"./index-ekpwvbra.js";
|
|
30
|
-
import"./index-1xxnjn0d.js";
|
|
31
33
|
import"./index-z1w83f81.js";
|
|
32
34
|
export {
|
|
33
35
|
validateKnowledgeBaseSearchHistory,
|
|
36
|
+
searchEvidenceRank,
|
|
34
37
|
packUntrustedSearchContext,
|
|
35
38
|
packSearchContext,
|
|
36
39
|
openKnowledgeBase,
|
package/dist/search.js
CHANGED
|
@@ -6,10 +6,10 @@ import {
|
|
|
6
6
|
fuseRankedCandidates,
|
|
7
7
|
searchExactVault,
|
|
8
8
|
validateSearchQuery
|
|
9
|
-
} from "./index-
|
|
9
|
+
} from "./index-gm9t95d9.js";
|
|
10
|
+
import"./index-d13v9ckt.js";
|
|
10
11
|
import"./index-48pz4jpc.js";
|
|
11
12
|
import"./index-06c9ctr6.js";
|
|
12
|
-
import"./index-d13v9ckt.js";
|
|
13
13
|
import"./index-5vwpzb5a.js";
|
|
14
14
|
import"./index-ekpwvbra.js";
|
|
15
15
|
import"./index-z1w83f81.js";
|
package/dist/semantic.js
CHANGED
|
@@ -14,12 +14,12 @@ import {
|
|
|
14
14
|
searchSemanticVault,
|
|
15
15
|
semanticDatabasePath,
|
|
16
16
|
sha256EmbeddingModelFile
|
|
17
|
-
} from "./index-
|
|
18
|
-
import"./index-
|
|
19
|
-
import"./index-
|
|
17
|
+
} from "./index-hcw140eb.js";
|
|
18
|
+
import"./index-gm9t95d9.js";
|
|
19
|
+
import"./index-1tm7bgx7.js";
|
|
20
|
+
import"./index-d13v9ckt.js";
|
|
20
21
|
import"./index-48pz4jpc.js";
|
|
21
22
|
import"./index-06c9ctr6.js";
|
|
22
|
-
import"./index-d13v9ckt.js";
|
|
23
23
|
import"./index-5vwpzb5a.js";
|
|
24
24
|
import"./index-ekpwvbra.js";
|
|
25
25
|
import"./index-z1w83f81.js";
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
import {
|
|
3
|
+
parseArguments as parseArguments2,
|
|
4
|
+
parseUrlMetadataArguments
|
|
5
|
+
} from "./index-4ag64rc1.js";
|
|
6
|
+
import"./index-bcknqxrq.js";
|
|
7
|
+
import {
|
|
8
|
+
parsePdfArguments
|
|
9
|
+
} from "./index-054mb7d3.js";
|
|
10
|
+
import"./index-avbce90h.js";
|
|
11
|
+
import"./index-j4zgmzjr.js";
|
|
12
|
+
import"./index-de2w8crk.js";
|
|
13
|
+
import"./index-6jcz0m1c.js";
|
|
14
|
+
import"./index-f984hw45.js";
|
|
15
|
+
import"./index-fc4dr114.js";
|
|
16
|
+
import"./index-5n05se68.js";
|
|
17
|
+
import"./index-g5vsqmdy.js";
|
|
18
|
+
import"./index-hgve9rh2.js";
|
|
19
|
+
import"./index-2gv8y733.js";
|
|
20
|
+
import"./index-w2zc0vwa.js";
|
|
21
|
+
import"./index-e5fbsywq.js";
|
|
22
|
+
import {
|
|
23
|
+
parseArguments
|
|
24
|
+
} from "./index-dfag79p7.js";
|
|
25
|
+
import"./index-gh719d91.js";
|
|
26
|
+
import"./index-npg9z1a4.js";
|
|
27
|
+
import"./index-mxxxytys.js";
|
|
28
|
+
import"./index-23z4zxgg.js";
|
|
29
|
+
import"./index-pj501bh1.js";
|
|
30
|
+
import"./index-9rf81m0p.js";
|
|
31
|
+
import"./index-e6p9e926.js";
|
|
32
|
+
import"./index-2hf27mws.js";
|
|
33
|
+
import"./index-adx6khj5.js";
|
|
34
|
+
import"./index-hcw140eb.js";
|
|
35
|
+
import"./index-4j3tt0c3.js";
|
|
36
|
+
import"./index-j70m75wd.js";
|
|
37
|
+
import"./index-b88v3vtm.js";
|
|
38
|
+
import"./index-t2bs9xdr.js";
|
|
39
|
+
import"./index-nd6nynv2.js";
|
|
40
|
+
import"./index-famy7fhs.js";
|
|
41
|
+
import"./index-11621h23.js";
|
|
42
|
+
import"./index-1gwbassd.js";
|
|
43
|
+
import"./index-gm9t95d9.js";
|
|
44
|
+
import"./index-1xxnjn0d.js";
|
|
45
|
+
import"./index-0dqfnrz9.js";
|
|
46
|
+
import"./index-1tm7bgx7.js";
|
|
47
|
+
import"./index-d13v9ckt.js";
|
|
48
|
+
import"./index-48pz4jpc.js";
|
|
49
|
+
import"./index-06c9ctr6.js";
|
|
50
|
+
import"./index-4knsp9qj.js";
|
|
51
|
+
import"./index-66pshdtx.js";
|
|
52
|
+
import"./index-3agn8scn.js";
|
|
53
|
+
import"./index-hya40gb2.js";
|
|
54
|
+
import"./index-5vwpzb5a.js";
|
|
55
|
+
import"./index-x3fthpsc.js";
|
|
56
|
+
import"./index-6sw24nvv.js";
|
|
57
|
+
import"./index-3rm7cz6h.js";
|
|
58
|
+
import"./index-ekpwvbra.js";
|
|
59
|
+
import"./index-z1w83f81.js";
|
|
60
|
+
|
|
61
|
+
// src/support.ts
|
|
62
|
+
import { maybeShowSupportInvitation, runSupportCommand } from "@hraness/support-foundation/node";
|
|
63
|
+
|
|
64
|
+
// src/support-profile.ts
|
|
65
|
+
var supportProfile = {
|
|
66
|
+
id: "kb",
|
|
67
|
+
name: "Wordcell",
|
|
68
|
+
valueProposition: "Support ongoing development of inspectable Markdown memory for coding agents.",
|
|
69
|
+
updates: false
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
// src/support.ts
|
|
73
|
+
function standaloneSupportEnvironment() {
|
|
74
|
+
const environment = { ...process.env };
|
|
75
|
+
process.env.HRANESS_SUPPORT_AUDIENCE = "off";
|
|
76
|
+
return environment;
|
|
77
|
+
}
|
|
78
|
+
function isUsefulSupportResult(args, environment) {
|
|
79
|
+
const parsed = parseArguments2(args);
|
|
80
|
+
if (!parsed.ok)
|
|
81
|
+
return false;
|
|
82
|
+
const command = parsed.value;
|
|
83
|
+
switch (command.kind) {
|
|
84
|
+
case "init":
|
|
85
|
+
case "refresh":
|
|
86
|
+
case "graph":
|
|
87
|
+
case "graph-rebuild":
|
|
88
|
+
case "graph-query":
|
|
89
|
+
case "backlinks":
|
|
90
|
+
case "links":
|
|
91
|
+
case "catalog":
|
|
92
|
+
case "context":
|
|
93
|
+
case "index":
|
|
94
|
+
case "search":
|
|
95
|
+
case "history":
|
|
96
|
+
case "list":
|
|
97
|
+
case "inbox":
|
|
98
|
+
case "note-create":
|
|
99
|
+
case "relation":
|
|
100
|
+
case "percolate":
|
|
101
|
+
case "portfolio-search":
|
|
102
|
+
case "capture-diff":
|
|
103
|
+
return true;
|
|
104
|
+
case "capture-bundle":
|
|
105
|
+
return command.action === "show";
|
|
106
|
+
case "clip": {
|
|
107
|
+
const capture = parseArguments(command.arguments, environment);
|
|
108
|
+
return capture.ok && (capture.value.command === "capture" || capture.value.command === "inspect") && !capture.value.quiet;
|
|
109
|
+
}
|
|
110
|
+
case "pdf": {
|
|
111
|
+
const pdf = parsePdfArguments(command.arguments, environment);
|
|
112
|
+
return pdf.ok && pdf.value.command === "capture" && !pdf.value.quiet;
|
|
113
|
+
}
|
|
114
|
+
case "url-metadata": {
|
|
115
|
+
const metadata = parseUrlMetadataArguments(command.arguments, environment);
|
|
116
|
+
return metadata.ok && metadata.value.kind === "backfill";
|
|
117
|
+
}
|
|
118
|
+
default:
|
|
119
|
+
return false;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
async function runProductSupportCommand(args, options = {}) {
|
|
123
|
+
const result = await runSupportCommand(supportProfile, args, { command: ["wordcell"], gitEmail: false, ...options });
|
|
124
|
+
if (result.stdout !== "")
|
|
125
|
+
process.stdout.write(result.stdout);
|
|
126
|
+
if (result.stderr !== "")
|
|
127
|
+
process.stderr.write(result.stderr);
|
|
128
|
+
return result.exitCode;
|
|
129
|
+
}
|
|
130
|
+
async function showProductSupportInvitation(options = {}) {
|
|
131
|
+
try {
|
|
132
|
+
await maybeShowSupportInvitation(supportProfile, { command: ["wordcell"], usefulResult: true, gitEmail: false, ...options });
|
|
133
|
+
} catch {}
|
|
134
|
+
}
|
|
135
|
+
export {
|
|
136
|
+
standaloneSupportEnvironment,
|
|
137
|
+
showProductSupportInvitation,
|
|
138
|
+
runProductSupportCommand,
|
|
139
|
+
isUsefulSupportResult
|
|
140
|
+
};
|
|
@@ -1,26 +1,27 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
decisionContextWorkflow
|
|
4
|
-
} from "../index-
|
|
4
|
+
} from "../index-a6kbv718.js";
|
|
5
5
|
import"../index-h170byqw.js";
|
|
6
|
-
import"../index-
|
|
7
|
-
import"../index-4j3tt0c3.js";
|
|
6
|
+
import"../index-2hf27mws.js";
|
|
8
7
|
import"../index-adx6khj5.js";
|
|
9
|
-
import"../index-
|
|
10
|
-
import"../index-
|
|
11
|
-
import"../index-
|
|
12
|
-
import"../index-
|
|
13
|
-
import"../index-0k2x4nn9.js";
|
|
8
|
+
import"../index-hcw140eb.js";
|
|
9
|
+
import"../index-4j3tt0c3.js";
|
|
10
|
+
import"../index-j70m75wd.js";
|
|
11
|
+
import"../index-t2bs9xdr.js";
|
|
14
12
|
import"../index-nd6nynv2.js";
|
|
13
|
+
import"../index-famy7fhs.js";
|
|
14
|
+
import"../index-11621h23.js";
|
|
15
15
|
import"../index-1gwbassd.js";
|
|
16
|
-
import"../index-
|
|
17
|
-
import"../index-
|
|
16
|
+
import"../index-gm9t95d9.js";
|
|
17
|
+
import"../index-1xxnjn0d.js";
|
|
18
|
+
import"../index-1tm7bgx7.js";
|
|
19
|
+
import"../index-d13v9ckt.js";
|
|
18
20
|
import"../index-48pz4jpc.js";
|
|
19
21
|
import"../index-06c9ctr6.js";
|
|
20
|
-
import"../index-d13v9ckt.js";
|
|
21
22
|
import"../index-5vwpzb5a.js";
|
|
23
|
+
import"../index-3rm7cz6h.js";
|
|
22
24
|
import"../index-ekpwvbra.js";
|
|
23
|
-
import"../index-1xxnjn0d.js";
|
|
24
25
|
import"../index-z1w83f81.js";
|
|
25
26
|
export {
|
|
26
27
|
decisionContextWorkflow
|
package/dist/workflows/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
decisionContextWorkflow
|
|
4
|
-
} from "../index-
|
|
4
|
+
} from "../index-a6kbv718.js";
|
|
5
5
|
import {
|
|
6
6
|
explainChangeWorkflow
|
|
7
7
|
} from "../index-e4fagfjz.js";
|
|
@@ -9,24 +9,25 @@ import {
|
|
|
9
9
|
planRadarWorkflow
|
|
10
10
|
} from "../index-rdd5f7jj.js";
|
|
11
11
|
import"../index-h170byqw.js";
|
|
12
|
-
import"../index-
|
|
13
|
-
import"../index-4j3tt0c3.js";
|
|
12
|
+
import"../index-2hf27mws.js";
|
|
14
13
|
import"../index-adx6khj5.js";
|
|
15
|
-
import"../index-
|
|
16
|
-
import"../index-
|
|
17
|
-
import"../index-
|
|
18
|
-
import"../index-
|
|
19
|
-
import"../index-0k2x4nn9.js";
|
|
14
|
+
import"../index-hcw140eb.js";
|
|
15
|
+
import"../index-4j3tt0c3.js";
|
|
16
|
+
import"../index-j70m75wd.js";
|
|
17
|
+
import"../index-t2bs9xdr.js";
|
|
20
18
|
import"../index-nd6nynv2.js";
|
|
19
|
+
import"../index-famy7fhs.js";
|
|
20
|
+
import"../index-11621h23.js";
|
|
21
21
|
import"../index-1gwbassd.js";
|
|
22
|
-
import"../index-
|
|
23
|
-
import"../index-
|
|
22
|
+
import"../index-gm9t95d9.js";
|
|
23
|
+
import"../index-1xxnjn0d.js";
|
|
24
|
+
import"../index-1tm7bgx7.js";
|
|
25
|
+
import"../index-d13v9ckt.js";
|
|
24
26
|
import"../index-48pz4jpc.js";
|
|
25
27
|
import"../index-06c9ctr6.js";
|
|
26
|
-
import"../index-d13v9ckt.js";
|
|
27
28
|
import"../index-5vwpzb5a.js";
|
|
29
|
+
import"../index-3rm7cz6h.js";
|
|
28
30
|
import"../index-ekpwvbra.js";
|
|
29
|
-
import"../index-1xxnjn0d.js";
|
|
30
31
|
import"../index-z1w83f81.js";
|
|
31
32
|
export {
|
|
32
33
|
planRadarWorkflow,
|