solfaces 1.0.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/LICENSE +21 -0
- package/README.md +518 -0
- package/dist/agent/index.cjs +51 -0
- package/dist/agent/index.cjs.map +1 -0
- package/dist/agent/index.d.cts +65 -0
- package/dist/agent/index.d.ts +65 -0
- package/dist/agent/index.js +6 -0
- package/dist/agent/index.js.map +1 -0
- package/dist/agent/mcp-server.cjs +836 -0
- package/dist/chunk-2DIKGLXZ.cjs +126 -0
- package/dist/chunk-2DIKGLXZ.cjs.map +1 -0
- package/dist/chunk-A6N3RPEA.cjs +111 -0
- package/dist/chunk-A6N3RPEA.cjs.map +1 -0
- package/dist/chunk-CVFO7YHY.cjs +97 -0
- package/dist/chunk-CVFO7YHY.cjs.map +1 -0
- package/dist/chunk-H3SK3MNX.cjs +409 -0
- package/dist/chunk-H3SK3MNX.cjs.map +1 -0
- package/dist/chunk-KSGFMW33.js +401 -0
- package/dist/chunk-KSGFMW33.js.map +1 -0
- package/dist/chunk-LQWJRHGC.js +86 -0
- package/dist/chunk-LQWJRHGC.js.map +1 -0
- package/dist/chunk-RX6D5FGH.js +211 -0
- package/dist/chunk-RX6D5FGH.js.map +1 -0
- package/dist/chunk-SNJABBAT.js +107 -0
- package/dist/chunk-SNJABBAT.js.map +1 -0
- package/dist/chunk-VMNATBH3.cjs +222 -0
- package/dist/chunk-VMNATBH3.cjs.map +1 -0
- package/dist/chunk-WURY4QGH.js +117 -0
- package/dist/chunk-WURY4QGH.js.map +1 -0
- package/dist/core/index.cjs +82 -0
- package/dist/core/index.cjs.map +1 -0
- package/dist/core/index.d.cts +104 -0
- package/dist/core/index.d.ts +104 -0
- package/dist/core/index.js +5 -0
- package/dist/core/index.js.map +1 -0
- package/dist/index.cjs +100 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +4 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -0
- package/dist/react/index.cjs +543 -0
- package/dist/react/index.cjs.map +1 -0
- package/dist/react/index.d.cts +28 -0
- package/dist/react/index.d.ts +28 -0
- package/dist/react/index.js +541 -0
- package/dist/react/index.js.map +1 -0
- package/dist/solfaces.cdn.global.js +3 -0
- package/dist/solfaces.cdn.global.js.map +1 -0
- package/dist/themes/index.cjs +48 -0
- package/dist/themes/index.cjs.map +1 -0
- package/dist/themes/index.d.cts +14 -0
- package/dist/themes/index.d.ts +14 -0
- package/dist/themes/index.js +3 -0
- package/dist/themes/index.js.map +1 -0
- package/dist/traits-DAFZnXeS.d.cts +61 -0
- package/dist/traits-DAFZnXeS.d.ts +61 -0
- package/dist/vanilla/index.cjs +43 -0
- package/dist/vanilla/index.cjs.map +1 -0
- package/dist/vanilla/index.d.cts +7 -0
- package/dist/vanilla/index.d.ts +7 -0
- package/dist/vanilla/index.js +39 -0
- package/dist/vanilla/index.js.map +1 -0
- package/package.json +100 -0
- package/python/solfaces.py +475 -0
- package/skill.md +463 -0
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
// src/core/traits.ts
|
|
2
|
+
var SKIN_COLORS = [
|
|
3
|
+
"#ffd5b0",
|
|
4
|
+
"#f4c794",
|
|
5
|
+
"#e0a370",
|
|
6
|
+
"#c68642",
|
|
7
|
+
"#8d5524",
|
|
8
|
+
"#4a2c17"
|
|
9
|
+
];
|
|
10
|
+
var EYE_COLORS = [
|
|
11
|
+
"#3d2b1f",
|
|
12
|
+
// dark brown
|
|
13
|
+
"#4a80c4",
|
|
14
|
+
// blue
|
|
15
|
+
"#5a9a5a",
|
|
16
|
+
// green
|
|
17
|
+
"#c89430",
|
|
18
|
+
// amber
|
|
19
|
+
"#8a8a8a"
|
|
20
|
+
// gray
|
|
21
|
+
];
|
|
22
|
+
var HAIR_COLORS = [
|
|
23
|
+
"#1a1a1a",
|
|
24
|
+
// black
|
|
25
|
+
"#6b3a2a",
|
|
26
|
+
// brown
|
|
27
|
+
"#d4a844",
|
|
28
|
+
// blonde
|
|
29
|
+
"#c44a20",
|
|
30
|
+
// ginger
|
|
31
|
+
"#c8e64a",
|
|
32
|
+
// neon lime
|
|
33
|
+
"#6090e0",
|
|
34
|
+
// neon blue
|
|
35
|
+
"#14F195",
|
|
36
|
+
// neon mint
|
|
37
|
+
"#e040c0"
|
|
38
|
+
// neon magenta
|
|
39
|
+
];
|
|
40
|
+
var BG_COLORS = [
|
|
41
|
+
"#c8e64a",
|
|
42
|
+
"#6090e0",
|
|
43
|
+
"#14F195",
|
|
44
|
+
"#e8dcc8",
|
|
45
|
+
"#f85149"
|
|
46
|
+
];
|
|
47
|
+
function djb2(str) {
|
|
48
|
+
let hash = 5381;
|
|
49
|
+
for (let i = 0; i < str.length; i++) {
|
|
50
|
+
hash = (hash << 5) + hash + str.charCodeAt(i) | 0;
|
|
51
|
+
}
|
|
52
|
+
return hash >>> 0;
|
|
53
|
+
}
|
|
54
|
+
function mulberry32(seed) {
|
|
55
|
+
let s = seed | 0;
|
|
56
|
+
return () => {
|
|
57
|
+
s = s + 1831565813 | 0;
|
|
58
|
+
let t = Math.imul(s ^ s >>> 15, 1 | s);
|
|
59
|
+
t = t + Math.imul(t ^ t >>> 7, 61 | t) ^ t;
|
|
60
|
+
return ((t ^ t >>> 14) >>> 0) / 4294967296;
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
function generateTraits(walletAddress, overrides) {
|
|
64
|
+
const seed = djb2(walletAddress);
|
|
65
|
+
const rand = mulberry32(seed);
|
|
66
|
+
const traits = {
|
|
67
|
+
faceShape: Math.floor(rand() * 4),
|
|
68
|
+
skinColor: Math.floor(rand() * 6),
|
|
69
|
+
eyeStyle: Math.floor(rand() * 8),
|
|
70
|
+
eyeColor: Math.floor(rand() * 5),
|
|
71
|
+
eyebrows: Math.floor(rand() * 5),
|
|
72
|
+
nose: Math.floor(rand() * 4),
|
|
73
|
+
mouth: Math.floor(rand() * 6),
|
|
74
|
+
hairStyle: Math.floor(rand() * 8),
|
|
75
|
+
hairColor: Math.floor(rand() * 8),
|
|
76
|
+
accessory: Math.floor(rand() * 6),
|
|
77
|
+
bgColor: Math.floor(rand() * 5)
|
|
78
|
+
};
|
|
79
|
+
return overrides ? { ...traits, ...overrides } : traits;
|
|
80
|
+
}
|
|
81
|
+
var FACE_LABELS = ["Round", "Square", "Oval", "Hexagon"];
|
|
82
|
+
var SKIN_LABELS = ["Light Peach", "Warm Tan", "Golden Brown", "Medium Brown", "Deep Brown", "Rich Dark Brown"];
|
|
83
|
+
var EYE_STYLE_LABELS = ["Round", "Dots", "Almond", "Wide", "Sleepy", "Winking", "Lashes", "Narrow"];
|
|
84
|
+
var EYE_COLOR_LABELS = ["Dark Brown", "Blue", "Green", "Amber", "Gray"];
|
|
85
|
+
var BROW_LABELS = ["None", "Thin", "Thick", "Arched", "Angled"];
|
|
86
|
+
var NOSE_LABELS = ["None", "Dot", "Triangle", "Button"];
|
|
87
|
+
var MOUTH_LABELS = ["Smile", "Neutral", "Grin", "Open", "Smirk", "Wide Smile"];
|
|
88
|
+
var HAIR_STYLE_LABELS = ["Bald", "Short", "Spiky", "Swept", "Mohawk", "Long", "Bob", "Buzz"];
|
|
89
|
+
var HAIR_COLOR_LABELS = ["Black", "Brown", "Blonde", "Ginger", "Neon Lime", "Neon Blue", "Solana Mint", "Neon Magenta"];
|
|
90
|
+
var ACCESSORY_LABELS = ["None", "None", "Round Glasses", "Square Glasses", "Earring", "Bandana"];
|
|
91
|
+
var BG_COLOR_LABELS = ["Lime", "Blue", "Mint", "Sand", "Red"];
|
|
92
|
+
function getTraitLabels(traits) {
|
|
93
|
+
return {
|
|
94
|
+
faceShape: FACE_LABELS[traits.faceShape] ?? "Round",
|
|
95
|
+
skinColor: SKIN_LABELS[traits.skinColor] ?? "Warm Tan",
|
|
96
|
+
eyeStyle: EYE_STYLE_LABELS[traits.eyeStyle] ?? "Round",
|
|
97
|
+
eyeColor: EYE_COLOR_LABELS[traits.eyeColor] ?? "Dark Brown",
|
|
98
|
+
eyebrows: BROW_LABELS[traits.eyebrows] ?? "None",
|
|
99
|
+
nose: NOSE_LABELS[traits.nose] ?? "None",
|
|
100
|
+
mouth: MOUTH_LABELS[traits.mouth] ?? "Smile",
|
|
101
|
+
hairStyle: HAIR_STYLE_LABELS[traits.hairStyle] ?? "Bald",
|
|
102
|
+
hairColor: HAIR_COLOR_LABELS[traits.hairColor] ?? "Black",
|
|
103
|
+
accessory: ACCESSORY_LABELS[traits.accessory] ?? "None",
|
|
104
|
+
bgColor: BG_COLOR_LABELS[traits.bgColor] ?? "Lime"
|
|
105
|
+
};
|
|
106
|
+
}
|
|
107
|
+
function traitHash(walletAddress) {
|
|
108
|
+
return (djb2(walletAddress) >>> 0).toString(16).padStart(8, "0");
|
|
109
|
+
}
|
|
110
|
+
function resolveTheme(themeName, themes) {
|
|
111
|
+
if (!themeName || !themes) return void 0;
|
|
112
|
+
return themes[themeName];
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export { BG_COLORS, EYE_COLORS, HAIR_COLORS, SKIN_COLORS, generateTraits, getTraitLabels, resolveTheme, traitHash };
|
|
116
|
+
//# sourceMappingURL=chunk-WURY4QGH.js.map
|
|
117
|
+
//# sourceMappingURL=chunk-WURY4QGH.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/core/traits.ts"],"names":[],"mappings":";AA2DO,IAAM,WAAA,GAAc;AAAA,EACzB,SAAA;AAAA,EAAW,SAAA;AAAA,EAAW,SAAA;AAAA,EACtB,SAAA;AAAA,EAAW,SAAA;AAAA,EAAW;AACxB;AAEO,IAAM,UAAA,GAAa;AAAA,EACxB,SAAA;AAAA;AAAA,EACA,SAAA;AAAA;AAAA,EACA,SAAA;AAAA;AAAA,EACA,SAAA;AAAA;AAAA,EACA;AAAA;AACF;AAEO,IAAM,WAAA,GAAc;AAAA,EACzB,SAAA;AAAA;AAAA,EACA,SAAA;AAAA;AAAA,EACA,SAAA;AAAA;AAAA,EACA,SAAA;AAAA;A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kB,MAAA,CAAO,SAAS,CAAA,IAAK,MAAA;AAAA,IAClD,SAAA,EAAW,iBAAA,CAAkB,MAAA,CAAO,SAAS,CAAA,IAAK,OAAA;AAAA,IAClD,SAAA,EAAW,gBAAA,CAAiB,MAAA,CAAO,SAAS,CAAA,IAAK,MAAA;AAAA,IACjD,OAAA,EAAS,eAAA,CAAgB,MAAA,CAAO,OAAO,CAAA,IAAK;AAAA,GAC9C;AACF;AAIO,SAAS,UAAU,aAAA,EAA+B;AACvD,EAAA,OAAA,CAAQ,IAAA,CAAK,aAAa,CAAA,KAAM,CAAA,EAAG,SAAS,EAAE,CAAA,CAAE,QAAA,CAAS,CAAA,EAAG,GAAG,CAAA;AACjE;AAIO,SAAS,YAAA,CACd,WACA,MAAA,EAC0B;AAC1B,EAAA,IAAI,CAAC,SAAA,IAAa,CAAC,MAAA,EAAQ,OAAO,MAAA;AAClC,EAAA,OAAO,OAAO,SAAS,CAAA;AACzB","file":"chunk-WURY4QGH.js","sourcesContent":["// ═══════════════════════════════════════════════════\n// SOLFACES — Deterministic avatar trait engine\n// ═══════════════════════════════════════════════════\n\n// ─── Types ────────────────────────────────────────\n\nexport interface SolFaceTraits {\n faceShape: number; // 0-3\n skinColor: number; // 0-5\n eyeStyle: number; // 0-7\n eyeColor: number; // 0-4\n eyebrows: number; // 0-4\n nose: number; // 0-3\n mouth: number; // 0-5\n hairStyle: number; // 0-7\n hairColor: number; // 0-7\n accessory: number; // 0-5 (0-1 = none, 2-5 = items)\n bgColor: number; // 0-4\n}\n\nexport interface SolFaceTheme {\n skinColors?: string[];\n eyeColors?: string[];\n hairColors?: string[];\n bgColors?: string[];\n mouthColor?: string;\n eyebrowColor?: string;\n accessoryColor?: string;\n eyeWhiteColor?: string;\n noseColor?: string;\n bgOpacity?: number;\n bgRadius?: number;\n border?: { color: string; width: number };\n}\n\nexport interface RenderOptions {\n size?: number;\n theme?: SolFaceTheme;\n traitOverrides?: Partial<SolFaceTraits>;\n enableBlink?: boolean | {\n duration?: number;\n delay?: number;\n };\n className?: string;\n colorOverrides?: {\n skin?: string;\n eyes?: string;\n hair?: string;\n bg?: string;\n mouth?: string;\n eyebrow?: string;\n accessory?: string;\n nose?: string;\n eyeWhite?: string;\n };\n}\n\n// ─── Color Palettes ──────────────────────────────\n\nexport const SKIN_COLORS = [\n \"#ffd5b0\", \"#f4c794\", \"#e0a370\",\n \"#c68642\", \"#8d5524\", \"#4a2c17\",\n];\n\nexport const EYE_COLORS = [\n \"#3d2b1f\", // dark brown\n \"#4a80c4\", // blue\n \"#5a9a5a\", // green\n \"#c89430\", // amber\n \"#8a8a8a\", // gray\n];\n\nexport const HAIR_COLORS = [\n \"#1a1a1a\", // black\n \"#6b3a2a\", // brown\n \"#d4a844\", // blonde\n \"#c44a20\", // ginger\n \"#c8e64a\", // neon lime\n \"#6090e0\", // neon blue\n \"#14F195\", // neon mint\n \"#e040c0\", // neon magenta\n];\n\nexport const BG_COLORS = [\n \"#c8e64a\", \"#6090e0\", \"#14F195\", \"#e8dcc8\", \"#f85149\",\n];\n\n// ─── Hashing (djb2) ─────────────────────────────\n\nfunction djb2(str: string): number {\n let hash = 5381;\n for (let i = 0; i < str.length; i++) {\n hash = ((hash << 5) + hash + str.charCodeAt(i)) | 0;\n }\n return hash >>> 0;\n}\n\n// ─── PRNG (mulberry32) ──────────────────────────\n\nfunction mulberry32(seed: number): () => number {\n let s = seed | 0;\n return () => {\n s = (s + 0x6d2b79f5) | 0;\n let t = Math.imul(s ^ (s >>> 15), 1 | s);\n t = (t + Math.imul(t ^ (t >>> 7), 61 | t)) ^ t;\n return ((t ^ (t >>> 14)) >>> 0) / 4294967296;\n };\n}\n\n// ─── Trait Generation ───────────────────────────\n\nexport function generateTraits(\n walletAddress: string,\n overrides?: Partial<SolFaceTraits>\n): SolFaceTraits {\n const seed = djb2(walletAddress);\n const rand = mulberry32(seed);\n\n const traits: SolFaceTraits = {\n faceShape: Math.floor(rand() * 4),\n skinColor: Math.floor(rand() * 6),\n eyeStyle: Math.floor(rand() * 8),\n eyeColor: Math.floor(rand() * 5),\n eyebrows: Math.floor(rand() * 5),\n nose: Math.floor(rand() * 4),\n mouth: Math.floor(rand() * 6),\n hairStyle: Math.floor(rand() * 8),\n hairColor: Math.floor(rand() * 8),\n accessory: Math.floor(rand() * 6),\n bgColor: Math.floor(rand() * 5),\n };\n\n return overrides ? { ...traits, ...overrides } : traits;\n}\n\n// ─── Trait Labels ───────────────────────────────\n\nconst FACE_LABELS = [\"Round\", \"Square\", \"Oval\", \"Hexagon\"];\nconst SKIN_LABELS = [\"Light Peach\", \"Warm Tan\", \"Golden Brown\", \"Medium Brown\", \"Deep Brown\", \"Rich Dark Brown\"];\nconst EYE_STYLE_LABELS = [\"Round\", \"Dots\", \"Almond\", \"Wide\", \"Sleepy\", \"Winking\", \"Lashes\", \"Narrow\"];\nconst EYE_COLOR_LABELS = [\"Dark Brown\", \"Blue\", \"Green\", \"Amber\", \"Gray\"];\nconst BROW_LABELS = [\"None\", \"Thin\", \"Thick\", \"Arched\", \"Angled\"];\nconst NOSE_LABELS = [\"None\", \"Dot\", \"Triangle\", \"Button\"];\nconst MOUTH_LABELS = [\"Smile\", \"Neutral\", \"Grin\", \"Open\", \"Smirk\", \"Wide Smile\"];\nconst HAIR_STYLE_LABELS = [\"Bald\", \"Short\", \"Spiky\", \"Swept\", \"Mohawk\", \"Long\", \"Bob\", \"Buzz\"];\nconst HAIR_COLOR_LABELS = [\"Black\", \"Brown\", \"Blonde\", \"Ginger\", \"Neon Lime\", \"Neon Blue\", \"Solana Mint\", \"Neon Magenta\"];\nconst ACCESSORY_LABELS = [\"None\", \"None\", \"Round Glasses\", \"Square Glasses\", \"Earring\", \"Bandana\"];\nconst BG_COLOR_LABELS = [\"Lime\", \"Blue\", \"Mint\", \"Sand\", \"Red\"];\n\nexport function getTraitLabels(traits: SolFaceTraits): Record<string, string> {\n return {\n faceShape: FACE_LABELS[traits.faceShape] ?? \"Round\",\n skinColor: SKIN_LABELS[traits.skinColor] ?? \"Warm Tan\",\n eyeStyle: EYE_STYLE_LABELS[traits.eyeStyle] ?? \"Round\",\n eyeColor: EYE_COLOR_LABELS[traits.eyeColor] ?? \"Dark Brown\",\n eyebrows: BROW_LABELS[traits.eyebrows] ?? \"None\",\n nose: NOSE_LABELS[traits.nose] ?? \"None\",\n mouth: MOUTH_LABELS[traits.mouth] ?? \"Smile\",\n hairStyle: HAIR_STYLE_LABELS[traits.hairStyle] ?? \"Bald\",\n hairColor: HAIR_COLOR_LABELS[traits.hairColor] ?? \"Black\",\n accessory: ACCESSORY_LABELS[traits.accessory] ?? \"None\",\n bgColor: BG_COLOR_LABELS[traits.bgColor] ?? \"Lime\",\n };\n}\n\n// ─── Trait Hash ─────────────────────────────────\n\nexport function traitHash(walletAddress: string): string {\n return (djb2(walletAddress) >>> 0).toString(16).padStart(8, \"0\");\n}\n\n// ─── Theme Resolution ───────────────────────────\n\nexport function resolveTheme(\n themeName?: string,\n themes?: Record<string, SolFaceTheme>\n): SolFaceTheme | undefined {\n if (!themeName || !themes) return undefined;\n return themes[themeName];\n}\n"]}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkA6N3RPEA_cjs = require('../chunk-A6N3RPEA.cjs');
|
|
4
|
+
var chunkH3SK3MNX_cjs = require('../chunk-H3SK3MNX.cjs');
|
|
5
|
+
var chunk2DIKGLXZ_cjs = require('../chunk-2DIKGLXZ.cjs');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
Object.defineProperty(exports, "renderSolFacePNG", {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function () { return chunkA6N3RPEA_cjs.renderSolFacePNG; }
|
|
12
|
+
});
|
|
13
|
+
Object.defineProperty(exports, "renderSolFacePNGBrowser", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () { return chunkA6N3RPEA_cjs.renderSolFacePNGBrowser; }
|
|
16
|
+
});
|
|
17
|
+
Object.defineProperty(exports, "renderSolFacePNGDataURL", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: function () { return chunkA6N3RPEA_cjs.renderSolFacePNGDataURL; }
|
|
20
|
+
});
|
|
21
|
+
Object.defineProperty(exports, "agentAppearancePrompt", {
|
|
22
|
+
enumerable: true,
|
|
23
|
+
get: function () { return chunkH3SK3MNX_cjs.agentAppearancePrompt; }
|
|
24
|
+
});
|
|
25
|
+
Object.defineProperty(exports, "describeAppearance", {
|
|
26
|
+
enumerable: true,
|
|
27
|
+
get: function () { return chunkH3SK3MNX_cjs.describeAppearance; }
|
|
28
|
+
});
|
|
29
|
+
Object.defineProperty(exports, "describeTraits", {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
get: function () { return chunkH3SK3MNX_cjs.describeTraits; }
|
|
32
|
+
});
|
|
33
|
+
Object.defineProperty(exports, "renderSolFaceBase64", {
|
|
34
|
+
enumerable: true,
|
|
35
|
+
get: function () { return chunkH3SK3MNX_cjs.renderSolFaceBase64; }
|
|
36
|
+
});
|
|
37
|
+
Object.defineProperty(exports, "renderSolFaceDataURI", {
|
|
38
|
+
enumerable: true,
|
|
39
|
+
get: function () { return chunkH3SK3MNX_cjs.renderSolFaceDataURI; }
|
|
40
|
+
});
|
|
41
|
+
Object.defineProperty(exports, "renderSolFaceSVG", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
get: function () { return chunkH3SK3MNX_cjs.renderSolFaceSVG; }
|
|
44
|
+
});
|
|
45
|
+
Object.defineProperty(exports, "solFaceAltText", {
|
|
46
|
+
enumerable: true,
|
|
47
|
+
get: function () { return chunkH3SK3MNX_cjs.solFaceAltText; }
|
|
48
|
+
});
|
|
49
|
+
Object.defineProperty(exports, "BG_COLORS", {
|
|
50
|
+
enumerable: true,
|
|
51
|
+
get: function () { return chunk2DIKGLXZ_cjs.BG_COLORS; }
|
|
52
|
+
});
|
|
53
|
+
Object.defineProperty(exports, "EYE_COLORS", {
|
|
54
|
+
enumerable: true,
|
|
55
|
+
get: function () { return chunk2DIKGLXZ_cjs.EYE_COLORS; }
|
|
56
|
+
});
|
|
57
|
+
Object.defineProperty(exports, "HAIR_COLORS", {
|
|
58
|
+
enumerable: true,
|
|
59
|
+
get: function () { return chunk2DIKGLXZ_cjs.HAIR_COLORS; }
|
|
60
|
+
});
|
|
61
|
+
Object.defineProperty(exports, "SKIN_COLORS", {
|
|
62
|
+
enumerable: true,
|
|
63
|
+
get: function () { return chunk2DIKGLXZ_cjs.SKIN_COLORS; }
|
|
64
|
+
});
|
|
65
|
+
Object.defineProperty(exports, "generateTraits", {
|
|
66
|
+
enumerable: true,
|
|
67
|
+
get: function () { return chunk2DIKGLXZ_cjs.generateTraits; }
|
|
68
|
+
});
|
|
69
|
+
Object.defineProperty(exports, "getTraitLabels", {
|
|
70
|
+
enumerable: true,
|
|
71
|
+
get: function () { return chunk2DIKGLXZ_cjs.getTraitLabels; }
|
|
72
|
+
});
|
|
73
|
+
Object.defineProperty(exports, "resolveTheme", {
|
|
74
|
+
enumerable: true,
|
|
75
|
+
get: function () { return chunk2DIKGLXZ_cjs.resolveTheme; }
|
|
76
|
+
});
|
|
77
|
+
Object.defineProperty(exports, "traitHash", {
|
|
78
|
+
enumerable: true,
|
|
79
|
+
get: function () { return chunk2DIKGLXZ_cjs.traitHash; }
|
|
80
|
+
});
|
|
81
|
+
//# sourceMappingURL=index.cjs.map
|
|
82
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"index.cjs"}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { R as RenderOptions, b as SolFaceTraits } from '../traits-DAFZnXeS.cjs';
|
|
2
|
+
export { B as BG_COLORS, E as EYE_COLORS, H as HAIR_COLORS, S as SKIN_COLORS, a as SolFaceTheme, g as generateTraits, c as getTraitLabels, r as resolveTheme, t as traitHash } from '../traits-DAFZnXeS.cjs';
|
|
3
|
+
|
|
4
|
+
declare function renderSolFaceSVG(walletAddress: string, options?: RenderOptions): string;
|
|
5
|
+
declare function renderSolFaceDataURI(walletAddress: string, options?: RenderOptions): string;
|
|
6
|
+
declare function renderSolFaceBase64(walletAddress: string, options?: RenderOptions): string;
|
|
7
|
+
|
|
8
|
+
interface DescribeOptions {
|
|
9
|
+
/** Include background color in description. Default: true */
|
|
10
|
+
includeBackground?: boolean;
|
|
11
|
+
/** Output format. Default: "paragraph" */
|
|
12
|
+
format?: "paragraph" | "structured" | "compact";
|
|
13
|
+
/** Perspective: how the description is framed. Default: "third" */
|
|
14
|
+
perspective?: "first" | "third";
|
|
15
|
+
/** Optional name to use instead of "This SolFace" / "I". */
|
|
16
|
+
name?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Generate a natural language description of a SolFace avatar.
|
|
20
|
+
*
|
|
21
|
+
* Designed for AI agent system prompts, profile bios, alt text,
|
|
22
|
+
* and anywhere a wallet's visual identity needs to be described in words.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```ts
|
|
26
|
+
* // For an AI agent's system prompt
|
|
27
|
+
* const desc = describeAppearance("7xKXq...", {
|
|
28
|
+
* perspective: "first",
|
|
29
|
+
* name: "Atlas",
|
|
30
|
+
* });
|
|
31
|
+
* // → "I'm Atlas. I have a round face with light peach skin, wide
|
|
32
|
+
* // and expressive blue eyes with elegantly arched eyebrows, and
|
|
33
|
+
* // tall, spiky Solana mint green hair. I'm wearing round glasses
|
|
34
|
+
* // and have a confident smirk."
|
|
35
|
+
*
|
|
36
|
+
* // For alt text
|
|
37
|
+
* const alt = describeAppearance("7xKXq...", { format: "compact" });
|
|
38
|
+
* // → "Round face, light peach skin, blue wide eyes, spiky mint hair, round glasses, smirking"
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
declare function describeAppearance(walletAddress: string, options?: DescribeOptions): string;
|
|
42
|
+
/**
|
|
43
|
+
* Generate description from pre-computed traits (for when you already have them).
|
|
44
|
+
*/
|
|
45
|
+
declare function describeTraits(traits: SolFaceTraits, options?: DescribeOptions): string;
|
|
46
|
+
/**
|
|
47
|
+
* Generate accessible alt text for a SolFace avatar.
|
|
48
|
+
* Shorter than full description, optimized for screen readers.
|
|
49
|
+
*/
|
|
50
|
+
declare function solFaceAltText(walletAddress: string): string;
|
|
51
|
+
/**
|
|
52
|
+
* Generate a system prompt snippet for an AI agent describing its appearance.
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* ```ts
|
|
56
|
+
* const appearance = agentAppearancePrompt("7xKXq...", "Atlas");
|
|
57
|
+
* // Use in system prompt:
|
|
58
|
+
* // `You are Atlas, an AI agent. ${appearance}`
|
|
59
|
+
* ```
|
|
60
|
+
*/
|
|
61
|
+
declare function agentAppearancePrompt(walletAddress: string, agentName?: string): string;
|
|
62
|
+
|
|
63
|
+
interface PNGOptions extends RenderOptions {
|
|
64
|
+
/** Output pixel size (both width and height). Default: 256 */
|
|
65
|
+
pngSize?: number;
|
|
66
|
+
/** PNG quality (0-1, only affects some renderers). Default: 1 */
|
|
67
|
+
quality?: number;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Render a SolFace as a PNG Buffer using `sharp`.
|
|
71
|
+
* Requires: `npm install sharp`
|
|
72
|
+
*
|
|
73
|
+
* @returns PNG buffer
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* ```ts
|
|
77
|
+
* import { renderSolFacePNG } from "solfaces/core/rasterize";
|
|
78
|
+
*
|
|
79
|
+
* const png = await renderSolFacePNG("7xKXq...", { pngSize: 256 });
|
|
80
|
+
* fs.writeFileSync("avatar.png", png);
|
|
81
|
+
* ```
|
|
82
|
+
*/
|
|
83
|
+
declare function renderSolFacePNG(walletAddress: string, options?: PNGOptions): Promise<Buffer>;
|
|
84
|
+
/**
|
|
85
|
+
* Render a SolFace as a PNG Blob in the browser.
|
|
86
|
+
* Uses Canvas API — works in all modern browsers.
|
|
87
|
+
*
|
|
88
|
+
* @returns PNG Blob
|
|
89
|
+
*
|
|
90
|
+
* @example
|
|
91
|
+
* ```ts
|
|
92
|
+
* const blob = await renderSolFacePNGBrowser("7xKXq...", { pngSize: 256 });
|
|
93
|
+
* const url = URL.createObjectURL(blob);
|
|
94
|
+
* img.src = url;
|
|
95
|
+
* ```
|
|
96
|
+
*/
|
|
97
|
+
declare function renderSolFacePNGBrowser(walletAddress: string, options?: PNGOptions): Promise<Blob>;
|
|
98
|
+
/**
|
|
99
|
+
* Render a SolFace as a PNG data URL in the browser.
|
|
100
|
+
* Convenient for directly setting img.src without blob URLs.
|
|
101
|
+
*/
|
|
102
|
+
declare function renderSolFacePNGDataURL(walletAddress: string, options?: PNGOptions): Promise<string>;
|
|
103
|
+
|
|
104
|
+
export { type DescribeOptions, type PNGOptions, RenderOptions, SolFaceTraits, agentAppearancePrompt, describeAppearance, describeTraits, renderSolFaceBase64, renderSolFaceDataURI, renderSolFacePNG, renderSolFacePNGBrowser, renderSolFacePNGDataURL, renderSolFaceSVG, solFaceAltText };
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { R as RenderOptions, b as SolFaceTraits } from '../traits-DAFZnXeS.js';
|
|
2
|
+
export { B as BG_COLORS, E as EYE_COLORS, H as HAIR_COLORS, S as SKIN_COLORS, a as SolFaceTheme, g as generateTraits, c as getTraitLabels, r as resolveTheme, t as traitHash } from '../traits-DAFZnXeS.js';
|
|
3
|
+
|
|
4
|
+
declare function renderSolFaceSVG(walletAddress: string, options?: RenderOptions): string;
|
|
5
|
+
declare function renderSolFaceDataURI(walletAddress: string, options?: RenderOptions): string;
|
|
6
|
+
declare function renderSolFaceBase64(walletAddress: string, options?: RenderOptions): string;
|
|
7
|
+
|
|
8
|
+
interface DescribeOptions {
|
|
9
|
+
/** Include background color in description. Default: true */
|
|
10
|
+
includeBackground?: boolean;
|
|
11
|
+
/** Output format. Default: "paragraph" */
|
|
12
|
+
format?: "paragraph" | "structured" | "compact";
|
|
13
|
+
/** Perspective: how the description is framed. Default: "third" */
|
|
14
|
+
perspective?: "first" | "third";
|
|
15
|
+
/** Optional name to use instead of "This SolFace" / "I". */
|
|
16
|
+
name?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Generate a natural language description of a SolFace avatar.
|
|
20
|
+
*
|
|
21
|
+
* Designed for AI agent system prompts, profile bios, alt text,
|
|
22
|
+
* and anywhere a wallet's visual identity needs to be described in words.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```ts
|
|
26
|
+
* // For an AI agent's system prompt
|
|
27
|
+
* const desc = describeAppearance("7xKXq...", {
|
|
28
|
+
* perspective: "first",
|
|
29
|
+
* name: "Atlas",
|
|
30
|
+
* });
|
|
31
|
+
* // → "I'm Atlas. I have a round face with light peach skin, wide
|
|
32
|
+
* // and expressive blue eyes with elegantly arched eyebrows, and
|
|
33
|
+
* // tall, spiky Solana mint green hair. I'm wearing round glasses
|
|
34
|
+
* // and have a confident smirk."
|
|
35
|
+
*
|
|
36
|
+
* // For alt text
|
|
37
|
+
* const alt = describeAppearance("7xKXq...", { format: "compact" });
|
|
38
|
+
* // → "Round face, light peach skin, blue wide eyes, spiky mint hair, round glasses, smirking"
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
declare function describeAppearance(walletAddress: string, options?: DescribeOptions): string;
|
|
42
|
+
/**
|
|
43
|
+
* Generate description from pre-computed traits (for when you already have them).
|
|
44
|
+
*/
|
|
45
|
+
declare function describeTraits(traits: SolFaceTraits, options?: DescribeOptions): string;
|
|
46
|
+
/**
|
|
47
|
+
* Generate accessible alt text for a SolFace avatar.
|
|
48
|
+
* Shorter than full description, optimized for screen readers.
|
|
49
|
+
*/
|
|
50
|
+
declare function solFaceAltText(walletAddress: string): string;
|
|
51
|
+
/**
|
|
52
|
+
* Generate a system prompt snippet for an AI agent describing its appearance.
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* ```ts
|
|
56
|
+
* const appearance = agentAppearancePrompt("7xKXq...", "Atlas");
|
|
57
|
+
* // Use in system prompt:
|
|
58
|
+
* // `You are Atlas, an AI agent. ${appearance}`
|
|
59
|
+
* ```
|
|
60
|
+
*/
|
|
61
|
+
declare function agentAppearancePrompt(walletAddress: string, agentName?: string): string;
|
|
62
|
+
|
|
63
|
+
interface PNGOptions extends RenderOptions {
|
|
64
|
+
/** Output pixel size (both width and height). Default: 256 */
|
|
65
|
+
pngSize?: number;
|
|
66
|
+
/** PNG quality (0-1, only affects some renderers). Default: 1 */
|
|
67
|
+
quality?: number;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Render a SolFace as a PNG Buffer using `sharp`.
|
|
71
|
+
* Requires: `npm install sharp`
|
|
72
|
+
*
|
|
73
|
+
* @returns PNG buffer
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* ```ts
|
|
77
|
+
* import { renderSolFacePNG } from "solfaces/core/rasterize";
|
|
78
|
+
*
|
|
79
|
+
* const png = await renderSolFacePNG("7xKXq...", { pngSize: 256 });
|
|
80
|
+
* fs.writeFileSync("avatar.png", png);
|
|
81
|
+
* ```
|
|
82
|
+
*/
|
|
83
|
+
declare function renderSolFacePNG(walletAddress: string, options?: PNGOptions): Promise<Buffer>;
|
|
84
|
+
/**
|
|
85
|
+
* Render a SolFace as a PNG Blob in the browser.
|
|
86
|
+
* Uses Canvas API — works in all modern browsers.
|
|
87
|
+
*
|
|
88
|
+
* @returns PNG Blob
|
|
89
|
+
*
|
|
90
|
+
* @example
|
|
91
|
+
* ```ts
|
|
92
|
+
* const blob = await renderSolFacePNGBrowser("7xKXq...", { pngSize: 256 });
|
|
93
|
+
* const url = URL.createObjectURL(blob);
|
|
94
|
+
* img.src = url;
|
|
95
|
+
* ```
|
|
96
|
+
*/
|
|
97
|
+
declare function renderSolFacePNGBrowser(walletAddress: string, options?: PNGOptions): Promise<Blob>;
|
|
98
|
+
/**
|
|
99
|
+
* Render a SolFace as a PNG data URL in the browser.
|
|
100
|
+
* Convenient for directly setting img.src without blob URLs.
|
|
101
|
+
*/
|
|
102
|
+
declare function renderSolFacePNGDataURL(walletAddress: string, options?: PNGOptions): Promise<string>;
|
|
103
|
+
|
|
104
|
+
export { type DescribeOptions, type PNGOptions, RenderOptions, SolFaceTraits, agentAppearancePrompt, describeAppearance, describeTraits, renderSolFaceBase64, renderSolFaceDataURI, renderSolFacePNG, renderSolFacePNGBrowser, renderSolFacePNGDataURL, renderSolFaceSVG, solFaceAltText };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { renderSolFacePNG, renderSolFacePNGBrowser, renderSolFacePNGDataURL } from '../chunk-SNJABBAT.js';
|
|
2
|
+
export { agentAppearancePrompt, describeAppearance, describeTraits, renderSolFaceBase64, renderSolFaceDataURI, renderSolFaceSVG, solFaceAltText } from '../chunk-KSGFMW33.js';
|
|
3
|
+
export { BG_COLORS, EYE_COLORS, HAIR_COLORS, SKIN_COLORS, generateTraits, getTraitLabels, resolveTheme, traitHash } from '../chunk-WURY4QGH.js';
|
|
4
|
+
//# sourceMappingURL=index.js.map
|
|
5
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"index.js"}
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkA6N3RPEA_cjs = require('./chunk-A6N3RPEA.cjs');
|
|
4
|
+
var chunkVMNATBH3_cjs = require('./chunk-VMNATBH3.cjs');
|
|
5
|
+
var chunkH3SK3MNX_cjs = require('./chunk-H3SK3MNX.cjs');
|
|
6
|
+
var chunk2DIKGLXZ_cjs = require('./chunk-2DIKGLXZ.cjs');
|
|
7
|
+
var chunkCVFO7YHY_cjs = require('./chunk-CVFO7YHY.cjs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
Object.defineProperty(exports, "renderSolFacePNG", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunkA6N3RPEA_cjs.renderSolFacePNG; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "renderSolFacePNGBrowser", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return chunkA6N3RPEA_cjs.renderSolFacePNGBrowser; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "renderSolFacePNGDataURL", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return chunkA6N3RPEA_cjs.renderSolFacePNGDataURL; }
|
|
22
|
+
});
|
|
23
|
+
Object.defineProperty(exports, "SOLFACE_TOOLS", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
get: function () { return chunkVMNATBH3_cjs.SOLFACE_TOOLS; }
|
|
26
|
+
});
|
|
27
|
+
Object.defineProperty(exports, "handleToolCall", {
|
|
28
|
+
enumerable: true,
|
|
29
|
+
get: function () { return chunkVMNATBH3_cjs.handleToolCall; }
|
|
30
|
+
});
|
|
31
|
+
Object.defineProperty(exports, "agentAppearancePrompt", {
|
|
32
|
+
enumerable: true,
|
|
33
|
+
get: function () { return chunkH3SK3MNX_cjs.agentAppearancePrompt; }
|
|
34
|
+
});
|
|
35
|
+
Object.defineProperty(exports, "describeAppearance", {
|
|
36
|
+
enumerable: true,
|
|
37
|
+
get: function () { return chunkH3SK3MNX_cjs.describeAppearance; }
|
|
38
|
+
});
|
|
39
|
+
Object.defineProperty(exports, "describeTraits", {
|
|
40
|
+
enumerable: true,
|
|
41
|
+
get: function () { return chunkH3SK3MNX_cjs.describeTraits; }
|
|
42
|
+
});
|
|
43
|
+
Object.defineProperty(exports, "renderSolFaceBase64", {
|
|
44
|
+
enumerable: true,
|
|
45
|
+
get: function () { return chunkH3SK3MNX_cjs.renderSolFaceBase64; }
|
|
46
|
+
});
|
|
47
|
+
Object.defineProperty(exports, "renderSolFaceDataURI", {
|
|
48
|
+
enumerable: true,
|
|
49
|
+
get: function () { return chunkH3SK3MNX_cjs.renderSolFaceDataURI; }
|
|
50
|
+
});
|
|
51
|
+
Object.defineProperty(exports, "renderSolFaceSVG", {
|
|
52
|
+
enumerable: true,
|
|
53
|
+
get: function () { return chunkH3SK3MNX_cjs.renderSolFaceSVG; }
|
|
54
|
+
});
|
|
55
|
+
Object.defineProperty(exports, "solFaceAltText", {
|
|
56
|
+
enumerable: true,
|
|
57
|
+
get: function () { return chunkH3SK3MNX_cjs.solFaceAltText; }
|
|
58
|
+
});
|
|
59
|
+
Object.defineProperty(exports, "BG_COLORS", {
|
|
60
|
+
enumerable: true,
|
|
61
|
+
get: function () { return chunk2DIKGLXZ_cjs.BG_COLORS; }
|
|
62
|
+
});
|
|
63
|
+
Object.defineProperty(exports, "EYE_COLORS", {
|
|
64
|
+
enumerable: true,
|
|
65
|
+
get: function () { return chunk2DIKGLXZ_cjs.EYE_COLORS; }
|
|
66
|
+
});
|
|
67
|
+
Object.defineProperty(exports, "HAIR_COLORS", {
|
|
68
|
+
enumerable: true,
|
|
69
|
+
get: function () { return chunk2DIKGLXZ_cjs.HAIR_COLORS; }
|
|
70
|
+
});
|
|
71
|
+
Object.defineProperty(exports, "SKIN_COLORS", {
|
|
72
|
+
enumerable: true,
|
|
73
|
+
get: function () { return chunk2DIKGLXZ_cjs.SKIN_COLORS; }
|
|
74
|
+
});
|
|
75
|
+
Object.defineProperty(exports, "generateTraits", {
|
|
76
|
+
enumerable: true,
|
|
77
|
+
get: function () { return chunk2DIKGLXZ_cjs.generateTraits; }
|
|
78
|
+
});
|
|
79
|
+
Object.defineProperty(exports, "getTraitLabels", {
|
|
80
|
+
enumerable: true,
|
|
81
|
+
get: function () { return chunk2DIKGLXZ_cjs.getTraitLabels; }
|
|
82
|
+
});
|
|
83
|
+
Object.defineProperty(exports, "resolveTheme", {
|
|
84
|
+
enumerable: true,
|
|
85
|
+
get: function () { return chunk2DIKGLXZ_cjs.resolveTheme; }
|
|
86
|
+
});
|
|
87
|
+
Object.defineProperty(exports, "traitHash", {
|
|
88
|
+
enumerable: true,
|
|
89
|
+
get: function () { return chunk2DIKGLXZ_cjs.traitHash; }
|
|
90
|
+
});
|
|
91
|
+
Object.defineProperty(exports, "PRESET_THEMES", {
|
|
92
|
+
enumerable: true,
|
|
93
|
+
get: function () { return chunkCVFO7YHY_cjs.PRESET_THEMES; }
|
|
94
|
+
});
|
|
95
|
+
Object.defineProperty(exports, "getPresetTheme", {
|
|
96
|
+
enumerable: true,
|
|
97
|
+
get: function () { return chunkCVFO7YHY_cjs.getPresetTheme; }
|
|
98
|
+
});
|
|
99
|
+
//# sourceMappingURL=index.cjs.map
|
|
100
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"index.cjs"}
|
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { B as BG_COLORS, E as EYE_COLORS, H as HAIR_COLORS, R as RenderOptions, S as SKIN_COLORS, a as SolFaceTheme, b as SolFaceTraits, g as generateTraits, c as getTraitLabels, r as resolveTheme, t as traitHash } from './traits-DAFZnXeS.cjs';
|
|
2
|
+
export { DescribeOptions, PNGOptions, agentAppearancePrompt, describeAppearance, describeTraits, renderSolFaceBase64, renderSolFaceDataURI, renderSolFacePNG, renderSolFacePNGBrowser, renderSolFacePNGDataURL, renderSolFaceSVG, solFaceAltText } from './core/index.cjs';
|
|
3
|
+
export { PRESET_THEMES, getPresetTheme } from './themes/index.cjs';
|
|
4
|
+
export { SOLFACE_TOOLS, SolFaceTool, handleToolCall } from './agent/index.cjs';
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { B as BG_COLORS, E as EYE_COLORS, H as HAIR_COLORS, R as RenderOptions, S as SKIN_COLORS, a as SolFaceTheme, b as SolFaceTraits, g as generateTraits, c as getTraitLabels, r as resolveTheme, t as traitHash } from './traits-DAFZnXeS.js';
|
|
2
|
+
export { DescribeOptions, PNGOptions, agentAppearancePrompt, describeAppearance, describeTraits, renderSolFaceBase64, renderSolFaceDataURI, renderSolFacePNG, renderSolFacePNGBrowser, renderSolFacePNGDataURL, renderSolFaceSVG, solFaceAltText } from './core/index.js';
|
|
3
|
+
export { PRESET_THEMES, getPresetTheme } from './themes/index.js';
|
|
4
|
+
export { SOLFACE_TOOLS, SolFaceTool, handleToolCall } from './agent/index.js';
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { renderSolFacePNG, renderSolFacePNGBrowser, renderSolFacePNGDataURL } from './chunk-SNJABBAT.js';
|
|
2
|
+
export { SOLFACE_TOOLS, handleToolCall } from './chunk-RX6D5FGH.js';
|
|
3
|
+
export { agentAppearancePrompt, describeAppearance, describeTraits, renderSolFaceBase64, renderSolFaceDataURI, renderSolFaceSVG, solFaceAltText } from './chunk-KSGFMW33.js';
|
|
4
|
+
export { BG_COLORS, EYE_COLORS, HAIR_COLORS, SKIN_COLORS, generateTraits, getTraitLabels, resolveTheme, traitHash } from './chunk-WURY4QGH.js';
|
|
5
|
+
export { PRESET_THEMES, getPresetTheme } from './chunk-LQWJRHGC.js';
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
7
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"index.js"}
|