Skip to content

feat(onboarding): sign in with alphaXiv instead of a research profile - #895

Merged
alphaxiv-bot[bot] merged 6 commits into
mainfrom
myles/alphaxiv-onboarding-signin
Nov 5, 2026
Merged

alphaxiv-bot[bot] merged 6 commits into
mainfrom
myles/alphaxiv-onboarding-signin

Conversation

@myles332

@myles332 myles332 commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

The last onboarding step no longer asks for a research profile. It offers Continue with alphaXiv ("Bring your alphaXiv library"): optional, it lets you add library papers to chats and personalizes starter prompts. Signing in finishes onboarding and opens the demo; Skip finishes without it.

  • Connection state. "Linked" means alphaXiv confirmed the connection through the new loopback route GET /api/alphaxiv/me, which also returns the avatar. An OpenResearch account without an alphaXiv connection gets the connect-only sign-in.
  • Starter prompts. Blank-project starter prompts are briefed from the user's public alphaXiv profile: /users/v3/{sub} (institution, bio), followed topics, and the researcher card's areas and headline. The desktop token is only accepted on library routes, so private data (claimed papers) isn't reachable. The result is remembered for 10 min per user. If it's missing or times out (5 s), the brief falls back to the profile saved by older onboarding.
  • Compatibility. complete_onboarding treats no research areas as no profile, so a saved profile is never erased. Old clients still send areas and behave as before. The UI's profile client is removed, but the /api/settings/profile routes stay as a shipped contract.
  • Docs. arc/storage.md lists the new alphaXiv reads, and notes that the profile reaches the agent's model provider through starter prompts.

Known gap: a sparse public profile wins over a richer saved one (e.g. an institution alone). This is accepted for now.

Closes ORX-320

Test plan

  • cargo fmt --check, cargo clippy --all-targets -D warnings, cargo build --locked
  • cargo test --locked: 1365 pass. 3 Codex/OpenCode tests fail the same way on clean origin/main on this machine (environment-dependent)
  • UI: tsc, lint:i18n, lint:styles, pnpm test (627 pass), including new Skip / Get started / connect-only / sign-in-finishes cases
  • alphaXiv mock test covers profile mapping and the avatar thumbnail preference. A live public GET /users/v3/{sub} confirmed the token's sub is the alphaXiv user id
  • Dev desktop app: the step renders, signed out
  • Fresh onboarding: sign in with alphaXiv, then the demo opens without clicking Get started
  • Sign-up path for someone with no alphaXiv account
  • Signed-in avatar shows (account with an avatar)
  • OpenResearch account without an alphaXiv connection, then connect-only sign-in
  • Blank project after linking shows tailored starter prompts
  • Remote machine agent setup unchanged

🤖 Generated with Claude Code

myles332 and others added 4 commits November 4, 2026 18:10
Assisted-by: claude-opus-5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ile client, egress docs

Assisted-by: claude-opus-5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Assisted-by: claude-opus-5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The PR changes local onboarding and the source of blank-project starter prompts.

The PR appears safe to merge, with a non-blocking fix recommended for connection-check errors.

Findings

  1. P2 Connection errors restart full login ▶
Fix with agent prompt
### Issue 1
ui/src/components/Onboarding.tsx:93-94
When `/api/alphaxiv/me` times out or returns a server error, an existing OpenResearch user sees a sign-in button with `connectOnly=false`. Clicking it starts full login, which replaces their OpenResearch credentials. If the browser uses a different alphaXiv account, this can switch their OpenResearch account too. Show the failed check with a retry action instead of treating the user as signed out.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Summary

Replaces the research-profile onboarding form with optional alphaXiv sign-in.

  • Onboarding offers alphaXiv sign-in or Skip before opening the demo.
  • Blank projects can use public alphaXiv details to shape starter prompts.
  • Finishing onboarding without research areas preserves an older saved profile.

Acknowledged by myles332: a sparse public profile can override a richer saved profile. This is accepted for now and is not reported.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Finish agent setup] --> B[Optional alphaXiv step]
  B --> C[Sign in]
  B --> D[Skip or Get started]
  C --> E[Complete onboarding]
  D --> E
  E --> F[Open demo]
  G[Open blank project] --> H[Read public alphaXiv profile]
  H --> I{Useful profile within five seconds?}
  I -->|Yes| J[Build starter prompt brief]
  I -->|No| K[Load saved profile]
  K --> J
Loading

Reviews (1) · Last reviewed commit: "fix(onboarding): address review round 2 ..." · Reviewed by Greptile

Comment on lines +93 to +94
const connectOnly = !!user && alphaXivMe.error instanceof AlphaXivNotConnectedError;
const alphaXivLinked = !!user && alphaXivMe.isSuccess;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Connection errors restart full login

When /api/alphaxiv/me times out or returns a server error, an existing OpenResearch user sees a sign-in button with connectOnly=false. Clicking it starts full login, which replaces their OpenResearch credentials. If the browser uses a different alphaXiv account, this can switch their OpenResearch account too. Show the failed check with a retry action instead of treating the user as signed out.

Prompt To Fix With AI
This is a comment left during a code review.
Path: ui/src/components/Onboarding.tsx
Line: 93-94

Comment:
**Connection errors restart full login**

When `/api/alphaxiv/me` times out or returns a server error, an existing OpenResearch user sees a sign-in button with `connectOnly=false`. Clicking it starts full login, which replaces their OpenResearch credentials. If the browser uses a different alphaXiv account, this can switch their OpenResearch account too. Show the failed check with a retry action instead of treating the user as signed out.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Assisted-by: claude-opus-5.5

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@myles332 myles332 added the auto-merge Queue for automatic merge once all checks pass label Nov 5, 2026
@alphaxiv-bot
alphaxiv-bot Bot merged commit 73e21fd into main Nov 5, 2026
12 checks passed
@alphaxiv-bot
alphaxiv-bot Bot deleted the myles/alphaxiv-onboarding-signin branch November 5, 2026 20:18
small-angel added a commit that referenced this pull request Nov 5, 2026
Ports the onboarding tests and the e2e onboarding spec to #895's alphaXiv step.

Assisted-by: claude-opus-5.5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-merge Queue for automatic merge once all checks pass

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant