Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

feat(cos): add Esoteric 3D avatar style with mystical octahedron core

Adam Eivy5575db8ea038
diff --git a/.changelog/v0.10.x.md b/.changelog/v0.10.x.md
index 6afad259c9..3720b4c184 100644
--- a/.changelog/v0.10.x.md
+++ b/.changelog/v0.10.x.md
@@ -30,6 +30,11 @@ This release introduces a structured changelog documentation system for creating
- **New Avatar Style**: Added an additional Three.js avatar option, "Arcane Sigil (3D)", alongside the existing Cyberpunk 3D style
- **State-Reactive Animation**: Sigil intensity, rune ring motion, and scan effects respond to agent state (sleeping/thinking/coding/investigating) and speaking activity
+### Chief of Staff - Esoteric (3D) Avatar
+- **New Avatar Style**: Added "Esoteric (3D)" avatar option featuring a mystical octahedron core with distortion effects, orbiting runic shards, ancient halo rings, and floating sparkle particles
+- **State-Reactive Visuals**: Core wireframes in investigation mode, increased distortion during thinking, shard orbit speed increases during coding/thinking states
+- **Speaking Animation**: Core pulses rapidly when the agent is speaking
+
### Dashboard - Activity Streak
- **Current Streak Display**: Shows consecutive days of activity with dynamic emoji (fire for 7+ days, lightning for 3+, sparkles for less)
- **Longest Streak Tracking**: Displays your personal best streak alongside current streak
diff --git a/client/src/components/cos/EsotericCoSAvatar.jsx b/client/src/components/cos/EsotericCoSAvatar.jsx
new file mode 100644
index 0000000000..3c08925371
--- /dev/null
+++ b/client/src/components/cos/EsotericCoSAvatar.jsx
@@ -0,0 +1,217 @@
+import { useRef, useMemo } from 'react';
+import { Canvas, useFrame } from '@react-three/fiber';
+import { Float, MeshDistortMaterial, Sparkles, Stars, Trail } from '@react-three/drei';
+import * as THREE from 'three';
+import { AGENT_STATES } from './constants';
+
+// Central mystical core - an artifact of unknown origin
+function EsotericCore({ color, state, speaking }) {
+ const meshRef = useRef();
+ const glowRef = useRef();
+
+ useFrame(({ clock }) => {
+ const t = clock.getElapsedTime();
+
+ // Core rotation and pulse
+ if (meshRef.current) {
+ meshRef.current.rotation.x = Math.sin(t * 0.2) * 0.5;
+ meshRef.current.rotation.y += 0.01;
+
+ // React to speaking
+ const speakPulse = speaking ? Math.sin(t * 20) * 0.2 : 0;
+ meshRef.current.scale.setScalar(1 + Math.sin(t * 1.5) * 0.05 + speakPulse);
+ }
+
+ if (glowRef.current) {
+ glowRef.current.scale.setScalar(1.2 + Math.sin(t * 2) * 0.1);
+ glowRef.current.material.opacity = 0.2 + Math.sin(t * 3) * 0.1;
+ }
+ });
+
+ return (
+ <group>
+ <Float speed={2} rotationIntensity={0.5} floatIntensity={0.5}>
+ {/* Inner Core */}
+ <mesh ref={meshRef}>
+ <octahedronGeometry args={[0.8, 0]} />
+ <MeshDistortMaterial
+ color={color}
+ emissive={color}
+ emissiveIntensity={state === 'thinking' ? 2 : 0.5}
+ roughness={0.1}
+ metalness={1}
+ distort={0.4}
+ speed={2}
+ wireframe={state === 'investigating'}
+ />
+ </mesh>
+
+ {/* Outer Glow Shell */}
+ <mesh ref={glowRef}>
+ <icosahedronGeometry args={[0.9, 2]} />
+ <meshBasicMaterial
+ color={color}
+ transparent
+ opacity={0.1}
+ wireframe
+ side={THREE.DoubleSide}
+ />
+ </mesh>
+ </Float>
+ </group>
+ );
+}
+
+// Orbiting runic shards
+function RunicShards({ color, state }) {
+ const groupRef = useRef();
+ const shards = useMemo(() => {
+ return Array.from({ length: 5 }).map((_, i) => ({
+ rotationSpeed: (Math.random() - 0.5) * 2,
+ orbitSpeed: 0.5 + Math.random() * 0.5,
+ orbitRadius: 1.5 + Math.random() * 0.5,
+ phase: Math.random() * Math.PI * 2,
+ scale: 0.2 + Math.random() * 0.3
+ }));
+ }, []);
+
+ useFrame(({ clock }) => {
+ const t = clock.getElapsedTime();
+ if (groupRef.current) {
+ groupRef.current.children.forEach((child, i) => {
+ const shard = shards[i];
+ const angle = t * shard.orbitSpeed + shard.phase;
+
+ // Orbital motion
+ child.position.x = Math.cos(angle) * shard.orbitRadius;
+ child.position.z = Math.sin(angle) * shard.orbitRadius;
+ child.position.y = Math.sin(t * 0.5 + shard.phase) * 0.5;
+
+ // Self rotation
+ child.rotation.x += shard.rotationSpeed * 0.02;
+ child.rotation.y += shard.rotationSpeed * 0.03;
+ });
+
+ // Speed up for active states
+ const speedMult = state === 'coding' || state === 'thinking' ? 2 : 1;
+ groupRef.current.rotation.y = t * 0.1 * speedMult;
+ }
+ });
+
+ return (
+ <group ref={groupRef}>
+ {shards.map((shard, i) => (
+ <mesh key={i}>
+ <coneGeometry args={[shard.scale, shard.scale * 2, 4]} />
+ <meshStandardMaterial
+ color={color}
+ emissive={color}
+ emissiveIntensity={1}
+ transparent
+ opacity={0.8}
+ roughness={0.2}
+ metalness={0.8}
+ />
+ </mesh>
+ ))}
+ </group>
+ );
+}
+
+// Ancient halo rings
+function AncientHalo({ color, state }) {
+ const ringRef = useRef();
+ const ring2Ref = useRef();
+
+ useFrame(({ clock }) => {
+ const t = clock.getElapsedTime();
+ if (ringRef.current) {
+ ringRef.current.rotation.z = t * 0.2;
+ ringRef.current.rotation.x = Math.PI / 2 + Math.sin(t * 0.5) * 0.2;
+ }
+ if (ring2Ref.current) {
+ ring2Ref.current.rotation.z = -t * 0.15;
+ ring2Ref.current.rotation.y = Math.PI / 3 + Math.sin(t * 0.3) * 0.1;
+ }
+ });
+
+ return (
+ <group>
+ <mesh ref={ringRef}>
+ <torusGeometry args={[1.8, 0.02, 16, 100]} />
+ <meshStandardMaterial
+ color={color}
+ emissive={color}
+ emissiveIntensity={0.5}
+ transparent
+ opacity={0.4}
+ />
+ </mesh>
+ <mesh ref={ring2Ref}>
+ <torusGeometry args={[2.2, 0.01, 16, 100]} />
+ <meshStandardMaterial
+ color={color}
+ emissive={color}
+ emissiveIntensity={0.3}
+ transparent
+ opacity={0.2}
+ />
+ </mesh>
+ </group>
+ )
+}
+
+function FloatingRunes({ color }) {
+ // Generate random positions for "runes" (small geometries)
+ const count = 15;
+ const positions = useMemo(() => {
+ return new Float32Array(count * 3).map(() => (Math.random() - 0.5) * 5);
+ }, []);
+
+ return (
+ <Sparkles
+ count={30}
+ scale={4}
+ size={4}
+ speed={0.4}
+ opacity={0.5}
+ color={color}
+ />
+ )
+}
+
+
+function Scene({ state, speaking }) {
+ const stateConfig = AGENT_STATES[state] || AGENT_STATES.sleeping;
+ const color = stateConfig.color;
+
+ return (
+ <>
+ <ambientLight intensity={0.2} />
+ <pointLight position={[10, 10, 10]} intensity={1} color={color} />
+ <pointLight position={[-10, -10, -10]} intensity={0.5} color="#4c1d95" />
+
+ <EsotericCore color={color} state={state} speaking={speaking} />
+ <RunicShards color={color} state={state} />
+ <AncientHalo color={color} state={state} />
+ <FloatingRunes color={color} />
+
+ {/* Background stars for depth */}
+ <Stars radius={100} depth={50} count={1000} factor={4} saturation={0} fade speed={1} />
+ </>
+ );
+}
+
+export default function EsotericCoSAvatar({ state, speaking }) {
+ return (
+ <div className="relative w-28 h-36 sm:w-36 sm:h-44 md:w-44 md:h-56 lg:w-56 lg:h-72">
+ <Canvas
+ camera={{ position: [0, 0, 5], fov: 45 }}
+ style={{ background: 'transparent' }}
+ gl={{ alpha: true, antialias: true }}
+ >
+ <Scene state={state} speaking={speaking} />
+ </Canvas>
+ </div>
+ );
+}
diff --git a/client/src/components/cos/index.js b/client/src/components/cos/index.js
index 49c6984477..823fd9d24b 100644
--- a/client/src/components/cos/index.js
+++ b/client/src/components/cos/index.js
@@ -8,6 +8,7 @@ export { default as useNextEvalCountdown } from './useNextEvalCountdown';
export { default as CoSCharacter } from './CoSCharacter';
export { default as CyberCoSAvatar } from './CyberCoSAvatar';
export { default as SigilCoSAvatar } from './SigilCoSAvatar';
+export { default as EsotericCoSAvatar } from './EsotericCoSAvatar';
export { default as StateLabel } from './StateLabel';
export { default as TerminalCoSPanel } from './TerminalCoSPanel';
diff --git a/client/src/components/cos/tabs/ConfigTab.jsx b/client/src/components/cos/tabs/ConfigTab.jsx
index ecb4b6a000..65a89da5c5 100644
--- a/client/src/components/cos/tabs/ConfigTab.jsx
+++ b/client/src/components/cos/tabs/ConfigTab.jsx
@@ -324,7 +324,7 @@ export default function ConfigTab({ config, onUpdate, onEvaluate, avatarStyle, s
onChange={async (e) => {
const style = e.target.value;
await setAvatarStyle(style);
- const labels = { svg: 'Digital', ascii: 'Minimalist', cyber: 'Cyberpunk 3D', sigil: 'Arcane Sigil 3D' };
+ const labels = { svg: 'Digital', ascii: 'Minimalist', cyber: 'Cyberpunk 3D', sigil: 'Arcane Sigil 3D', esoteric: 'Esoteric (3D)' };
toast.success(`Avatar style changed to ${labels[style] || style}`);
}}
className="bg-port-bg border border-port-border rounded px-3 py-1.5 text-white text-sm"
@@ -332,6 +332,7 @@ export default function ConfigTab({ config, onUpdate, onEvaluate, avatarStyle, s
<option value="svg">Digital (SVG)</option>
<option value="cyber">Cyberpunk (3D)</option>
<option value="sigil">Arcane Sigil (3D)</option>
+ <option value="esoteric">Esoteric (3D)</option>
<option value="ascii">Minimalist (ASCII)</option>
</select>
</div>
diff --git a/client/src/pages/ChiefOfStaff.jsx b/client/src/pages/ChiefOfStaff.jsx
index 063edb9c96..4088f29ee9 100644
--- a/client/src/pages/ChiefOfStaff.jsx
+++ b/client/src/pages/ChiefOfStaff.jsx
@@ -13,6 +13,7 @@ import {
CoSCharacter,
CyberCoSAvatar,
SigilCoSAvatar,
+ EsotericCoSAvatar,
StateLabel,
TerminalCoSPanel,
StatusIndicator,
@@ -391,6 +392,8 @@ export default function ChiefOfStaff() {
? <CyberCoSAvatar state={agentState} speaking={speaking} />
: avatarStyle === 'sigil'
? <SigilCoSAvatar state={agentState} speaking={speaking} />
+ : avatarStyle === 'esoteric'
+ ? <EsotericCoSAvatar state={agentState} speaking={speaking} />
: <CoSCharacter state={agentState} speaking={speaking} />
}
<StateLabel state={agentState} />