Sunstead · Discover for Tangled#
Discover points you to the repos and issues where your skills can actually help — based on the kinds of work you've already done.
Built for a hackathon, with Tangled as a challenge partner. This repo is a fork of the Tangled codebase with the Discover feature added to its web frontend — see Built on Tangled.
What it does#
- A
/discoverfeed — three scrollable rows of recommendations: Repos for you, Issues you could tackle, and Good first issues. - View-all pages — every row caps at 15 cards with a Load more tile that reveals
the rest of the row inline; see all → opens a full
/discover/{category}grid. - Sources — a
…settings menu manages your sources (Tangled + an optional GitHub username) and shows how many repos were scanned on each. - Graceful cold start — an empty or unreachable engine falls back to a trending view rather than a blank page.
How it's built#
The recommendation / account-scan engine is a separate, externally-hosted service
(built by the rest of the team). This repo is the frontend — server-rendered Go
html/template + htmx + Tailwind, living inside Tangled's appview.
The HTTPS integration is wired and ready:
- Integration:
appview/state/discover_engine.gofetches and decodes the engine response. Point it at the engine withTANGLED_DISCOVER_ENDPOINT; when unset, the page servesmockDiscoverData()so it's fully demoable offline. - Data contract:
schema.md(and §8 of the design spec).
Where the code lives#
| Concern | Path |
|---|---|
| Handlers, routes, mock data | appview/state/discover.go |
| Engine HTTPS client | appview/state/discover_engine.go |
| View models + render methods | appview/pages/discover.go |
| Templates (page + cards) | appview/pages/templates/discover/ |
| Nav entry | appview/pages/templates/layouts/fragments/topbar.html |
| Engine schema, design spec & plan | schema.md, docs/superpowers/specs/, docs/superpowers/plans/ |
Routes#
| Route | Purpose |
|---|---|
/discover |
the personalized feed (?fresh=1 → cold-start view) |
/discover/{repos,issues,good-first-issues} |
per-category view-all grids |
Running locally#
Requires Nix with flakes enabled. From the repo root:
# 1. enter the dev shell (Go, Tailwind, redis, OAuth env, …)
nix develop
# 2. session store (separate terminal)
redis-server
# 3. the appview — hot-reloads, serves http://localhost:3000
TANGLED_DEV=true nix run .#watch-appview
# optional: live Tailwind rebuilds while editing styles
nix run .#watch-tailwind
Then open http://localhost:3000/discover. With no engine configured it serves mock
data; set TANGLED_DISCOVER_ENDPOINT to point at the real recommendation service.
Built on Tangled#
Tangled is a code-collaboration platform built on the
AT Protocol; this project extends its appview. Upstream:
Security issues in Tangled itself: security@tangled.org.