Skip to content

feat(www): step-by-step guides with screenshots and videos, part 1 of 4 - #2428

Merged
MODSetter merged 3 commits into
devfrom
feat/tutorial-guides
Nov 10, 2026
Merged

MODSetter merged 3 commits into
devfrom
feat/tutorial-guides

Conversation

@MODSetter

@MODSetter MODSetter commented Nov 10, 2026 •

Copy link
Copy Markdown
Owner

What

The first of the tutorial PRs in plans/community-local/tutorials.md: eight step-by-step guides on the site, and the tooling that captures them from the real app.

  • Guides at /docs/v2/guides: set up SurfSense, run a model on your computer, use a model from a server or provider, add files and folders, ask a question and check its citations, choose which sources to use, add web pages and YouTube videos, and workspaces. Each one is a short silent video above numbered steps, with a screenshot of SurfSense for every step (2× WebP, 2.1 MB for all eight).
  • Capture tooling in www/scripts/guides/. capture.mjs boots a throwaway SurfSense: the same sidecars Electron boots, on a data folder of its own. It does not use headless/main.ts, which sets HF_HUB_OFFLINE and the Docker runtime. It drives the built renderer in Chromium with the Electron bridge stubbed. Each walkthrough writes its screenshots and records its video in the same run. The video gets a drawn pointer and a caption line, the screenshot frames are cut out, and model waits are sped up. upload-videos.mjs puts the videos on Vercel Blob under content-hashed names.
  • Site: "Tutorials" leads the Resources menu and the footer's Resources column, /tutorials redirects to the hub, and the reference pages (Sources, Chat, Workspaces, Local models, API providers, Quick start) link to their guides.
  • Quick start fix: it described an optional-models step that setup no longer has (since 4485896), and said to click Use after a download; the model is now in use as soon as it downloads.

The demo documents are three NIST publications, public domain, fetched and checked against the sha256 in demo-documents/manifest.json; none is committed. The web guide uses a NIST page and NIST's own CSF 2.0 video. Answers come from Qwen3.8 27B through OpenRouter. The server walkthrough types a placeholder into the key field, and the request that saves the server carries OPENROUTER_API_KEY instead, so no key is typed or shown.

Why

The maintainer asked for tutorial videos and step-by-step screenshot guides for everything SurfSense does, on the site and in the app. This PR covers getting started, sources and chat. Studio, the agent, plugins, voice, jobs and settings follow in three more site PRs, then the in-app links.

The videos are on the site's Vercel Blob store: upload-videos.mjs uploaded all 27 takes on 10 Nov 2026 and listed them in features/guides/guide-videos.json, so the unit test "every guide video is hosted" passes.

Found while capturing: searxng.surfsense.com answers with zero results, because every engine behind it reports "Suspended: proxy error". So the search half of Add from the web finds nothing right now. The web guide uses pasted links instead.

Fixes # (none: asked in chat)

How to test

  • cd www && pnpm test:unit: 195 of 196 pass; the one failure is the video upload check above.
  • cd www && pnpm build: passes, and prerenders the hub and the eight guides.
  • Open /docs/v2/guides and a guide, such as /docs/v2/guides/ask-and-cite.
  • To capture again, from www, with surfsense_local/frontend built (pnpm translations, then vite build) and OPENROUTER_API_KEY set: node scripts/guides/capture.mjs --fresh, or name walkthroughs to retake only those. In a worktree, point GUIDES_RUNTIMES_DIR and GUIDES_MODELS_DIR at a checkout with staged runtimes and bundled models.
  • Then BLOB_READ_WRITE_TOKEN=… node scripts/guides/upload-videos.mjs.

High-level PR Summary

This PR adds eight step-by-step tutorial guides with silent videos and screenshots to the SurfSense website. The guides cover getting started tasks like setup, running models locally, connecting to API providers, adding sources, asking questions, and managing workspaces. Each guide includes a short video and numbered steps with 2× WebP screenshots. The implementation includes sophisticated capture tooling that boots a throwaway SurfSense instance and uses Playwright to automate walkthroughs, recording videos with drawn pointers and captions while capturing screenshots. Videos are uploaded to Vercel Blob storage with content hashing. The guides are accessible from the Resources menu and footer, with cross-links from relevant documentation pages. A minor fix updates the Quick start guide to reflect recent setup flow changes.

⏱️ Estimated Review Time: 30-90 minutes

💡 Review Order Suggestion
Order File Path
1 plans/community-local/tutorials.md
2 www/AGENTS.md
3 www/scripts/guides/capture.mjs
4 www/scripts/guides/app/boot-app.mjs
5 www/scripts/guides/app/bridge.mjs
6 www/scripts/guides/capture/walkthrough-session.mjs
7 www/scripts/guides/walkthroughs/index.mjs
8 www/scripts/guides/walkthroughs/set-up.mjs
9 www/scripts/guides/walkthroughs/local-model.mjs
10 www/scripts/guides/walkthroughs/connect-a-server.mjs
11 www/scripts/guides/walkthroughs/add-sources.mjs
12 www/scripts/guides/walkthroughs/ask-and-cite.mjs
13 www/scripts/guides/walkthroughs/pick-sources.mjs
14 www/scripts/guides/walkthroughs/add-from-the-web.mjs
15 www/scripts/guides/walkthroughs/workspaces.mjs
16 www/scripts/guides/walkthroughs/new-chat.mjs
17 www/scripts/guides/walkthroughs/open-settings.mjs
18 www/scripts/guides/demo-documents/fetch-demo-documents.mjs
19 www/scripts/guides/demo-documents/manifest.json
20 www/scripts/guides/media/edit-video.mjs
21 www/scripts/guides/media/png-to-webp.mjs
22 www/scripts/guides/media/run-ffmpeg.mjs
23 www/scripts/guides/page/overlay.mjs
24 www/scripts/guides/upload-videos.mjs
25 www/features/guides/guide-video.tsx
26 www/features/guides/guide-videos.json
27 www/features/guides/guides-content.test.ts
28 www/content/docs/v2/guides/index.mdx
29 www/content/docs/v2/guides/meta.json
30 www/content/docs/v2/guides/set-up.mdx
31 www/content/docs/v2/guides/local-model.mdx
32 www/content/docs/v2/guides/connect-a-server.mdx
33 www/content/docs/v2/guides/add-sources.mdx
34 www/content/docs/v2/guides/ask-and-cite.mdx
35 www/content/docs/v2/guides/pick-sources.mdx
36 www/content/docs/v2/guides/add-from-the-web.mdx
37 www/content/docs/v2/guides/workspaces.mdx
38 www/content/docs/v2/meta.json
39 www/content/docs/v2/quick-start.mdx
40 www/content/docs/v2/sources.mdx
41 www/content/docs/v2/chat.mdx
42 www/content/docs/v2/workspaces.mdx
43 www/content/docs/v2/models/local.mdx
44 www/content/docs/v2/models/api-providers.mdx
45 www/features/site-navigation/site-navigation.ts
46 www/features/site-navigation/site-navigation.test.ts
47 www/components/site/site-content.ts
48 www/components/ui/icons.tsx
49 www/mdx-components.tsx
50 www/next.config.mts
51 www/features/docs/source.ts
52 www/package.json
53 www/pnpm-lock.yaml
54 .pre-commit-config.yaml

Need help? Join our Discord

scripts/guides/capture.mjs boots the sidecars Electron boots, on a data
folder of its own, serves the built renderer, and drives it in Chromium with
the Electron bridge stubbed. Each walkthrough writes its screenshots as 2x
WebP into public/guides/<slug>/ and records its video in the same run: a
drawn pointer and a one-line caption, the screenshot frames cut out, and long
waits on a model played faster. upload-videos.mjs puts the videos on Vercel
Blob under content-hashed names.

The demo documents are public NIST publications, fetched from their source
and checked against the sha256 in demo-documents/manifest.json; none is
committed. The server walkthrough types a placeholder key and swaps in
OPENROUTER_API_KEY on the request, so no key is typed or shown.

The plan the maintainer agreed is plans/community-local/tutorials.md.
…s link

/docs/v2/guides holds one guide per task, each a video above numbered steps
with a screenshot of SurfSense for every step: set up, run a model on your
computer, use a server or provider, add files and folders, ask and check
citations, choose sources, add web pages and YouTube videos, and workspaces.
The hub sits under Overview in the docs sidebar, Tutorials leads the
Resources menu and footer, /tutorials redirects to it, and the reference
pages point to their guides.

GuideVideo plays a guide's video from guide-videos.json, loading nothing
until the reader presses play. guides-content.test.ts holds every shot to
250 KB with alt text, every video to the Blob store, and public/guides to
pictures a page shows.

Quick start described an optional-models step that setup no longer has, and
said to click Use after a download, which now makes the model the one in use.
@vercel

vercel Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
surf-sense-frontend Ignored Ignored Preview Nov 10, 2026 8:10am UTC

Request Review

@coderabbitai

coderabbitai Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

Explain Change →

Caution

Review failed

The pull request is closed.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

upload-videos.mjs put all 27 takes on the site's Blob store, so every guide
page now plays its video, and the check that every guide video is hosted
passes.
@MODSetter
MODSetter marked this pull request as ready for review November 10, 2026 08:18
@MODSetter
MODSetter merged commit acebff4 into dev Nov 10, 2026
58 of 59 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant