Commit graph

17 commits

Author SHA1 Message Date
jedarden
3ecc113911 docs(metrics): add Prometheus metrics documentation and completeness tests
- Add docs/metrics.md with comprehensive metrics reference
- Document all 9 exported metrics with types and descriptions
- Include Prometheus configuration examples
- Include Grafana dashboard recommendations
- Include alerting rule examples
- Update README.md to reference metrics documentation
- Add tests verifying all documented metrics are present
- Add tests verifying HELP/TYPE comments for each metric

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Bead-Id: bd-y0t
2026-04-28 13:59:50 -04:00
jedarden
19450d3047 feat(infra): expose FABRIC dashboard over Tailscale with TLS
Configure tailscale serve to proxy https://hetzner-ex44.tail1b1987.ts.net/
to localhost:3000. Tailnet-only — no public internet exposure.

- scripts/setup-tailscale-serve.sh: one-time setup script (idempotent)
- README.md: add Remote Access section with URL, access model, and setup steps
- CLAUDE.md: new project-level reference for service location, URLs, auth model

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-23 22:05:39 -04:00
jedarden
c73fe67e81 feat(bd-ch6.4): add startup warning and token rotation docs
- Warn at startup when FABRIC_AUTH_TOKEN is unset so operators know
  POST /api/events is open to any local process; surfaced before
  "Press Ctrl+C to stop" so it's visible in systemd journal
- Add "Token rotation" section to README with step-by-step procedure:
  generate new secret, update secrets.env (0600), restart service,
  verify 401 enforcement; notes that NEEDLE workers reload on next task
  start when auth_token uses \${FABRIC_AUTH_TOKEN} substitution

The full auth chain is now in place end-to-end:
  ~/.config/fabric/secrets.env (0600) → EnvironmentFile →
  FABRIC_AUTH_TOKEN env var → server auth middleware → 401/403 on
  unauthenticated POST; NEEDLE config auth_token: "\${FABRIC_AUTH_TOKEN}"
  routes worker events through the same token.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-23 21:31:24 -04:00
jedarden
794d5c3034 feat(bd-ch6.2): add fabric prune CLI with archive/delete retention policy
NEEDLE log retention for ~/.needle/logs/. The directory had grown to
103k files / 11GB with no cleanup. Adds:

- fabric prune command: archives old files into dated tar.gz, deletes
  expired archives, with configurable age thresholds
- mend.logs_pruned events emitted to fabric-mend.jsonl for FABRIC tailer
- systemd timer (fabric-prune.timer) for daily automatic pruning
- 9 tests covering archive, delete, dry-run, edge cases

Ran initial prune: 103,857 -> 1,006 files, 8.6 GB freed.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-23 21:04:54 -04:00
jedarden
a0cd3934f5 docs(bd-ch6.3): document production OTLP/HTTP deployment in README
Enable OTLP receivers in fabric-web.service by adding --otlp-http :4318,
configure NEEDLE otlp_metric_sink, and document the deployed config.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-23 20:59:50 -04:00
jedarden
8d1af46705 docs(bd-n8y): add auth token documentation to README and startup script 2026-04-23 16:14:51 -04:00
jedarden
de96f2a776 docs(bd-czg): document config-based NEEDLE→FABRIC wiring and enable fabric telemetry
Enable fabric.enabled in ~/.needle/config.yaml and add README section
explaining HTTP POST /api/events as a simpler local-dev alternative to OTLP.
NEEDLE's FabricConfig already includes endpoint in src/config/mod.rs.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-23 15:46:47 -04:00
jedarden
91d0896797 docs(bd-0nd): update plan.md and README to reflect directory-tailing behavior
Mark all Phase 8 checklist items complete (bd-0nd.1–4 closed).
Clarify README: FABRIC watches the directory and tails every *.jsonl,
not a single workers.log file.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-22 16:37:59 -04:00
jedarden
1f392c39d6 feat(bd-pyz): add --source flag, logs alias, and update CLI examples
Add --source flag to tui/web/tail subcommands for specifying log source
as file or directory (directories get workers.log appended). Add 'logs'
as alias for 'tail' subcommand per plan.md CLI spec. Update README.md
with fabric logs examples and --source usage.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-21 14:59:15 -04:00
jedarden
10146b6415 feat(bd-cj8): adopt NeedleEvent canonical schema + publish docs/schema.md
Add NeedleEvent interface as the canonical internal shape versioned at
schema-version 1. Parser validates wire format and asserts schema version
on incoming events. Legacy LogEvent retained as backward-compatible adapter.
docs/schema.md documents all fields, the (worker_id, sequence) ordering
contract, and the full event taxonomy cross-referenced with NeedleEventType.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-21 11:57:19 -04:00
jedarden
adb3d68366 docs: expand OTEL wiring section with receiver flags and both protocols
Add FABRIC-side receiver setup (--otlp-grpc, --otlp-http) with port
table covering both gRPC (4317) and HTTP (4318) protocols.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-21 10:20:40 -04:00
jedarden
a5eae21f08 docs: add Wiring NEEDLE → FABRIC section to README
Covers the OTEL_EXPORTER_OTLP_ENDPOINT and OTEL_EXPORTER_OTLP_PROTOCOL
env vars, the default-on otlp feature, and the local/read-only nature
of the data flow.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-21 10:18:10 -04:00
jeda
9ab1e3a407 docs: add 8 additional intelligence features (wave 2)
New features added:
- Conversation Transcript View: see full Claude prompts/responses
- Semantic Activity Narrative: natural language status updates
- AI Session Digest: auto-generated session summaries
- File Context Panel: see file contents alongside activity
- Git Integration Panel: live git status and conflict detection
- Worker Comparison Analytics: performance tracking over time
- Recovery Playbook: suggestions from similar past errors
- Focus Mode with Pinning: filter to specific workers/tasks

Updated implementation phases to 7 phases covering all 18 features.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 02:52:55 +00:00
jeda
e7483199b9 docs: update README with intelligence features summary
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 02:44:02 +00:00
jeda
88ee6a4cf5 docs: FABRIC is a live display, not a report generator
- Remove static HTML report generation concept
- TUI and web modes are both live, real-time displays
- Add 'fabric web' command for browser dashboard
- Emphasize tail-style log watching and WebSocket updates
- Simplify README to focus on live display purpose

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 02:28:51 +00:00
jeda
f164e7e253 docs: refocus FABRIC on worker visualization via logging/telemetry
- Shift focus from bead tracking to NEEDLE worker visibility
- Emphasize TUI and HTML output formats as primary deliverables
- Add CLI interface examples (fabric tui, fabric html, fabric logs)
- Define worker event data model and log format contract
- Update README to reflect worker-centric purpose

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-02 01:52:04 +00:00
jeda
727661e0f0 feat: initialize FABRIC (Flow Analysis & Bead Reporting Interface Console)
Add initial README and implementation plan for visualization/dashboard
system to monitor NEEDLE's bead orchestration output.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-03-02 00:58:09 +00:00