Skip to content

feat: refresh frontend and remove legacy research ui#415

Merged
CJBshuosi merged 1 commit into
jerry609:paperbot_v01from
CJBshuosi:paperbot-design-refresh
May 8, 2026
Merged

feat: refresh frontend and remove legacy research ui#415
CJBshuosi merged 1 commit into
jerry609:paperbot_v01from
CJBshuosi:paperbot-design-refresh

Conversation

@CJBshuosi

Copy link
Copy Markdown
Collaborator

No description provided.

@CJBshuosi
CJBshuosi requested a review from jerry609 as a code owner May 8, 2026 14:37
@vercel

vercel Bot commented May 8, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
paper-bot Ready Ready Preview, Comment May 8, 2026 2:39pm

@coderabbitai

coderabbitai Bot commented May 8, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: b9384050-c9de-4922-bae0-bbca87062849

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


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

Comment @coderabbitai help to get the list of available commands and usage tips.

@CJBshuosi
CJBshuosi merged commit 585f752 into jerry609:paperbot_v01 May 8, 2026
3 of 4 checks passed

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request performs a comprehensive redesign and refactoring of the PaperBot Web UI, including the dashboard, research workspace, and authentication flows. It introduces new documentation for testing and UI tracking, as well as components for managing research tracks and paper collections. Feedback focuses on ensuring a professional and consistent tone throughout the UI, replacing placeholder labels with context-relevant data, and improving performance and error handling in data-fetching logic.

Dashboard
</div>
<h1 className="mt-2 text-[36px] font-bold leading-[1.1] tracking-[-0.025em] text-[#0a0a0a]">
Oh, God! 你回来了!

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The UI contains a mix of English and Chinese, and the tone of this greeting is quite informal compared to the rest of the application. It is recommended to maintain a consistent language and professional tone throughout the interface.

Suggested change
Oh, God! 你回来了!
Welcome back!

<div className="flex justify-center gap-6 pt-3.5">
<span className="inline-flex items-center gap-1.5 text-[12px] text-[#0a0a0a]">
<span className="h-2 w-2 rounded-[2px] bg-[#0a0a0a]" />
Mobile

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The label 'Mobile' appears to be a placeholder from a generic dashboard template and does not align with the context of a research paper bot. It should be updated to reflect relevant data categories, such as 'Prompt Tokens'.

Suggested change
Mobile
Prompt Tokens

</span>
<span className="inline-flex items-center gap-1.5 text-[12px] text-[#0a0a0a]">
<span className="h-2 w-2 rounded-[2px] bg-[#737373]" />
Desktop

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The label 'Desktop' appears to be a placeholder. It should be updated to reflect data relevant to the research bot, such as 'Completion Tokens'.

Suggested change
Desktop
Completion Tokens

cache: "no-store",
headers: accessToken ? { Authorization: `Bearer ${accessToken}` } : undefined,
})
if (!res.ok) return []

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

Returning an empty array on a failed fetch request silently masks potential issues (e.g., 401 Unauthorized or 500 Internal Server Error). Consider logging the error or throwing it so it can be handled by an error boundary or reported to the user.

  if (!res.ok) {
    console.error("Failed to fetch saved papers: " + res.status + " " + res.statusText);
    return [];
  }

Comment on lines +270 to +277
for (const paper of visiblePapers) {
const res = await fetch(`/api/research/collections/${selectedCollectionId}/items`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ paper_id: String(paper.id) }),
})
if (!res.ok) throw new Error(await res.text().catch(() => `${res.status}`))
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

Executing API requests sequentially within a loop can lead to poor performance, especially as the number of papers increases. Consider using Promise.all to execute these requests in parallel for better efficiency.

Suggested change
for (const paper of visiblePapers) {
const res = await fetch(`/api/research/collections/${selectedCollectionId}/items`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ paper_id: String(paper.id) }),
})
if (!res.ok) throw new Error(await res.text().catch(() => `${res.status}`))
}
await Promise.all(visiblePapers.map(async (paper) => {
const res = await fetch("/api/research/collections/" + selectedCollectionId + "/items", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ paper_id: String(paper.id) }),
})
if (!res.ok) throw new Error(await res.text().catch(() => String(res.status)))
}))

@sonarqubecloud

sonarqubecloud Bot commented May 8, 2026

Copy link
Copy Markdown

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