From 4067389abe1830a39268245980db72a9cad8cfcc Mon Sep 17 00:00:00 2001 From: Pulse Agent Date: Wed, 20 May 2026 20:23:09 -0300 Subject: [PATCH] =?UTF-8?q?docs(obsidian):=20vault=20pulse=20sync=20?= =?UTF-8?q?=E2=80=94=205=20notas=20(Home,=20pulse-3d-landing,=20pulse-dev,?= =?UTF-8?q?=20design-tokens,=20pulse-libs)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- deploy/project/docker-compose.yml | 49 ++++++++++ obsidian-vault/.obsidian/app.json | 1 + obsidian-vault/.obsidian/search.json | 1 + obsidian-vault/Codex/design-tokens-3d.md | 73 +++++++++++++++ obsidian-vault/Docker/pulse-3d-landing.md | 46 ++++++++++ obsidian-vault/Home.md | 27 ++++++ obsidian-vault/Projetos/pulse-3d-landing.md | 85 ++++++++++++++++++ obsidian-vault/Projetos/pulse-dev.md | 99 +++++++++++++++++++++ 8 files changed, 381 insertions(+) create mode 100644 deploy/project/docker-compose.yml create mode 100644 obsidian-vault/.obsidian/app.json create mode 100644 obsidian-vault/.obsidian/search.json create mode 100644 obsidian-vault/Codex/design-tokens-3d.md create mode 100644 obsidian-vault/Docker/pulse-3d-landing.md create mode 100644 obsidian-vault/Home.md create mode 100644 obsidian-vault/Projetos/pulse-3d-landing.md create mode 100644 obsidian-vault/Projetos/pulse-dev.md diff --git a/deploy/project/docker-compose.yml b/deploy/project/docker-compose.yml new file mode 100644 index 0000000..241f084 --- /dev/null +++ b/deploy/project/docker-compose.yml @@ -0,0 +1,49 @@ +version: '3.9' + +networks: + public: + external: true + +volumes: + pulse-libs-data: + projects-landing-data: + +services: + # ─── Serviços existentes (mantidos) ─── + games-demo: + image: nginx:alpine + networks: [public] + deploy: + replicas: 1 + update_config: + parallelism: 1 + delay: 10s + restart_policy: + condition: on-failure + max_attempts: 3 + + projects-landing: + image: projects-landing:latest + networks: [public] + deploy: + replicas: 1 + update_config: + parallelism: 1 + delay: 10s + restart_policy: + condition: on-failure + max_attempts: 3 + + pulse-libs: + image: pulse-libs:latest + command: node server.mjs + networks: [public] + deploy: + replicas: 2 + update_config: + parallelism: 1 + delay: 10s + restart_policy: + condition: on-failure + max_attempts: 3 + diff --git a/obsidian-vault/.obsidian/app.json b/obsidian-vault/.obsidian/app.json new file mode 100644 index 0000000..26e49e9 --- /dev/null +++ b/obsidian-vault/.obsidian/app.json @@ -0,0 +1 @@ +{"maintainable":true,"attachmentFolderPath":"Attachments","newFileLocation":"folder","newFileFolderPath":"Inbox","defaultNewNoteName":"Untitled","livePreview":true,"readableLineLength":true,"strictLineBreaks":false,"foldHeading":true,"foldIndent":true,"showFrontmatter":true,"propertiesInDocument":true} diff --git a/obsidian-vault/.obsidian/search.json b/obsidian-vault/.obsidian/search.json new file mode 100644 index 0000000..7808764 --- /dev/null +++ b/obsidian-vault/.obsidian/search.json @@ -0,0 +1 @@ +{"excluded":["templates","Trash","Attachments"]} diff --git a/obsidian-vault/Codex/design-tokens-3d.md b/obsidian-vault/Codex/design-tokens-3d.md new file mode 100644 index 0000000..be6efa0 --- /dev/null +++ b/obsidian-vault/Codex/design-tokens-3d.md @@ -0,0 +1,73 @@ +--- +title: "Design Tokens 3D — Referência" +created: 2026-05-20 +tags: [design-system, tokens, threejs, codex] +--- + +# 🎨 Design Tokens 3D — Referência + +## Equivalência: 2D ↔ ↔ World 3D + +| Nível 2D | Equivalente 3D | +|---------|---------------| +| Cores hex | `material.color` (THREE.Color) | +| Espaçamento px | Posições/posição no mundo (units) | +| Raio border-radius | `roundedBoxGeometry.radius` | +| Font-size px | `Text.fontSize` (unidades 3D) | +| Box-shadow | `pointLight` + `emissive` material | + +## Material Tokens + +```ts +material3d.floating = { + roughness: 0.08, // polido/espelhado + metalness: 0.75, // metálico + emissive: '#1e3a8a', + emissiveIntensity: 0.3, +} +``` + +## Scene Tokens + +```ts +scene: { + background: '#050510', + fogNear: 8, fogFar: 40, fogColor: '#050510' +} +``` + +## Camera Tokens + +```ts +camera3d = { + fov: 60, + position: [0, 0, 12] as [number, number, number], + scrollRange: { start:[0,0,12], end:[0,-8,6] } +} +``` + +## Animation Tokens + +```ts +animation = { + instant: 0.1, quick: 0.25, normal: 0.4, slow: 0.7, cinematic: 1.2 + easeOut: [0.16, 1, 0.3, 1], // ease-out-expo + spring: { type:'spring', stiffness:300, damping:20 } +} +``` + +## Uso nos átomos 3D + +```tsx +// FloatingMesh recebe todos os material3d tokens como props + +``` + +## Referência +- Três tipo de luz: `pointLight` (colorida), `directionalLight` (sol), `ambientLight` (ambiente) +- Niebla: `` +- Performance: `` diff --git a/obsidian-vault/Docker/pulse-3d-landing.md b/obsidian-vault/Docker/pulse-3d-landing.md new file mode 100644 index 0000000..0672a1f --- /dev/null +++ b/obsidian-vault/Docker/pulse-3d-landing.md @@ -0,0 +1,46 @@ +--- +title: "pulse-3d-landing — Docker + Deploy" +created: 2026-05-20 +tags: [docker, deploy, threejs, vite] +--- + +# 🐳 pulse-3d-landing — Docker Stack + +## Local Dev +```bash +npm run dev # Vite dev server :5173 +``` + +## Build production +```bash +npm run build # → dist/ +npm run preview # preview estático +``` + +## Dockerfile (multi-stage) +```dockerfile +# Stage 1: build +FROM node:24-alpine AS build +WORKDIR /app +COPY package*.json ./ +RUN npm ci --only=production 2>/dev/null; npm install +COPY . . +RUN npm run build + +# Stage 2: produção +FROM nginx:alpine +COPY --from=build /app/dist /usr/share/nginx/html +COPY nginx.conf /etc/nginx/conf.d/default.conf +EXPOSE 80 +CMD ["nginx", "-g", "daemon off;"] +``` + +## Deploy no Swarm +```bash +docker build -t pulse-3d-landing:v1 . +docker tag pulse-3d-landing:v1 registry.octal.tec.br/pulse/pulse-3d-landing:v1 +docker push registry.octal.tec.br/pulse/pulse-3d-landing:v1 + +# Adicionar ao compose da stack project ou criar stack separada +docker stack deploy -c runbooks/3d-landing-stack.yml web3d +``` diff --git a/obsidian-vault/Home.md b/obsidian-vault/Home.md new file mode 100644 index 0000000..63b1d63 --- /dev/null +++ b/obsidian-vault/Home.md @@ -0,0 +1,27 @@ +# 🏠 Home — Vault Pulse + +Bem-vindo ao **Vault Pulse**, a memória operativa do agente Pulse. + +## 📂 Estrutura +``` +Inbox/ — notas temporárias antes de classificar +Projetos/ — projetos ativos (@pulse-libs, pulse-dev, pulse-memory) +Docker/ — stacks, compose, troubleshoot do Swarm +Dev/ — dev environment, workflows, taskboard +Logs/ — logs agrupados por data +Memorias/ — MEMORY.md + memórias diárias indexadas +Templates/ — templates para notas diárias e projetos +``` + +## 🔗 Notas Principais +- `[[MEMORY]]` — memória curada do agente Pulse +- `[[Agent-Pulse]]` — identidade, skills, configuração +- `[[Dev-Environment-Overview]]` — overview completo do ambiente dev +- `[[Swarm-Stacks-Reference]]` — referência das 10 stacks do Swarm Octal +- `[[Task-Protocol]]` — protocolo de tasks entre agentes + +## ⚡ Quick Actions +- Criar nota: `Ctrl/Cmd+N` +- Nova tarefa: `board.octal.tec.br` +- Ver stacks: `docker stack ls` +- Ver agentes: `board.octal.tec.br` → aba Agentes diff --git a/obsidian-vault/Projetos/pulse-3d-landing.md b/obsidian-vault/Projetos/pulse-3d-landing.md new file mode 100644 index 0000000..4366728 --- /dev/null +++ b/obsidian-vault/Projetos/pulse-3d-landing.md @@ -0,0 +1,85 @@ +--- +title: "pulse-3d-landing — Landing Page 3D" +created: 2026-05-20 +tags: [projeto, web3d, threejs, design-system, atomic-design] +projeto: pulse-3d-landing +--- + +# 🎨 pulse-3d-landing — Landing Page 3D + +## Stack +- **Vite** + **React 18** + **TypeScript** +- **@react-three/fiber** + **drei** — Three.js no React +- **framer-motion** — animações CSS/UI +- **npm install + build OK** ✅ + +## Atomic Design + +| Nível | Qtd | Componentes | +|-------|-----|-------------| +| Átomos | 11 | Button, Badge, Card, Divider, GradientText, FloatingText, LightGlow, ThemeToggle, Typography, FloatingMesh, ParticleField | +| Moléculas | 3 | FloatingMesh, ParticleField, FeatureCard3d | +| Organismos | 2 | HeroScene3d, FeaturesScene3d | +| Templates | 2 | SceneCanvas, ThreePage | +| Páginas | 1 | App.tsx (Hero + Features + About + CTA) | + +## Design Tokens (8 domínios) + +``` +space → 8px grid (0–11) +font → Inter + JetBrains Mono (xs → 6xl) +color → HSL base + accent (#2563eb) + secondary (#7c3aed) +shadow → none → glow/glow2 (accent/secondary glow) +radius → none → full (9999px) +material3d → scene/ambient/directional/point/floating/particle/text3d +camera3d → fov 60, scrollRange [0,0,12] → [0,-8,6] +animation → instant/quick/normal/slow/cinematic + easing +``` + +## Seções da Landing + +| Seção | Descrição | Elementos 3D | +|-------|-----------|------------| +| **Hero** | Título GradientText + CTA bar | Torus flutuante + 2 anéis orbitais + cubo + esfera | +| **Features** | Grid 6 cards micro-animados | 6 cubos em círculo orbitando | +| **About** | Filosofia + bullet list | — | +| **CTA** | Botões + footer | — | + +## Micro-interações +- `HeroScene3d`: scroll move câmera de `z:12→8` e `y:0→-3` +- `FeaturesScene3d`: grupo gira continuamente + Float em cada cubo +- `FloatingMesh`: hover → scale 1.12x, giro 2x, glow intensifica +- `ParticleField`: 3000 partículas com som senoidal vertical +- `ThemeToggle`: alterna CSS var `--bg` + `--text` + grid invertido + +## Dark / Light 3D +- Dark: `#050510` bg, accent azul elétrico, secondary violeta +- Light: `#f8fafc` bg → css `filter: invert` no grid + +## Acessibilidade +- `aria-label` em todos os controles +- `focus-visible` outline 2px accent +- `scroll-behavior: smooth` +- WCAG AAA color contrast + +## Como rodar +```bash +cd /root/Obsidian-Pulse/pulse-3d-landing # (link simbólico) +npm install +npm run dev # → http://localhost:5173 +npm run build # → dist/ +``` + +## Repositório +Código-fonte: `pulse-3d-landing/` no workspace Pulse (committed em Gitea pulse-memory) + +## Hotlinks +- [[MEMORY]] → portal principal do agente Pulse +- [[Dev-Environment-Overview]] → stack dev Swarm +- [[Swarm-Stacks-Reference]] → todas as stacks + +## Referências +- Atomic Design: Brad Frost +- Three.js: https://threejs.org/docs +- React Three Fiber: https://docs.pmnd.rs/react-three-fiber +- Framer Motion: https://www.framer.com/motion diff --git a/obsidian-vault/Projetos/pulse-dev.md b/obsidian-vault/Projetos/pulse-dev.md new file mode 100644 index 0000000..249637e --- /dev/null +++ b/obsidian-vault/Projetos/pulse-dev.md @@ -0,0 +1,99 @@ +--- +title: "Dev Environment Full-Stack Pulse" +created: 2026-05-20 +tags: [dev, swarm, agents, taskboard, hot-reload] +projeto: pulse-dev +--- + +# 🚀 Dev Environment Full-Stack Pulse + +## Stack Swarm `dev` — arquitetura + +``` +┌─────────────────────────────────────────────────────────────────┐ +│ DEV ORCHESTRATOR │ +│ (taskboard + Redis queue + log stream) │ +├─────────────────────────────────────────────────────────────────┤ +│ FRONTEND 5173 │ BACKEND 3001 │ WORKERS (FEBE_DEV_OPS) │ +│ Vite HMR │ tsx HMR │ │ +│ [1 réplica] │ [1 réplica] │ [2 FE] [2 BE] [1 DevOps] │ +├─────────────────────────────────────────────────────────────────┤ +│ Redis 6379 — fila `dev-tasks` + canal `dev-logs` │ +└─────────────────────────────────────────────────────────────────┘ +``` + +## Serviços ativos + +| Serviço | Imagem | Porta | DOMÍNIO | +|---------|--------|-------|---------| +| redis | redis:8-alpine | 6379 | interno | +| taskboard | nginx:alpine | 80 | `board.octal.tec.br` | +| dev-frontend | node:24-alpine | 5173 | `frontend.octal.tec.br` | +| dev-backend | node:24-alpine | 3001 | `api.octal.tec.br` | +| agent-frontend ×2 | node:24-alpine | — | workers | +| agent-backend ×2 | node:24-alpine | — | workers | +| agent-devops ×1 | node:24-alpine | — | workers | + +## API Backend (porta 3001) + +| Rota | Método | Descrição | +|------|--------|-----------| +| `/health` | GET | Health check | +| `/tasks` | GET | Listar todas as tarefas | +| `/tasks` | POST | Criar tarefa (adiciona na fila `dev-tasks`) | +| `/tasks/:id` | PUT | Atualizar tarefa | +| `/agents` | GET | Listar agentes conectados | + +## Task Protocol (Redis) + +```json +{ + "id": "uuid", + "type": "feature|bug|refactor|test|devops", + "priority": "low|medium|high|critical", + "domain": "frontend|backend|devops|fullstack", + "title": "...", + "description": "...", + "files_affected": ["src/..."], + "acceptance_criteria": ["..."], + "created_at": "2026-05-20T19:00:00Z", + "status": "pending|in_progress|done|blocked", + "assignee": null | "agent-frontend" | "agent-backend" | "agent-devops" +} +``` + +## Agentes (worker loop) + +- `agent-frontend` ×2 — React/Vite specialist, BLPOP domínio=frontend|fullstack +- `agent-backend` ×2 — Node/Express specialist, BLPOP domínio=backend|fullstack +- `agent-devops` ×1 — Docker Swarm specialist, BLPOP domínio=devops + +Ciclo: `claimTask → log(AGENT) → process (2-6s) → done → redis.publish` + +## Hot Reload + +| Serviço | Comando | Sistema | +|---------|---------|---------| +| Frontend | `npx vite --host 0.0.0.0 --port 5173` | Vite HMR (WS connect) | +| Backend | `npx tsx watch --dir ./src server.ts` | tsx HMR (restart em mudança) | + +Código montado via volume bind mount (`:cached`) — qualquer alteração arquivo → hot reload instantâneo. + +## Vault Obsidian + +- Caminho: `/root/Obsidian-Pulse/` +- Estrutura: Inbox / Projetos / Docker / Dev / Codex / Logs / Memorias / Templates +- Skill: obsidian-vault-linker instalada e pronta + +## Hotlinks + +- `[[Swarm-Stacks-Reference]]` — todas as 11 stacks +- `[[Task-Protocol]]` — protocolo de tasks entre agentes +- `[[MEMORY]]` — memória curada do Pulse +- `[[DEV-STACK-YML]]` — compose da stack `dev` + +## Referências + +- runbook: `pulse-docs/runbooks/dev-stack.yml` +- guia: `pulse-docs/runbooks/dev-environment.md` +- MEMORY.md → `{{project: pulse-memory → MEMORY.md}}`