smithery.ai

chatbot-implementation

Details of the RAG Chatbot, including UI and backend logic.

First seen Mar 24, 2026

Installation

$ npx skills add https://smithery.ai

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from smithery.ai · top by installs.

npx skills add https://smithery.ai

Browse all from smithery.ai

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Declared
Cline Not declared
OpenCode Not declared

Skill metadata

Parsed from SKILL.md frontmatter.

Declared agents gemini

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 1,247 B
  • docs SUMMARY.md 89 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 2 installs

SKILL.md

Chatbot Logic

Overview

A specialized RAG (Retrieval Augmented Generation) chatbot that helps users learn from the textbook content.

Backend

  • Route: app/api/chat/route.ts
  • Logic:

1. Receives query and history. 2. Embeds query using Gemini or OpenAI embedding model. 3. Searches Qdrant (vector DB) for relevant textbook chunks. 4. Constructs context from matches. 5. Generates response using Gemini Flash/Pro.

Vector Search (Qdrant)

We use Qdrant for storing embeddings of the textbook.

  • Collection: textbook_chunks (or similar).
  • Fields: text, source, chunk_id.

UI Component

  • Location: textbook/src/components/Chatbot/index.tsx.
  • Features:

- Floating chat window. - Size controls (Small, Medium, Large). - Markdown rendering of responses. - Context selection (highlight text to ask about it). - Mobile responsive design. - Auth awareness (personalizes answer based on user profile).

Styling

  • CSS: styles.module.css (Premium animations, shadow effects).
  • Themes: Dark/Light mode compatible (using --ifm variables).