Skip to content

feat(reputation): vendor reputation system with verified reports feed (#5)#160

Open
saidai-bhuvanesh wants to merge 6 commits into
jpdevhub:mainfrom
saidai-bhuvanesh:feat/vendor-reputation
Open

feat(reputation): vendor reputation system with verified reports feed (#5)#160
saidai-bhuvanesh wants to merge 6 commits into
jpdevhub:mainfrom
saidai-bhuvanesh:feat/vendor-reputation

Conversation

@saidai-bhuvanesh

@saidai-bhuvanesh saidai-bhuvanesh commented Jul 3, 2026

Copy link
Copy Markdown

🔗 Upstream Issue Connection

Closes #159

This Pull Request is officially linked to and resolves Issue #159 (Feature 5: Vendor Reputation System with Reviews & Verification) in the upstream repository.

Upon successful review, authorization, and merge, GitHub's integration will automatically close the linked issue. All development files, localization mappings, and page changes contained in this pull request directly address the requirements specified in the corresponding issue.


What changes are made?

  1. Interactive Detail Panel: Clicking any vendor in the Leaderboard page (src/pages/Leaderboard.tsx) now opens an interactive details drawer, presenting vendor trust scores, address, total scans, and trust status.
  2. Verified Consumer Reports Feed: Added a verified reports feed for each vendor showing details of bought fish freshness or general feedback reports.
  3. Reputation Submission Form: Integrated an interactive form in the drawer allowing consumers to report any freshness discrepancies or disputes.
  4. Backend Review Endpoints (backend/vendors.py): Added GET /{vendor_id}/reviews and POST /{vendor_id}/reviews to list and create user reviews in an in-memory database fallback.
  5. Robust Optional Authentication: Configured the POST review endpoint on the backend to dynamically parse credentials from Request headers and gracefully fallback to "Anonymous Consumer" if the user is unauthenticated, avoiding hard API crashes.
  6. I18n Localization: Translated all new vendor detail headers, report submission text, and review elements to English, Hindi, and Bengali locales.

Technical Depth and Verification

The reputation system enhances marketplace integrity. The backend routes handle both authenticated and guest submissions, automatically assigning authorship based on JWT tokens or falling back to "Anonymous Consumer" securely. The leaderboard page now functions as a trust portal, loading historical verified reports dynamically when a vendor is selected.

Verified reviews submissions on the vendor details panel. Submitting ratings immediately updates the real-time list of reports, showing translated titles and dates correctly.

@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the karan3431's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions

github-actions Bot commented Jul 3, 2026

Copy link
Copy Markdown

⚠️ No linked issue found!
This PR cannot be reviewed until a related issue is linked.
Please add Closes #issue_number in your PR description.

@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@saidai-bhuvanesh, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 46 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: c9c761e6-db5c-4960-b564-a299631e642c

📥 Commits

Reviewing files that changed from the base of the PR and between 97c6f33 and f13c8ea.

📒 Files selected for processing (12)
  • backend/main.py
  • backend/vendors.py
  • src/components/AnalyticsTrends.tsx
  • src/fusionInference.js
  • src/i18n/locales/bn.json
  • src/i18n/locales/en.json
  • src/i18n/locales/hi.json
  • src/lib/api.ts
  • src/lib/offlineDb.ts
  • src/pages/AnalysisDashboard.tsx
  • src/pages/Leaderboard.tsx
  • src/pages/ScannerPage.tsx
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature 5: Vendor Reputation System with Reviews & Verification

1 participant